Build improvements, no change to end result.

Remove useless 'pre-configure' target; it did nothing
but modify a comment.

Remove uneccessary 'tclsh' patching and always specify 'TCLSH_CMD'
and 'TCLLIBDIR'.
Sqlite3's configurator will now no longer look for various tclsh's,
or attempt to determine 'TCLLIBDIR' by running a tclsh, which it was
doing even with the 'no_tcl' flavour.

Moved some things from CONFIGURE_ENV to CONFIGURE_ARGS because it looks
cleaner/a tad less complicated to me, and works the same.

Some tidying. Whitespace diff may follow.


Problem: OpenBSD's libtool does this:
"warning: dependency on tclstub85_pic dropped"
which is not good, since libtclsqlite3.so needs to
be linked against the stub lib.
I don't know how to fix this. Help! ;)



Index: databases/sqlite3/Makefile
===================================================================
RCS file: /cvs/ports/databases/sqlite3/Makefile,v
retrieving revision 1.53
diff -u -p -r1.53 Makefile
--- databases/sqlite3/Makefile  15 Nov 2010 00:22:54 -0000      1.53
+++ databases/sqlite3/Makefile  21 Nov 2010 15:50:21 -0000
@@ -34,7 +34,8 @@ CFLAGS+=      -DSQLITE_ENABLE_COLUMN_METADATA
 CONFIGURE_STYLE=gnu
 CONFIGURE_ARGS+=${CONFIGURE_SHARED} \
                --enable-threads-override-locks \
-               --enable-load-extension
+               --enable-load-extension \
+               TCLLIBDIR="${MODTCL_LIBDIR}/sqlite3"

 PSEUDO_FLAVORS=        no_tcl
 .if ${MACHINE_ARCH} != "m88k" && ${MACHINE_ARCH} != "vax"
@@ -54,17 +55,13 @@ LIB_DEPENDS-tcl = ${BUILD_PKGPATH},-main
 WANTLIB-tcl =  sqlite3

 .if ${MULTI_PACKAGES:M-tcl}
-CONFIGURE_ARGS+=--with-tcl=${MODTCL_LIBDIR}
-
-REGRESS_TARGET=        test
-
-pre-configure:
-       @perl -pi -e s,'tclsh',${MODTCL_BIN},g ${WRKSRC}/Makefile.in
-
+CONFIGURE_ARGS += --with-tcl="${MODTCL_LIBDIR}" \
+               TCLSH_CMD="${MODTCL_BIN}"
+REGRESS_TARGET = test
 .else
-CONFIGURE_ARGS+=--disable-tcl
-CONFIGURE_ENV += TCLSH_CMD=none
-NO_REGRESS=    Yes
+CONFIGURE_ARGS += --disable-tcl \
+               TCLSH_CMD=none
+NO_REGRESS =   Yes
 .endif

 # Don't include dependency on pthreads, weak pthread functions are
Index: databases/sqlite3/patches/patch-configure
===================================================================
RCS file: /cvs/ports/databases/sqlite3/patches/patch-configure,v
retrieving revision 1.9
diff -u -p -r1.9 patch-configure
--- databases/sqlite3/patches/patch-configure   2 Apr 2010 20:07:11 -0000       
1.9
+++ databases/sqlite3/patches/patch-configure   21 Nov 2010 15:50:21 -0000
@@ -1,15 +1,6 @@
 $OpenBSD: patch-configure,v 1.9 2010/04/02 20:07:11 sthen Exp $
---- configure.orig     Mon Apr 13 12:09:25 2009
-+++ configure  Thu Apr 16 23:11:23 2009
-@@ -12259,7 +12259,7 @@ USE_AMALGAMATION=1
- # if not, then we fall back to plain tclsh.
- # TODO: try other versions before falling back?
- #
--for ac_prog in tclsh8.4 tclsh
-+for ac_prog in tclsh8.5 tclsh8.4 tclsh
- do
-   # Extract the first word of "$ac_prog", so it can be a program name with 
args.
- set dummy $ac_prog; ac_word=$2
+--- configure.orig     Mon Mar  8 10:08:54 2010
++++ configure  Sat Nov 20 14:53:14 2010
 @@ -12498,8 +12498,8 @@ for ac_lib in '' pthread; do
    if test -z "$ac_lib"; then
      ac_res="none required"

Reply via email to