Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] Nix
@ 2022-05-08 12:32 faulesocke
  2022-05-08 12:35 ` [PR PATCH] [Updated] nix: update to 2.8.0 faulesocke
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: faulesocke @ 2022-05-08 12:32 UTC (permalink / raw)
  To: ml

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

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

https://github.com/faulesocke/void-packages nix
https://github.com/void-linux/void-packages/pull/37040

Nix
<!-- Uncomment relevant sections and delete options which are not applicable -->

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

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-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, (x86_64-glibc)



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

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

From f5953ed1b354c02c7b880a36251d6f633ae8cf34 Mon Sep 17 00:00:00 2001
From: Urs Schulz <voidpkgs@ursschulz.de>
Date: Wed, 16 Feb 2022 16:58:21 +0100
Subject: [PATCH 1/3] lowdown: add shared library

---
 common/shlibs                        |  1 +
 srcpkgs/lowdown/patches/shared.patch | 43 ++++++++++++++++++++++++++++
 srcpkgs/lowdown/template             |  6 +++-
 3 files changed, 49 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/lowdown/patches/shared.patch

diff --git a/common/shlibs b/common/shlibs
index 784375c7c9aa..677f7cc0a53b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4169,3 +4169,4 @@ libMatrix.so root-6.24.06_1
 libThread.so root-6.24.06_1
 libTMVA.so root-6.24.06_1
 libMathCore.so root-6.24.06_1
+liblowdown.so lowdown-0.9.2_2
diff --git a/srcpkgs/lowdown/patches/shared.patch b/srcpkgs/lowdown/patches/shared.patch
new file mode 100644
index 000000000000..acbe304aed93
--- /dev/null
+++ b/srcpkgs/lowdown/patches/shared.patch
@@ -0,0 +1,43 @@
+diff --git a/Makefile b/Makefile
+Stolen from nixpkgs
+https://github.com/obsidiansystems/nixpkgs/blob/0ceadf99f221cf461efa9edb34424ff6ad375119/pkgs/tools/typesetting/lowdown/shared.patch
+(modified)
+index 955f737..2c9532c 100644
+--- a/Makefile
++++ b/Makefile
+@@ -80,7 +80,7 @@ REGRESS_ARGS	+= "--parse-no-autolink"
+ REGRESS_ARGS	+= "--parse-no-cmark"
+ REGRESS_ARGS	+= "--parse-no-deflists"
+ 
+-all: lowdown lowdown-diff lowdown.pc
++all: lowdown lowdown-diff liblowdown.so lowdown.pc
+ 
+ www: $(HTMLS) $(PDFS) $(THUMBS) lowdown.tar.gz lowdown.tar.gz.sha512
+ 
+@@ -101,6 +101,9 @@ lowdown-diff: lowdown
+ liblowdown.a: $(OBJS) $(COMPAT_OBJS)
+ 	$(AR) rs $@ $(OBJS) $(COMPAT_OBJS)
+ 
++liblowdown.so: $(OBJS) $(COMPAT_OBJS)
++	$(CC) -shared -o $@ $(OBJS) $(COMPAT_OBJS) $(LDFLAGS)
++
+ install: all
+ 	mkdir -p $(DESTDIR)$(BINDIR)
+ 	mkdir -p $(DESTDIR)$(LIBDIR)/pkgconfig
+@@ -111,7 +114,8 @@ install: all
+ 	$(INSTALL_DATA) lowdown.pc $(DESTDIR)$(LIBDIR)/pkgconfig
+ 	$(INSTALL_PROGRAM) lowdown $(DESTDIR)$(BINDIR)
+ 	$(INSTALL_PROGRAM) lowdown-diff $(DESTDIR)$(BINDIR)
+ 	$(INSTALL_LIB) liblowdown.a $(DESTDIR)$(LIBDIR)
++	$(INSTALL_LIB) liblowdown.so $(DESTDIR)$(LIBDIR)
+ 	$(INSTALL_DATA) lowdown.h $(DESTDIR)$(INCLUDEDIR)
+ 	for f in $(MANS) ; do \
+ 		name=`basename $$f .html` ; \
+@@ -199,7 +202,8 @@ main.o: lowdown.h
+ 
+ clean:
+ 	rm -f $(OBJS) $(COMPAT_OBJS) main.o
+ 	rm -f lowdown lowdown-diff liblowdown.a lowdown.pc
++	rm -f lowdown lowdown-diff liblowdown.so lowdown.pc
+ 	rm -f index.xml diff.xml diff.diff.xml README.xml lowdown.tar.gz.sha512 lowdown.tar.gz
+ 	rm -f $(PDFS) $(HTMLS) $(THUMBS)
diff --git a/srcpkgs/lowdown/template b/srcpkgs/lowdown/template
index c76c46601e44..5f69caa0588c 100644
--- a/srcpkgs/lowdown/template
+++ b/srcpkgs/lowdown/template
@@ -1,7 +1,7 @@
 # Template file for 'lowdown'
 pkgname=lowdown
 version=0.9.2
-revision=1
+revision=2
 build_style=configure
 configure_args="PREFIX=/usr MANDIR=/usr/share/man"
 make_check_target="regress"
@@ -13,6 +13,10 @@ homepage="https://kristaps.bsd.lv/lowdown/"
 changelog="https://kristaps.bsd.lv/lowdown/archive.html"
 distfiles="https://kristaps.bsd.lv/lowdown/snapshots/lowdown-${version}.tar.gz"
 checksum=5c355d1db2071916b1ad6e789208de664be3781bd17dd8b6b09b1707a283a988
+shlib_provides="liblowdown.so"
+
+CFLAGS+=" -fPIE -fPIC"
+LDFLAGS+=" -pie"
 
 post_install() {
 	vlicense LICENSE.md

From 73bc0f0bf2635f8209ddf63dc73892ac40793e93 Mon Sep 17 00:00:00 2001
From: Urs Schulz <voidpkgs@ursschulz.de>
Date: Sun, 8 May 2022 13:57:09 +0200
Subject: [PATCH 2/3] New package: nlohmann-json-3.10.5

---
 srcpkgs/nlohmann-json/template | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)
 create mode 100644 srcpkgs/nlohmann-json/template

diff --git a/srcpkgs/nlohmann-json/template b/srcpkgs/nlohmann-json/template
new file mode 100644
index 000000000000..404cd84c4d8f
--- /dev/null
+++ b/srcpkgs/nlohmann-json/template
@@ -0,0 +1,29 @@
+# Template file for 'nlohmann-json'
+pkgname=nlohmann-json
+version=3.10.5
+revision=1
+#archs="i686 x86_64"
+wrksrc="json-${version}"
+#create_wrksrc=yes
+build_style=cmake
+configure_args="-DCMAKE_BUILD_TYPE=None -DJSON_MultipleHeaders=ON"
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+hostmakedepends=""
+makedepends=""
+depends=""
+short_desc="JSON for Modern C++"
+maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
+license="MIT"
+homepage="https://github.com/nlohmann/json"
+#changelog=""
+distfiles="https://github.com/nlohmann/json/archive/refs/tags/v${version}.tar.gz"
+checksum=5daca6ca216495edf89d167f808d1d03c4a4d929cef7da5e10f135ae1540c7e4
+
+
+post_install() {
+    vdoc "README.md"
+    vlicense "LICENSE.MIT"
+}

From 57d0fe00160e7c51fa7e4779f1b459f86b5c5959 Mon Sep 17 00:00:00 2001
From: Urs Schulz <voidpkgs@ursschulz.de>
Date: Sun, 8 May 2022 14:26:54 +0200
Subject: [PATCH 3/3] nix: update to 2.8.0.

---
 srcpkgs/nix/template | 26 ++++++++++++++------------
 1 file changed, 14 insertions(+), 12 deletions(-)

diff --git a/srcpkgs/nix/template b/srcpkgs/nix/template
index 6e481b3760af..a3fc7cc394f6 100644
--- a/srcpkgs/nix/template
+++ b/srcpkgs/nix/template
@@ -1,22 +1,23 @@
 # Template file for 'nix'
 pkgname=nix
-version=2.3.12
+version=2.8.0
 revision=1
 build_style=gnu-configure
 # Use /nix/var as suggested by the official Manual.
 configure_args="--localstatedir=/nix/var --with-sandbox-shell=/bin/sh"
-hostmakedepends="curl pkg-config flex tar xz"
+hostmakedepends="curl pkg-config flex tar xz automake autoconf-archive mdBook"
 makedepends="boost-devel brotli-devel bzip2-devel gc-devel libcurl-devel
  liblzma-devel openssl-devel libsodium-devel sqlite-devel
- libseccomp-devel editline-devel"
+ libseccomp-devel editline-devel jq-devel libarchive-devel libcpuid-devel
+ gtest-devel lowdown-devel nlohmann-json"
 depends="curl tar xz"
 short_desc="Purely functional package manager"
 maintainer="Juan RP <xtraeme@gmail.com>"
 license="LGPL-2.1-or-later"
 homepage="https://nixos.org/nix/"
 changelog="https://nixos.org/releases/${pkgname}/${pkgname}-${version}/manual/#sec-relnotes"
-distfiles="https://nixos.org/releases/${pkgname}/${pkgname}-${version}/${pkgname}-${version}.tar.xz"
-checksum=213a7d49c461079b32361e4d008d248d7f68e34d2cc9347f3a8ff9029f9afb5d
+distfiles="https://github.com/NixOS/nix/archive/refs/tags/${version}.tar.gz"
+checksum=91a7f2bcdde3263927d842f04a345ed77319148c700e2c8be01498724e6808c0
 
 CXXFLAGS="-Wno-deprecated-declarations"
 
@@ -47,13 +48,14 @@ if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
 fi
 
 pre_configure() {
-	if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
-		echo "libexpr_LDFLAGS += -latomic" >> src/libexpr/local.mk
-		echo "libutil_LDFLAGS += -latomic" >> src/libutil/local.mk
-		echo "libstore_LDFLAGS += -latomic" >> src/libstore/local.mk
-	fi
-	sed -i '/^CFLAGS=/d;/^CXXFLAGS=/d' configure
-	echo "GLOBAL_LDFLAGS += $LDFLAGS" >>mk/lib.mk
+    ./bootstrap.sh
+	#if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
+	#	echo "libexpr_LDFLAGS += -latomic" >> src/libexpr/local.mk
+	#	echo "libutil_LDFLAGS += -latomic" >> src/libutil/local.mk
+	#	echo "libstore_LDFLAGS += -latomic" >> src/libstore/local.mk
+	#fi
+	#sed -i '/^CFLAGS=/d;/^CXXFLAGS=/d' configure
+	#echo "GLOBAL_LDFLAGS += $LDFLAGS" >>mk/lib.mk
 }
 
 post_install() {

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

end of thread, other threads:[~2022-05-17  7:52 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-08 12:32 [PR PATCH] Nix faulesocke
2022-05-08 12:35 ` [PR PATCH] [Updated] nix: update to 2.8.0 faulesocke
2022-05-08 12:52 ` faulesocke
2022-05-08 13:12 ` [PR PATCH] [Updated] " faulesocke
2022-05-08 17:47 ` faulesocke
2022-05-08 19:50 ` faulesocke
2022-05-08 20:44 ` faulesocke
2022-05-08 20:54 ` faulesocke
2022-05-08 22:13 ` faulesocke
2022-05-08 23:10 ` faulesocke
2022-05-09 15:28 ` faulesocke
2022-05-17  7:52 ` [PR PATCH] [Merged]: " the-maldridge

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).