mirror of
https://github.com/Kitware/CMake.git
synced 2025-10-16 14:08:35 +08:00
CPackDeb: allow empty directories in component packages
This commit is contained in:

committed by
Domen Vrankar

parent
cec45e27f6
commit
47b060aee0
@@ -95,6 +95,7 @@ int cmCPackDebGenerator::PackageOnePack(std::string initialTopLevel,
|
|||||||
std::string findExpr(this->GetOption("GEN_WDIR"));
|
std::string findExpr(this->GetOption("GEN_WDIR"));
|
||||||
findExpr += "/*";
|
findExpr += "/*";
|
||||||
gl.RecurseOn();
|
gl.RecurseOn();
|
||||||
|
gl.SetRecurseListDirs(true);
|
||||||
if ( !gl.FindFiles(findExpr) )
|
if ( !gl.FindFiles(findExpr) )
|
||||||
{
|
{
|
||||||
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
||||||
@@ -222,6 +223,7 @@ int cmCPackDebGenerator::PackageComponentsAllInOne()
|
|||||||
std::string findExpr(this->GetOption("GEN_WDIR"));
|
std::string findExpr(this->GetOption("GEN_WDIR"));
|
||||||
findExpr += "/*";
|
findExpr += "/*";
|
||||||
gl.RecurseOn();
|
gl.RecurseOn();
|
||||||
|
gl.SetRecurseListDirs(true);
|
||||||
if ( !gl.FindFiles(findExpr) )
|
if ( !gl.FindFiles(findExpr) )
|
||||||
{
|
{
|
||||||
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
||||||
|
@@ -110,9 +110,8 @@ install(FILES ${CPackComponentsDEB_BINARY_DIR}/symtest
|
|||||||
if(EXISTS "./dirtest")
|
if(EXISTS "./dirtest")
|
||||||
execute_process(COMMAND ${CMAKE_COMMAND} -E remove_directory ./dirtest)
|
execute_process(COMMAND ${CMAKE_COMMAND} -E remove_directory ./dirtest)
|
||||||
endif()
|
endif()
|
||||||
|
# NOTE: directory left empty on purpose
|
||||||
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ./dirtest)
|
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ./dirtest)
|
||||||
# BUG: apparently cannot add an empty directory
|
|
||||||
execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink ../mylibapp ./dirtest/symtest)
|
|
||||||
# NOTE: we should not add the trailing "/" to dirtest
|
# NOTE: we should not add the trailing "/" to dirtest
|
||||||
install(DIRECTORY ${CPackComponentsDEB_BINARY_DIR}/dirtest
|
install(DIRECTORY ${CPackComponentsDEB_BINARY_DIR}/dirtest
|
||||||
DESTINATION bin/
|
DESTINATION bin/
|
||||||
|
Reference in New Issue
Block a user