summaryrefslogtreecommitdiffstats
path: root/Modules/BundleUtilities.cmake
diff options
context:
space:
mode:
authorRolf Eike Beer <eike@sf-mail.de>2019-06-14 06:30:34 (GMT)
committerRolf Eike Beer <eike@sf-mail.de>2019-06-17 15:49:31 (GMT)
commit6695383dd5a7855321dc011158e30ec24a7cf902 (patch)
tree7510f54c06be8e4777201031b2ec950ad5bc4959 /Modules/BundleUtilities.cmake
parentd5333c0923b80f211bd7be1ec3a2a935d70481e8 (diff)
downloadCMake-6695383dd5a7855321dc011158e30ec24a7cf902.zip
CMake-6695383dd5a7855321dc011158e30ec24a7cf902.tar.gz
CMake-6695383dd5a7855321dc011158e30ec24a7cf902.tar.bz2
BundleUtilities: remove needless variable expansions in if() arguments
Diffstat (limited to 'Modules/BundleUtilities.cmake')
-rw-r--r--Modules/BundleUtilities.cmake34
1 files changed, 17 insertions, 17 deletions
diff --git a/Modules/BundleUtilities.cmake b/Modules/BundleUtilities.cmake
index ca92f85..182720b 100644
--- a/Modules/BundleUtilities.cmake
+++ b/Modules/BundleUtilities.cmake
@@ -279,7 +279,7 @@ function(get_bundle_main_executable bundle result_var)
endif()
endforeach()
- if(NOT "${bundle_executable}" STREQUAL "")
+ if(NOT bundle_executable STREQUAL "")
if(EXISTS "${bundle}/Contents/MacOS/${bundle_executable}")
set(result "${bundle}/Contents/MacOS/${bundle_executable}")
else()
@@ -601,9 +601,9 @@ function(get_bundle_keys app libs dirs keys_var)
set(prereqs "")
set(ignoreFile FALSE)
get_filename_component(prereq_filename ${lib} NAME)
- if(NOT "${CFG_IGNORE_ITEM}" STREQUAL "" )
+ if(NOT CFG_IGNORE_ITEM STREQUAL "")
foreach(item ${CFG_IGNORE_ITEM})
- if("${item}" STREQUAL "${prereq_filename}")
+ if(item STREQUAL prereq_filename)
set(ignoreFile TRUE)
endif()
endforeach()
@@ -626,7 +626,7 @@ function(get_bundle_keys app libs dirs keys_var)
foreach(exe ${exes})
# Main executable is scanned first above:
#
- if(NOT "${exe}" STREQUAL "${executable}")
+ if(NOT exe STREQUAL executable)
# Add the exe itself to the keys:
#
set_bundle_key_values(${keys_var} "${exe}" "${exe}" "${exepath}" "${dirs}" 0 "${main_rpaths}")
@@ -644,9 +644,9 @@ function(get_bundle_keys app libs dirs keys_var)
set(prereqs "")
set(ignoreFile FALSE)
get_filename_component(prereq_filename ${exe} NAME)
- if(NOT "${CFG_IGNORE_ITEM}" STREQUAL "" )
+ if(NOT CFG_IGNORE_ITEM STREQUAL "" )
foreach(item ${CFG_IGNORE_ITEM})
- if("${item}" STREQUAL "${prereq_filename}")
+ if(item STREQUAL prereq_filename)
set(ignoreFile TRUE)
endif()
endforeach()
@@ -664,7 +664,7 @@ function(get_bundle_keys app libs dirs keys_var)
# preserve library symlink structure
foreach(key ${${keys_var}})
- if("${${key}_COPYFLAG}" STREQUAL 1)
+ if("${${key}_COPYFLAG}" STREQUAL "1")
if(IS_SYMLINK "${${key}_RESOLVED_ITEM}")
get_filename_component(target "${${key}_RESOLVED_ITEM}" REALPATH)
set_bundle_key_values(${keys_var} "${exe}" "${target}" "${exepath}" "${dirs}" 1 "${exe_rpaths}")
@@ -681,7 +681,7 @@ function(get_bundle_keys app libs dirs keys_var)
get_filename_component(resolved_item_compare "${resolved_item_compare}" NAME)
get_filename_component(resolved_embedded_item_compare "${resolved_embedded_item_compare}" NAME)
- if(NOT "${resolved_item_compare}" STREQUAL "${resolved_embedded_item_compare}")
+ if(NOT resolved_item_compare STREQUAL resolved_embedded_item_compare)
set(${key}_COPYFLAG "2")
set(${key}_RESOLVED_ITEM "${${targetkey}_RESOLVED_EMBEDDED_ITEM}")
endif()
@@ -715,7 +715,7 @@ function(link_resolved_item_into_bundle resolved_item resolved_embedded_item)
set(resolved_embedded_item_compare "${resolved_embedded_item}")
endif()
- if("${resolved_item_compare}" STREQUAL "${resolved_embedded_item_compare}")
+ if(resolved_item_compare STREQUAL resolved_embedded_item_compare)
message(STATUS "warning: resolved_item == resolved_embedded_item - not linking...")
else()
get_filename_component(target_dir "${resolved_embedded_item}" DIRECTORY)
@@ -737,7 +737,7 @@ function(copy_resolved_item_into_bundle resolved_item resolved_embedded_item)
set(resolved_embedded_item_compare "${resolved_embedded_item}")
endif()
- if("${resolved_item_compare}" STREQUAL "${resolved_embedded_item_compare}")
+ if(resolved_item_compare STREQUAL resolved_embedded_item_compare)
message(STATUS "warning: resolved_item == resolved_embedded_item - not copying...")
else()
#message(STATUS "copying COMMAND ${CMAKE_COMMAND} -E copy ${resolved_item} ${resolved_embedded_item}")
@@ -760,7 +760,7 @@ function(copy_resolved_framework_into_bundle resolved_item resolved_embedded_ite
set(resolved_embedded_item_compare "${resolved_embedded_item}")
endif()
- if("${resolved_item_compare}" STREQUAL "${resolved_embedded_item_compare}")
+ if(resolved_item_compare STREQUAL resolved_embedded_item_compare)
message(STATUS "warning: resolved_item == resolved_embedded_item - not copying...")
else()
if(BU_COPY_FULL_FRAMEWORK_CONTENTS)
@@ -840,12 +840,12 @@ function(fixup_bundle_item resolved_embedded_item exepath dirs)
string(LENGTH "${resolved_embedded_item}" resolved_embedded_item_length)
set(path_too_short 0)
set(is_embedded 0)
- if(${resolved_embedded_item_length} LESS ${exe_dotapp_dir_length})
+ if(resolved_embedded_item_length LESS exe_dotapp_dir_length)
set(path_too_short 1)
endif()
if(NOT path_too_short)
string(SUBSTRING "${resolved_embedded_item}" 0 ${exe_dotapp_dir_length} item_substring)
- if("${exe_dotapp_dir}/" STREQUAL "${item_substring}")
+ if("${exe_dotapp_dir}/" STREQUAL item_substring)
set(is_embedded 1)
endif()
endif()
@@ -1034,9 +1034,9 @@ function(verify_bundle_prerequisites bundle result_var info_var)
set(ignoreFile FALSE)
get_filename_component(prereq_filename ${f} NAME)
- if(NOT "${CFG_IGNORE_ITEM}" STREQUAL "" )
+ if(NOT CFG_IGNORE_ITEM STREQUAL "" )
foreach(item ${CFG_IGNORE_ITEM})
- if("${item}" STREQUAL "${prereq_filename}")
+ if(item STREQUAL prereq_filename)
set(ignoreFile TRUE)
endif()
endforeach()
@@ -1062,11 +1062,11 @@ function(verify_bundle_prerequisites bundle result_var info_var)
gp_file_type("${f}" "${p}" p_type)
if(APPLE)
- if(NOT "${p_type}" STREQUAL "embedded" AND NOT "${p_type}" STREQUAL "system")
+ if(NOT p_type STREQUAL "embedded" AND NOT p_type STREQUAL "system")
set(external_prereqs ${external_prereqs} "${p}")
endif()
else()
- if(NOT "${p_type}" STREQUAL "local" AND NOT "${p_type}" STREQUAL "system")
+ if(NOT p_type STREQUAL "local" AND NOT p_type STREQUAL "system")
set(external_prereqs ${external_prereqs} "${p}")
endif()
endif()