Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] [RFC] add vdevel helper
@ 2022-09-14  4:18 classabbyamp
  2022-09-14  4:23 ` [PR PATCH] [Updated] " classabbyamp
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: classabbyamp @ 2022-09-14  4:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1688 bytes --]

There is a new pull request by classabbyamp against master on the void-packages repository

https://github.com/classabbyamp/void-packages vdevel
https://github.com/void-linux/void-packages/pull/39274

[RFC] add vdevel helper
This adds a helper for the install phase, `vdevel`, which moves commonly-moved patterns/directories to the subpkg in which it's called using `vmove`.

Based on these Highly Scientific™ stats and the existing list in Manual.md, I came up with a list of patterns and directories to move.

<details><summary>The Numbers</summary>

```
  count  command
   1859  vmove usr/include
   1664  vmove usr/lib/*.so
   1414  vmove usr/lib/pkgconfig
    750  vmove usr/lib/*.a
    331  vmove usr/lib/cmake
    182  vmove usr/share/gir-1.0
    154  vmove usr/share/man/man3
    112  vmove usr/lib/qt5/mkspecs
    101  vmove usr/share/gtk-doc
     94  vmove usr/share/vala
     64  vmove usr/share/aclocal
     17  vmove usr/share/info
     15  vmove usr/share/man
     14  vmove usr/lib/*.la
     12  vmove usr/share/cmake
     10  vmove usr/share/pkgconfig
```

</details>

(Should `usr/share/gtk-doc` and/or `usr/share/man/man3` be added to the `vdevel` list?)

If a pattern or directory is not matched, only a warning is printed, describing what wasn't found.

This should be compatible with many `-devel` packages, but not all, and that is okay. Also, if additional files need to be moved, they can be `vmove`d manually.

Some examples of `vdevel` in action are included.

#### Testing the changes
- I tested the changes in this PR: **YES**


A patch file from https://github.com/void-linux/void-packages/pull/39274.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-vdevel-39274.patch --]
[-- Type: text/x-diff, Size: 8556 bytes --]

From 4a27f8a53c4f50cfc0894d3466324c5a67bf70f6 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 13 Sep 2022 23:46:42 -0400
Subject: [PATCH 1/8] common/environment/setup/install.sh: add vdevel helper

---
 common/environment/setup/install.sh | 41 ++++++++++++++++++++++++++++-
 1 file changed, 40 insertions(+), 1 deletion(-)

diff --git a/common/environment/setup/install.sh b/common/environment/setup/install.sh
index 5f0571de14ae..a8c67c8ae12f 100644
--- a/common/environment/setup/install.sh
+++ b/common/environment/setup/install.sh
@@ -13,7 +13,7 @@ _noglob_helper() {
 }
 
 # Apply _noglob to v* commands
-for cmd in vinstall vcopy vcompletion vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv; do
+for cmd in vinstall vcopy vcompletion vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv vdevel; do
        alias ${cmd}="set -f; _noglob_helper _${cmd}"
 done
 
@@ -265,3 +265,42 @@ _vcompletion() {
 			;;
 	esac
 }
+
+_vdevel() {
+	if [ -z "$DESTDIR" ]; then
+		msg_red "$pkgver: vdevel: DESTDIR unset, can't continue...\n"
+		return 1
+	elif [ -z "$PKGDESTDIR" ]; then
+		msg_red "$pkgver: vdevel: PKGDESTDIR unset, can't continue...\n"
+		return 1
+	elif [ "$DESTDIR" = "$PKGDESTDIR" ]; then
+		msg_red "$pkgver: vdevel is intended to be used in pkg_install\n"
+		return 1
+	fi
+
+	_move_glob() {
+		local pat=$1 msg=$2
+		if [ -n "$(ls ${DESTDIR}/$pat 2>/dev/null)" ]; then
+			vmove "$pat"
+		else
+			msg_warn "$pkgver: vdevel: no $msg found ($pat)\n"
+		fi
+	}
+
+	_move_dir() {
+		local dir=$1 msg=$2
+		[ -d "${DESTDIR}/$dir" ] && _move_glob "$dir" "$msg"
+	}
+
+	_move_glob 'usr/lib/*.so' 'unversioned shlibs'
+	_move_glob 'usr/lib/*.a' 'library archives'
+	_move_glob 'usr/share/gir-*' 'Gobject introspection XML files'
+
+	_move_dir 'usr/include' 'header files'
+	_move_dir 'usr/lib/cmake' 'cmake rules'
+	_move_dir 'usr/share/cmake' 'cmake rules'
+	_move_dir 'usr/lib/pkgconfig' 'pkgconfig files'
+	_move_dir 'usr/share/pkgconfig' 'pkgconfig files'
+	_move_dir 'usr/share/aclocal' 'Autoconf macros'
+	_move_dir 'usr/share/vala' 'Vala bindings'
+}

From 8b39bd0608af4ed65ab1479cedfd95715503c151 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 13 Sep 2022 23:55:23 -0400
Subject: [PATCH 2/8] Manual.md: document vdevel

---
 Manual.md | 25 +++++++++++++++++++++----
 1 file changed, 21 insertions(+), 4 deletions(-)

diff --git a/Manual.md b/Manual.md
index c24be6e90a74..349a53b586cf 100644
--- a/Manual.md
+++ b/Manual.md
@@ -330,6 +330,23 @@ The following functions are defined by `xbps-src` and can be used on any templat
 	it will default to `pkgname`. The `shell` argument can be one of `bash`,
 	`fish` or `zsh`.
 
+- *vdevel()*
+
+	Installs common development files in the pkg `$DESTDIR`. Prints a warning if files
+	aren't found. Equivalent to:
+```sh
+vmove "usr/lib/*.so"  # unversioned shlibs
+vmove "usr/lib/*.a"  # library archives
+vmove "usr/share/gir-*"  # Gobject introspection XML files
+vmove usr/include  # header files
+vmove usr/lib/cmake  # cmake rules
+vmove usr/share/cmake  # cmake rules
+vmove usr/lib/pkgconfig  # pkgconfig files
+vmove usr/share/pkgconfig  # pkgconfig files
+vmove usr/share/aclocal  # Autoconf macros
+vmove usr/share/vala  # Vala bindings
+```
+
 > Shell wildcards must be properly quoted, Example: `vmove "usr/lib/*.a"`.
 
 <a id="global_vars"></a>
@@ -1438,10 +1455,8 @@ foo-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmove usr/include
-		vmove "usr/lib/*.a"
-		vmove "usr/lib/*.so"
-		vmove usr/lib/pkgconfig
+		vdevel
+		vmove usr/share/gtk-doc
 	}
 }
 ```
@@ -1500,6 +1515,8 @@ following subset of files from the main package:
 * Gobject introspection XML files `usr/share/gir-1.0`
 * Vala bindings `usr/share/vala`
 
+> These common files can be automatically moved to the `-devel` subpackage using `vdevel`
+
 <a id="pkgs_data"></a>
 ### Data packages
 

From eb8e118be8940ae06dc5734dc883e4d80f3d3495 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:21 -0400
Subject: [PATCH 3/8] LimeSuite: use vdevel

---
 srcpkgs/LimeSuite/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/LimeSuite/template b/srcpkgs/LimeSuite/template
index f7caba84c2fe..b517829b4f7f 100644
--- a/srcpkgs/LimeSuite/template
+++ b/srcpkgs/LimeSuite/template
@@ -64,10 +64,7 @@ LimeSuite-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/cmake
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
+		vdevel
 	}
 }
 

From d5204d19528e6088f4698d53f426d45cf660d901 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:24 -0400
Subject: [PATCH 4/8] farstream: use vdevel

---
 srcpkgs/farstream/template | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/srcpkgs/farstream/template b/srcpkgs/farstream/template
index e93c7a0c23bb..db6e66fb7ca7 100644
--- a/srcpkgs/farstream/template
+++ b/srcpkgs/farstream/template
@@ -32,12 +32,7 @@ farstream-devel_package() {
 	depends="gst-plugins-base1-devel farstream-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove usr/lib/*.so
+		vdevel
 		vmove usr/share/gtk-doc
-		if [ "$build_option_gir" ]; then
-			vmove usr/share/gir-1.0
-		fi
 	}
 }

From 0a63f27765364c80ec63b7b082f00881f81a39dd Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:25 -0400
Subject: [PATCH 5/8] hamlib: use vdevel

---
 srcpkgs/hamlib/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/hamlib/template b/srcpkgs/hamlib/template
index 3e9e84512853..ea4418751066 100644
--- a/srcpkgs/hamlib/template
+++ b/srcpkgs/hamlib/template
@@ -27,9 +27,6 @@ hamlib-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmove usr/include
-		vmove "usr/lib/*.so"
-		vmove usr/lib/pkgconfig
-		vmove usr/share/aclocal
+		vdevel
 	}
 }

From e14eccde94fd2d6ae9873cf35534f3bd4db3bbd4 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:25 -0400
Subject: [PATCH 6/8] libjaylink: use vdevel

---
 srcpkgs/libjaylink/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/libjaylink/template b/srcpkgs/libjaylink/template
index 56eae2f11537..57392b4f5508 100644
--- a/srcpkgs/libjaylink/template
+++ b/srcpkgs/libjaylink/template
@@ -21,9 +21,6 @@ libjaylink-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
-		vmove "usr/lib/*.so"
+		vdevel
 	}
 }

From d709d32fd2e6f6537a8d744bdc47161a352d72a5 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:26 -0400
Subject: [PATCH 7/8] qtforkawesome: use vdevel

---
 srcpkgs/qtforkawesome/template | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/srcpkgs/qtforkawesome/template b/srcpkgs/qtforkawesome/template
index 33820cedf364..f9db6c153c4d 100644
--- a/srcpkgs/qtforkawesome/template
+++ b/srcpkgs/qtforkawesome/template
@@ -31,9 +31,7 @@ qtforkawesome-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
+		vdevel
 		vmove usr/share
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
 	}
 }

From 9388d2419ba3eeed5ee393ae9d9f7bd36d034bf6 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:27 -0400
Subject: [PATCH 8/8] syncthingtray: use vdevel

---
 srcpkgs/syncthingtray/template | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/srcpkgs/syncthingtray/template b/srcpkgs/syncthingtray/template
index 7c49025c8258..9748ee7d946d 100644
--- a/srcpkgs/syncthingtray/template
+++ b/srcpkgs/syncthingtray/template
@@ -37,9 +37,7 @@ syncthingtray-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
+		vdevel
 		for d in connector fileitemaction model plasmoid widgets; do
 			vmove "usr/share/syncthing${d}/cmake"
 		done

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PR PATCH] [Updated] [RFC] add vdevel helper
  2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
@ 2022-09-14  4:23 ` classabbyamp
  2022-09-22  8:17 ` thypon
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: classabbyamp @ 2022-09-14  4:23 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1693 bytes --]

There is an updated pull request by classabbyamp against master on the void-packages repository

https://github.com/classabbyamp/void-packages vdevel
https://github.com/void-linux/void-packages/pull/39274

[RFC] add vdevel helper
This adds a helper for the install phase, `vdevel`, which moves commonly-moved patterns/directories to the subpkg in which it's called using `vmove`.

Based on these Highly Scientific™ stats and the existing list in Manual.md, I came up with a list of patterns and directories to move.

<details><summary>The Numbers</summary>

```
  count  command
   1859  vmove usr/include
   1664  vmove usr/lib/*.so
   1414  vmove usr/lib/pkgconfig
    750  vmove usr/lib/*.a
    331  vmove usr/lib/cmake
    182  vmove usr/share/gir-1.0
    154  vmove usr/share/man/man3
    112  vmove usr/lib/qt5/mkspecs
    101  vmove usr/share/gtk-doc
     94  vmove usr/share/vala
     64  vmove usr/share/aclocal
     17  vmove usr/share/info
     15  vmove usr/share/man
     14  vmove usr/lib/*.la
     12  vmove usr/share/cmake
     10  vmove usr/share/pkgconfig
```

</details>

(Should `usr/share/gtk-doc` and/or `usr/share/man/man3` be added to the `vdevel` list?)

If a pattern or directory is not matched, only a warning is printed, describing what wasn't found.

This should be compatible with many `-devel` packages, but not all, and that is okay. Also, if additional files need to be moved, they can be `vmove`d manually.

Some examples of `vdevel` in action are included.

#### Testing the changes
- I tested the changes in this PR: **YES**


A patch file from https://github.com/void-linux/void-packages/pull/39274.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-vdevel-39274.patch --]
[-- Type: text/x-diff, Size: 8572 bytes --]

From a1c034758ce0e3f5a74ee05823811771dc356f88 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 13 Sep 2022 23:46:42 -0400
Subject: [PATCH 1/8] common/environment/setup/install.sh: add vdevel helper

---
 common/environment/setup/install.sh | 43 ++++++++++++++++++++++++++++-
 1 file changed, 42 insertions(+), 1 deletion(-)

diff --git a/common/environment/setup/install.sh b/common/environment/setup/install.sh
index 5f0571de14ae..ac64098e272b 100644
--- a/common/environment/setup/install.sh
+++ b/common/environment/setup/install.sh
@@ -13,7 +13,7 @@ _noglob_helper() {
 }
 
 # Apply _noglob to v* commands
-for cmd in vinstall vcopy vcompletion vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv; do
+for cmd in vinstall vcopy vcompletion vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv vdevel; do
        alias ${cmd}="set -f; _noglob_helper _${cmd}"
 done
 
@@ -265,3 +265,44 @@ _vcompletion() {
 			;;
 	esac
 }
+
+_vdevel() {
+	if [ -z "$DESTDIR" ]; then
+		msg_red "$pkgver: vdevel: DESTDIR unset, can't continue...\n"
+		return 1
+	elif [ -z "$PKGDESTDIR" ]; then
+		msg_red "$pkgver: vdevel: PKGDESTDIR unset, can't continue...\n"
+		return 1
+	elif [ "$DESTDIR" = "$PKGDESTDIR" ]; then
+		msg_red "$pkgver: vdevel is intended to be used in pkg_install\n"
+		return 1
+	fi
+
+	_move_glob() {
+		local pat=$1 msg=$2
+		if [ -n "$(ls ${DESTDIR}/$pat 2>/dev/null)" ]; then
+			vmove "$pat"
+		else
+			msg_warn "$pkgver: vdevel: no $msg found ($pat)\n"
+		fi
+	}
+
+	_move_dir() {
+		local dir=$1 msg=$2
+		if [ -d "${DESTDIR}/$dir" ]; then
+			_move_glob "$dir" "$msg"
+		fi
+	}
+
+	_move_glob 'usr/lib/*.so' 'unversioned shlibs'
+	_move_glob 'usr/lib/*.a' 'library archives'
+	_move_glob 'usr/share/gir-*' 'Gobject introspection XML files'
+
+	_move_dir 'usr/include' 'header files'
+	_move_dir 'usr/lib/cmake' 'cmake rules'
+	_move_dir 'usr/share/cmake' 'cmake rules'
+	_move_dir 'usr/lib/pkgconfig' 'pkgconfig files'
+	_move_dir 'usr/share/pkgconfig' 'pkgconfig files'
+	_move_dir 'usr/share/aclocal' 'Autoconf macros'
+	_move_dir 'usr/share/vala' 'Vala bindings'
+}

From 076d40474e61f38567b3ef29470447f447a40c54 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 13 Sep 2022 23:55:23 -0400
Subject: [PATCH 2/8] Manual.md: document vdevel

---
 Manual.md | 25 +++++++++++++++++++++----
 1 file changed, 21 insertions(+), 4 deletions(-)

diff --git a/Manual.md b/Manual.md
index c24be6e90a74..349a53b586cf 100644
--- a/Manual.md
+++ b/Manual.md
@@ -330,6 +330,23 @@ The following functions are defined by `xbps-src` and can be used on any templat
 	it will default to `pkgname`. The `shell` argument can be one of `bash`,
 	`fish` or `zsh`.
 
+- *vdevel()*
+
+	Installs common development files in the pkg `$DESTDIR`. Prints a warning if files
+	aren't found. Equivalent to:
+```sh
+vmove "usr/lib/*.so"  # unversioned shlibs
+vmove "usr/lib/*.a"  # library archives
+vmove "usr/share/gir-*"  # Gobject introspection XML files
+vmove usr/include  # header files
+vmove usr/lib/cmake  # cmake rules
+vmove usr/share/cmake  # cmake rules
+vmove usr/lib/pkgconfig  # pkgconfig files
+vmove usr/share/pkgconfig  # pkgconfig files
+vmove usr/share/aclocal  # Autoconf macros
+vmove usr/share/vala  # Vala bindings
+```
+
 > Shell wildcards must be properly quoted, Example: `vmove "usr/lib/*.a"`.
 
 <a id="global_vars"></a>
@@ -1438,10 +1455,8 @@ foo-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmove usr/include
-		vmove "usr/lib/*.a"
-		vmove "usr/lib/*.so"
-		vmove usr/lib/pkgconfig
+		vdevel
+		vmove usr/share/gtk-doc
 	}
 }
 ```
@@ -1500,6 +1515,8 @@ following subset of files from the main package:
 * Gobject introspection XML files `usr/share/gir-1.0`
 * Vala bindings `usr/share/vala`
 
+> These common files can be automatically moved to the `-devel` subpackage using `vdevel`
+
 <a id="pkgs_data"></a>
 ### Data packages
 

From 78037bdb5b139cf4bc9786ca7bf7ae2e4fe01933 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:21 -0400
Subject: [PATCH 3/8] LimeSuite: use vdevel

---
 srcpkgs/LimeSuite/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/LimeSuite/template b/srcpkgs/LimeSuite/template
index f7caba84c2fe..b517829b4f7f 100644
--- a/srcpkgs/LimeSuite/template
+++ b/srcpkgs/LimeSuite/template
@@ -64,10 +64,7 @@ LimeSuite-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/cmake
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
+		vdevel
 	}
 }
 

From 027eade4fc81fe07d3d480c7f43b735133f80078 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:24 -0400
Subject: [PATCH 4/8] farstream: use vdevel

---
 srcpkgs/farstream/template | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/srcpkgs/farstream/template b/srcpkgs/farstream/template
index e93c7a0c23bb..db6e66fb7ca7 100644
--- a/srcpkgs/farstream/template
+++ b/srcpkgs/farstream/template
@@ -32,12 +32,7 @@ farstream-devel_package() {
 	depends="gst-plugins-base1-devel farstream-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove usr/lib/*.so
+		vdevel
 		vmove usr/share/gtk-doc
-		if [ "$build_option_gir" ]; then
-			vmove usr/share/gir-1.0
-		fi
 	}
 }

From 2033c277808ad01c4e3238bfd179d63b26863d23 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:25 -0400
Subject: [PATCH 5/8] hamlib: use vdevel

---
 srcpkgs/hamlib/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/hamlib/template b/srcpkgs/hamlib/template
index 3e9e84512853..ea4418751066 100644
--- a/srcpkgs/hamlib/template
+++ b/srcpkgs/hamlib/template
@@ -27,9 +27,6 @@ hamlib-devel_package() {
 	short_desc+=" - development files"
 	depends="${sourcepkg}>=${version}_${revision}"
 	pkg_install() {
-		vmove usr/include
-		vmove "usr/lib/*.so"
-		vmove usr/lib/pkgconfig
-		vmove usr/share/aclocal
+		vdevel
 	}
 }

From ca3a12f25812f0af4d2409f5d3a4ad93c9d45d42 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:25 -0400
Subject: [PATCH 6/8] libjaylink: use vdevel

---
 srcpkgs/libjaylink/template | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/srcpkgs/libjaylink/template b/srcpkgs/libjaylink/template
index 56eae2f11537..57392b4f5508 100644
--- a/srcpkgs/libjaylink/template
+++ b/srcpkgs/libjaylink/template
@@ -21,9 +21,6 @@ libjaylink-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
-		vmove "usr/lib/*.so"
+		vdevel
 	}
 }

From f7d6e06c6a715ce106b9fc0dbbd86ac15c6aa3a0 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:26 -0400
Subject: [PATCH 7/8] qtforkawesome: use vdevel

---
 srcpkgs/qtforkawesome/template | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/srcpkgs/qtforkawesome/template b/srcpkgs/qtforkawesome/template
index 33820cedf364..f9db6c153c4d 100644
--- a/srcpkgs/qtforkawesome/template
+++ b/srcpkgs/qtforkawesome/template
@@ -31,9 +31,7 @@ qtforkawesome-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
+		vdevel
 		vmove usr/share
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
 	}
 }

From 886097359b7c604924d868f3abd6100443552433 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Wed, 14 Sep 2022 00:00:27 -0400
Subject: [PATCH 8/8] syncthingtray: use vdevel

---
 srcpkgs/syncthingtray/template | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/srcpkgs/syncthingtray/template b/srcpkgs/syncthingtray/template
index 7c49025c8258..9748ee7d946d 100644
--- a/srcpkgs/syncthingtray/template
+++ b/srcpkgs/syncthingtray/template
@@ -37,9 +37,7 @@ syncthingtray-devel_package() {
 	depends="${sourcepkg}>=${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
-		vmove usr/include
-		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.so"
+		vdevel
 		for d in connector fileitemaction model plasmoid widgets; do
 			vmove "usr/share/syncthing${d}/cmake"
 		done

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [RFC] add vdevel helper
  2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
  2022-09-14  4:23 ` [PR PATCH] [Updated] " classabbyamp
@ 2022-09-22  8:17 ` thypon
  2022-09-22 11:15 ` classabbyamp
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: thypon @ 2022-09-22  8:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 269 bytes --]

New comment by thypon on void-packages repository

https://github.com/void-linux/void-packages/pull/39274#issuecomment-1254684570

Comment:
Adding a top-level `split_devel=yes` that automatically adds the sub-pkg may substantially decrease the code duplication as well

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [RFC] add vdevel helper
  2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
  2022-09-14  4:23 ` [PR PATCH] [Updated] " classabbyamp
  2022-09-22  8:17 ` thypon
@ 2022-09-22 11:15 ` classabbyamp
  2022-09-22 17:09 ` Vaelatern
  2022-09-22 17:09 ` Vaelatern
  4 siblings, 0 replies; 6+ messages in thread
From: classabbyamp @ 2022-09-22 11:15 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 337 bytes --]

New comment by classabbyamp on void-packages repository

https://github.com/void-linux/void-packages/pull/39274#issuecomment-1254879762

Comment:
i feel that that approach causes too much magic. what if the devel package has a different name than`$sourcepkg-devel`? what is done in the case of other things also going in the devel pkg? 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [RFC] add vdevel helper
  2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
                   ` (2 preceding siblings ...)
  2022-09-22 11:15 ` classabbyamp
@ 2022-09-22 17:09 ` Vaelatern
  2022-09-22 17:09 ` Vaelatern
  4 siblings, 0 replies; 6+ messages in thread
From: Vaelatern @ 2022-09-22 17:09 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 269 bytes --]

New comment by Vaelatern on void-packages repository

https://github.com/void-linux/void-packages/pull/39274#issuecomment-1255313214

Comment:
Magic is relative, right? For many people vmove is a little bit magical, how it differs from vinstall, why you'd use it, etc.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [RFC] add vdevel helper
  2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
                   ` (3 preceding siblings ...)
  2022-09-22 17:09 ` Vaelatern
@ 2022-09-22 17:09 ` Vaelatern
  4 siblings, 0 replies; 6+ messages in thread
From: Vaelatern @ 2022-09-22 17:09 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 342 bytes --]

New comment by Vaelatern on void-packages repository

https://github.com/void-linux/void-packages/pull/39274#issuecomment-1255313214

Comment:
Magic is relative, right? For many people vmove is a little bit magical, how it differs from vinstall, why you'd use it, etc. All in favor of minimizing magic, though, since that's important for us.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-09-22 17:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-14  4:18 [PR PATCH] [RFC] add vdevel helper classabbyamp
2022-09-14  4:23 ` [PR PATCH] [Updated] " classabbyamp
2022-09-22  8:17 ` thypon
2022-09-22 11:15 ` classabbyamp
2022-09-22 17:09 ` Vaelatern
2022-09-22 17:09 ` Vaelatern

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).