aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-06-03 09:10:55 -0300
committerNatanael Copa <ncopa@alpinelinux.org>2019-06-05 15:31:48 +0000
commited25b49d21e93a205836887564c69179412d097b (patch)
tree86e6909bce79eb379c64d0edd88a7fcbd04db121
parent88db1e621726e201ea9e91e1a11317006deb85e2 (diff)
downloadaports-ed25b49d21e93a205836887564c69179412d097b.tar.gz
aports-ed25b49d21e93a205836887564c69179412d097b.tar.bz2
aports-ed25b49d21e93a205836887564c69179412d097b.tar.xz
community/wxgtk: split into wxgtk-base-dev wxgtk3-dev and wxgtk-dev
-rw-r--r--community/wxgtk/APKBUILD57
1 files changed, 52 insertions, 5 deletions
diff --git a/community/wxgtk/APKBUILD b/community/wxgtk/APKBUILD
index 94a3d1ac09..dbf1d923ed 100644
--- a/community/wxgtk/APKBUILD
+++ b/community/wxgtk/APKBUILD
@@ -3,7 +3,7 @@
# Maintainer: ScrumpyJack <scrumpyjack@st.ilet.to>
pkgname=wxgtk
pkgver=3.0.4
-pkgrel=3
+pkgrel=4
pkgdesc="GTK2 port of wxWidgets GUI library"
url="https://www.wxwidgets.org/"
arch="all"
@@ -13,8 +13,16 @@ depends_dev="gtk+2.0-dev mesa-dev zlib-dev tiff-dev libjpeg-turbo-dev expat-dev
makedepends="$depends_dev glu-dev sdl-dev gst-plugins-base-dev
gstreamer-dev"
options="!check" # doesn't have any checks
-subpackages="$pkgname-dev $pkgname-lang $pkgname-base $pkgname-media:_media2
- ${pkgname}3-media:_media3 ${pkgname}3:_gtk3"
+subpackages="
+ $pkgname-dev
+ $pkgname-lang
+ $pkgname-base
+ $pkgname-base-dev:_base_dev
+ $pkgname-media:_media2
+ ${pkgname}3-media:_media3
+ ${pkgname}3-dev:_dev3
+ ${pkgname}3:_gtk3
+ "
source="https://github.com/wxWidgets/wxWidgets/releases/download/v${pkgver}/wxWidgets-${pkgver}.tar.bz2"
builddir="$srcdir/wxWidgets-$pkgver"
@@ -27,7 +35,7 @@ build() {
for gtk_version in 2 3; do
cd "$builddir"
mkdir gtk${gtk_version}
- cd gtk${gtk_version}
+ cd "$builddir"/gtk${gtk_version}
"$builddir"/configure \
--build=$CBUILD \
--host=$CHOST \
@@ -57,13 +65,52 @@ package() {
}
dev() {
+ depends_dev="$depends_dev wxgtk-base-dev=$pkgver-r$pkgrel"
default_dev
+
+ mkdir -p "$subpkgdir"/usr/lib/wx/config
+ mv "$pkgdir"/usr/lib/wx/config/gtk2-unicode-3.0 "$subpkgdir"/usr/lib/wx/config
+
+ mkdir -p "$subpkgdir"/usr/bin
cd "$subpkgdir"/usr/bin/
ln -s /usr/lib/wx/config/gtk2-unicode-3.0 wx-config-gtk2
ln -sf /usr/bin/wx-config-gtk2 wx-config
- ln -s /usr/lib/wx/config/gtk3-unicode-3.0 wx-config-gtk3
+
+ # Move stuff back into the wild for the other -dev packages
+ mv "$subpkgdir"/usr/include/wx-3.0 "$pkgdir"/usr/include
+ mv "$subpkgdir"/usr/lib/libwx_baseu*.so "$pkgdir"/usr/lib
+ mv "$subpkgdir"/usr/share/aclocal "$pkgdir"/usr/share
+ mv "$subpkgdir"/usr/lib/libwx_gtk3u*.so "$pkgdir"/usr/lib
+
+ mkdir -p "$pkgdir"/usr/lib/wx/include
+ mv "$subpkgdir"/usr/lib/wx/include/gtk3-unicode-3.0 "$pkgdir"/usr/lib/wx/include
+}
+
+_base_dev() {
+ short_desc="Common development files of wxgtk"
+ pkgdesc="Non-GUI support classes from the wxWidgets library"
+ default_dev
+
+ mkdir -p "$subpkgdir"/usr/bin "$subpkgdir"/usr/share
mv "$pkgdir"/usr/bin/wxrc* "$subpkgdir"/usr/bin/
mv "$pkgdir"/usr/share/bakefile "$subpkgdir"/usr/share/
+
+ # Move stuff back into the wild
+ mv "$subpkgdir"/usr/lib/libwx_gtk3u*.so "$pkgdir"/usr/lib
+ mv "$subpkgdir"/usr/lib/wx/include "$pkgdir"/usr/lib/wx
+}
+
+_dev3() {
+ depends_dev="$depends_dev wxgtk-base-dev=$pkgver-r$pkgrel"
+ pkgdesc="${pkgdesc/GTK2/GTK3}"
+ default_dev
+
+ mkdir -p "$subpkgdir"/usr/lib/wx/config
+ mv "$pkgdir"/usr/lib/wx/config/gtk3-unicode-3.0 "$subpkgdir"/usr/lib/wx/config
+
+ mkdir -p "$subpkgdir"/usr/bin
+ cd "$subpkgdir"/usr/bin/
+ ln -s /usr/lib/wx/config/gtk3-unicode-3.0 wx-config-gtk3
}
_media2() {