mirror of
https://github.com/fergalmoran/flameshot.git
synced 2026-03-25 17:40:06 +00:00
Add packaging flags for qmake
This commit is contained in:
45
README.md
45
README.md
@@ -15,6 +15,7 @@
|
||||
- [Fedora](#fedora)
|
||||
- [Arch](#arch)
|
||||
- [Install](#install)
|
||||
- [Packaging](#packaging)
|
||||
- [License](#license)
|
||||
|
||||
## Features
|
||||
@@ -83,11 +84,6 @@ apt install -y git g++ build-essential qt5-qmake qt5-default
|
||||
|
||||
Compilation: run `qmake && make` in the main directory.
|
||||
|
||||
Runtime Dependencies (not needed if compiled from source):
|
||||
````
|
||||
apt install -y libqt5dbus5, libqt5network5, libqt5core5a, libqt5widgets5, libqt5gui5
|
||||
````
|
||||
|
||||
### Fedora
|
||||
Compilation Dependencies:
|
||||
````
|
||||
@@ -96,11 +92,6 @@ dnf install -y qt5-devel gcc-c++ git qt5-qtbase-devel
|
||||
|
||||
Compilation: run `qmake-qt5 && make` in the main directory.
|
||||
|
||||
Runtime Dependencies (not needed if compiled from source):
|
||||
````
|
||||
dnf install -y qt5-qtbase
|
||||
````
|
||||
|
||||
### Arch
|
||||
Compilation Dependencies:
|
||||
````
|
||||
@@ -109,15 +100,37 @@ pacman -S git qt5-base base-devel
|
||||
|
||||
Compilation: run `qmake && make` in the main directory.
|
||||
|
||||
Runtime Dependencies (not needed if compiled from source):
|
||||
````
|
||||
pacman -S qt5-base
|
||||
````
|
||||
|
||||
## Install
|
||||
### Install
|
||||
|
||||
Simply use `make install` with privileges.
|
||||
|
||||
## Packaging
|
||||
|
||||
In order to generate the makefile installing in `/usr` instead of in `/usr/local` you can use the `packaging` option to generate the proper makefile (`qmake CONFIG+=packaging` instead of just `qmake`).
|
||||
|
||||
If you want to install in a custom directory you can define the `BASEDIR` variable.
|
||||
|
||||
**Example**:
|
||||
You whant to install Flameshot in ~/myBuilds/test. You would execute the following to do so:
|
||||
`qmake CONFIG+=packaging BASEDIR=~/myBuilds/test && make install`
|
||||
|
||||
### Runtime Dependencies
|
||||
|
||||
**Debian**:
|
||||
````
|
||||
libqt5dbus5, libqt5network5, libqt5core5a, libqt5widgets5, libqt5gui5
|
||||
````
|
||||
|
||||
**Fedora**:
|
||||
````
|
||||
qt5-qtbase
|
||||
````
|
||||
|
||||
**Arch**:
|
||||
````
|
||||
qt5-base
|
||||
````
|
||||
|
||||
## License
|
||||
- The main code is licensed under [GPLv3](./LICENSE)
|
||||
- The logo of Flameshot is licensed under [Free Art License v1.3](./img/flameshotLogoLicense.txt)
|
||||
|
||||
3
dbus/package/org.dharkael.Flameshot.service
Normal file
3
dbus/package/org.dharkael.Flameshot.service
Normal file
@@ -0,0 +1,3 @@
|
||||
[D-BUS Service]
|
||||
Name=org.dharkael.Flameshot
|
||||
Exec=/usr/bin/flameshot
|
||||
16
docs/desktopEntry/make/flameshot-init.desktop
Executable file
16
docs/desktopEntry/make/flameshot-init.desktop
Executable file
@@ -0,0 +1,16 @@
|
||||
[Desktop Entry]
|
||||
Encoding=UTF-8
|
||||
Name=Launch Flameshot
|
||||
Name[es]=Iniciar Flameshot
|
||||
GenericName=Screenshot tool
|
||||
GenericName[es]=Herramienta de captura de pantalla
|
||||
Comment=Powerfull yet simple to use screenshot software.
|
||||
Comment[es]=Potente pero simple de usar software de capturas.
|
||||
Exec=/usr/local/bin/flameshot
|
||||
TryExec=/usr/local/bin/flameshot
|
||||
Icon=/usr/local/share/icons/flameshot.png
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Graphics
|
||||
StartupNotify=false
|
||||
|
||||
15
docs/desktopEntry/package/flameshot-init.desktop
Normal file
15
docs/desktopEntry/package/flameshot-init.desktop
Normal file
@@ -0,0 +1,15 @@
|
||||
[Desktop Entry]
|
||||
Encoding=UTF-8
|
||||
Name=Launch Flameshot
|
||||
Name[es]=Iniciar Flameshot
|
||||
GenericName=Screenshot tool
|
||||
GenericName[es]=Herramienta de captura de pantalla
|
||||
Comment=Powerfull yet simple to use screenshot software.
|
||||
Comment[es]=Potente pero simple de usar software de capturas.
|
||||
Exec=/usr/bin/flameshot
|
||||
TryExec=/usr/bin/flameshot
|
||||
Icon=/usr/share/icons/flameshot.png
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Graphics
|
||||
StartupNotify=false
|
||||
@@ -13,6 +13,8 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||
CONFIG += c++11
|
||||
CONFIG += link_pkgconfig
|
||||
|
||||
#CONFIG += packaging # Enables "make install" for packaging paths
|
||||
|
||||
TARGET = flameshot
|
||||
TEMPLATE = app
|
||||
|
||||
@@ -70,27 +72,41 @@ RESOURCES += \
|
||||
|
||||
# installs
|
||||
unix: {
|
||||
target.path = /usr/local/bin/
|
||||
packaging {
|
||||
USRPATH = /usr
|
||||
} else {
|
||||
USRPATH = /usr/local
|
||||
}
|
||||
|
||||
qmfile.path = /usr/share/flameshot/translations/
|
||||
target.path = $${BASEDIR}$${USRPATH}/bin/
|
||||
|
||||
qmfile.path = $${BASEDIR}/usr/share/flameshot/translations/
|
||||
qmfile.files = translation/Internationalization_es.qm
|
||||
|
||||
servicedbus.path = /usr/share/dbus-1/services/
|
||||
servicedbus.files = dbus/org.dharkael.Flameshot.service
|
||||
|
||||
dbus.path = /usr/share/dbus-1/interfaces/
|
||||
dbus.path = $${BASEDIR}/usr/share/dbus-1/interfaces/
|
||||
dbus.files = dbus/org.dharkael.Flameshot.xml
|
||||
|
||||
icon.path = /usr/local/share/icons/
|
||||
icon.path = $${BASEDIR}$${USRPATH}/share/icons/
|
||||
icon.files = img/flameshot.png
|
||||
|
||||
desktopentry.path = /usr/local/share/applications
|
||||
desktopentry.files = docs/desktopEntry/make/flameshot.desktop
|
||||
desktopentry.path = $${BASEDIR}$${USRPATH}/share/applications
|
||||
desktopentryinit.path = $${BASEDIR}$${USRPATH}/share/applications
|
||||
servicedbus.path = $${BASEDIR}/usr/share/dbus-1/services/
|
||||
|
||||
packaging {
|
||||
desktopentry.files = docs/desktopEntry/package/flameshot.desktop
|
||||
desktopentryinit.files = docs/desktopEntry/package/flameshot-init.desktop
|
||||
servicedbus.files = dbus/package/org.dharkael.Flameshot.service
|
||||
} else {
|
||||
desktopentry.files = docs/desktopEntry/make/flameshot.desktop
|
||||
desktopentryinit.files = docs/desktopEntry/make/flameshot-init.desktop
|
||||
servicedbus.files = dbus/make/org.dharkael.Flameshot.service
|
||||
}
|
||||
|
||||
INSTALLS += target \
|
||||
icon \
|
||||
desktopentry \
|
||||
desktopentryinit \
|
||||
qmfile \
|
||||
servicedbus \
|
||||
dbus
|
||||
|
||||
Reference in New Issue
Block a user