Skip to content

CI add compile and archive steps #5

CI add compile and archive steps

CI add compile and archive steps #5

Workflow file for this run

name: Build libhkl library
on: push
# TODO: define symbols
# https://repo.or.cz/hkl.git
# v5.0.0.3001
# v5.0.0.3357
defaults:
run:
shell: bash -l {0}
jobs:
build:
name: build job
runs-on: ubuntu-20.04
steps:
- name: Diagnostics
run: |
apt update
apt-cache show gobject-introspection # | grep Version
apt-cache show libgsl-dev # | grep Version
apt-cache show libcglm-dev # | grep Version
apt-cache show libglm-dev # | grep Version
cat /etc/os-release
which git
which make
which autoconf
# gobject-introspection=1.64.1-1~ubuntu20.04.1
# libgsl-dev=2.5+dfsg-6build1
- name: Development tools
run: |
DEBIAN_FRONTEND=noninteractive sudo apt-get install -y \
apt-utils \
autoconf \
autoconf-archive \
automake \
build-essential \
git \
gobject-introspection=1.64.1-1~ubuntu20.04.1 \
libgsl-dev=2.5+dfsg-6build1 \
libglm-dev \
libgirepository1.0-dev \
libglib2.0-dev \
libhdf5-dev \
libtool \
m4 \
make \
pkg-config
#
# not in ubuntu-20.04
# libcglm-dev \
- name: Get source
run: |
# TODO: use symbols
git clone https://repo.or.cz/hkl.git
cd hkl
git checkout --detach v5.0.0.3001 # 3357
- name: Compile
run: |
# TODO: add version info, somehow
set -e
export PREFIX=/opt/hkl
cd hkl
#
# don't build the documentation
# sed removes any lines containing the described text
sed -i '/gtk-doc/d' ./configure.ac
sed -i '/GTK_DOC_CHECK/d' ./configure.ac
sed -i '/Documentation/d' ./configure.ac
#
test -d m4 || mkdir m4
aclocal --print-ac-dir
autoreconf -ivf
#
./configure \
--disable-static \
--disable-gui \
--disable-hkl-doc \
--enable-introspection=yes \
--prefix="${PREFIX}"
#
make -j ${CPU_COUNT}
make install
- name: archive
run: |
export PREFIX=/opt/hkl
cd "${PREFIX}"
tar czf ../libhdf.tar.gz ./*/
# TODO: save this tar file