Browse Source

In panda config, unset libraries we're not using so that they're not used as link targets.

kestred 12 years ago
parent
commit
995688760b
1 changed files with 4 additions and 0 deletions
  1. 4 0
      cmake/macros/PackageConfig.cmake

+ 4 - 0
cmake/macros/PackageConfig.cmake

@@ -73,6 +73,10 @@ function(package_option name)
 
 
   # Create the option.
   # Create the option.
   option("HAVE_${name}" "${cache_string}" "${default}")
   option("HAVE_${name}" "${cache_string}" "${default}")
+  if(NOT HAVE_${name})
+    unset(${name}_LIBRARY)
+    unset(${name}_LIBRARIES)
+  endif()
 endfunction()
 endfunction()
 
 
 #
 #