From: <ai...@us...> - 2011-11-29 21:03:44
|
Revision: 12068 http://plplot.svn.sourceforge.net/plplot/?rev=12068&view=rev Author: airwin Date: 2011-11-29 21:03:33 +0000 (Tue, 29 Nov 2011) Log Message: ----------- Untested change to the build system to only use the --static pkg-config option for the traditional installed examples build when the experimental option FORCE_EXTERNAL_STATIC in ON. The D case is no longer treated as a special case because FORCE_EXTERNAL_STATIC is ON only when the PLplot internal libraries are built statically (BUILD_SHARED_LIBS OFF) so that distinctions between plplotdmd_SHARED ON or OFF no longer matter for the D case. Modified Paths: -------------- trunk/examples/CMakeLists.txt trunk/examples/d/CMakeLists.txt trunk/examples/d/Makefile.examples.in Modified: trunk/examples/CMakeLists.txt =================================================================== --- trunk/examples/CMakeLists.txt 2011-11-29 06:33:04 UTC (rev 12067) +++ trunk/examples/CMakeLists.txt 2011-11-29 21:03:33 UTC (rev 12068) @@ -181,21 +181,20 @@ set(PDFQT_COMMENT "#") endif(NOT PLD_pdfqt) - # The D case takes special handling so the logic below is for the - # generic non-D examples case. - if(NON_TRANSITIVE) - if(BUILD_SHARED_LIBS) - # pkg-config does not use --static option for examples build. - set(PC_STATIC_OPTION) - else(BUILD_SHARED_LIBS) - # pkg-config does use --static option for examples build. + if(FORCE_EXTERNAL_STATIC) + # This experiment option untested, but it should work as well as + # FORCE_EXTERNAL_STATIC does for the CMake linking case for the + # core build in the build tree. That is, not well at all (drivers + # limited to those without external dependencies and languages limited + # to C, C++, D, Fortran 77, and Fortran 95) because + # of severe limitations in static library support on Linux. + + # pkg-config does use --static option for traditional installed examples build. set(PC_STATIC_OPTION "--static") - endif(BUILD_SHARED_LIBS) - else(NON_TRANSITIVE) - # pkg-config never uses the --static option for the examples build - # for the transitive case. + else(FORCE_EXTERNAL_STATIC) + # pkg-config does not use --static option for traditional installed examples build. set(PC_STATIC_OPTION) - endif(NON_TRANSITIVE) + endif(FORCE_EXTERNAL_STATIC) configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/Makefile.examples.in Modified: trunk/examples/d/CMakeLists.txt =================================================================== --- trunk/examples/d/CMakeLists.txt 2011-11-29 06:33:04 UTC (rev 12067) +++ trunk/examples/d/CMakeLists.txt 2011-11-29 21:03:33 UTC (rev 12068) @@ -72,20 +72,6 @@ set(DC ${CMAKE_D_COMPILER}) - if(NON_TRANSITIVE) - if(plplotdmd_SHARED AND BUILD_SHARED_LIBS) - # pkg-config does not use --static option for d examples build. - set(PC_STATIC_OPTION_D) - else(plplotdmd_SHARED AND BUILD_SHARED_LIBS) - # pkg-config uses --static option for d examples build. - set(PC_STATIC_OPTION_D "--static") - endif(plplotdmd_SHARED AND BUILD_SHARED_LIBS) - else(NON_TRANSITIVE) - # pkg-config never uses the --static option for the d examples build - # for the transitive case. - set(PC_STATIC_OPTION_D) - endif(NON_TRANSITIVE) - configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/Makefile.examples.in ${CMAKE_CURRENT_BINARY_DIR}/Makefile.examples Modified: trunk/examples/d/Makefile.examples.in =================================================================== --- trunk/examples/d/Makefile.examples.in 2011-11-29 06:33:04 UTC (rev 12067) +++ trunk/examples/d/Makefile.examples.in 2011-11-29 21:03:33 UTC (rev 12068) @@ -66,6 +66,6 @@ rm -f $(EXECUTABLES_list) .d$(EXEEXT): -@pkg_config_true@ $(DC) $< -o $@ $(RPATHCMD) `$(PKG_CONFIG_ENV) pkg-config @PC_STATIC_OPTION_D@ --cflags --libs plplot$(LIB_TAG)-d` +@pkg_config_true@ $(DC) $< -o $@ $(RPATHCMD) `$(PKG_CONFIG_ENV) pkg-config @PC_STATIC_OPTION@ --cflags --libs plplot$(LIB_TAG)-d` .SUFFIXES: .d $(EXEEXT) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |