Date: Thu, 24 Mar 2011 00:54:06 -0700 (PDT) From: Baptiste Daroussin <bapt@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/155908: [PATCH] use sqlite3-autoconf instead of the deprecated sqlite3-src Message-ID: <4d8af89e.0504d90a.50b3.4bd2@mx.google.com> Resent-Message-ID: <201103240820.p2O8K1Wq077996@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 155908 >Category: ports >Synopsis: [PATCH] use sqlite3-autoconf instead of the deprecated sqlite3-src >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Mar 24 08:20:01 UTC 2011 >Closed-Date: >Last-Modified: >Originator: Baptiste Daroussin >Release: FreeBSD 8.2-STABLE amd64 >Organization: >Environment: System: FreeBSD azathoth.lan 8.2-STABLE FreeBSD 8.2-STABLE #0 r219454M: Thu Mar 10 20:09:22 CET 2011 root@azathoth.lan:/usr/obj/usr/src/sys/AZATHOTH amd64 >Description: database/sqlite3 uses the deprecated and not recommanded sqlite3-src instead of sqlite3-autoconf. One of the main difference with sqlite3-src is that it doesn't provide the tcl interface, but a new sqlite3-tea exists to fit that purpose (a shar can be found here: http://people.freebsd.org/~bapt/sqlite3-tea.shar) If maintainer wanted I can take maintainership on databases/sqlite3 or at his discretion give to him the maintainership on sqlite3-tea. regards, bapt >How-To-Repeat: >Fix: --- sqlite3-autoconf.diff begins here --- Index: Makefile =================================================================== RCS file: /home/pcvs/ports/databases/sqlite3/Makefile,v retrieving revision 1.55 diff -u -r1.55 Makefile --- Makefile 4 Mar 2011 14:00:56 -0000 1.55 +++ Makefile 23 Mar 2011 12:16:14 -0000 @@ -7,41 +7,30 @@ PORTNAME= sqlite3 PORTVERSION= 3.7.5 +PORTREVISION= 1 CATEGORIES= databases MASTER_SITES= http://www.sqlite.org/ http://www2.sqlite.org/ -DISTNAME= sqlite-src-3070500 +DISTNAME= sqlite-autoconf-3070500 MAINTAINER= pavelivolkov@googlemail.com COMMENT= An SQL database engine in a C library -LICENSE= unknown +LICENSE= public LICENSE_NAME= Public Domain LICENSE_PERMS= ${_LICENSE_PERMS_DEFAULT} LICENSE_TEXT= Description of the license can be obtained from the following URL: http://www.sqlite.org/copyright.html CONFLICTS= sqlite34-[0-9]* -USE_ZIP= YES -USE_GMAKE= YES USE_GNOME= pkgconfig gnomehack USE_LDCONFIG= YES GNU_CONFIGURE= YES -USE_TCL_BUILD= 84+ -CONFIGURE_ENV+= TCLSH_CMD="${TCLSH}" \ - TCLLIBDIR="${PREFIX}/lib/${PORTNAME}" \ - ac_cv_search_pthread_create="" - -# Use an in-ram database for temporary tables (never,no,yes,always), -# which is equivalent of SQLITE_TEMP_STORE=[0,1,2,3] -RAMTABLE?= yes - # Compilation Options For SQLite http://www.sqlite.org/compile.html OPTIONS= \ FTS3 "Enable FTS3/4 (Full Text Search) module" on \ ICU "Enable built with ICU" off \ RTREE "Enable R*Tree module" off \ - RAMTABLE "Store temporary tables in RAM = ${RAMTABLE}" off \ UPD_DEL_LIMIT "ORDER BY and LIMIT on UPDATE and DELETE" off \ SOUNDEX "Enables the soundex() SQL function" off \ METADATA "Enable column metadata" on \ @@ -50,45 +39,18 @@ SECURE_DELETE "Overwrite deleted information with zeros" on \ UNLOCK_NOTIFY "Enable notification on unlocking" on \ THREADSAFE "Build thread-safe library" on \ - EXTENSION "Allow loadable extensions" on \ - TCLWRAPPER "Enable TCL wrapper" off \ + EXTENSION "Allow loadable extensions" on .include <bsd.port.options.mk> PLIST_FILES= bin/sqlite3 include/sqlite3.h include/sqlite3ext.h \ lib/libsqlite3.a lib/libsqlite3.la lib/libsqlite3.so \ lib/libsqlite3.so.8 libdata/pkgconfig/sqlite3.pc -PORTDOCS= * .if !defined(NO_INSTALL_MANPAGES) MAN1= sqlite3.1 .endif -.if ${OSVERSION} < 700000 -EXTRA_PATCHES+= ${FILESDIR}/pthread_equal_stub -.endif - -# DEBUG "Enable debugging & verbose explain" off \ -# This options used only for debug and is not required during normal work -# applications or its libraries. -# This options can be specified on the command line. -# Execute: make -D WITH_DEBUG ... -.if defined(WITH_DEBUG) -CONFIGURE_ARGS+= --enable-debug -CFLAGS+= -Wall -.endif - -# GCOV "Enable coverage testing using gcov/gprof" off \ -# These options are only used for debugging, profiling the application. -# And can cause errors when using the application or its libraries in other -# products (for example build security/nss is BROKEN). -# This options can be specified on the command line. -# Execute: make -D WITH_GCOV ... -.if defined(WITH_GCOV) -CONFIGURE_ARGS+= --enable-gcov -LDFLAGS+= -fstack-protector -.endif - # By default, the sqlite3_step() interface will automatically invoke # sqlite3_reset() to reset the prepared statement if necessary. This # compile-time option changes that behavior so that sqlite3_step() will @@ -141,10 +103,6 @@ LDFLAGS+= `${LOCALBASE}/bin/icu-config --ldflags` .endif -.if defined(WITH_RAMTABLE) -CONFIGURE_ARGS+= --enable-tempstore=${RAMTABLE} -.endif - .if defined(WITH_SECURE_DELETE) CFLAGS+= -DSQLITE_SECURE_DELETE=1 .endif @@ -153,21 +111,6 @@ CFLAGS+= -DSQLITE_ENABLE_UNLOCK_NOTIFY=1 .endif -.if defined(WITH_TCLWRAPPER) -CATEGORIES+= lang tcl -COMMENT+= with TCL Wrapper -USE_TCL_RUN= yes -ALL_TARGET= all tclsqlite3 -INSTALL_TARGET= install tcl_install -CONFIGURE_ARGS+= --with-tcl=${TCL_LIBDIR} -PORTEXAMPLES+= example.tcl -PLIST_DIRS+= lib/sqlite3 -PLIST_FILES+= bin/tclsqlite3 lib/sqlite3/libtclsqlite3.so \ - lib/sqlite3/pkgIndex.tcl -.else -CONFIGURE_ARGS+= --disable-tcl -.endif - .if !defined(WITHOUT_METADATA) CFLAGS+= -DSQLITE_ENABLE_COLUMN_METADATA=1 .endif @@ -179,63 +122,21 @@ .endif .if !defined(WITHOUT_EXTENSION) -CONFIGURE_ARGS+= --enable-load-extension +CONFIGURE_ARGS+= --enable-dynamic-extensions .else -CONFIGURE_ARGS+= --disable-load-extension +CONFIGURE_ARGS+= --enable-dynamic-extensions .endif -CONFIGURE_ENV+= CPPFLAGS="-I. -I./src ${CPPFLAGS}" LDFLAGS="${LDFLAGS}" -MAKE_ENV+= CPPFLAGS="-I. -I./src ${CPPFLAGS}" LDFLAGS="${LDFLAGS}" +CONFIGURE_ENV+= LDFLAGS="${LDFLAGS}" .include <bsd.port.pre.mk> -.if defined(TCL_VER) && ${TCL_VER} > 8.4 -BUILD_DEPENDS+= ${LOCALBASE}/lib/tcl8/${TCL_VER}:${PORTSDIR}/lang/tcl-modules -.if defined(WITH_TCLWRAPPER) -RUN_DEPENDS+= ${LOCALBASE}/lib/tcl8/${TCL_VER}:${PORTSDIR}/lang/tcl-modules -.endif -.endif - -# To test you must specify the value of TESTUSER variable. -# It must correspond to a normal (not root) user, from which it will be tested. -# Execute: make TESTUSER=ordinary_user_login_name test -.ifmake test -.ifndef TESTUSER -IGNORE= set the value of the variable TESTUSER corresponding normal (not root) user, from which will be tested -.endif -.ifndef WITH_TCLWRAPPER -IGNORE= for the purpose of test you want to include TCL wrapper -.endif -.endif - -test: build - @(cd ${WRKSRC} && ${CHOWN} -R ${TESTUSER} ${WRKSRC} && su ${TESTUSER} -c "${MAKE} test"; ${CHOWN} ${USER} ${WRKSRC}) - -post-build: - @${ECHO_CMD} - @${ECHO_CMD} "You can test sqlite using supplied with the him tests." - @${ECHO_CMD} "Execute: make TESTUSER=ordinary_user_login_name test" +post-patch: + @${REINPLACE_CMD} "s,^pkgconfigdir = .*$$,pkgconfigdir = ${PREFIX}/libdata/pkgconfig,g" ${WRKSRC}/Makefile.in post-install: -.if defined(WITH_TCLWRAPPER) - @${INSTALL_PROGRAM} ${WRKSRC}/.libs/tclsqlite3 ${PREFIX}/bin - @${MKDIR} ${EXAMPLESDIR} - @${INSTALL_DATA} ${FILESDIR}/example.tcl ${EXAMPLESDIR} -.endif .if !defined(NO_INSTALL_MANPAGES) @${INSTALL_MAN} ${WRKSRC}/sqlite3.1 ${MANPREFIX}/man/man1 .endif -.ifndef NOPORTDOCS - @${MKDIR} ${DOCSDIR} -.ifdef WITH_FTS3 - @${INSTALL_DATA} ${WRKSRC}/ext/fts3/README.syntax ${WRKSRC}/ext/fts3/README.tokenizers ${DOCSDIR} -.endif -.ifdef WITH_RTREE - @${INSTALL_DATA} ${WRKSRC}/ext/rtree/README ${DOCSDIR} -.endif -.ifdef WITH_ICU - @${INSTALL_DATA} ${WRKSRC}/ext/icu/README.txt ${DOCSDIR} -.endif -.endif .include <bsd.port.post.mk> Index: distinfo =================================================================== RCS file: /home/pcvs/ports/databases/sqlite3/distinfo,v retrieving revision 1.33 diff -u -r1.33 distinfo --- distinfo 4 Mar 2011 14:00:56 -0000 1.33 +++ distinfo 23 Mar 2011 12:16:14 -0000 @@ -1,2 +1,2 @@ -SHA256 (sqlite-src-3070500.zip) = 1bb838c02b4946c514e28cfcd1c15b0079f8626f5fbcfcf2b48e2a075acc5c51 -SIZE (sqlite-src-3070500.zip) = 3987471 +SHA256 (sqlite-autoconf-3070500.tar.gz) = cb5b86926ec9f65882b2dddd244f2d620337d911ec73411863f77e48cf6a2f94 +SIZE (sqlite-autoconf-3070500.tar.gz) = 1551070 Index: files/patch-Makefile.in =================================================================== RCS file: files/patch-Makefile.in diff -N files/patch-Makefile.in --- files/patch-Makefile.in 22 Apr 2010 15:34:07 -0000 1.11 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ ---- Makefile.in.orig 2009-09-17 13:41:21.000000000 +0200 -+++ Makefile.in 2009-09-17 13:45:38.000000000 +0200 -@@ -687,7 +687,7 @@ - $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/status.c - - sqlite3.h: $(TOP)/src/sqlite.h.in $(TOP)/manifest.uuid $(TOP)/VERSION -- tclsh $(TOP)/tool/mksqlite3h.tcl $(TOP) >sqlite3.h -+ $(TCLSH_CMD) $(TOP)/tool/mksqlite3h.tcl $(TOP) >sqlite3.h - - table.lo: $(TOP)/src/table.c $(HDR) - $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/table.c Index: files/patch-src-os_unix.c =================================================================== RCS file: files/patch-src-os_unix.c diff -N files/patch-src-os_unix.c --- files/patch-src-os_unix.c 1 Sep 2010 17:49:49 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ ---- src/os_unix.c.orig 2010-08-31 10:44:29.000000000 +0400 -+++ src/os_unix.c 2010-08-31 10:44:48.000000000 +0400 -@@ -4841,7 +4841,7 @@ - char *zErr; - UNUSED_PARAMETER(NotUsed); - unixEnterMutex(); -- zErr = dlerror(); -+ zErr = (char *)dlerror(); - if( zErr ){ - sqlite3_snprintf(nBuf, zBufOut, "%s", zErr); - } Index: files/patch-test-backup2.test =================================================================== RCS file: files/patch-test-backup2.test diff -N files/patch-test-backup2.test --- files/patch-test-backup2.test 10 Dec 2010 23:07:55 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ ---- test/backup2.test.orig 2010-12-09 13:44:49.000000000 +0300 -+++ test/backup2.test 2010-12-09 13:45:39.000000000 +0300 -@@ -155,7 +155,7 @@ - file mkdir bu3.db - set rc [catch {db restore temp bu3.db} res] - lappend rc $res -- } {1 {cannot open source database: disk I/O error}} -+ } {1 {restore failed: file is encrypted or is not a database}} - } - - # Try to restore from something that is not a database file. Index: files/pthread_equal_stub =================================================================== RCS file: files/pthread_equal_stub diff -N files/pthread_equal_stub --- files/pthread_equal_stub 2 Nov 2009 10:11:49 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ ---- src/mutex_unix.c.orig 2009-09-18 12:39:33.000000000 +0200 -+++ src/mutex_unix.c 2009-09-18 12:39:04.000000000 +0200 -@@ -326,4 +326,8 @@ - return &sMutex; - } - -+int pthread_equal() __attribute__ ((weak)); -+ -+#define pthread_equal(a,b) ((pthread_equal) ? pthread_equal(a,b) : 1) -+ - #endif /* SQLITE_MUTEX_PTHREAD */ --- sqlite3-autoconf.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4d8af89e.0504d90a.50b3.4bd2>