Ticket #12431: macports-sqlite.diff

File macports-sqlite.diff, 3.2 KB (added by afb@…, 17 years ago)

macports-sqlite.diff

  • databases/sqlite3/files/patch-Makefile.in

     
    11--- Makefile.in 2007-01-08 14:39:27.000000000 +0100
    22+++ Makefile.in 2007-02-12 12:56:16.000000000 +0100
    3 @@ -44,11 +44,11 @@
    4  
    5  # Compiler options needed for programs that use the readline() library.
    6  #
    7 -READLINE_FLAGS = -DHAVE_READLINE=@TARGET_HAVE_READLINE@ @TARGET_READLINE_INC@
    8 +READLINE_FLAGS = -DHAVE_READLINE=1 @CFLAGS@
    9  
    10  # The library that programs using readline() must link against.
    11  #
    12 -LIBREADLINE = @TARGET_READLINE_LIBS@
    13 +LIBREADLINE = @LDFLAGS@ -lreadline
    14  
    15  # Should the database engine be compiled threadsafe
    16  #
    17 @@ -60,7 +60,7 @@
    18  
    19  # Do threads override each others locks by default (1), or do we test (-1)
    20  #
    21 -TCC += -DSQLITE_THREAD_OVERRIDE_LOCK=@THREADSOVERRIDELOCKS@
    22 +TCC += -DSQLITE_THREAD_OVERRIDE_LOCK=@THREADSOVERRIDELOCKS@ -DSQLITE_ENABLE_LOCKING_STYLE=1
    23  
    24  # The fdatasync library
    25  TLIBS = @TARGET_LIBS@
    263@@ -101,7 +101,9 @@
    274 #
    285 prefix = @prefix@
  • databases/sqlite3/files/patch-Makefile.in-darwin

     
     1--- Makefile.in 2007-01-08 14:39:27.000000000 +0100
     2+++ Makefile.in 2007-02-12 12:56:16.000000000 +0100
     3@@ -44,11 +44,11 @@
     4 
     5 # Compiler options needed for programs that use the readline() library.
     6 #
     7-READLINE_FLAGS = -DHAVE_READLINE=@TARGET_HAVE_READLINE@ @TARGET_READLINE_INC@
     8+READLINE_FLAGS = -DHAVE_READLINE=1 @CFLAGS@
     9 
     10 # The library that programs using readline() must link against.
     11 #
     12-LIBREADLINE = @TARGET_READLINE_LIBS@
     13+LIBREADLINE = @LDFLAGS@ -lreadline
     14 
     15 # Should the database engine be compiled threadsafe
     16 #
     17@@ -60,7 +60,7 @@
     18 
     19 # Do threads override each others locks by default (1), or do we test (-1)
     20 #
     21-TCC += -DSQLITE_THREAD_OVERRIDE_LOCK=@THREADSOVERRIDELOCKS@
     22+TCC += -DSQLITE_THREAD_OVERRIDE_LOCK=@THREADSOVERRIDELOCKS@ -DSQLITE_ENABLE_LOCKING_STYLE=1
     23 
     24 # The fdatasync library
     25 TLIBS = @TARGET_LIBS@
  • databases/sqlite3/Portfile

     
    55name                    sqlite3
    66version                 3.4.1
    77categories              databases
    8 platforms               darwin
     8platforms               darwin freebsd linux
    99maintainers             mww@macports.org
    1010description             an embedded SQL database engine
    1111long_description        SQLite3 is an SQL database engine in a C library. \
     
    4242        xinstall -m 644 ${worksrcpath}/${name}.1 ${destroot}${prefix}/share/man/man1
    4343}
    4444
     45platform darwin {
     46        patchfiles      patch-Makefile.in-darwin
     47}
     48
    4549platform darwin 8 {
    4650        configure.env-append CC=/usr/bin/gcc-4.0 CPP=/usr/bin/cpp-4.0 CXX=/usr/bin/g++-4.0
    4751}
    4852
     53platform freebsd {
     54        post-configure { reinplace "s|-lpthread|-lpthread -lm|" Makefile }
     55}
     56
     57platform linux {
     58        configure.cflags-delete         -DSQLITE_ENABLE_LOCKING_STYLE=1 -I${prefix}/include/readline
     59}