gta5view/.ci/debian_build.sh

45 lines
2 KiB
Bash
Raw Normal View History

2017-12-23 07:48:01 +01:00
#!/bin/bash
# Creating folders
cd ${PROJECT_DIR} && \
echo "gta5view build version is ${APPLICATION_VERSION}" && \
2018-01-18 00:31:21 +01:00
mkdir -p build && \
mkdir -p assets && \
2020-08-28 22:11:52 +02:00
chmod -x res/gta5sync_*.qm res/*.desktop res/*gta5view*.png && \
2017-12-23 07:48:01 +01:00
cd build && \
2018-01-18 00:31:21 +01:00
mkdir -p qt4 && \
2017-12-23 07:48:01 +01:00
cd qt4 && \
2018-06-03 16:10:20 +02:00
echo "Grand Theft Auto V Snapmatic and Savegame viewer/editor" > ./description-pak && \
2017-12-23 07:48:01 +01:00
cd .. && \
2018-01-18 00:31:21 +01:00
mkdir -p qt5 && \
2017-12-23 07:48:01 +01:00
cd qt5 && \
2018-06-03 16:10:20 +02:00
echo "Grand Theft Auto V Snapmatic and Savegame viewer/editor" > ./description-pak && \
2017-12-23 07:48:01 +01:00
cd .. && \
2020-08-30 18:48:33 +02:00
# Set compiler
export CC=clang && \
export CXX=clang++ && \
2017-12-23 07:48:01 +01:00
# Prepare checkinstall step
mkdir -p /usr/share/gta5view && \
# Starting build
cd qt5 && \
cmake \
"-DCMAKE_INSTALL_PREFIX=/usr" \
${CMAKE_BUILD_TYPE} \
"-DGTA5VIEW_BUILDCODE=${PACKAGE_CODE}" \
"-DGTA5VIEW_APPVER=${APPLICATION_VERSION}" \
"-DGTA5VIEW_COMMIT=${APPLICATION_COMMIT}" \
"-DWITH_TELEMETRY=ON" \
"-DTELEMETRY_WEBURL=https://dev.syping.de/gta5view-userstats/" \
"-DQCONF_BUILD=ON" \
../../ && \
2017-12-23 07:48:01 +01:00
make -j 4 && \
2018-11-18 18:08:18 +01:00
checkinstall -D --default --nodoc --install=no --pkgname=gta5view-qt5 --pkgversion=${PACKAGE_VERSION} --pkgrelease=${PACKAGE_BUILD} --pkggroup=utility --maintainer="Syping \<dpkg@syping.de\>" --requires=libqt5core5a,libqt5gui5,libqt5network5,libqt5svg5,libqt5widgets5,qttranslations5-l10n --conflicts=gta5view,gta5view-qt4 --replaces=gta5view,gta5view-qt4 --pakdir=${PROJECT_DIR}/assets && \
2017-12-23 07:48:01 +01:00
cd .. && \
cd qt4 && \
2018-07-27 02:56:22 +02:00
qmake -qt=4 GTA5SYNC_PREFIX=/usr QMAKE_CXXFLAGS+=-std=gnu++11 ${QMAKE_FLAGS_QT4} ${QMAKE_BUILD_TYPE} "DEFINES+=GTA5SYNC_BUILDCODE=\\\\\\\"${PACKAGE_CODE}\\\\\\\"" "DEFINES+=GTA5SYNC_APPVER=\\\\\\\"${APPLICATION_VERSION}\\\\\\\"" DEFINES+=GTA5SYNC_QCONF ../../gta5view.pro && \
2017-12-23 07:48:01 +01:00
make -j 4 && \
2018-11-18 18:08:18 +01:00
checkinstall -D --default --nodoc --install=no --pkgname=gta5view-qt4 --pkgversion=${PACKAGE_VERSION} --pkgrelease=${PACKAGE_BUILD} --pkggroup=utility --maintainer="Syping \<dpkg@syping.de\>" --requires=libqtcore4,libqtgui4,libqt4-network,libqt4-svg,qtcore4-l10n --conflicts=gta5view,gta5view-qt5 --replaces=gta5view,gta5view-qt5 --pakdir=${PROJECT_DIR}/assets