* [PR PATCH] docbook2mdoc: fix build and extract license file
@ 2022-09-20 21:07 mtboehlke
2022-09-21 0:51 ` [PR REVIEW] " sgn
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: mtboehlke @ 2022-09-20 21:07 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1365 bytes --]
There is a new pull request by mtboehlke against master on the void-packages repository
https://github.com/mtboehlke/void-packages docbook2mdoc
https://github.com/void-linux/void-packages/pull/39395
docbook2mdoc: fix build and extract license file
<!-- Uncomment relevant sections and delete options which are not applicable -->
Use pkg-config to set flags for libbsd, add missing libmd depend, and install a license file
#### Testing the changes
- I tested the changes in this PR: **YES**
<!--
#### 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/39395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-docbook2mdoc-39395.patch --]
[-- Type: text/x-diff, Size: 1826 bytes --]
From 4532202db97281a8b7f5946693334635e2cb7ff2 Mon Sep 17 00:00:00 2001
From: Mat Boehlke <mtboehlke@gmail.com>
Date: Tue, 20 Sep 2022 16:01:49 -0500
Subject: [PATCH] docbook2mdoc: fix build and extract license file
---
srcpkgs/docbook2mdoc/template | 26 ++++++++++++++++++--------
1 file changed, 18 insertions(+), 8 deletions(-)
diff --git a/srcpkgs/docbook2mdoc/template b/srcpkgs/docbook2mdoc/template
index 24f1bee61836..0c8729a51afe 100644
--- a/srcpkgs/docbook2mdoc/template
+++ b/srcpkgs/docbook2mdoc/template
@@ -1,19 +1,29 @@
# Template file for 'docbook2mdoc'
pkgname=docbook2mdoc
version=1.1.0
-revision=1
+revision=2
build_style=gnu-makefile
-makedepends="libbsd-devel"
+hostmakedepends="pkg-config"
+makedepends="libbsd-devel libmd-devel"
short_desc="Converter from DocBook V4.x and v5.x XML into mdoc"
maintainer="Orphaned <orphan@voidlinux.org>"
license="ISC"
-homepage="http://mdocml.bsd.lv/docbook2mdoc"
-distfiles="http://mdocml.bsd.lv/docbook2mdoc/snapshots/${pkgname}-${version}.tgz"
+homepage="https://mandoc.bsd.lv/docbook2mdoc"
+distfiles="https://mandoc.bsd.lv/docbook2mdoc/snapshots/${pkgname}-${version}.tgz"
checksum=9fc6411cf041ff10e76f19a50a142075a8df9d343f248e20d8fc98bf8e547c71
-LDFLAGS="-lbsd"
+CFLAGS="-D_GNU_SOURCE"
+
post_extract() {
- sed -i '/CC.*-o/s/$/ $(LDFLAGS)/' Makefile
- sed -i 's,/man/man1,/share/man/man1,g' Makefile
- vsed -e 's:sys/queue.h:bsd/sys/queue.h:' -i node.h
+ # Use pkg-config to set libbsd flags
+ vsed -e '/^CFLAGS/c override CFLAGS += $(shell pkg-config --cflags libbsd-overlay)\
+override LDFLAGS += $(shell pkg-config --libs libbsd-overlay)' \
+ -e '/CC.*-o/s/$/ $(LDFLAGS)/; s,/man/man1,/share/man/man1,g' -i Makefile
+
+ # Create License file
+ sed -E '3,16 !d;s/^ [*] ?//' docbook2mdoc.c > LICENSE
+}
+
+post_install() {
+ vlicense LICENSE
}
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR REVIEW] docbook2mdoc: fix build and extract license file
2022-09-20 21:07 [PR PATCH] docbook2mdoc: fix build and extract license file mtboehlke
@ 2022-09-21 0:51 ` sgn
2022-09-21 1:35 ` [PR PATCH] [Updated] " mtboehlke
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: sgn @ 2022-09-21 0:51 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 163 bytes --]
New review comment by sgn on void-packages repository
https://github.com/void-linux/void-packages/pull/39395#discussion_r975922791
Comment:
Please make a patch.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR PATCH] [Updated] docbook2mdoc: fix build and extract license file
2022-09-20 21:07 [PR PATCH] docbook2mdoc: fix build and extract license file mtboehlke
2022-09-21 0:51 ` [PR REVIEW] " sgn
@ 2022-09-21 1:35 ` mtboehlke
2022-09-21 1:36 ` [PR REVIEW] " mtboehlke
2022-09-21 8:37 ` [PR PATCH] [Merged]: " sgn
3 siblings, 0 replies; 5+ messages in thread
From: mtboehlke @ 2022-09-21 1:35 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1370 bytes --]
There is an updated pull request by mtboehlke against master on the void-packages repository
https://github.com/mtboehlke/void-packages docbook2mdoc
https://github.com/void-linux/void-packages/pull/39395
docbook2mdoc: fix build and extract license file
<!-- Uncomment relevant sections and delete options which are not applicable -->
Use pkg-config to set flags for libbsd, add missing libmd depend, and install a license file
#### Testing the changes
- I tested the changes in this PR: **YES**
<!--
#### 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/39395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-docbook2mdoc-39395.patch --]
[-- Type: text/x-diff, Size: 3085 bytes --]
From 590d8e1e707c706e0f8fb338fa5988bfbba0ea9c Mon Sep 17 00:00:00 2001
From: Mat Boehlke <mtboehlke@gmail.com>
Date: Tue, 20 Sep 2022 16:01:49 -0500
Subject: [PATCH] docbook2mdoc: fix build and extract license file
---
srcpkgs/docbook2mdoc/patches/Makefile.patch | 33 +++++++++++++++++++++
srcpkgs/docbook2mdoc/template | 21 ++++++++-----
2 files changed, 46 insertions(+), 8 deletions(-)
create mode 100644 srcpkgs/docbook2mdoc/patches/Makefile.patch
diff --git a/srcpkgs/docbook2mdoc/patches/Makefile.patch b/srcpkgs/docbook2mdoc/patches/Makefile.patch
new file mode 100644
index 000000000000..592209c20974
--- /dev/null
+++ b/srcpkgs/docbook2mdoc/patches/Makefile.patch
@@ -0,0 +1,33 @@
+diff --git a/Makefile b/Makefile
+index d4d536b..d6fc20e 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,5 +1,6 @@
+ VERSION = 1.1.0
+-CFLAGS += -g -W -Wall -Wstrict-prototypes -Wno-unused-parameter -Wwrite-strings
++override CFLAGS += $(shell pkg-config --cflags libbsd-overlay)
++override LDFLAGS += $(shell pkg-config --libs libbsd-overlay)
+ WWWPREFIX = /var/www/vhosts/mdocml.bsd.lv/htdocs/docbook2mdoc
+ PREFIX = /usr/local
+
+@@ -11,7 +12,7 @@ DISTFILES = Makefile NEWS docbook2mdoc.1
+ all: docbook2mdoc
+
+ docbook2mdoc: $(OBJS)
+- $(CC) -g -o $@ $(OBJS)
++ $(CC) -g -o $@ $(OBJS) $(LDFLAGS)
+
+ statistics: statistics.o xmalloc.o
+ $(CC) -g -o $@ statistics.o xmalloc.o
+@@ -20,9 +21,9 @@ www: docbook2mdoc.1.html docbook2mdoc-$(VERSION).tgz README.txt
+
+ install: all
+ mkdir -p $(DESTDIR)$(PREFIX)/bin
+- mkdir -p $(DESTDIR)$(PREFIX)/man/man1
++ mkdir -p $(DESTDIR)$(PREFIX)/share/man/man1
+ install -m 0755 docbook2mdoc $(DESTDIR)$(PREFIX)/bin
+- install -m 0444 docbook2mdoc.1 $(DESTDIR)$(PREFIX)/man/man1
++ install -m 0444 docbook2mdoc.1 $(DESTDIR)$(PREFIX)/share/man/man1
+
+ installwww: www
+ mkdir -p $(WWWPREFIX)/snapshots
diff --git a/srcpkgs/docbook2mdoc/template b/srcpkgs/docbook2mdoc/template
index 24f1bee61836..cad29f76d8d8 100644
--- a/srcpkgs/docbook2mdoc/template
+++ b/srcpkgs/docbook2mdoc/template
@@ -1,19 +1,24 @@
# Template file for 'docbook2mdoc'
pkgname=docbook2mdoc
version=1.1.0
-revision=1
+revision=2
build_style=gnu-makefile
-makedepends="libbsd-devel"
+hostmakedepends="pkg-config"
+makedepends="libbsd-devel libmd-devel"
short_desc="Converter from DocBook V4.x and v5.x XML into mdoc"
maintainer="Orphaned <orphan@voidlinux.org>"
license="ISC"
-homepage="http://mdocml.bsd.lv/docbook2mdoc"
-distfiles="http://mdocml.bsd.lv/docbook2mdoc/snapshots/${pkgname}-${version}.tgz"
+homepage="https://mandoc.bsd.lv/docbook2mdoc"
+distfiles="https://mandoc.bsd.lv/docbook2mdoc/snapshots/${pkgname}-${version}.tgz"
checksum=9fc6411cf041ff10e76f19a50a142075a8df9d343f248e20d8fc98bf8e547c71
-LDFLAGS="-lbsd"
+CFLAGS="-D_GNU_SOURCE"
+
post_extract() {
- sed -i '/CC.*-o/s/$/ $(LDFLAGS)/' Makefile
- sed -i 's,/man/man1,/share/man/man1,g' Makefile
- vsed -e 's:sys/queue.h:bsd/sys/queue.h:' -i node.h
+ # Create License file
+ sed -E '3,16 !d;s/^ [*] ?//' docbook2mdoc.c > LICENSE
+}
+
+post_install() {
+ vlicense LICENSE
}
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR REVIEW] docbook2mdoc: fix build and extract license file
2022-09-20 21:07 [PR PATCH] docbook2mdoc: fix build and extract license file mtboehlke
2022-09-21 0:51 ` [PR REVIEW] " sgn
2022-09-21 1:35 ` [PR PATCH] [Updated] " mtboehlke
@ 2022-09-21 1:36 ` mtboehlke
2022-09-21 8:37 ` [PR PATCH] [Merged]: " sgn
3 siblings, 0 replies; 5+ messages in thread
From: mtboehlke @ 2022-09-21 1:36 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 153 bytes --]
New review comment by mtboehlke on void-packages repository
https://github.com/void-linux/void-packages/pull/39395#discussion_r975957173
Comment:
Done
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PR PATCH] [Merged]: docbook2mdoc: fix build and extract license file
2022-09-20 21:07 [PR PATCH] docbook2mdoc: fix build and extract license file mtboehlke
` (2 preceding siblings ...)
2022-09-21 1:36 ` [PR REVIEW] " mtboehlke
@ 2022-09-21 8:37 ` sgn
3 siblings, 0 replies; 5+ messages in thread
From: sgn @ 2022-09-21 8:37 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1205 bytes --]
There's a merged pull request on the void-packages repository
docbook2mdoc: fix build and extract license file
https://github.com/void-linux/void-packages/pull/39395
Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->
Use pkg-config to set flags for libbsd, add missing libmd depend, and install a license file
#### Testing the changes
- I tested the changes in this PR: **YES**
<!--
#### 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
-->
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-09-21 8:37 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-20 21:07 [PR PATCH] docbook2mdoc: fix build and extract license file mtboehlke
2022-09-21 0:51 ` [PR REVIEW] " sgn
2022-09-21 1:35 ` [PR PATCH] [Updated] " mtboehlke
2022-09-21 1:36 ` [PR REVIEW] " mtboehlke
2022-09-21 8:37 ` [PR PATCH] [Merged]: " sgn
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).