mirror of https://gitee.com/cxasm/notepad--.git
cmake-deb-package: 增加声明发行版号,在构建时生成的文件中添加尾部声明
This commit is contained in:
parent
d5d4683d3f
commit
41f0802e84
|
@ -129,6 +129,12 @@ function(set_package_vars _IN_KEY _IN_VAL)
|
|||
message("--> 日历化版本: ${_IN_VAL}")
|
||||
endif(_CalVer EQUAL "0")
|
||||
|
||||
find_str("${_IN_KEY}" "OSD" _OSDVer)
|
||||
if(_OSDVer EQUAL "0")
|
||||
set(OSDVer "${_IN_VAL}" PARENT_SCOPE)
|
||||
message("--> 声明发行版号: ${_IN_VAL}")
|
||||
endif(_OSDVer EQUAL "0")
|
||||
|
||||
find_str("${_IN_KEY}" "Architecture" _Architecture)
|
||||
if(_Architecture EQUAL "0")
|
||||
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "${_IN_VAL}" PARENT_SCOPE)
|
||||
|
@ -264,6 +270,19 @@ function(add_package_descript IN_DES)
|
|||
endif("${CalVer}" STREQUAL "true")
|
||||
|
||||
|
||||
####################### OS Release ######################
|
||||
if("${OSDVer}" STREQUAL "true")
|
||||
exec_program(lsb_release ARGS -si
|
||||
OUTPUT_VARIABLE _OSI
|
||||
)
|
||||
exec_program(lsb_release ARGS -sr
|
||||
OUTPUT_VARIABLE _OSR
|
||||
)
|
||||
if(NOT "${_OSI}" STREQUAL "" AND NOT "${_OSR}" STREQUAL "")
|
||||
set(PACKAGE_SUFFIX "${PACKAGE_SUFFIX}_${_OSI}${_OSR}")
|
||||
endif(NOT "${_OSI}" STREQUAL "" AND NOT "${_OSR}" STREQUAL "")
|
||||
endif("${OSDVer}" STREQUAL "true")
|
||||
|
||||
|
||||
##################### deb file name #####################
|
||||
set(_Package "${CPACK_DEBIAN_PACKAGE_NAME}")
|
||||
|
|
|
@ -25,6 +25,8 @@ Package: com.hmja.notepad
|
|||
Version: auto
|
||||
# 日历化尾部版本
|
||||
CalVer: true
|
||||
# 声明发行版号(类似于 Debian11,Debian为OS标志,11为发行版号)
|
||||
OSD: true
|
||||
# 软件包架构(自动)
|
||||
Architecture: auto
|
||||
# 软件包属于的系统部分[admin|cli-mono|comm|database|debug|devel|doc|editors|education|electronics|embedded|fonts|games|gnome|gnu-r|gnustep|graphics|hamradio|haskell|httpd|interpreters|introspection|java|javascript|kde|kernel|libdevel|libs|lisp|localization|mail|math|metapackages|misc|net|news|ocaml|oldlibs|otherosfs|perl|php|python|ruby|rust|science|shells|sound|tasks|tex|text|utils|vcs|video|web|x11|xfce|zope]
|
||||
|
|
Loading…
Reference in New Issue