File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -94,6 +94,14 @@ add_custom_target(
94
94
95
95
###########################################################################
96
96
# Add target to replace the unity package version number in files
97
+ if (${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" )
98
+ set (VERSION_AS_STRING "\\ '${PACKAGE_VERSION} \\ '" )
99
+ elseif (${CMAKE_SYSTEM_NAME} STREQUAL "Windows" )
100
+ set (VERSION_AS_STRING "'${PACKAGE_VERSION} '" )
101
+ elseif (${CMAKE_SYSTEM_NAME} STREQUAL "Linux" )
102
+ set (VERSION_AS_STRING "\\ '${PACKAGE_VERSION} \\ '" )
103
+ endif ()
104
+
97
105
set (README_TARGET readme_replace )
98
106
add_custom_target (
99
107
${README_TARGET}
@@ -106,7 +114,7 @@ add_custom_target(
106
114
"${CMAKE_SOURCE_DIR} /scripts/file-search-replace.py"
107
115
"${CMAKE_SOURCE_DIR} /Assets/FbxExporters/Integrations/Autodesk/maya/scripts/UnityFbxForMaya/version.py"
108
116
".*VERSION.*=.*"
109
- "VERSION = \\ ' ${PACKAGE_VERSION} \\ ' "
117
+ "VERSION = ${VERSION_AS_STRING} "
110
118
DEPENDS "${CMAKE_SOURCE_DIR} /scripts/file-search-replace.py"
111
119
COMMENT "Replacing version number in files with ${PACKAGE_VERSION} "
112
120
)
You can’t perform that action at this time.
0 commit comments