The current SQLite3 Portfile defines the following build environment:
build.env CFLAGS="-I${prefix}/include/ -DSQLITE_ENABLE_LOCKING_STYLE=1" \
LDFLAGS="-L${prefix}/lib"
I tried building without the -I${prefix}/include/
and -L${prefix}/lib
declarations and found linkage of the build results to be unaltered, so Id' say those can be safely removed (MacPorts now passes them by default out of the box). In doing that, I moved the remaining compiler macro to the configure environment following the new syntax:
configure.cflags-append -DSQLITE_ENABLE_LOCKING_STYLE=1
But also found that that's rather unnecessary, as SQLite3's build magic still passes that particular compiler macro to the build calls even if we don't list it explicitly in CFLAGS. The attached Portfile patch moves the macro to configure.env per the syntax above even if for safety, but I would say we're safe removing it altogether (the attached destroot.log
file catches all the output of the destroot run and demonstrates the macro is being passed even though it's neither in configure.env, DEBUG: Environment: CXXFLAGS='-O2' CPPFLAGS='-I/opt/local/include' CFLAGS='-O2' LDFLAGS='-L/opt/local/lib'
, nor in build.env, DEBUG: Environment:
).
-jmpp
Committed in r26620 due to maintainer timeout.
-jmpp