Date: Friday, April 30, 2021 @ 11:28:31
  Author: bgyorgy
Revision: 925346

Patch the build system to get a proper install target

Added:
  beebeep/trunk/install-target.patch
Modified:
  beebeep/trunk/PKGBUILD
Deleted:
  beebeep/trunk/beebeep.appdata.xml

----------------------+
 PKGBUILD             |   19 +++----
 beebeep.appdata.xml  |   21 --------
 install-target.patch |  124 +++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 133 insertions(+), 31 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2021-04-30 11:26:54 UTC (rev 925345)
+++ PKGBUILD    2021-04-30 11:28:31 UTC (rev 925346)
@@ -13,23 +13,22 @@
 license=('GPL3')
 depends=('qt5-multimedia' 'qt5-x11extras')
 source=("https://downloads.sourceforge.net/$pkgname/$pkgname-code-$pkgver.zip";
-        'beebeep.appdata.xml')
+        'install-target.patch')
 sha256sums=('43e65a9d5249385fde782907d0cc3e26d6dd435bb623bcc0f93499055988f04c'
-            '05c6add5d33f4e429b213f25d46053611f838fdd709c593af211133c96788ca7')
+            '35f28432630bd9cf7ca3d99e33454cafe6e8127ef9d0935071f587ddb062269d')
  
+prepare() {
+  cd $pkgname-code-r*
+  patch -Np0 -i ../install-target.patch
+}
+ 
 build() {
   cd $pkgname-code-r*
-  qmake-qt5
+  qmake-qt5 PREFIX=/usr
   make
 }
  
 package(){
   cd $pkgname-code-r*
-  install -Dm755 test/beebeep "$pkgdir/usr/bin/beebeep"
-  install -Dm644 test/lib*.so -t "$pkgdir/usr/lib/beebeep/"
-  install -Dm644 locale/beebeep_*.qm -t "$pkgdir/usr/share/beebeep/"
-  install -Dm644 src/images/beebeep.png "$pkgdir/usr/share/beebeep/beebeep.png"
-  install -Dm644 misc/beep.wav "$pkgdir/usr/share/beebeep/beep.wav"
-  install -Dm644 scripts/debian_amd64/$pkgname.desktop 
"$pkgdir/usr/share/applications/$pkgname.desktop"
-  install -Dm644 ../beebeep.appdata.xml 
"$pkgdir/usr/share/metainfo/$pkgname.appdata.xml"
+  make INSTALL_ROOT="$pkgdir" install
 }

Deleted: beebeep.appdata.xml
===================================================================
--- beebeep.appdata.xml 2021-04-30 11:26:54 UTC (rev 925345)
+++ beebeep.appdata.xml 2021-04-30 11:28:31 UTC (rev 925346)
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<component type="desktop-application">
-  <id>net.beebeep.BeeBEEP</id>
-  <launchable type="desktop-id">beebeep.desktop</launchable>
-  <name>BeeBEEP</name>
-  <summary>Free office messenger</summary>
-  <metadata_license>CC0-1.0</metadata_license>
-  <project_license>GPL-3.0</project_license>
-  <developer_name>Marco Mastroddi</developer_name>
-  <description>
-    <p>This office messaging application, BeeBEEP, does not need an external 
server to let users communicate with each other. In your office, in your 
laboratory, at school, at home, in the hospital or in any other activity having 
the need for security and privacy, BeeBEEP is the best way to keep your private 
messages safe.</p>
-  </description>
-  <screenshots>
-    <screenshot type="default">
-      
<image>https://www.beebeep.net/images/shots/beebeep_in_action_windows.png</image>
-    </screenshot>
-  </screenshots>
-  <url type="bugtracker">https://sourceforge.net/p/beebeep/tickets/</url>
-  <url type="homepage">https://www.beebeep.net/</url>
-  <update_contact>marco.mastro...@gmail.com</update_contact>
-</component>

