Github messages for voidlinux
 help / color / mirror / Atom feed
From: oreo639 <oreo639@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] binutils: make libiberty-devel into subpkg
Date: Wed, 12 Apr 2023 08:13:42 +0200	[thread overview]
Message-ID: <20230412061342.li0e05pD9iuAbKSt1qJe9OdM5nwT2TvI_YNvzXSqCak@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-41878@inbox.vuxu.org>

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

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

https://github.com/oreo639/void-packages libiberty
https://github.com/void-linux/void-packages/pull/41878

binutils: make libiberty-devel into subpkg
<!-- Uncomment relevant sections and delete options which are not applicable -->

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

Currently libiberty-devel fails to build due to the distfile being deleted.

This was originally used before being switched by q66 due to it not installing the `-fPIC` version (despite it getting built) which is worked around in this PR the same as it is in the libiberty-devel package (rebuilding the non-pic version of libiberty with `-fPIC`)

The previous debian source we used was taken from binutils 2.39 source anyway.

Also require packages that use it to explicitly depend on it.

Alternatively, this issue can be resolved by: https://github.com/void-linux/void-packages/pull/43318

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


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

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

From a2ca8d3598e7d162db33dd625aad1b68c9619904 Mon Sep 17 00:00:00 2001
From: oreo639 <oreo6391@gmail.com>
Date: Wed, 25 Jan 2023 21:05:01 -0800
Subject: [PATCH] binutils: make libiberty-devel into subpkg

---
 srcpkgs/binutils/template        | 21 +++++++++++++++++----
 srcpkgs/libiberty-devel          |  1 +
 srcpkgs/libiberty-devel/template | 16 ----------------
 3 files changed, 18 insertions(+), 20 deletions(-)
 create mode 120000 srcpkgs/libiberty-devel
 delete mode 100644 srcpkgs/libiberty-devel/template

diff --git a/srcpkgs/binutils/template b/srcpkgs/binutils/template
index c355a5fc8016..441e43553904 100644
--- a/srcpkgs/binutils/template
+++ b/srcpkgs/binutils/template
@@ -1,7 +1,7 @@
 # Template file for 'binutils'
 pkgname=binutils
 version=2.39
-revision=1
+revision=2
 bootstrap=yes
 hostmakedepends="pkgconf"
 makedepends="zlib-devel"
@@ -9,7 +9,7 @@ short_desc="GNU binary utilities"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="http://www.gnu.org/software/binutils/"
-distfiles="${GNU_SITE}/$pkgname/$pkgname-$version.tar.xz"
+distfiles="${GNU_SITE}/binutils/binutils-${version}.tar.xz"
 checksum=645c25f563b8adc0a81dbd6a41cffbf4d37083a382e02d5d3df4f65c09516d00
 
 subpackages="binutils-doc"
@@ -18,7 +18,7 @@ if [ "$CHROOT_READY" ]; then
 	makedepends+=" elfutils-devel"
 	checkdepends="bc"
 	depends="binutils-doc"
-	subpackages+=" binutils-devel"
+	subpackages+=" libiberty-devel binutils-devel"
 fi
 
 _get_triplet() {
@@ -36,7 +36,7 @@ do_configure() {
 	local conf
 
 	if [ "$CHROOT_READY" ]; then
-		conf+=" --with-debuginfod --enable-shared"
+		conf+=" --with-debuginfod --enable-shared --enable-install-libiberty"
 	else
 		conf+=" --without-debuginfod --disable-shared --disable-install-libbfd"
 	fi
@@ -132,6 +132,9 @@ do_install() {
 			>${DESTDIR}/usr/lib/libbfd.so
 		echo "INPUT ( /usr/lib/libopcodes.a -lbfd )" \
 			>${DESTDIR}/usr/lib/libopcodes.so
+
+		# Install PIC version of libiberty.a
+		vinstall build/libiberty/pic/libiberty.a 755 usr/lib
 	fi
 
 	# Remove useless manpages.
@@ -163,3 +166,13 @@ binutils-doc_package() {
 		rm -f ${PKGDESTDIR}/usr/share/info/standards.info
 	}
 }
+
+libiberty-devel_package() {
+	reverts="20220713_1 20210106_1"
+	short_desc="Library of utility functions used by GNU programs"
+	conflicts="binutils-devel<=2.35.1_3"
+	pkg_install() {
+		vmove usr/include/libiberty
+		vmove usr/lib/libiberty.a
+	}
+}
diff --git a/srcpkgs/libiberty-devel b/srcpkgs/libiberty-devel
new file mode 120000
index 000000000000..695eb82eae64
--- /dev/null
+++ b/srcpkgs/libiberty-devel
@@ -0,0 +1 @@
+binutils
\ No newline at end of file
diff --git a/srcpkgs/libiberty-devel/template b/srcpkgs/libiberty-devel/template
deleted file mode 100644
index d9618e3806ba..000000000000
--- a/srcpkgs/libiberty-devel/template
+++ /dev/null
@@ -1,16 +0,0 @@
-# Template file for 'libiberty-devel'
-pkgname=libiberty-devel
-version=20220713
-revision=1
-build_wrksrc=libiberty
-build_style=gnu-configure
-configure_args="--disable-multilib --enable-install-libiberty"
-short_desc="Library of utility functions used by GNU programs"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="GPL-3.0-or-later"
-homepage="http://gcc.gnu.org/"
-distfiles="http://deb.debian.org/debian/pool/main/libi/libiberty/libiberty_${version}.orig.tar.xz"
-checksum=b59050f48c8a0f9c9e6fba5d17c7a4f11d1329de0c0dca7331b767a6d2bbe8d9
-conflicts="binutils-devel<=2.35.1_3"
-
-CFLAGS="-fPIC"

  parent reply	other threads:[~2023-04-12  6:13 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-26  6:58 [PR PATCH] " oreo639
2023-01-26  7:03 ` [PR PATCH] [Updated] " oreo639
2023-01-26  7:05 ` oreo639
2023-01-26  7:07 ` oreo639
2023-01-26  7:45 ` oreo639
2023-01-26  7:50 ` oreo639
2023-01-26  8:56 ` [PR PATCH] [Updated] " oreo639
2023-02-25 11:35 ` oreo639
2023-04-12  6:13 ` oreo639 [this message]
2023-04-12  6:17 ` oreo639
2023-04-12 11:20 ` [PR PATCH] [Merged]: " leahneukirchen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230412061342.li0e05pD9iuAbKSt1qJe9OdM5nwT2TvI_YNvzXSqCak@z \
    --to=oreo639@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).