Added package automatic generation.
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
e80407eee5
commit
311e5b046e
107
.drone.yml
107
.drone.yml
|
@ -202,7 +202,112 @@ steps:
|
||||||
- name: debian-package-cache
|
- name: debian-package-cache
|
||||||
path: /var/cache/apt/archives
|
path: /var/cache/apt/archives
|
||||||
|
|
||||||
- name: notify
|
---
|
||||||
|
kind: pipeline
|
||||||
|
name: packages x86_64
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- name: debian-package-cache
|
||||||
|
host:
|
||||||
|
path: /var/cache/debian-package-cache
|
||||||
|
- name: centos-package-cache
|
||||||
|
host:
|
||||||
|
path: /var/cache/centos-package-cache
|
||||||
|
|
||||||
|
trigger:
|
||||||
|
event:
|
||||||
|
- tag
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: download
|
||||||
|
image: plugins/download
|
||||||
|
settings:
|
||||||
|
source: https://raw.githubusercontent.com/badaix/popl/v1.2.0/include/popl.hpp
|
||||||
|
destination: src/popl.hpp
|
||||||
|
|
||||||
|
- name: deb
|
||||||
|
image: debian:stretch-slim
|
||||||
|
pull: always
|
||||||
|
environment:
|
||||||
|
LANG: C.utf8
|
||||||
|
CXX: g++-6
|
||||||
|
CXXFLAGS: -pipe -O2
|
||||||
|
commands:
|
||||||
|
- rm /etc/apt/apt.conf.d/docker-clean
|
||||||
|
- echo "APT::Default-Release \"stretch\";" >> /etc/apt/apt.conf.d/00default_release
|
||||||
|
- echo "deb http://deb.debian.org/debian sid main" >> /etc/apt/sources.list.d/sid.list
|
||||||
|
- apt-get update -q
|
||||||
|
- apt-get install -qy g++-6 cmake pkg-config
|
||||||
|
- apt-get install -qy libcurl4-openssl-dev libxdg-basedir-dev libvsqlitepp-dev libboost-system-dev libboost-filesystem-dev asciidoc catch
|
||||||
|
- apt-get install -qy -t sid libcurlpp-dev
|
||||||
|
- apt-get install -qy build-essential file
|
||||||
|
- rm -rf build && mkdir -p build && cd build
|
||||||
|
- cmake -DCMAKE_INSTALL_PREFIX=/usr -DWITH_DEB=YES ..
|
||||||
|
- make package
|
||||||
|
- cp -v remwharead_${DRONE_TAG}-0_amd64.deb ..
|
||||||
|
volumes:
|
||||||
|
- name: debian-package-cache
|
||||||
|
path: /var/cache/apt/archives
|
||||||
|
|
||||||
|
- name: rpm
|
||||||
|
image: centos:7
|
||||||
|
pull: always
|
||||||
|
environment:
|
||||||
|
LANG: C.utf8
|
||||||
|
CXXFLAGS: -pipe -O2
|
||||||
|
commands:
|
||||||
|
- sed -i 's/keepcache=0/keepcache=1/' /etc/yum.conf
|
||||||
|
- curl -s -o /var/cache/yum/epel-release-latest-7.noarch.rpm http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
|
||||||
|
- rpm -i /var/cache/yum/epel-release-latest-7.noarch.rpm
|
||||||
|
- yum install -qy centos-release-scl
|
||||||
|
- yum install -qy devtoolset-6
|
||||||
|
- scl enable devtoolset-6 bash
|
||||||
|
- yum install -qy libcurl-devel rpm-build libxdg-basedir boost-devel boost-system boost-filesystem asciidoc
|
||||||
|
- yum --enablerepo=epel install -qy cmake3 vsqlite++-devel
|
||||||
|
- curl -s -o /var/cache/yum/curlpp-devel-0.7.3-5.el6.x86_64.rpm https://download.fedoraproject.org/pub/epel/6/x86_64/Packages/c/curlpp-devel-0.7.3-5.el6.x86_64.rpm
|
||||||
|
- curl -s -o /var/cache/yum/curlpp-0.7.3-5.el6.x86_64.rpm https://download.fedoraproject.org/pub/epel/6/x86_64/Packages/c/curlpp-0.7.3-5.el6.x86_64.rpm
|
||||||
|
- yum localinstall -qy /var/cache/yum/curlpp-*
|
||||||
|
- rm -rf build && mkdir -p build && cd build
|
||||||
|
- cmake3 -DCMAKE_INSTALL_PREFIX=/usr -DWITH_RPM=YES ..
|
||||||
|
- make package
|
||||||
|
- cp -v remwharead-${DRONE_TAG}-0.x86_64.rpm ..
|
||||||
|
volumes:
|
||||||
|
- name: centos-package-cache
|
||||||
|
path: /var/cache/yum
|
||||||
|
|
||||||
|
- name: gitea_release
|
||||||
|
image: plugins/gitea-release
|
||||||
|
pull: always
|
||||||
|
settings:
|
||||||
|
base_url: https://schlomp.space
|
||||||
|
api_key:
|
||||||
|
from_secret: gitea_token
|
||||||
|
title: ${DRONE_TAG}
|
||||||
|
prerelease: true
|
||||||
|
files:
|
||||||
|
- remwharead_${DRONE_TAG}-0_amd64.deb
|
||||||
|
- remwharead-${DRONE_TAG}-0.x86_64.rpm
|
||||||
|
checksum:
|
||||||
|
- sha512
|
||||||
|
|
||||||
|
---
|
||||||
|
kind: pipeline
|
||||||
|
name: notify
|
||||||
|
|
||||||
|
depends_on:
|
||||||
|
- x86_64
|
||||||
|
- packages x86_64
|
||||||
|
|
||||||
|
trigger:
|
||||||
|
status:
|
||||||
|
- success
|
||||||
|
- failure
|
||||||
|
|
||||||
|
clone:
|
||||||
|
disable: true
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: email
|
||||||
image: drillster/drone-email
|
image: drillster/drone-email
|
||||||
pull: always
|
pull: always
|
||||||
settings:
|
settings:
|
||||||
|
|
|
@ -68,3 +68,5 @@ if(WITH_TESTS)
|
||||||
target_link_libraries(${PROJECT_NAME}_testlib ${COMMON_LIBRARIES})
|
target_link_libraries(${PROJECT_NAME}_testlib ${COMMON_LIBRARIES})
|
||||||
include(tests.CMakeLists.txt)
|
include(tests.CMakeLists.txt)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
include(packages.CMakeLists.txt)
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
an URI to the archived version, the current date and time, title, description,
|
an URI to the archived version, the current date and time, title, description,
|
||||||
the full text of the page and optional tags.
|
the full text of the page and optional tags.
|
||||||
|
|
||||||
.AsciiDoc export formatted with Asciidoctor
|
.AsciiDoc export formatted with Asciidoctor.
|
||||||
====
|
====
|
||||||
image::https://doc.schlomp.space/remwharead/example_dates.png[Dates view, width=400, link="https://doc.schlomp.space/remwharead/example_dates.png", role=left]
|
image::https://doc.schlomp.space/remwharead/example_dates.png[Dates view, width=400, link="https://doc.schlomp.space/remwharead/example_dates.png", role=left]
|
||||||
image::https://doc.schlomp.space/remwharead/example_tags.png[Tags view, width=400, link="https://doc.schlomp.space/remwharead/example_tags.png"]
|
image::https://doc.schlomp.space/remwharead/example_tags.png[Tags view, width=400, link="https://doc.schlomp.space/remwharead/example_tags.png"]
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
set(CPACK_PACKAGE_NAME ${PROJECT_NAME})
|
||||||
|
set(CPACK_PACKAGE_VERSION_MAJOR ${${PROJECT_NAME}_VERSION_MAJOR})
|
||||||
|
set(CPACK_PACKAGE_VERSION_MINOR ${${PROJECT_NAME}_VERSION_MINOR})
|
||||||
|
set(CPACK_PACKAGE_VERSION_PATCH ${${PROJECT_NAME}_VERSION_PATCH})
|
||||||
|
set(CPACK_PACKAGE_VERSION ${${PROJECT_NAME}_VERSION})
|
||||||
|
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Saves URIs of things you want to remember in a database. ")
|
||||||
|
set(CPACK_PACKAGE_CONTACT "tastytea <tastytea@tastytea.de>")
|
||||||
|
set(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/LICENSE")
|
||||||
|
set(CPACK_RESOURCE_FILE_README "${PROJECT_SOURCE_DIR}/README.adoc")
|
||||||
|
list(APPEND CPACK_SOURCE_IGNORE_FILES "/\\\\.git"
|
||||||
|
"/.gitignore"
|
||||||
|
"/build/"
|
||||||
|
"/.drone.yml")
|
||||||
|
execute_process(COMMAND uname -m
|
||||||
|
OUTPUT_VARIABLE CPACK_PACKAGE_ARCHITECTURE
|
||||||
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
|
set(CPACK_PACKAGE_FILE_NAME
|
||||||
|
"${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}_${CPACK_PACKAGE_ARCHITECTURE}")
|
||||||
|
set(CPACK_GENERATOR "TGZ")
|
||||||
|
set(CPACK_SOURCE_GENERATOR "TGZ")
|
||||||
|
|
||||||
|
if (WITH_DEB)
|
||||||
|
set(CPACK_PACKAGE_NAME "lib${PROJECT_NAME}")
|
||||||
|
set(CPACK_GENERATOR "DEB")
|
||||||
|
set(CPACK_SOURCE_GENERATOR "DEB")
|
||||||
|
set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://schlomp.space/tastytea/${PROJECT_NAME}")
|
||||||
|
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS ON)
|
||||||
|
execute_process(COMMAND dpkg --print-architecture
|
||||||
|
OUTPUT_VARIABLE CPACK_DEBIAN_PACKAGE_ARCHITECTURE
|
||||||
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
|
set(CPACK_PACKAGE_FILE_NAME
|
||||||
|
"${CPACK_PACKAGE_NAME}_${CPACK_PACKAGE_VERSION}-0_${CPACK_DEBIAN_PACKAGE_ARCHITECTURE}")
|
||||||
|
set(CPACK_SOURCE_PACKAGE_FILE_NAME
|
||||||
|
"${CPACK_PACKAGE_NAME}_${CPACK_PACKAGE_VERSION}-0_src")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WITH_RPM)
|
||||||
|
set(CPACK_PACKAGE_NAME "lib${PROJECT_NAME}")
|
||||||
|
set(CPACK_GENERATOR "RPM")
|
||||||
|
set(CPACK_SOURCE_GENERATOR "RPM")
|
||||||
|
set(CPACK_RPM_PACKAGE_LICENSE "GPL-3")
|
||||||
|
set(CPACK_RPM_PACKAGE_URL "https://schlomp.space/tastytea/${PROJECT_NAME}")
|
||||||
|
set(CPACK_RPM_PACKAGE_REQUIRES "curlpp >= 0.8.1, libxdg-basedir, vsqlite++ >= 0.3.13")
|
||||||
|
set(CPACK_PACKAGE_FILE_NAME
|
||||||
|
"${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}-0.${CPACK_PACKAGE_ARCHITECTURE}")
|
||||||
|
set(CPACK_SOURCE_PACKAGE_FILE_NAME
|
||||||
|
"${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}-0.src")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
include(CPack)
|
Loading…
Reference in New Issue