Skip to content

Commit

Permalink
Fix: Compatibility with qt5 in control file in .deb package
Browse files Browse the repository at this point in the history
This patch adds required packages (which is libqt5widgets5 in this case)
for additional compatibility with Qt5.

+ updated version in control and repo link.
  • Loading branch information
tetektoza committed Oct 18, 2023
1 parent b8e29d9 commit 9c3764e
Show file tree
Hide file tree
Showing 9 changed files with 731 additions and 9 deletions.
25 changes: 18 additions & 7 deletions build-deb.sh
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
#!/bin/bash

debian_qt_ver=""
if [ "$1" == "qt5" ]
then
debian_qt_ver="debian-qt5"
else
debian_qt_ver="debian-qt6"
fi

echo "Building for: $1"

# Copy latest release build
mkdir -p debian/usr/bin/
cp build/D1GraphicsTool debian/usr/bin/
mkdir -p debian/$debian_qt_ver/usr/bin/
cp build/D1GraphicsTool debian/$debian_qt_ver/usr/bin/

# Strip symbols
strip -s debian/usr/bin/D1GraphicsTool
strip -s debian/$debian_qt_ver/usr/bin/D1GraphicsTool

# Copy short cut icon
mkdir -p debian/opt/d1-graphics-tool/
cp resources/icon.svg debian/opt/d1-graphics-tool/
mkdir -p debian/$debian_qt_ver/opt/d1-graphics-tool/
cp resources/icon.svg debian/$debian_qt_ver/opt/d1-graphics-tool/

# Build .deb package
dpkg-deb --build debian
dpkg-deb --build debian/$debian_qt_ver

# Rename package
mv debian.deb d1-graphics-tool.deb
mv debian/$debian_qt_ver.deb debian/d1-graphics-tool-$debian_qt_ver.deb
10 changes: 10 additions & 0 deletions debian/debian-qt5/DEBIAN/control
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Package: d1-graphics-tool
Version: 1.0.0
Architecture: amd64
Maintainer: Anders Jenbo <[email protected]>
Installed-Size: 444
Depends: libqt5widgets5 (>= 5.15.0)
Section: graphics
Priority: optional
Homepage: https://github.com/diasurgical/d1-graphics-tool
Description: Diablo 1 Graphics Tool can open CEL/CL2 graphics files and display them with chosen color palette (PAL) and color translation (TRN) files.
345 changes: 345 additions & 0 deletions debian/debian-qt5/opt/d1-graphics-tool/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added debian/debian-qt5/usr/bin/D1GraphicsTool
Binary file not shown.
4 changes: 2 additions & 2 deletions debian/DEBIAN/control → debian/debian-qt6/DEBIAN/control
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Package: d1-graphics-tool
Version: 0.5.0
Version: 1.0.0
Architecture: amd64
Maintainer: Anders Jenbo <[email protected]>
Installed-Size: 444
Depends: libqt6widgets6 (>= 6.2.4), qt6-qpa-plugins (>= 6.2.4)
Section: graphics
Priority: optional
Homepage: https://github.com/savagesteel/d1-graphics-tool
Homepage: https://github.com/diasurgical/d1-graphics-tool
Description: Diablo 1 Graphics Tool can open CEL/CL2 graphics files and display them with chosen color palette (PAL) and color translation (TRN) files.
345 changes: 345 additions & 0 deletions debian/debian-qt6/opt/d1-graphics-tool/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added debian/debian-qt6/usr/bin/D1GraphicsTool
Binary file not shown.
11 changes: 11 additions & 0 deletions debian/debian-qt6/usr/share/applications/D1GraphicsTool.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[Desktop Entry]
Version=0.5.0
Type=Application
Name=Diablo 1 Graphics Tool
Comment=Work with Diablo 1 graphics files
Keywords=Diablo;graphic;
Exec=D1GraphicsTool
Icon=/opt/d1-graphics-tool/icon.svg
Terminal=false
Categories=Graphics;2DGraphics;RasterGraphics;
StartupNotify=true

0 comments on commit 9c3764e

Please sign in to comment.