Source: firebird2.5 Version: 2.5.0.25784~ReleaseCandidate1.ds2-6 Severity: important Tags: patch User: debian-...@superh.org Usertags: sh4 X-Debbugs-CC: debian-sup...@lists.debian.org
Hi, firebird2.5 FTBFS on SH4. Because AO_compare_and_swap_emulation is necessary, sh4 has to link libatomic_ops.a http://buildd.debian-ports.org/fetch.php?pkg=firebird2.5&arch=sh4&ver=2.5.0.25784~ReleaseCandidate1.ds2-6&stamp=1264775198&file=log&as=raw ----- g++ -ggdb -O3 -DNDEBUG -DLINUX -pipe -MMD -fPIC -DFB_SEND_FLAGS=MSG_NOSIGNAL -I../src/include/gen -I../src/include -I../src/vulcan -DNAMESPACE=Vulcan -pthread -g -O2 -DBOOT_BUILD -fno-rtti -c ../src/common/classes/SafeArg.cpp -o ../temp/boot/common/classes/SafeArg.o g++ -ggdb -O3 -DNDEBUG -DLINUX -pipe -MMD -fPIC -DFB_SEND_FLAGS=MSG_NOSIGNAL -I../src/include/gen -I../src/include -I../src/vulcan -DNAMESPACE=Vulcan -pthread -g -O2 -DBOOT_BUILD -fno-rtti -c ../src/common/classes/MsgPrint.cpp -o ../temp/boot/common/classes/MsgPrint.o g++ -ggdb -O3 -DNDEBUG -DLINUX -pipe -MMD -fPIC -DFB_SEND_FLAGS=MSG_NOSIGNAL -I../src/include/gen -I../src/include -I../src/vulcan -DNAMESPACE=Vulcan -pthread -g -O2 -DBOOT_BUILD -fno-rtti -c ../src/common/classes/BaseStream.cpp -o ../temp/boot/common/classes/BaseStream.o g++ -ggdb -O3 -DNDEBUG -DLINUX -pipe -MMD -fPIC -DFB_SEND_FLAGS=MSG_NOSIGNAL -I../src/include/gen -I../src/include -I../src/vulcan -DNAMESPACE=Vulcan -pthread -g -O2 -DBOOT_BUILD -fno-rtti -c ../src/common/cvt.cpp -o ../temp/boot/common/cvt.o g++ -pthread ../temp/boot/jrd/dsc.o ../temp/boot/jrd/gds.o ../temp/boot/jrd/isc.o ../temp/boot/gpre/cmd.o ../temp/boot/gpre/cme.o ../temp/boot/gpre/cmp.o ../temp/boot/gpre/c_cxx.o ../temp/boot/gpre/exp.o ../temp/boot/gpre/gpre.o ../temp/boot/gpre/hsh.o ../temp/boot/gpre/int_cxx.o ../temp/boot/gpre/jrdmet.o ../temp/boot/gpre/movg.o ../temp/boot/gpre/msc.o ../temp/boot/gpre/par.o ../temp/boot/gpre/pat.o ../temp/boot/gpre/sqe.o ../temp/boot/gpre/sql.o ../temp/boot/gpre/pretty.o ../temp/boot/gpre/gpre_meta_boot.o ../temp/boot/jrd/config_root.o ../temp/boot/jrd/path_utils.o ../temp/boot/jrd/mod_loader.o ../temp/boot/jrd/fbsyslog.o ../temp/boot/jrd/guid.o ../temp/boot/jrd/os_utils.o ../temp/boot/common/dllinst.o ../temp/boot/common/fb_exception.o ../temp/boot/common/thd.o ../temp/boot/common/classes/MetaName.o ../temp/boot/common/StatusHolder.o ../temp/boot/common/classes/init.o ../temp/boot/common/StatusArg.o ../temp/boot/common/utils.o ../temp/boot/common/config/config.o ../ temp/boot/common/config/config_file.o ../temp/boot/common/config/dir_list.o ../temp/boot/common/classes/alloc.o ../temp/boot/common/classes/locks.o ../temp/boot/common/classes/semaphore.o ../temp/boot/common/classes/fb_string.o ../temp/boot/common/classes/timestamp.o ../temp/boot/common/classes/PublicHandle.o ../temp/boot/common/classes/TempFile.o ../temp/boot/common/classes/SafeArg.o ../temp/boot/common/classes/MsgPrint.o ../temp/boot/common/classes/BaseStream.o ../temp/boot/common/cvt.o -o ../gen/firebird/bin/gpre_boot -L../gen/firebird/lib -lm -ldl ../temp/boot/common/utils.o: In function `fb_utils::genUniqueId()': /build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/common/utils.cpp:682: undefined reference to `AO_compare_and_swap_emulation' ../temp/boot/common/classes/alloc.o: In function `Firebird::Mutex::enter()': /build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/include/../common/classes/locks.h:170: undefined reference to `AO_compare_and_swap_emulation' /build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/include/../common/classes/locks.h:170: undefined reference to `AO_compare_and_swap_emulation' /build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/include/../common/classes/locks.h:170: undefined reference to `AO_compare_and_swap_emulation' /build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/include/../common/classes/locks.h:170: undefined reference to `AO_compare_and_swap_emulation' ../temp/boot/common/classes/alloc.o:/build/buildd-firebird2.5_2.5.0.25784~ReleaseCandidate1.ds2-6-sh4-NSqS1F/firebird2.5-2.5.0.25784~ReleaseCandidate1.ds2/gen/../src/include/../common/classes/locks.h:170: more undefined references to `AO_compare_and_swap_emulation' follow collect2: ld returned 1 exit status make[4]: *** [../gen/firebird/bin/gpre_boot] Error 1 make[3]: *** [boot_phase1_build.stamp] Error 2 ----- A patch(debian/patches/link_atomic_ops.patch) same as other arch is necessary for sh. I add support of SH to the patch which I attached. Could you apply this patch? Best regards, Nobuhiro -- Nobuhiro Iwamatsu GPG ID: 3170EBE9 / 40AD1FA6
--- a/builds/posix/Makefile.in.client.util +++ b/builds/posix/Makefile.in.client.util @@ -184,13 +184,13 @@ $(FBSVCMGR): $(FBSVCMGR_Objects) $(LIBFB fbtracemgr: $(FBTRACEMGR) $(FBTRACEMGR): $(FBTRACEMGR_Objects) $(LIBFBCLIENT_SO) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) + $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) $(ATOMIC_LIBS) fbguard: $(LIBFBCLIENT_SO) $(FBGUARD) $(FBGUARD): $(FBGUARD_Objects) $(FBCOMMON_Objects) $(FBCLASSES_Objects) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) -lfbclient $(LIB_GUI) + $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) -lfbclient $(LIB_GUI) $(ATOMIC_LIBS) ibguard: $(LIBFBCLIENT_SO) $(IBGUARD) --- a/builds/posix/Makefile.in.embed.util +++ b/builds/posix/Makefile.in.embed.util @@ -184,7 +184,7 @@ $(FBSVCMGR): $(FBSVCMGR_Objects) $(LIBFB fbtracemgr: $(FBTRACEMGR) $(FBTRACEMGR): $(FBTRACEMGR_Objects) $(LIBFBEMBED_SO) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(FBEMBED_LINK) + $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(FBEMBED_LINK) $(ATOMIC_LIBS) gds_relay: $(GDS_RELAY) @@ -202,7 +202,7 @@ $(GSEC): $(GSEC_Objects) $(CLUMPLETS_Obj fbguard: $(LIBFBCLIENT_SO) $(FBGUARD) $(FBGUARD): $(FBGUARD_Objects) $(FBCOMMON_Objects) $(FBCLASSES_Objects) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) -lfbclient $(LIB_GUI) + $(EXE_LINK) $(LINK_OPTS) $^ -o $@ -L$(LIB) -lfbclient $(LIB_GUI) $(ATOMIC_LIBS) ibmgr_bin: $(IBMGR_BIN) --- a/builds/posix/Makefile.in.inet_server +++ b/builds/posix/Makefile.in.inet_server @@ -52,7 +52,7 @@ Dependencies = $(AllObjects:.o=.d) fb_inet_server : $(LIBFBEMBED_SO) $(FB_CLASSIC_SERVER) $(FB_CLASSIC_SERVER): $(SERVER_Objects) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(FBEMBED_LINK) $(LIB_GUI) + $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(FBEMBED_LINK) $(LIB_GUI) $(ATOMIC_LIBS) include $(ROOT)/gen/make.shared.targets --- a/builds/posix/make.defaults +++ b/builds/posix/make.defaults @@ -152,7 +152,8 @@ CLIENTLIB_LINK:= @CC@ $(GLOB_OPTIONS) EXE_LINK:= @CXX@ $(GLOB_OPTIONS) STATICEXE_LINK:= @CXX@ $(GLOB_OPTIONS) -LINK_LIBS = @LIBS@ +ATOMIC_LIBS = @ATOMIC_LIBS@ +LINK_LIBS = @LIBS@ $(ATOMIC_LIBS) ICU_LIBS = -licuuc STATICLINK_LIBS = @LIBS@ SO_LINK_LIBS = @LIBS@ @@ -299,11 +300,11 @@ LINK_TRACE_LIBS = -L$(LIB) $(SO_LINK_LIB LINK_CLIENT = $(CLIENTLIB_LINK) $(LINK_FIREBIRD_CLIENT_SYMBOLS) $(LIB_LINK_OPTIONS)\ $(LIB_LINK_IMPLIB) $(call LIB_LINK_SONAME,$(ClientLibrarySoName)) $(call LIB_LINK_RPATH,lib) $(THR_LIBS) $(THR_FLAGS) -LINK_CLIENT_LIBS = $(SO_LINK_LIBS) $(STATIC_CXXSUPPORT_LIB) +LINK_CLIENT_LIBS = $(SO_LINK_LIBS) $(STATIC_CXXSUPPORT_LIB) $(ATOMIC_LIBS) LINK_EMBED = $(LIB_LINK) $(LINK_FIREBIRD_EMBED_SYMBOLS) $(LIB_LINK_OPTIONS) $(LIB_EMBED_LINK_OPTIONS)\ $(call LIB_LINK_SONAME,$(SharedLibrarySoName)) $(call LIB_LINK_RPATH,lib) $(THR_LIBS) $(THR_FLAGS) -LINK_EMBED_LIBS = -L$(LIB) $(LIB_GUI) $(SO_LINK_LIBS) $(ICU_LIBS) +LINK_EMBED_LIBS = -L$(LIB) $(LIB_GUI) $(SO_LINK_LIBS) $(ICU_LIBS) $(ATOMIC_LIBS) # From utilities CREATE_DB = $(BIN)/create_db$(EXEC_EXT) --- a/configure.in 2010-01-30 23:09:27.000000000 +0000 +++ b/configure.in 2010-01-30 23:10:24.000000000 +0000 @@ -210,6 +210,7 @@ SHRLIB_EXT=so STD_EDITLINE=true STD_ICU=true + ATOMIC_LIBS=-latomic_ops ;; sparc*-*-linux* | sparc*-*-gnu* | sparc*-*-k*bsd*-gnu) @@ -219,6 +220,7 @@ AC_DEFINE(LINUX, 1, [Define this if OS is Linux]) EDITLINE_FLG=Y SHRLIB_EXT=so + ATOMIC_LIBS=-latomic_ops ;; powerpc*-*-linux*) @@ -256,6 +258,7 @@ LOCK_MANAGER_FLG=Y EDITLINE_FLG=Y SHRLIB_EXT=so + ATOMIC_LIBS=-latomic_ops ;; @@ -268,6 +271,7 @@ LOCK_MANAGER_FLG=Y EDITLINE_FLG=Y SHRLIB_EXT=so + ATOMIC_LIBS=-latomic_ops ;; *-*-linux* | *-*-gnu*) @@ -400,6 +404,7 @@ AC_SUBST(ICU_PLATFORM) AC_DEFINE(CASE_SENSITIVITY, false, [Define this if paths are case sensitive]) AC_SUBST(RPM64) +AC_SUBST(ATOMIC_LIBS) dnl Some controllable options