Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
33b57ce2
Commit
33b57ce2
authored
Apr 23, 2010
by
Daniel Fischer
Browse files
Options
Browse Files
Download
Plain Diff
merge
parents
0ced244e
e8bb2fd4
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
129 additions
and
50 deletions
+129
-50
packaging/WiX/CMakeLists.txt
packaging/WiX/CMakeLists.txt
+23
-4
packaging/WiX/create_msi.cmake.in
packaging/WiX/create_msi.cmake.in
+15
-12
packaging/WiX/extra.wxs.in
packaging/WiX/extra.wxs.in
+85
-32
packaging/WiX/mysql_server.wxs.in
packaging/WiX/mysql_server.wxs.in
+6
-2
No files found.
packaging/WiX/CMakeLists.txt
View file @
33b57ce2
...
@@ -18,28 +18,47 @@ IF(NOT WIX_DIR)
...
@@ -18,28 +18,47 @@ IF(NOT WIX_DIR)
RETURN
()
RETURN
()
ENDIF
()
ENDIF
()
# extra.wxs.in needs DATADIR_MYSQL_FILES and DATADIR_PERFORMANCE_SCHEMA_FILES, i.e
# Wix-compatible file lists for ${builddir}\sql\data\{mysql,performance_schema}
FOREACH
(
dir mysql performance_schema
)
FILE
(
GLOB files
${
CMAKE_BINARY_DIR
}
/sql/data/
${
dir
}
/*
)
SET
(
filelist
)
FOREACH
(
f
${
files
}
)
FILE
(
TO_NATIVE_PATH
"
${
f
}
"
file_native_path
)
GET_FILENAME_COMPONENT
(
file_name
"
${
f
}
"
NAME
)
SET
(
filelist
"
${
filelist
}
<File Id='
${
file_name
}
' Source='
${
file_native_path
}
'/>"
)
ENDFOREACH
()
STRING
(
TOUPPER
${
dir
}
DIR_UPPER
)
SET
(
DATADIR_
${
DIR_UPPER
}
_FILES
"
${
filelist
}
"
)
ENDFOREACH
()
FIND_PROGRAM
(
HEAT_EXECUTABLE heat
${
WIX_DIR
}
)
FIND_PROGRAM
(
HEAT_EXECUTABLE heat
${
WIX_DIR
}
)
FIND_PROGRAM
(
CANDLE_EXECUTABLE candle
${
WIX_DIR
}
)
FIND_PROGRAM
(
CANDLE_EXECUTABLE candle
${
WIX_DIR
}
)
FIND_PROGRAM
(
LIGHT_EXECUTABLE light
${
WIX_DIR
}
)
FIND_PROGRAM
(
LIGHT_EXECUTABLE light
${
WIX_DIR
}
)
CONFIGURE_FILE
(
${
CMAKE_CURRENT_SOURCE_DIR
}
/create_msi.cmake.in
CONFIGURE_FILE
(
${
CMAKE_CURRENT_SOURCE_DIR
}
/create_msi.cmake.in
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
@ONLY
)
@ONLY
)
CONFIGURE_FILE
(
${
CMAKE_CURRENT_SOURCE_DIR
}
/extra.wxs.in
CONFIGURE_FILE
(
${
CMAKE_CURRENT_SOURCE_DIR
}
/extra.wxs.in
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
@ONLY
@
@ONLY
)
)
IF
(
CMAKE_GENERATOR MATCHES
"Visual Studio"
)
IF
(
CMAKE_GENERATOR MATCHES
"Visual Studio"
)
SET
(
CONFIG_PARAM
"-DCMAKE_INSTALL_CONFIG_NAME=
${
CMAKE_CFG_INTDIR
}
"
)
SET
(
CONFIG_PARAM
"-DCMAKE_INSTALL_CONFIG_NAME=
${
CMAKE_CFG_INTDIR
}
"
)
ENDIF
()
ENDIF
()
ADD_CUSTOM_TARGET
(
ADD_CUSTOM_TARGET
(
MSI
MSI
COMMAND set VS_UNICODE_OUTPUT=
COMMAND set VS_UNICODE_OUTPUT=
COMMAND
${
CMAKE_COMMAND
}
COMMAND
${
CMAKE_COMMAND
}
-DCPACK_WIX_CONFIG=
${
CMAKE_CURRENT_SOURCE_DIR
}
/CPackWixConfig.cmake
-DCPACK_WIX_CONFIG=
${
CMAKE_CURRENT_SOURCE_DIR
}
/CPackWixConfig.cmake
-DCPACK_WIX_
EXTRA_SOURC
E=
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
-DCPACK_WIX_
INCLUD
E=
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
${
CONFIG_PARAM
}
${
CONFIG_PARAM
}
-P
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
-P
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
)
)
...
@@ -49,7 +68,7 @@ ADD_CUSTOM_TARGET(
...
@@ -49,7 +68,7 @@ ADD_CUSTOM_TARGET(
COMMAND set VS_UNICODE_OUTPUT=
COMMAND set VS_UNICODE_OUTPUT=
COMMAND
${
CMAKE_COMMAND
}
-DESSENTIALS=1
COMMAND
${
CMAKE_COMMAND
}
-DESSENTIALS=1
-DCPACK_WIX_CONFIG=
${
CMAKE_CURRENT_SOURCE_DIR
}
/CPackWixConfig.cmake
-DCPACK_WIX_CONFIG=
${
CMAKE_CURRENT_SOURCE_DIR
}
/CPackWixConfig.cmake
-DCPACK_WIX_
EXTRA_SOURC
E=
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
-DCPACK_WIX_
INCLUD
E=
${
CMAKE_CURRENT_BINARY_DIR
}
/extra.wxs
${
CONFIG_PARAM
}
${
CONFIG_PARAM
}
-P
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
-P
${
CMAKE_CURRENT_BINARY_DIR
}
/create_msi.cmake
)
)
...
...
packaging/WiX/create_msi.cmake.in
View file @
33b57ce2
...
@@ -274,21 +274,24 @@ FILE(APPEND directories.wxs "</DirectoryRef>\n")
...
@@ -274,21 +274,24 @@ FILE(APPEND directories.wxs "</DirectoryRef>\n")
FILE(READ directories.wxs CPACK_WIX_DIRECTORIES)
FILE(READ directories.wxs CPACK_WIX_DIRECTORIES)
FILE(REMOVE directories.wxs)
FILE(REMOVE directories.wxs)
FOREACH(src ${CPACK_WIX_INCLUDE})
SET(CPACK_WIX_INCLUDES
"${CPACK_WIX_INCLUDES}
<?include ${src}?>"
)
ENDFOREACH()
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mysql_server.wxs.in
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mysql_server.wxs.in
${CMAKE_CURRENT_BINARY_DIR}/mysql_server.wxs)
${CMAKE_CURRENT_BINARY_DIR}/mysql_server.wxs)
SET(WXS_FILES ${CMAKE_CURRENT_BINARY_DIR}/mysql_server.wxs ${CPACK_WIX_EXTRA_SOURCE})
SET(WIXOBJ_NATIVE_FILES)
SET(WXS_NATIVE_FILES)
FOREACH(f "${WXS_FILES}")
FILE(TO_NATIVE_PATH "${f}" f)
EXECUTE_PROCESS(COMMAND ${CANDLE_EXECUTABLE} ${f})
STRING(REPLACE ".wxs" ".wixobj" f "${f}")
LIST(APPEND WIXOBJ_NATIVE_FILES ${f})
ENDFOREACH()
FILE(REMOVE mysql_server.wixobj)
EXECUTE_PROCESS(
COMMAND ${CANDLE_EXECUTABLE} -ext WixUtilExtension mysql_server.wxs
)
EXECUTE_PROCESS(
EXECUTE_PROCESS(
COMMAND ${LIGHT_EXECUTABLE} -ext WixUIExtension ${WIXOBJ_NATIVE_FILES} -out ${CPACK_PACKAGE_FILE_NAME}.msi
COMMAND ${LIGHT_EXECUTABLE} -ext WixUIExtension -ext WixUtilExtension
mysql_server.wixobj -out ${CPACK_PACKAGE_FILE_NAME}.msi
)
)
packaging/WiX/extra.wxs.in
View file @
33b57ce2
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Include xmlns="http://schemas.microsoft.com/wix/2006/wi"
<Fragment>
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<DirectoryRef Id="INSTALLDIR">
<DirectoryRef Id='TARGETDIR'>
<Component Id="RegKeys" Guid="*">
<Component Id="RegKeys" Guid="*">
<RegistryKey
<RegistryKey
Id='MySQLKey'
Id='MySQLKey'
Root='HKLM'
Root='HKLM'
Key='SOFTWARE\MySQL AB\[ProductName]'
Key='SOFTWARE\MySQL AB\[ProductName]'
Action='createAndRemoveOnUninstall'>
Action='createAndRemoveOnUninstall'>
<RegistryValue
<RegistryValue
Type='string'
Type='string'
Name='Location'
Name='Location'
Value='[INSTALLDIR]'/>
Value='[INSTALLDIR]'/>
<RegistryValue
<RegistryValue
Type="string"
Type="string"
Name="Version"
Name="Version"
Value="[ProductVersion]"/>
Value="[ProductVersion]"/>
<RegistryValue
<RegistryValue
Type="string"
Type="string"
Name="DataLocation"
Name="DataLocation"
Value="[DATADIR]"/>
Value="[DATADIR]"/>
</RegistryKey>
</RegistryKey>
</Component>
</Component>
</DirectoryRef>
</DirectoryRef>
<Feature
Id='RegKeys'
<Feature
Display='hidden'
Id='RegKeys'
Level='1'>
Display='hidden'
<ComponentRef Id='RegKeys'/>
Level='1'>
</Feature>
<ComponentRef Id='RegKeys'/>
</Fragment>
</Feature>
</Wix>
\ No newline at end of file
<!-- Datafiles that installation will copy to CommonAppData (initial database)
They are declared Permanent and NeverOverwrite since it is user data -->
<DirectoryRef Id='TARGETDIR'>
<Directory Id="CommonAppDataFolder">
<Directory Id="datadir.mysql" Name="MySQL">
<Directory Id="datadir.mysql.mysqlserver"
Name="MySQL Server @MAJOR_VERSION@.@MINOR_VERSION@">
<Directory Id="DATADIR" Name=".">
<Component Id="component.datadir" Guid="d3491319-5dbc-4477-95f3-4f809ef1dd2d">
<CreateFolder>
<util:PermissionEx User="[LogonUser]" GenericAll="yes" />
</CreateFolder>
</Component>
<Directory Id="datadir.mysql.mysqlserver.data" Name="data">
<Directory Id="datadir.mysql.mysqlserver.data.mysql" Name="mysql">
<Component Id="component.datadir.mysql"
Guid="19ec0f1f-1a7f-424e-a788-b09346c0a709"
Permanent="yes" NeverOverwrite="yes">
@DATADIR_MYSQL_FILES@
</Component>
</Directory>
<Directory Id="datadir.mysql.mysqlserver.data.performance_schema"
Name="performance_schema">
<Component Id="component.datadir.performance_schema"
Guid="af2a6776-2655-431f-a748-9e9f4645acc3"
Permanent="yes" NeverOverwrite="yes">
@DATADIR_PERFORMANCE_SCHEMA_FILES@
</Component>
</Directory>
<Directory Id="datadir.mysql.mysqlserver.data.test" Name="test">
<Component Id="component.datadir.test" Guid="52fa9f0a-fcd1-420a-b2ac-95a8f70ad20a">
<CreateFolder/>
</Component>
</Directory>
</Directory>
</Directory>
</Directory>
</Directory>
</Directory>
</DirectoryRef>
<Feature Id="UserEditableDatafiles" Level='1' Display='hidden' ConfigurableDirectory="DATADIR">
<ComponentRef Id="component.datadir"/>
<ComponentRef Id="component.datadir.mysql"/>
<ComponentRef Id="component.datadir.performance_schema"/>
<ComponentRef Id="component.datadir.test"/>
</Feature>
</Include>
packaging/WiX/mysql_server.wxs.in
View file @
33b57ce2
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<Product
<Product
Id="*"
Id="*"
UpgradeCode="49EB7A6A-1CEF-4A1E-9E89-B9A4993963E3"
UpgradeCode="49EB7A6A-1CEF-4A1E-9E89-B9A4993963E3"
...
@@ -78,5 +79,8 @@
...
@@ -78,5 +79,8 @@
<!--CPACK_WIX_COMPONENTS_GROUPS -->
<!--CPACK_WIX_COMPONENTS_GROUPS -->
@CPACK_WIX_COMPONENT_GROUPS@
@CPACK_WIX_COMPONENT_GROUPS@
<!--CPACK_WIX_INCLUDES -->
@CPACK_WIX_INCLUDES@
</Product>
</Product>
</Wix>
</Wix>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment