Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
CMake
CMake
Commits
e65c40f9
Commit
e65c40f9
authored
Oct 31, 2007
by
Bill Hoffman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ENH: add CPACK_PROJECT_CONFIG_FILE option to CPack
parent
fb621fee
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
12 deletions
+18
-12
CMakeCPack.cmake
CMakeCPack.cmake
+3
-0
CMakeCPackOptions.cmake.in
CMakeCPackOptions.cmake.in
+6
-3
CPackSourceConfig.cmake.in
CPackSourceConfig.cmake.in
+0
-8
Source/CPack/cmCPackGenericGenerator.cxx
Source/CPack/cmCPackGenericGenerator.cxx
+9
-1
No files found.
CMakeCPack.cmake
View file @
e65c40f9
...
...
@@ -4,6 +4,9 @@ IF(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")
SET
(
CMAKE_INSTALL_MFC_LIBRARIES 1
)
INCLUDE
(
InstallRequiredSystemLibraries
)
ENDIF
(
EXISTS
"
${
CMAKE_ROOT
}
/Modules/InstallRequiredSystemLibraries.cmake"
)
CONFIGURE_FILE
(
"
${
CMake_SOURCE_DIR
}
/CMakeCPackOptions.cmake.in"
"
${
CMake_BINARY_DIR
}
/CMakeCPackOptions.cmake"
@ONLY
)
SET
(
CPACK_PROJECT_CONFIG_FILE
"
${
CMake_BINARY_DIR
}
/CMakeCPackOptions.cmake"
)
SET
(
CPACK_PACKAGE_DESCRIPTION_SUMMARY
"CMake is a build tool"
)
SET
(
CPACK_PACKAGE_VENDOR
"Kitware"
)
SET
(
CPACK_PACKAGE_DESCRIPTION_FILE
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/Copyright.txt"
)
...
...
C
PackConfig
.cmake.in
→
C
MakeCPackOptions
.cmake.in
View file @
e65c40f9
# all CPACK_ variables from the cmake project
@_CPACK_OTHER_VARIABLES_@
if(CPACK_GENERATOR MATCHES "NSIS")
# set the install/unistall icon used for the installer itself
# There is a bug in NSI that does not handle full unix paths properly.
...
...
@@ -31,3 +28,9 @@ if(CPACK_GENERATOR MATCHES "NSIS")
SET(CPACK_NSIS_CONTACT @CPACK_PACKAGE_CONTACT@)
SET(CPACK_NSIS_MODIFY_PATH ON)
endif(CPACK_GENERATOR MATCHES "NSIS")
if(CPACK_GENERATOR MATCHES "CygwinSource")
# when packaging source make sure the .build directory is not included
SET(CPACK_SOURCE_IGNORE_FILES
"/CVS/" "/\\.build/" "/\\.svn/" "\\.swp$" "\\.#" "/#" "~$")
endif(CPACK_GENERATOR MATCHES "CygwinSource")
CPackSourceConfig.cmake.in
deleted
100644 → 0
View file @
fb621fee
# All CPACK_ variables from the cmake project
@_CPACK_OTHER_VARIABLES_@
if(CPACK_GENERATOR MATCHES "CygwinSource")
# when packaging source make sure the .build directory is not included
SET(CPACK_SOURCE_IGNORE_FILES
"/CVS/" "/\\.build/" "/\\.svn/" "\\.swp$" "\\.#" "/#" "~$")
endif(CPACK_GENERATOR MATCHES "CygwinSource")
Source/CPack/cmCPackGenericGenerator.cxx
View file @
e65c40f9
...
...
@@ -60,7 +60,6 @@ void cmCPackGenericGenerator::DisplayVerboseOutput(const char* msg,
//----------------------------------------------------------------------
int
cmCPackGenericGenerator
::
PrepareNames
()
{
this
->
SetOption
(
"CPACK_GENERATOR"
,
this
->
Name
.
c_str
());
std
::
string
tempDirectory
=
this
->
GetOption
(
"CPACK_PACKAGE_DIRECTORY"
);
tempDirectory
+=
"/_CPack_Packages/"
;
...
...
@@ -754,6 +753,15 @@ int cmCPackGenericGenerator::Initialize(const char* name, cmMakefile* mf,
"Cannot initialize the generator"
<<
std
::
endl
);
return
0
;
}
// set the running generator name
this
->
SetOption
(
"CPACK_GENERATOR"
,
this
->
Name
.
c_str
());
// Load the project specific config file
const
char
*
config
=
this
->
GetOption
(
"CPACK_PROJECT_CONFIG_FILE"
);
if
(
config
)
{
mf
->
ReadListFile
(
config
);
}
int
result
=
this
->
InitializeInternal
();
if
(
cmSystemTools
::
GetErrorOccuredFlag
())
{
...
...
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