build: Fix various issues for upstream Fedora compatibility (#642)

* cmake: use GNUInstallDirs to find install dirs on Linux

* install plugins to lib/imhex/plugins

* fix included files in imhex.spec

* fix the release CI + do not upload x86_64 folder for Fedora

* change rpm names

* added IMHEX_STRIP_RELEASE option to optionally strip releases files (was done all the time before)

* Customize our imhex.spec file (use online building for our Fedora package)

* added IMHEX_PLUGINS_IN_SHARE option for AppImage

* test
This commit is contained in:
iTrooz_
2022-08-04 20:37:57 +02:00
committed by GitHub
parent e2d75ad6bf
commit e816b67472
7 changed files with 57 additions and 24 deletions

View File

@@ -262,6 +262,19 @@ jobs:
mv build/AppDir.deb imhex-${{env.IMHEX_VERSION}}.deb
rm -rf build/AppDir/DEBIAN
- name: 🛠️ Reconfigure build for AppImage
run: |
# Reconfigure CMake to include a flag needed for AppImage
# Other flags are kept from old configuration
cd build
cmake \
-DIMHEX_PLUGINS_IN_SHARE=ON \
..
rm -rf AppDir
make -j 4 install DESTDIR=AppDir
- name: 📦 Bundle AppImage
run: |
cd build
@@ -445,10 +458,11 @@ jobs:
- name: 📦 Build RPM
run: |
rpmbuild -ba --define "_version ${{env.IMHEX_VERSION}}" --define "_src_path $GITHUB_WORKSPACE" --define "_build_type $BUILD_TYPE" $GITHUB_WORKSPACE/dist/rpm/imhex.spec
mv ~/rpmbuild/RPMS/x86_64/*.rpm imhex-${{env.IMHEX_VERSION}}-Fedora-${{matrix.release}}.rpm
- name: ⬆️ Upload RPM
uses: actions/upload-artifact@v3
with:
name: Fedora ${{ matrix.release }} RPM
path: |
~/rpmbuild/RPMS/*/*.rpm
imhex-${{env.IMHEX_VERSION}}-Fedora-${{matrix.release}}.rpm

View File

@@ -63,9 +63,7 @@ jobs:
- name: ⬆️ Upload everything to release
uses: softprops/action-gh-release@v1
with:
files: |
'*'
'*/*.rpm'
files: '*'
- name: ✒️ Prepare PKGBUILD
run: |