Kaynağa Gözat

cmake: add new method to build deb package

cmd: cmake . && make  && make package
 output: WiingPi_lib-2.32.0-Linux.deb

Signed-off-by: sndnvaps <sndnvaps@gmail.com>
pull/48/head
sndnvaps 8 yıl önce
ebeveyn
işleme
3991ddd2f3
2 değiştirilmiş dosya ile 18 ekleme ve 0 silme
  1. +3
    -0
      .gitignore
  2. +15
    -0
      CMakeLists.txt

+ 3
- 0
.gitignore Dosyayı Görüntüle

@@ -10,3 +10,6 @@ CMakeFiles/
Makefile
cmake_install.cmake
install_manifest.txt
CPackConfig.cmake
CPackSourceConfig.cmake
_CPack_Packages/

+ 15
- 0
CMakeLists.txt Dosyayı Görüntüle

@@ -5,3 +5,18 @@ add_subdirectory(devLib)
add_subdirectory(gpio)
#add_subdirectory(pins)
add_subdirectory(wiringPi)

# Build deb package
# command to build *.deb
# cmake . && make && make package
SET(MAJOR_VERSION 2)
SET(MINOR_VERSION 32)
SET(PATCH_VERSION 0)
SET(CPACK_GENERATOR "DEB")
SET(CPACK_PACKAGE_VERSION_MAJOR "${MAJOR_VERSION}")
SET(CPACK_PACKAGE_VERSION_MINOR "${MINOR_VERSION}")
SET(CPACK_PACKAGE_VERSION_PATCH "${PATCH_VERSION}")
SET(CPACK_PACKAGE_DESCRIPTION "WiringPi Library for RaspberryPi")
SET(CPACK_PACKAGE_CONTACT "sndnvaps@gmail.com")
INCLUDE(CPack)


Yükleniyor…
İptal
Kaydet