Added: install-target.patch
===================================================================
--- install-target.patch                                (rev 0)
+++ install-target.patch        2021-04-30 11:28:31 UTC (rev 925346)
@@ -0,0 +1,124 @@
+Index: beebeep.pri
+===================================================================
+--- beebeep.pri        (revision 1502)
++++ beebeep.pri        (working copy)
+@@ -21,4 +21,28 @@
+   UI_DIR = $$OBJECTS_DIR
+   MOC_DIR = $$OBJECTS_DIR
+   RCC_DIR = $$OBJECTS_DIR
++
++  isEmpty(PREFIX) {
++    PREFIX = /usr/local
++  }
++  isEmpty(BINDIR) {
++    BINDIR = $$PREFIX/bin
++  }
++  isEmpty(DATADIR) {
++    DATADIR = $$PREFIX/share
++  }
++  isEmpty(PLUGINDIR) {
++    PLUGINDIR = $$PREFIX/lib/beebeep
++  }
++
++  data.files = locale/*.qm src/images/beebeep.png misc/beep.wav
++  data.path = $$DATADIR/beebeep/
++
++  desktop.files = scripts/debian_amd64/beebeep.desktop
++  desktop.path = $$DATADIR/applications/
++
++  appdata.files = scripts/debian_amd64/beebeep.appdata.xml
++  appdata.path = $$DATADIR/metainfo/
++
++  INSTALLS += data desktop appdata
+ }
+Index: plugins/lifegame/lifegame.pro
+===================================================================
+--- plugins/lifegame/lifegame.pro      (revision 1502)
++++ plugins/lifegame/lifegame.pro      (working copy)
+@@ -21,3 +21,8 @@
+ 
+ FORMS += \
+     GuiLife.ui
++
++unix:!macx:!android: {
++  target.path = $$PLUGINDIR
++  INSTALLS += target
++}
+Index: plugins/numbertextmarker/numbertextmarker.pro
+===================================================================
+--- plugins/numbertextmarker/numbertextmarker.pro      (revision 1502)
++++ plugins/numbertextmarker/numbertextmarker.pro      (working copy)
+@@ -17,3 +17,8 @@
+ 
+ RESOURCES += \
+     numbertextmarker.qrc
++
++unix:!macx:!android: {
++  target.path = $$PLUGINDIR
++  INSTALLS += target
++}
+Index: plugins/rainbowtextmarker/rainbowtextmarker.pro
+===================================================================
+--- plugins/rainbowtextmarker/rainbowtextmarker.pro    (revision 1502)
++++ plugins/rainbowtextmarker/rainbowtextmarker.pro    (working copy)
+@@ -17,3 +17,8 @@
+ 
+ RESOURCES += \
+     rainbowtextmarker.qrc
++
++unix:!macx:!android: {
++  target.path = $$PLUGINDIR
++  INSTALLS += target
++}
+Index: plugins/regularboldtextmarker/regularboldtextmarker.pro
+===================================================================
+--- plugins/regularboldtextmarker/regularboldtextmarker.pro    (revision 1502)
++++ plugins/regularboldtextmarker/regularboldtextmarker.pro    (working copy)
+@@ -17,3 +17,8 @@
+ 
+ RESOURCES += \
+     regularboldtextmarker.qrc
++
++unix:!macx:!android: {
++  target.path = $$PLUGINDIR
++  INSTALLS += target
++}
+Index: scripts/debian_amd64/beebeep.appdata.xml
+===================================================================
+--- scripts/debian_amd64/beebeep.appdata.xml   (nonexistent)
++++ scripts/debian_amd64/beebeep.appdata.xml   (working copy)
+@@ -0,0 +1,21 @@
++<?xml version="1.0" encoding="UTF-8"?>
++<component type="desktop-application">
++  <id>net.beebeep.BeeBEEP</id>
++  <launchable type="desktop-id">beebeep.desktop</launchable>
++  <name>BeeBEEP</name>
++  <summary>Free office messenger</summary>
++  <metadata_license>CC0-1.0</metadata_license>
++  <project_license>GPL-3.0</project_license>
++  <developer_name>Marco Mastroddi</developer_name>
++  <description>
++    <p>This office messaging application, BeeBEEP, does not need an external 
server to let users communicate with each other. In your office, in your 
laboratory, at school, at home, in the hospital or in any other activity having 
the need for security and privacy, BeeBEEP is the best way to keep your private 
messages safe.</p>
++  </description>
++  <screenshots>
++    <screenshot type="default">
++      
<image>https://www.beebeep.net/images/shots/beebeep_in_action_windows.png</image>
++    </screenshot>
++  </screenshots>
++  <url type="bugtracker">https://sourceforge.net/p/beebeep/tickets/</url>
++  <url type="homepage">https://www.beebeep.net/</url>
++  <update_contact>marco.mastro...@gmail.com</update_contact>
++</component>
+Index: src/src.pro
+===================================================================
+--- src/src.pro        (revision 1502)
++++ src/src.pro        (working copy)
+@@ -125,3 +125,8 @@
+ message( Object dir: $$OBJECTS_DIR )
+ unix: message( CXX flags: $$QMAKE_CXXFLAGS )
+ message( QT Plugins: $$QTPLUGIN )
++
++unix:!macx:!android: {
++  target.path = $$BINDIR
++  INSTALLS += target
++}

Reply via email to