Build fixes for Alpine latest (#246)

* trying alpine

* Make directory /usr/local/src/ for Alpine based distros

* fixes some alpine issue

* move gem install etc to its own task

* moved gem install etc for alphine into dependencies

* reenabling all ci tests

* typo fix as per review

* clarity around doc build disable being gnupg docs

* commit about ignoring non-zero return value
pull/247/head
Simon Massey 6 years ago committed by GitHub
parent bbcd50e563
commit b504facc5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -60,6 +60,11 @@
when:
- ansible_os_family == "RedHat"
- name: Install gnupg build dependencies for Alpine based distros
command: bash -lc "apk add gnutls-dev libksba-dev libgcrypt-dev libgpg-error-dev npth-dev zlib-dev libassuan-dev bzip2-dev sqlite-dev libusb-dev"
when:
- ansible_os_family == "Alpine"
- name: Install rspec in /usr/local/bin for RedHat based distros
command: bash -lc "gem install -n /usr/local/bin rspec"
when:
@ -90,6 +95,11 @@
retries: 5
delay: 10
- name: Make directory /usr/local/src/ for Alpine based distros
command: bash -lc "mkdir -p /usr/local/src/"
when:
- ansible_os_family == "Alpine"
- name: Extract gnupg source tarball
unarchive:
src: /tmp/gnupg.tar.gz
@ -132,6 +142,15 @@
command: bash -lc "cd {{ gpg_src_path }} && ./configure {{ gpg_build_config }}"
changed_when: False
# disable gnupg doc build on alpine as it is not detecting an absence of graphical tools such as fig2dev on alpine
- name: Disable making docs on Alpine
lineinfile:
path: "{{ gpg_src_path }}/Makefile"
regexp: '^doc = doc$'
line: 'doc = '
when:
- ansible_os_family == "Alpine"
- name: Compile gnupg src
command: bash -lc "cd {{ gpg_src_path }} && make"
changed_when: False

@ -28,3 +28,9 @@
name: fpm
state: present
user_install: no
# here the package is installed but a non-zero status code is returned that we ignore
- name: Install apk packaging dependencies for Alpine based distros
command: bash -lc "gem install etc || :"
when:
- ansible_os_family == "Alpine"

@ -13,3 +13,6 @@ test_dependencies:
build_tools:
- make
- tar
- autoconf
- automake
- gettext

@ -7,12 +7,12 @@ matrix:
sudo: required
language: ruby
rvm: 2.4
#- os: linux
# env: KITCHEN_REGEXP="gnupg1-alpine-latest"
# services: docker
# sudo: required
# language: ruby
# rvm: 2.4
- os: linux
env: KITCHEN_REGEXP="gnupg1-alpine-latest"
services: docker
sudo: required
language: ruby
rvm: 2.4
- os: linux
env: KITCHEN_REGEXP="gnupg1-debian-latest"
services: docker
@ -37,12 +37,12 @@ matrix:
sudo: required
language: ruby
rvm: 2.4
#- os: linux
# env: KITCHEN_REGEXP="gnupg2-alpine-latest"
# services: docker
# sudo: required
# language: ruby
# rvm: 2.4
- os: linux
env: KITCHEN_REGEXP="gnupg2-alpine-latest"
services: docker
sudo: required
language: ruby
rvm: 2.4
- os: linux
env: KITCHEN_REGEXP="gnupg2-debian-latest"; GITSECRET_DIST="deb"
services: docker
@ -122,4 +122,4 @@ after_deploy:
notifications:
email:
on_success: never
on_failure: change
on_failure: change
Loading…
Cancel
Save