Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ci): fix ci build #338

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ on:
jobs:

cstor:
runs-on: ubuntu-16.04
runs-on: ubuntu-18.04
strategy:
fail-fast: true
matrix:
Expand Down
128 changes: 64 additions & 64 deletions buildscripts/install-build-dep.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
#!/bin/bash

# Mandatory variables
# $REPO_ORG organisation from which to clone the dependent repositories
# $BRANCH to be used for building
#
# Optional variables
# $UZFS_BUILD variable need to be set. If not kernel mode zfs will be built
# # Mandatory variables
# # $REPO_ORG organisation from which to clone the dependent repositories
# # $BRANCH to be used for building
# #
# # Optional variables
# # $UZFS_BUILD variable need to be set. If not kernel mode zfs will be built

if [ -z "${REPO_ORG}" ]; then
echo "REPO_ORG variable not set. Required for fetching dependent build repositories"
Expand All @@ -27,28 +27,28 @@ else
echo "Installing dependencies for kernel mode ZFS"
fi

# zrepl will make use of /var/tmp/sock directory to create a sock file.
mkdir -p /var/tmp/sock
pushd .
cd /usr/src/gtest || exit 1
sudo cmake CMakeLists.txt
sudo make -j4
sudo cp *.a /usr/lib
popd || exit 1

# save the current location of cstor code to get back after installing dependencies
pushd .
# move to parent directory and clone dependent repositories
cd ..

# we need fio repo to build zfs replica fio engine
git clone https://github.com/axboe/fio
cd fio || exit 1
git checkout fio-3.9
./configure
make -j4

cd ..
# # zrepl will make use of /var/tmp/sock directory to create a sock file.
# mkdir -p /var/tmp/sock
# pushd .
# cd /usr/src/gtest || exit 1
# sudo cmake CMakeLists.txt
# sudo make -j4
# sudo cp *.a /usr/lib
# popd || exit 1

# # save the current location of cstor code to get back after installing dependencies
# pushd .
# # move to parent directory and clone dependent repositories
# cd ..

# # we need fio repo to build zfs replica fio engine
# git clone https://github.com/axboe/fio
# cd fio || exit 1
# git checkout fio-3.9
# ./configure
# make -j4

# cd ..

# clone and build SPL
git clone https://github.com/${REPO_ORG}/spl
Expand All @@ -64,39 +64,39 @@ else
sudo dpkg -i *.deb
fi

cd ..

# Build libcstor for uzfs feature
git clone https://github.com/${REPO_ORG}/libcstor.git
cd libcstor || exit 1
if [ "${BRANCH}" == "develop" ]; then
git checkout develop
else
git checkout ${BRANCH} || git checkout develop
fi

sh autogen.sh;
./configure --enable-debug --with-zfs-headers=$PWD/../cstor/include --with-spl-headers=$PWD/../cstor/lib/libspl/include
make -j4;
sudo make install;
sudo ldconfig

# return to cstor code
popd || exit 1

sh autogen.sh
if [ "$UZFS_BUILD" = 1 ]; then
./configure --with-config=user --enable-debug --enable-uzfs=yes --with-jemalloc --with-fio=$PWD/../fio --with-libcstor=$PWD/../libcstor/include || exit 1
make -j4
else
./configure --enable-debug || exit 1
make --no-print-directory -s pkg-utils pkg-kmod || exit 1
sudo dpkg -i *.deb || exit 1
fi

# If build is to build uZFS feature then go to zrepl in libcstor and build zrepl binary
if [ "$UZFS_BUILD" = 1 ]; then
pushd .
cd ../libcstor/cmd/zrepl && make || exit 1
popd || exit 1
fi
# cd ..

# # Build libcstor for uzfs feature
# git clone https://github.com/${REPO_ORG}/libcstor.git
# cd libcstor || exit 1
# if [ "${BRANCH}" == "develop" ]; then
# git checkout develop
# else
# git checkout ${BRANCH} || git checkout develop
# fi

# sh autogen.sh;
# ./configure --enable-debug --with-zfs-headers=$PWD/../cstor/include --with-spl-headers=$PWD/../cstor/lib/libspl/include
# make -j4;
# sudo make install;
# sudo ldconfig

# # return to cstor code
# popd || exit 1

# sh autogen.sh
# if [ "$UZFS_BUILD" = 1 ]; then
# ./configure --with-config=user --enable-debug --enable-uzfs=yes --with-jemalloc --with-fio=$PWD/../fio --with-libcstor=$PWD/../libcstor/include || exit 1
# make -j4
# else
# ./configure --enable-debug || exit 1
# make --no-print-directory -s pkg-utils pkg-kmod || exit 1
# sudo dpkg -i *.deb || exit 1
# fi

# # If build is to build uZFS feature then go to zrepl in libcstor and build zrepl binary
# if [ "$UZFS_BUILD" = 1 ]; then
# pushd .
# cd ../libcstor/cmd/zrepl && make || exit 1
# popd || exit 1
# fi