2016-06-12 11:32:30 +00:00
|
|
|
# .gitlab-ci.yml -- to test some source code build scenarios
|
2019-02-02 01:38:35 +00:00
|
|
|
# Copyright (C) 2016-2019 Olaf Meeuwissen
|
2016-06-12 11:32:30 +00:00
|
|
|
#
|
|
|
|
# License: GPL-3.0+
|
|
|
|
|
|
|
|
variables:
|
|
|
|
REGISTRY_HUB: "registry.gitlab.com/sane-project/ci-envs"
|
2016-07-09 06:10:00 +00:00
|
|
|
CONFIGURE_MINI: "--enable-silent-rules"
|
|
|
|
CONFIGURE_FULL: "--with-usb --enable-avahi --enable-pnm-backend"
|
2016-06-12 11:32:30 +00:00
|
|
|
|
2017-06-02 12:08:44 +00:00
|
|
|
stages:
|
2017-06-17 03:38:21 +00:00
|
|
|
- prepare
|
|
|
|
- compile
|
|
|
|
- archive
|
2019-07-30 13:40:11 +00:00
|
|
|
- release
|
2017-06-02 12:08:44 +00:00
|
|
|
|
2017-06-17 03:38:21 +00:00
|
|
|
prepare:
|
2019-07-14 05:03:56 +00:00
|
|
|
image: $REGISTRY_HUB:debian-stretch-mini
|
2017-06-17 03:38:21 +00:00
|
|
|
stage: prepare
|
2017-06-02 12:08:44 +00:00
|
|
|
script:
|
2019-06-29 08:08:52 +00:00
|
|
|
- git ls-files | xargs ./tools/style-check.sh
|
2019-06-05 14:34:56 +00:00
|
|
|
- ./autogen.sh
|
2019-06-29 06:57:04 +00:00
|
|
|
- ./tools/create-changelog.sh
|
2019-06-29 08:29:15 +00:00
|
|
|
- ./tools/update-upstreams.sh
|
2019-06-05 14:34:56 +00:00
|
|
|
- ./configure
|
|
|
|
- make dist
|
2017-06-17 03:38:21 +00:00
|
|
|
artifacts:
|
|
|
|
paths:
|
2019-06-05 14:34:56 +00:00
|
|
|
- sane-backends-*.tar.gz
|
2017-06-17 03:38:21 +00:00
|
|
|
expire_in: 1 day
|
2017-06-02 12:08:44 +00:00
|
|
|
|
2017-06-17 03:38:21 +00:00
|
|
|
.compile_template: &compile_definition
|
|
|
|
stage: compile
|
2016-06-12 11:32:30 +00:00
|
|
|
script:
|
2019-06-05 14:34:56 +00:00
|
|
|
- mkdir build
|
2019-06-06 11:37:08 +00:00
|
|
|
- cd build
|
2019-06-06 11:50:29 +00:00
|
|
|
- tar xzf ../sane-backends-*.tar.gz --strip-components=1
|
2019-06-06 11:37:08 +00:00
|
|
|
- ./configure $CONFIGURE_OPTS
|
|
|
|
- make -j2 -k $MAKE_FLAGS
|
2016-06-12 11:32:30 +00:00
|
|
|
|
2017-06-22 11:36:59 +00:00
|
|
|
compile:debian-9-mini:
|
2019-07-14 05:03:56 +00:00
|
|
|
image: $REGISTRY_HUB:debian-stretch-mini
|
2017-06-22 11:36:59 +00:00
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI"
|
2019-05-22 12:48:32 +00:00
|
|
|
MAKE_FLAGS: "CFLAGS=-Werror"
|
2017-06-22 11:36:59 +00:00
|
|
|
<<: *compile_definition
|
|
|
|
|
|
|
|
compile:debian-9-full:
|
2019-07-14 05:03:56 +00:00
|
|
|
image: $REGISTRY_HUB:debian-stretch-full
|
2017-06-22 11:36:59 +00:00
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI $CONFIGURE_FULL"
|
2019-05-22 12:48:32 +00:00
|
|
|
MAKE_FLAGS: "CFLAGS=-Werror CXXFLAGS=-Werror"
|
2017-06-22 11:36:59 +00:00
|
|
|
<<: *compile_definition
|
2018-03-15 00:22:53 +00:00
|
|
|
after_script:
|
2019-06-05 14:34:56 +00:00
|
|
|
- make -C build/doc html-pages
|
|
|
|
- rm -rf lists && mkdir lists && mv build/doc/*.html lists/
|
|
|
|
- cd build/doc && doxygen doxygen-sanei.conf && mv sanei-html ../../doc
|
2018-03-15 00:22:53 +00:00
|
|
|
artifacts:
|
|
|
|
paths:
|
2019-06-05 14:34:56 +00:00
|
|
|
- sane-backends-*.tar.gz
|
2018-03-15 00:22:53 +00:00
|
|
|
- lists
|
|
|
|
- doc/sanei-html
|
|
|
|
expire_in: 1 day
|
2017-06-22 11:36:59 +00:00
|
|
|
|
2019-07-14 05:03:56 +00:00
|
|
|
compile:debian-10-mini:
|
|
|
|
image: $REGISTRY_HUB:debian-buster-mini
|
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI"
|
|
|
|
#MAKE_FLAGS: "CFLAGS=-Werror"
|
|
|
|
<<: *compile_definition
|
|
|
|
|
|
|
|
compile:debian-10-full:
|
|
|
|
image: $REGISTRY_HUB:debian-buster-full
|
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI $CONFIGURE_FULL"
|
|
|
|
#MAKE_FLAGS: "CFLAGS=-Werror"
|
|
|
|
<<: *compile_definition
|
|
|
|
|
2019-05-04 00:19:26 +00:00
|
|
|
compile:fedora-29-clang:
|
|
|
|
image: $REGISTRY_HUB:fedora-29-clang
|
2017-07-15 08:19:38 +00:00
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI $CONFIGURE_FULL"
|
|
|
|
<<: *compile_definition
|
|
|
|
|
2019-05-04 00:19:26 +00:00
|
|
|
compile:fedora-30-clang:
|
|
|
|
image: $REGISTRY_HUB:fedora-30-clang
|
2018-03-15 00:04:31 +00:00
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI $CONFIGURE_FULL"
|
|
|
|
<<: *compile_definition
|
|
|
|
|
2019-06-20 11:02:15 +00:00
|
|
|
compile:alpine-3.10-musl:
|
|
|
|
image: $REGISTRY_HUB:alpine-3.10-musl
|
2018-03-15 00:41:58 +00:00
|
|
|
variables:
|
|
|
|
CONFIGURE_OPTS: "$CONFIGURE_MINI $CONFIGURE_FULL"
|
|
|
|
<<: *compile_definition
|
|
|
|
|
2017-06-17 03:38:21 +00:00
|
|
|
archive:
|
2019-07-14 05:03:56 +00:00
|
|
|
image: $REGISTRY_HUB:debian-stretch-full
|
2017-06-17 03:38:21 +00:00
|
|
|
stage: archive
|
|
|
|
dependencies:
|
2018-03-15 00:22:53 +00:00
|
|
|
- compile:debian-9-full
|
2019-06-05 14:39:44 +00:00
|
|
|
script:
|
2019-07-03 13:19:52 +00:00
|
|
|
- tar xzf sane-backends-*.tar.gz --strip-components=1
|
|
|
|
- rm sane-backends-*.tar.gz
|
|
|
|
- ./configure
|
|
|
|
- make distcheck
|
2017-06-17 03:38:21 +00:00
|
|
|
artifacts:
|
|
|
|
paths:
|
|
|
|
- sane-backends-*.tar.gz
|
2018-02-21 11:50:07 +00:00
|
|
|
- lists
|
2018-03-10 01:14:06 +00:00
|
|
|
- doc/sanei-html
|
2019-07-30 13:40:11 +00:00
|
|
|
|
|
|
|
release:
|
|
|
|
image: alpine
|
|
|
|
stage: release
|
|
|
|
before_script:
|
|
|
|
- apk --no-cache add curl git jq
|
|
|
|
script:
|
|
|
|
- ./tools/create-release.sh
|
|
|
|
only:
|
|
|
|
- tags
|
|
|
|
when: manual
|
|
|
|
variables:
|
|
|
|
GIT_DEPTH: "3"
|
|
|
|
allow_failure: false
|