Author: damjan
Date: Mon Dec 26 06:44:44 2016
New Revision: 1776043
URL: http://svn.apache.org/viewvc?rev=1776043&view=rev
Log:
On Linux, building without --enable-dbgutil causes linking failures
in GoogleTests in main/binaryurp with missing pthread symbols.
The original cause is that ext_libraries/test's libgtest.so is
built without libpthread.so linked, which is what this commit fixes
(or rather hacks around; not sure why that happens).
There must also be a proximal cause in main/binaryurp's tests,
as they link with --enable-dbgutil even without this commit, and
can be made to link even without --enable-dbgutil by changing the
OSL_DEBUG_LEVEL define in the compiler options from 0 to 1 (this
doesn't however cause any changes in the preprocessed source file,
so I haven't been able to debug it further).
This should hopefully get the Linux buildbots working again.
Patch by: me
Added:
openoffice/trunk/ext_libraries/gtest/linux-pthread.patch
Modified:
openoffice/trunk/ext_libraries/gtest/makefile.mk
Added: openoffice/trunk/ext_libraries/gtest/linux-pthread.patch
URL:
http://svn.apache.org/viewvc/openoffice/trunk/ext_libraries/gtest/linux-pthread.patch?rev=1776043&view=auto
==============================================================================
--- openoffice/trunk/ext_libraries/gtest/linux-pthread.patch (added)
+++ openoffice/trunk/ext_libraries/gtest/linux-pthread.patch Mon Dec 26
06:44:44 2016
@@ -0,0 +1,11 @@
+--- misc/build/gtest-1.7.0/Makefile.in 2016-12-26 05:46:42.636975431 +0200
++++ misc/build/gtest-1.7.0/Makefile.in 2016-12-26 05:53:19.907981058 +0200
+@@ -97,7 +97,7 @@
+ "$(DESTDIR)$(pkgincludedir)" \
+ "$(DESTDIR)$(pkginclude_internaldir)"
+ LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES)
+-lib_libgtest_la_LIBADD =
++lib_libgtest_la_LIBADD = -lpthread
+ am__dirstamp = $(am__leading_dot)dirstamp
+ am_lib_libgtest_la_OBJECTS = src/gtest-all.lo
+ lib_libgtest_la_OBJECTS = $(am_lib_libgtest_la_OBJECTS)
Modified: openoffice/trunk/ext_libraries/gtest/makefile.mk
URL:
http://svn.apache.org/viewvc/openoffice/trunk/ext_libraries/gtest/makefile.mk?rev=1776043&r1=1776042&r2=1776043&view=diff
==============================================================================
--- openoffice/trunk/ext_libraries/gtest/makefile.mk (original)
+++ openoffice/trunk/ext_libraries/gtest/makefile.mk Mon Dec 26 06:44:44 2016
@@ -66,6 +66,10 @@ BUILD_FLAGS+= -f ../../../../win/Makefil
.ELSE
+.IF "$(OS)"=="LINUX"
+PATCH_FILES+=linux-pthread.patch
+.ENDIF
+
CONFIGURE_DIR=
CONFIGURE_ACTION=.$/configure