Questions tagged [cpack]

CPack is a packing and install tool for CMake generated projects

CPack is develop by Kitware to generated a package (install file) from your CMake generated projects. It is, like CMake, multi platfom aware and used different generators for different platforms, e.g. NSIS for windows plattforms.

It is been shipped with your CMake installation.

The documents can be found here.

330 questions
4
votes
2 answers

cpack component level install

For the example CMakeLists.txt attached to CMake wiki. I also added below what is the actual make command to create just the component based TGZ. I am confused and not seeing any help in the documents. CMakeLists.txt cmake_minimum_required(VERSION…
user2322491
  • 109
  • 1
  • 9
4
votes
1 answer

How to disable CPACK_PACKAGE_VERSION_PATCH in CMakeLists.txt?

I am still a CMake newbie (started learning 3 days ago). In my current CMakeLists.txt, I have the following set directives: [...] SET(CPACK_GENERATOR "RPM") SET(CPACK_PACKAGE_VERSION_MAJOR "3") SET(CPACK_PACKAGE_VERSION_MINOR…
user183394
  • 1,033
  • 1
  • 11
  • 20
4
votes
2 answers

Name and description of multiple debian packages with CMake and CPack

I am currently trying to generate more than one debian package from my project. My only problem with this is setting the name, description, group and so forth of the packages. # -------------------------------------------------------------- #…
padde
  • 661
  • 8
  • 19
3
votes
1 answer

cpack deb generator components output names

install (TARGETS ${PROJECT_NAME}_shared DESTINATION ${CMAKE_INSTALL_PREFIX}/lib COMPONENT runtime) install (TARGETS ${PROJECT_NAME}_static DESTINATION ${CMAKE_INSTALL_PREFIX}/lib COMPONENT development) install (FILES ${INCLUDES}…
puchu
  • 3,294
  • 6
  • 38
  • 62
3
votes
1 answer

How to create desktop icons for a deb package created with CPack?

I am using CMake/CPack for my project. On Windows, I use CPack with NSIS, and it's all good. But for Linux, I use the DEB generator for CPack, and I have run into a few issues. Namely, I cannot find a proper way to add an icon in the menu of…
Amy
  • 1,814
  • 2
  • 23
  • 38
3
votes
1 answer

How to sign Windows binaries and NSIS installers when building with cmake + cpack

I am building an NSIS installer that includes a shared library and a set of tools that use that library. I need to sign everything so users can install it without getting scary warnings from Windows. In all my searches on this question, and…
msc
  • 1,549
  • 2
  • 12
  • 19
3
votes
1 answer

How can I make CPACK include 3rd party DLLs into the installer?

I've written a CMakeLists.txt as shown below: cmake_minimum_required (VERSION 3.22) project(tutorial) set(wxWidgets_CONFIGURATION mswu) find_package(wxWidgets REQUIRED COMPONENTS net core…
Jumogehn
  • 1,102
  • 3
  • 11
  • 29
3
votes
1 answer

What is the best way of creating several rpm's (deb's) packages in one CMake project?

I need to create several different rpm's (deb's) (with different list of files) from one CMake project. What is the best way for this? Can some one suggest some project (CMakeList.txt) with such options?
3
votes
1 answer

How to get CMake/CPack to generate multiple packages for different OSs and different architectures within each OS?

Say I have the following basic CMakeLists.txt file. target_include_directories( addnum PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include" ) add_executable(addnumapp src/main.cpp) target_link_libraries(addnumapp addnum) SET(CPACK_GENERATOR…
ptk
  • 6,835
  • 14
  • 45
  • 91
3
votes
0 answers

CPACK_DEBIAN_DEBUGINFO_PACKAGE with partial debug symbols

I'm trying to generate a dbgsym package alongside my regular debian package from CPack. I am using the CPACK_DEBIAN_DEBUGINFO_PACKAGE option for this. This works as long as either everything in my project contains debug symbols, or I generate…
Martijn Otto
  • 878
  • 4
  • 21
3
votes
2 answers

NSIS Installer Application name not displayed right

I built an application with CPack and NSIS and defined a rather long application name (it's for work, so I censored it a bit). When starting the installer the name is cut off. I already tried removing the spaces in the name, adding ' ' to the string…
3
votes
1 answer

CMake fix_bundle how to ignore embedded dll

My system has some dlls that are linked in other embedded executables, like commands from MSYS. Directories structure: MySystem/ |_ mysystem.exe |_ CMakeLists.txt |_ embedded system/ |_ msys_command1.exe |_ msys_command2.exe …
Avancini
  • 53
  • 4
3
votes
1 answer

How do you run cpack from visual studio?

I am porting some packages from Linux to windows and I've found that visual studio has quite good integration with cmake. I am able to configure and build the project using cmake but I cannot figure out how to run cpack to create the installation…
Bruce Adams
  • 4,953
  • 4
  • 48
  • 111
3
votes
1 answer

prevent creation of namelink for installed shared libraries when using CPack

I'm building two packages in a distribution: runtime shared library package dev libary package The problem is to include a correct symlink into any of them. Currently I use: set_target_properties(mylib PROPERTIES SOVERSION…
St.Antario
  • 26,175
  • 41
  • 130
  • 318
3
votes
1 answer

Why should include(CPack) go after the per project package configuration?

I'm experimenting with CPack module of CMake and got somewhat confusing behavior. I have CpackMylib.cmake that is included into a root CMakeLists.txt. It looks as follows: include(CPack) #included on top install (TARGETS mylib …
St.Antario
  • 26,175
  • 41
  • 130
  • 318