]> source.dussan.org Git - tigervnc.git/commitdiff
(Re-)fix static Xvnc build. We can leverage the BUILD_STATIC option to modify our...
authorDRC <dcommander@users.sourceforge.net>
Tue, 9 Aug 2011 02:26:30 +0000 (02:26 +0000)
committerDRC <dcommander@users.sourceforge.net>
Tue, 9 Aug 2011 02:26:30 +0000 (02:26 +0000)
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4614 3789f03b-4d11-0410-bbf8-ca57d06f2519

cmake/Modules/CMakeMacroLibtoolFile.cmake
unix/build-xorg

index df9d49f8426c3a5d912e587e55ae2ac6fb4798d2..0cf7b9fbb0369c325ba5a201d1157b3e25f60ed5 100644 (file)
@@ -77,6 +77,10 @@ macro(libtool_create_control_file _target)
   get_filename_component(_lname ${_target_location} NAME_WE)
   set(_laname ${CMAKE_CURRENT_BINARY_DIR}/${_lname}.la)
  
+  if(BUILD_STATIC)
+    set(_target_dependency_libs "${_target_dependency_libs} -L${CMAKE_BINARY_DIR}/staticlib")
+  endif()
+
   file(WRITE ${_laname} "# ${_lname}.la - a libtool library file\n# Generated by ltmain.sh (GNU libtool) 2.2.6b\n")
   file(APPEND ${_laname} "dlname=''\n\n")
   file(APPEND ${_laname} "library_names=''\n\n")
index e71f6dd4de5f4910e3acf47e26d9621ba3f7a339..f7abcc248cff2801cd61c800d5b8a8100267045e 100755 (executable)
@@ -293,7 +293,7 @@ if [ "$MODE" = "build" ]; then
     fi
     CFLAGS="$CFLAGS -fPIC"
     CXXFLAGS="$CXXFLAGS -fPIC"
-    LDFLAGS="$LDFLAGS -L`pwd`/xorg.build/syslib"
+    LDFLAGS="$LDFLAGS -static-libgcc -L`pwd`/xorg.build/syslib"
     echo CC = $CC
     echo CXX = $CXX
     echo CFLAGS = $CFLAGS