[Amarok] 6f00fb2 Tweak the way the Google Mock cmake module works t

Casey Link unnamedrambler at gmail.com
Sun May 30 06:33:12 CEST 2010


commit 6f00fb21fcc8c7004db9e53db4910e688888e151
Author: Casey Link <unnamedrambler at gmail.com>
Date:   Sat May 29 22:55:14 2010 -0500

    Tweak the way the Google Mock cmake module works to make it work on my
    system.
    
    With these changes the -L flag as gotten form gmock-config will be set
    to GOOGLEMOCK_LIBRARIES, as well as the standard -lgmock -lgtest. Before
    it was just doing -lgmock -lgtest, and ld couldn't find the location of
    the libraries. This shouldn't break it for anyone, but who knows..
    please test.
    
    CCMAIL: amarok-devel at kde.org

diff --git a/cmake/modules/FindGooglemock.cmake b/cmake/modules/FindGooglemock.cmake
index bf29577..742fca8 100644
--- a/cmake/modules/FindGooglemock.cmake
+++ b/cmake/modules/FindGooglemock.cmake
@@ -14,7 +14,9 @@ find_program(GMOCK-CONFIG_EXECUTABLE NAMES gmock-config PATHS
 
 if(GMOCK-CONFIG_EXECUTABLE)
 exec_program(${GMOCK-CONFIG_EXECUTABLE} ARGS --includedir OUTPUT_VARIABLE GOOGLEMOCK_INCLUDE_DIR)
-exec_program(${GMOCK-CONFIG_EXECUTABLE} ARGS --libs OUTPUT_VARIABLE GOOGLEMOCK_LIBRARIES)
+exec_program(${GMOCK-CONFIG_EXECUTABLE} ARGS --ldflags OUTPUT_VARIABLE GOOGLEMOCK_LDFLAGS)
+exec_program(${GMOCK-CONFIG_EXECUTABLE} ARGS --libs OUTPUT_VARIABLE GOOGLEMOCK_libs_tmp)
+set(GOOGLEMOCK_LIBRARIES ${GOOGLEMOCK_LDFLAGS} ${GOOGLEMOCK_libs_tmp})
 
 if(GOOGLEMOCK_INCLUDE_DIR AND GOOGLEMOCK_LIBRARIES)
    set(GOOGLEMOCK_FOUND TRUE)


More information about the Amarok-devel mailing list