Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Don't try to compare env variable just see if exist.
authornavarro <navarro@caraja.(none)>
Wed, 23 May 2012 14:28:00 +0000 (16:28 +0200)
committernavarro <navarro@caraja.(none)>
Wed, 23 May 2012 14:28:12 +0000 (16:28 +0200)
CMakeLists.txt

index 38dfa79..1e11fb3 100644 (file)
@@ -215,11 +215,11 @@ if(WIN32)
     endif(PEXPORTS_PATH)
 else(WIN32)
     target_link_libraries(SG_java pcre pthread simgrid)
     endif(PEXPORTS_PATH)
 else(WIN32)
     target_link_libraries(SG_java pcre pthread simgrid)
-    if($ENV{SIMGRID_PCRE_LIBRARY_PATH} STREQUAL "")
+    if($ENV{SIMGRID_PCRE_LIBRARY_PATH})
         set_target_properties(SG_java PROPERTIES LINK_FLAGS "-L${SIMGRID_LIB_PATH}")
         set_target_properties(SG_java PROPERTIES LINK_FLAGS "-L${SIMGRID_LIB_PATH}")
-    else($ENV{SIMGRID_PCRE_LIBRARY_PATH} STREQUAL "")
+    else($ENV{SIMGRID_PCRE_LIBRARY_PATH})
         set_target_properties(SG_java PROPERTIES LINK_FLAGS "-L${SIMGRID_LIB_PATH} -L$ENV{SIMGRID_PCRE_LIBRARY_PATH}/lib")
         set_target_properties(SG_java PROPERTIES LINK_FLAGS "-L${SIMGRID_LIB_PATH} -L$ENV{SIMGRID_PCRE_LIBRARY_PATH}/lib")
-    endif($ENV{SIMGRID_PCRE_LIBRARY_PATH} STREQUAL "")
+    endif($ENV{SIMGRID_PCRE_LIBRARY_PATH})
 endif(WIN32)
 
 # java_classes
 endif(WIN32)
 
 # java_classes
@@ -293,25 +293,25 @@ set(test_list basic async pingPong CommTime mutualExclusion bypass kill startKil
 # Set the  DYLD_LIBRARY_PATH for mac     #
 ##########################################
 if(APPLE)
 # Set the  DYLD_LIBRARY_PATH for mac     #
 ##########################################
 if(APPLE)
-    if($ENV{DYLD_LIBRARY_PATH} STREQUAL "")
+    if($ENV{DYLD_LIBRARY_PATH})
         set_tests_properties(${test_list}
         PROPERTIES ENVIRONMENT "DYLD_LIBRARY_PATH=${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
         set_tests_properties(${test_list}
         PROPERTIES ENVIRONMENT "DYLD_LIBRARY_PATH=${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
-    else($ENV{DYLD_LIBRARY_PATH} STREQUAL "")
+    else($ENV{DYLD_LIBRARY_PATH})
         set_tests_properties(${test_list}
         PROPERTIES ENVIRONMENT "DYLD_LIBRARY_PATH=$ENV{DYLD_LIBRARY_PATH}:${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
         set_tests_properties(${test_list}
         PROPERTIES ENVIRONMENT "DYLD_LIBRARY_PATH=$ENV{DYLD_LIBRARY_PATH}:${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
-    endif($ENV{DYLD_LIBRARY_PATH} STREQUAL "")
+    endif($ENV{DYLD_LIBRARY_PATH})
 else(APPLE)
     ##########################################
     # Set the  LD_LIBRARY_PATH for our tests #
     ##########################################
     if(NOT WIN32)
 else(APPLE)
     ##########################################
     # Set the  LD_LIBRARY_PATH for our tests #
     ##########################################
     if(NOT WIN32)
-        if($ENV{LD_LIBRARY_PATH} STREQUAL "")
+        if($ENV{LD_LIBRARY_PATH})
             set_tests_properties(${test_list}
             PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
             set_tests_properties(${test_list}
             PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
-        else($ENV{LD_LIBRARY_PATH} STREQUAL "")
+        else($ENV{LD_LIBRARY_PATH})
             set_tests_properties(${test_list}
             PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=$ENV{LD_LIBRARY_PATH}:${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
             set_tests_properties(${test_list}
             PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=$ENV{LD_LIBRARY_PATH}:${CMAKE_HOME_DIRECTORY}/lib:${SIMGRID_LIB_PATH}")
-        endif($ENV{LD_LIBRARY_PATH} STREQUAL "")
+        endif($ENV{LD_LIBRARY_PATH})
     endif(NOT WIN32)
 endif(APPLE)
 
     endif(NOT WIN32)
 endif(APPLE)