Commit d079ca39 authored by Mateusz Gniewkowski's avatar Mateusz Gniewkowski

Merge branch 'deb' into 'master'

Deb

See merge request !1
parents 81917369 319c05e1
Pipeline #2251 passed with stages
in 4 minutes and 58 seconds
image: clarinpl/cpp
stages:
- build
- deploy
build_deb:
stage: build
only:
- master
- deb
script:
- apt-get install -y apt-transport-https
- bash -c "wget -q -O - http://apt.clarin-pl.eu/KEY.gpg | apt-key add -"
- bash -c "echo 'deb https://apt.clarin-pl.eu/ /' > /etc/apt/sources.list.d/clarin.list"
- apt-get update && apt-get install -y
corpus2-python3.6
- mkdir build && cd build
- cmake .. && cmake --build . && cpack
artifacts:
paths:
- build/toki*.deb
expire_in: 1h
push_deb:
stage: deploy
only:
- master
- deb
script:
- FILE=$(ls build/toki*.deb)
- curl --fail -i -X POST -F "file=@./${FILE}" -u "${APT_USERNAME}:${APT_PASSWORD}" https://apt.clarin-pl.eu/
dependencies:
- build_deb
PROJECT(Tokenizer)
PROJECT(toki)
cmake_minimum_required(VERSION 2.6.0)
set(toki_ver_major "1")
set(toki_ver_minor "0")
set(toki_ver_patch "0")
set(TOKI_VERSION
"${toki_ver_major}.${toki_ver_minor}.${toki_ver_patch}")
SET(CMAKE_INSTALL_PREFIX, "/usr")
# use some of our own Find* scripts
set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/CMakeScripts)
......@@ -48,3 +56,17 @@ if(UNIX)
add_subdirectory(tests)
endif(UNIX)
add_subdirectory(toki-app)
# Requires to install dependencies
set(CPACK_DEBIAN_PACKAGE_DEPENDS "libboost-all-dev, libicu-dev, corpus2-python3.6, libloki-dev")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "")
# Set *.deb package name and version
SET(CPACK_PACKAGE_VERSION "${TOKI_VERSION}")
SET(CPACK_GENERATOR "DEB")
SET(CPACK_DEBIAN_PACKAGE_MAINTAINER "g419")
set(CPACK_SYSTEM_NAME "all")
set(CPACK_TOPLEVEL_TAG "all")
INCLUDE(CPack)
......@@ -35,6 +35,7 @@ include_directories(${Boost_INCLUDE_DIR})
link_directories(${Boost_LIBRARY_DIRS})
set(LIBS ${LIBS} ${Boost_LIBRARIES})
set(CMAKE_INSTALL_PREFIX /usr)
set(LIBTOKI_INSTALL_DATA_DIR share/toki)
set(LIBTOKI_PATH_SEPARATOR ";")
set(LIBTOKI_DATA_DIR ".;${CMAKE_INSTALL_PREFIX}/${LIBTOKI_INSTALL_DATA_DIR}")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment