From: meator <meator@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] New package: hwinfo-21.77
Date: Tue, 23 Nov 2021 16:15:55 +0100 [thread overview]
Message-ID: <20211123151555.dCTi7Z4HeCUTxVB7nxfQbsCNlOSFQPjzBgNPBTxCbJc@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-33757@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 886 bytes --]
There is an updated pull request by meator against master on the void-packages repository
https://github.com/meator/void-packages hwinfo
https://github.com/void-linux/void-packages/pull/33757
New package: hwinfo-21.77
<!-- Mark items with [x] where applicable -->
The current templates are working, but I'd like to make hwinfo cross-compilable.
#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)
#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [x] I generally don't use the affected packages but briefly tested this PR
Closes #32402
A patch file from https://github.com/void-linux/void-packages/pull/33757.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-hwinfo-33757.patch --]
[-- Type: text/x-diff, Size: 7410 bytes --]
From d4ab6f0294ace1c7a5050428fd916b79da1298f5 Mon Sep 17 00:00:00 2001
From: meator <meator.dev@gmail.com>
Date: Tue, 26 Oct 2021 10:26:44 +0200
Subject: [PATCH 1/2] New package: libx86emu-3.3
---
common/shlibs | 1 +
srcpkgs/libx86emu-devel | 1 +
srcpkgs/libx86emu/patches/makefile.patch | 38 ++++++++++++++++++++++++
srcpkgs/libx86emu/template | 32 ++++++++++++++++++++
4 files changed, 72 insertions(+)
create mode 120000 srcpkgs/libx86emu-devel
create mode 100644 srcpkgs/libx86emu/patches/makefile.patch
create mode 100644 srcpkgs/libx86emu/template
diff --git a/common/shlibs b/common/shlibs
index ab865cc085d2..85d773fc5659 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4070,3 +4070,4 @@ libbrial_groebner.so.3 brial-1.2.10_1
libm4ri-0.0.20200125.so m4ri-20200125_1
libm4rie-0.0.20200125.so m4rie-20200125_1
libptytty.so.0 libptytty-2.0_1
+libx86emu.so.3 libx86emu-3.4_1
diff --git a/srcpkgs/libx86emu-devel b/srcpkgs/libx86emu-devel
new file mode 120000
index 000000000000..2a7a94ee3c36
--- /dev/null
+++ b/srcpkgs/libx86emu-devel
@@ -0,0 +1 @@
+libx86emu
\ No newline at end of file
diff --git a/srcpkgs/libx86emu/patches/makefile.patch b/srcpkgs/libx86emu/patches/makefile.patch
new file mode 100644
index 000000000000..5c5465c54f3e
--- /dev/null
+++ b/srcpkgs/libx86emu/patches/makefile.patch
@@ -0,0 +1,38 @@
+--- a/Makefile 2021-08-18 18:30:18.000000000 +0200
++++ b/Makefile 2021-10-12 20:08:12.973944586 +0200
+@@ -12,7 +12,7 @@
+ MAJOR_VERSION := $(shell $(GIT2LOG) --version VERSION ; cut -d . -f 1 VERSION)
+
+ CC = gcc
+-CFLAGS = -g -O2 -fPIC -fvisibility=hidden -fomit-frame-pointer -Wall
++CFLAGS = -g -O2 -fomit-frame-pointer -Wall
+ LDFLAGS =
+
+ LIBDIR = /usr/lib$(shell ldd /bin/sh | grep -q /lib64/ && echo 64)
+@@ -27,7 +27,7 @@
+ .PHONY: all shared install test demo clean
+
+ %.o: %.c
+- $(CC) -c $(CFLAGS) $<
++ $(CC) -c -fPIC -fvisibility=hidden $(CFLAGS) $<
+
+ all: changelog shared
+
+@@ -43,7 +43,7 @@
+ install -m 644 -D include/x86emu.h $(DESTDIR)/usr/include/x86emu.h
+
+ $(LIB_NAME): .depend $(OBJS)
+- $(CC) -shared -Wl,-soname,$(LIB_SONAME) $(OBJS) -o $(LIB_NAME) $(LDFLAGS)
++ $(CC) -fvisibility=hidden -shared -Wl,-soname,$(LIB_SONAME) $(OBJS) -o $(LIB_NAME) $(LDFLAGS)
+ @ln -snf $(LIB_NAME) $(LIB_SONAME)
+ @ln -snf $(LIB_SONAME) $(LIBX86).so
+
+@@ -68,7 +68,7 @@
+
+ ifneq "$(MAKECMDGOALS)" "clean"
+ .depend: $(CFILES)
+- @$(CC) -MG -MM $(CFLAGS) $(CFILES) >$@
++ @$(CC) -MG -MM -fPIC -fvisibility=hidden $(CFLAGS) $(CFILES) >$@
+ -include .depend
+ endif
+
diff --git a/srcpkgs/libx86emu/template b/srcpkgs/libx86emu/template
new file mode 100644
index 000000000000..b723ae582df0
--- /dev/null
+++ b/srcpkgs/libx86emu/template
@@ -0,0 +1,32 @@
+# Template file for 'libx86emu'
+pkgname=libx86emu
+version=3.4
+revision=1
+build_style=gnu-makefile
+make_check_target=test
+make_install_args="LIBDIR=/usr/lib${XBPS_TARGET_WORDSIZE}"
+checkdepends="perl nasm"
+short_desc="X86 emulation library"
+maintainer="meator <meator.dev@gmail.com>"
+license="MIT" # Old Style with legal disclaimer
+homepage="https://github.com/wfeldt/libx86emu"
+distfiles="https://github.com/wfeldt/libx86emu/archive/refs/tags/${version}.tar.gz"
+checksum=bfc54da560931ea42db0dc1421164579e7aff1e62a91253ef20f069770e1b9a9
+
+do_configure() {
+ rm git2log
+ echo ${version} > VERSION
+}
+
+post_install() {
+ vlicense LICENSE
+}
+
+libx86emu-devel_package() {
+ depends="${sourcepkg}>=${version}_${revision}"
+ short_desc+=" - development files"
+ pkg_install() {
+ vmove usr/include
+ vmove "usr/lib/*.so"
+ }
+}
From d8d031ba249632048f498272bd33ad0c50382941 Mon Sep 17 00:00:00 2001
From: meator <meator.dev@gmail.com>
Date: Sun, 17 Oct 2021 10:52:31 +0200
Subject: [PATCH 2/2] New package: hwinfo-21.77
---
srcpkgs/hwinfo/files/ids.patch | 13 ++++++++++
srcpkgs/hwinfo/files/isdn.patch | 24 ++++++++++++++++++
srcpkgs/hwinfo/template | 44 +++++++++++++++++++++++++++++++++
3 files changed, 81 insertions(+)
create mode 100644 srcpkgs/hwinfo/files/ids.patch
create mode 100644 srcpkgs/hwinfo/files/isdn.patch
create mode 100644 srcpkgs/hwinfo/template
diff --git a/srcpkgs/hwinfo/files/ids.patch b/srcpkgs/hwinfo/files/ids.patch
new file mode 100644
index 000000000000..e6d016cf1c8c
--- /dev/null
+++ b/srcpkgs/hwinfo/files/ids.patch
@@ -0,0 +1,13 @@
+--- a/src/ids/Makefile 2021-10-01 13:55:16.000000000 +0200
++++ b/src/ids/Makefile 2021-10-26 13:05:51.241897833 +0200
+@@ -56,8 +56,8 @@
+ hd_ids.c: hd_ids.h hd_ids_tiny.h
+
+ hd_ids.h hd.ids: check_hd $(IDFILES)
+- ./check_hd --check --sort --cfile hd_ids.h $(IDFILES)
++ check_hd --check --sort --cfile hd_ids.h $(IDFILES)
+
+ hd_ids_tiny.h: check_hd hd.ids
+- ./check_hd --mini --cfile hd_ids_tiny.h --log=hd_tiny.log --out=hd_tiny.ids hd.ids
++ check_hd --mini --cfile hd_ids_tiny.h --log=hd_tiny.log --out=hd_tiny.ids hd.ids
+
diff --git a/srcpkgs/hwinfo/files/isdn.patch b/srcpkgs/hwinfo/files/isdn.patch
new file mode 100644
index 000000000000..47fa78240395
--- /dev/null
+++ b/srcpkgs/hwinfo/files/isdn.patch
@@ -0,0 +1,24 @@
+Remove isdn_cdb.h from TARGETS, so it won't be recompiled again. This is unnecessary
+because it is already being made explicitly.
+Remove isdn_cdb.h from CLEANFILES. The template uses make clean to clean junk from
+isdn_cdb.h, but it needs isdn_cdb.h, so this will not delete it.
+--- a/src/isdn/cdb/Makefile 2021-10-01 13:55:16.000000000 +0200
++++ b/src/isdn/cdb/Makefile 2021-10-26 12:59:56.810695582 +0200
+@@ -1,6 +1,6 @@
+ TOPDIR = ../../..
+-TARGETS = mk_isdnhwdb isdn_cdb.h ISDN.CDB.hwdb
+-CLEANFILES = isdn_cdb isdn_cdb.h lex.yy.c ISDN.CDB.txt mk_isdnhwdb ISDN.CDB.hwdb
++TARGETS = mk_isdnhwdb ISDN.CDB.hwdb
++CLEANFILES = isdn_cdb lex.yy.c ISDN.CDB.txt mk_isdnhwdb ISDN.CDB.hwdb
+
+ include $(TOPDIR)/Makefile.common
+
+@@ -28,6 +28,6 @@
+
+ mk_isdnhwdb.o: mk_isdnhwdb.c cdb_read.h lex.yy.c
+
+-ISDN.CDB.hwdb: mk_isdnhwdb ISDN.CDB.txt
++ISDN.CDB.hwdb: ISDN.CDB.txt
+ rm -f ISDN.CDB.hwdb
+- ./mk_isdnhwdb ISDN.CDB.txt ISDN.CDB.hwdb
++ mk_isdnhwdb ISDN.CDB.txt ISDN.CDB.hwdb
diff --git a/srcpkgs/hwinfo/template b/srcpkgs/hwinfo/template
new file mode 100644
index 000000000000..7ef28f615f43
--- /dev/null
+++ b/srcpkgs/hwinfo/template
@@ -0,0 +1,44 @@
+# Template file for 'hwinfo'
+pkgname=hwinfo
+version=21.78
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+make_build_args="HWINFO_VERSION=${version} LIBDIR=/usr/lib${XBPS_TARGET_WORDSIZE}"
+make_install_args="${make_build_args}"
+hostmakedepends="perl flex"
+makedepends="libx86emu-devel libuuid-devel"
+short_desc="Hardware information tool"
+maintainer="meator <meator.dev@gmail.com>"
+license="GPL-2.0-or-later"
+homepage="https://github.com/openSUSE/hwinfo"
+distfiles="https://github.com/openSUSE/hwinfo/archive/refs/tags/${version}.tar.gz"
+checksum=8693d4e8bc134139fc62e659ca608e138dc089a0cb1194dc93ee278fdef10bba
+disable_parallel_build=yes
+
+if [ "$CROSS_BUILD" ]; then
+ hostmakedepends+=" hwinfo"
+fi
+
+post_patch() {
+ if [ "$CROSS_BUILD" ]; then
+ for p in ${FILESDIR}/*; do
+ patch -p1 < $p
+ done
+ fi
+}
+
+pre_build() {
+ if [ "$CROSS_BUILD" ]; then
+ CC=gcc CFLAGS= LDFLAGS= make ${make_build_args} -C src/isdn/cdb isdn_cdb.h
+ make -C src/isdn/cdb clean
+ fi
+}
+
+post_install() {
+ mv ${DESTDIR}/usr/sbin ${DESTDIR}/usr/bin
+
+ for m in doc/*.[1-9]; do
+ vman ${m}
+ done
+}
next prev parent reply other threads:[~2021-11-23 15:15 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-26 9:11 [PR PATCH] " meator
2021-10-26 9:15 ` [PR REVIEW] " meator
2021-10-26 12:15 ` meator
2021-10-26 12:58 ` ericonr
2021-10-26 14:46 ` meator
2021-10-27 12:35 ` [PR PATCH] [Updated] " meator
2021-10-27 12:35 ` meator
2021-11-14 7:51 ` [PR PATCH] [Updated] " meator
2021-11-14 8:11 ` meator
2021-11-23 15:15 ` meator [this message]
2021-12-08 17:51 ` [PR PATCH] [Updated] " meator
2021-12-25 9:22 ` meator
2021-12-30 14:25 ` leahneukirchen
2021-12-30 16:28 ` [PR PATCH] [Updated] " meator
2021-12-30 16:30 ` meator
2021-12-30 19:22 ` meator
2021-12-30 19:30 ` [PR PATCH] [Merged]: " leahneukirchen
2021-12-30 19:30 ` 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=20211123151555.dCTi7Z4HeCUTxVB7nxfQbsCNlOSFQPjzBgNPBTxCbJc@z \
--to=meator@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).