Index: ObjSQLite3.oc.in ================================================================== --- ObjSQLite3.oc.in +++ ObjSQLite3.oc.in @@ -1,3 +1,4 @@ package_format 1 CPPFLAGS="$CPPFLAGS @SQLITE3_CPPFLAGS@" LIBS="-lobjsqlite3 @SQLITE3_LIBS@ $LIBS" +FRAMEWORK_LIBS="-framework ObjSQLite3 @SQLITE3_LIBS@ $FRAMEWORK_LIBS" Index: build-aux/m4/buildsys.m4 ================================================================== --- build-aux/m4/buildsys.m4 +++ build-aux/m4/buildsys.m4 @@ -307,10 +307,11 @@ FRAMEWORK_LDFLAGS_INSTALL_NAME='-Wl,-install_name,@executable_path/../Frameworks/$$out/$${out%.framework}' ]) AC_SUBST(FRAMEWORK_LDFLAGS) AC_SUBST(FRAMEWORK_LDFLAGS_INSTALL_NAME) + AC_SUBST(FRAMEWORK_LIBS) $1 ;; esac ]) Index: buildsys.mk.in ================================================================== --- buildsys.mk.in +++ buildsys.mk.in @@ -61,10 +61,11 @@ PLUGIN_CFLAGS = @PLUGIN_CFLAGS@ PLUGIN_LDFLAGS = @PLUGIN_LDFLAGS@ PLUGIN_SUFFIX = @PLUGIN_SUFFIX@ FRAMEWORK_LDFLAGS = @FRAMEWORK_LDFLAGS@ FRAMEWORK_LDFLAGS_INSTALL_NAME = @FRAMEWORK_LDFLAGS_INSTALL_NAME@ +FRAMEWORK_LIBS = @FRAMEWORK_LIBS@ CODESIGN = @CODESIGN@ CODESIGN_IDENTITY ?= - CLEAN_LIB = @CLEAN_LIB@ DEP_ASFLAGS = @DEP_ASFLAGS@ DEP_CFLAGS = @DEP_CFLAGS@ @@ -189,11 +190,11 @@ fi ${FRAMEWORK} ${FRAMEWORK_NOINST}: ${EXT_DEPS} ${LIB_OBJS} ${LIB_OBJS_EXTRA} ${LINK_STATUS} out="$@"; \ - if rm -fr $$out && ${MKDIR_P} $$out && ${MAKE} -s COPY_HEADERS_IF_SUBDIR=${includesubdir} COPY_HEADERS_DESTINATION=$$PWD/$@/Headers copy-headers-into-framework && if test -f Info.plist; then ${INSTALL} -m 644 Info.plist $$out/Info.plist; fi && if test -f module.modulemap; then ${MKDIR_P} $$out/Modules && ${INSTALL} -m 644 module.modulemap $$out/Modules/module.modulemap; fi && ${LD} -o $$out/$${out%.framework} ${LIB_OBJS} ${LIB_OBJS_EXTRA} ${FRAMEWORK_LDFLAGS} ${FRAMEWORK_LDFLAGS_INSTALL_NAME} ${LDFLAGS} ${FRAMEWORK_LIBS} && ${CODESIGN} -fs ${CODESIGN_IDENTITY} --timestamp=none $$out; then \ + if rm -fr $$out && ${MKDIR_P} $$out && ${MAKE} -s COPY_HEADERS_IF_SUBDIR=${includesubdir} COPY_HEADERS_DESTINATION=$$PWD/$@/Headers copy-headers-into-framework && if test -f Info.plist; then ${INSTALL} -m 644 Info.plist $$out/Info.plist; fi && if test -f module.modulemap; then ${MKDIR_P} $$out/Modules && ${INSTALL} -m 644 module.modulemap $$out/Modules/module.modulemap; fi && ${LD} -o $$out/$${out%.framework} ${LIB_OBJS} ${LIB_OBJS_EXTRA} ${FRAMEWORK_LDFLAGS} ${FRAMEWORK_LDFLAGS_INSTALL_NAME} ${LDFLAGS} ${FRAMEWORK_LIBS} && ${CODESIGN} -fs ${CODESIGN_IDENTITY} $$out; then \ ${LINK_OK}; \ else \ rm -fr $$out; false; \ ${LINK_FAILED}; \ fi Index: configure.ac ================================================================== --- configure.ac +++ configure.ac @@ -26,12 +26,12 @@ CPP="$OBJCPP" CPPFLAGS="$CPPFLAGS $OBJCPPFLAGS $($OBJFW_CONFIG --cppflags)" OBJCFLAGS="$OBJCFLAGS $($OBJFW_CONFIG --objcflags)" LDFLAGS="$LDFLAGS $($OBJFW_CONFIG --ldflags)" -AC_SUBST(OBJFW_LIBS, "$($OBJFW_CONFIG --libs)") -AC_SUBST(OBJFW_FRAMEWORK_LIBS, "$($OBJFW_CONFIG --framework-libs)") +FRAMEWORK_LIBS="$($OBJFW_CONFIG --framework-libs) $LIBS" +LIBS="$($OBJFW_CONFIG --libs) $LIBS" AX_CHECK_COMPILER_FLAGS(-Wdocumentation, [OBJCFLAGS="$OBJCFLAGS -Wdocumentation"]) AC_CHECK_TOOL(AR, ar) Index: extra.mk.in ================================================================== --- extra.mk.in +++ extra.mk.in @@ -8,8 +8,6 @@ EXCEPTIONS_EXCEPTIONS_A = @EXCEPTIONS_EXCEPTIONS_A@ EXCEPTIONS_EXCEPTIONS_LIB_A = @EXCEPTIONS_EXCEPTIONS_LIB_A@ EXCEPTIONS_LIB_A = @EXCEPTIONS_LIB_A@ LIBOBJSQLITE3_DEP = @LIBOBJSQLITE3_DEP@ OBJFW_CONFIG = @OBJFW_CONFIG@ -OBJFW_FRAMEWORK_LIBS = @OBJFW_FRAMEWORK_LIBS@ -OBJFW_LIBS = @OBJFW_LIBS@ RUN_TESTS = @RUN_TESTS@ Index: src/Makefile ================================================================== --- src/Makefile +++ src/Makefile @@ -3,12 +3,12 @@ SUBDIRS = exceptions SHARED_LIB = ${OBJSQLITE3_SHARED_LIB} STATIC_LIB = ${OBJSQLITE3_STATIC_LIB} FRAMEWORK = ${OBJSQLITE3_FRAMEWORK} -LIB_MAJOR = 0 -LIB_MINOR = 0 +LIB_MAJOR = ${OBJSQLITE3_LIB_MAJOR} +LIB_MINOR = ${OBJSQLITE3_LIB_MINOR} SRCS = SL3Connection.m \ SL3PreparedStatement.m INCLUDES := ${SRCS:.m=.h} \ ObjSQLite3.h @@ -18,7 +18,5 @@ include ../buildsys.mk CPPFLAGS += -I. -Iexceptions -DSL3_PUBLIC_IVARS LD = ${OBJC} -FRAMEWORK_LIBS := ${OBJFW_FRAMEWORK_LIBS} ${LIBS} -LIBS := ${OBJFW_LIBS} ${LIBS} Index: tests/Makefile ================================================================== --- tests/Makefile +++ tests/Makefile @@ -39,7 +39,7 @@ exit $$EXIT ${PROG_NOINST}: ${LIBOBJSQLITE3_DEP} CPPFLAGS += -I../src -LIBS := -L../src -lobjsqlite3 ${OBJFW_LIBS} ${LIBS} +LIBS := -L../src -lobjsqlite3 ${LIBS} LD = ${OBJC}