pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/net/libfetch
Module Name: pkgsrc
Committed By: pho
Date: Mon Feb 10 03:52:32 UTC 2025
Modified Files:
pkgsrc/net/libfetch: Makefile PLIST buildlink3.mk options.mk
pkgsrc/net/libfetch/files: Makefile
Added Files:
pkgsrc/net/libfetch/files: fetch.pc.in
Log Message:
net/libfetch: Install pkg-config fetch.pc
It's particularly important for libfetch to have a pkg-config file since it
can conditionally depend on libssl and libcrypto. Without it downstream
software have a hard time figuring out how to link it correctly.
While here fix several pkglint errors and warnings.
To generate a diff of this commit:
cvs rdiff -u -r1.65 -r1.66 pkgsrc/net/libfetch/Makefile
cvs rdiff -u -r1.2 -r1.3 pkgsrc/net/libfetch/PLIST
cvs rdiff -u -r1.19 -r1.20 pkgsrc/net/libfetch/buildlink3.mk
cvs rdiff -u -r1.5 -r1.6 pkgsrc/net/libfetch/options.mk
cvs rdiff -u -r1.8 -r1.9 pkgsrc/net/libfetch/files/Makefile
cvs rdiff -u -r0 -r1.1 pkgsrc/net/libfetch/files/fetch.pc.in
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/net/libfetch/Makefile
diff -u pkgsrc/net/libfetch/Makefile:1.65 pkgsrc/net/libfetch/Makefile:1.66
--- pkgsrc/net/libfetch/Makefile:1.65 Wed Jan 3 03:54:46 2024
+++ pkgsrc/net/libfetch/Makefile Mon Feb 10 03:52:32 2025
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.65 2024/01/03 03:54:46 riastradh Exp $
+# $NetBSD: Makefile,v 1.66 2025/02/10 03:52:32 pho Exp $
DISTNAME= libfetch-2.40
+PKGREVISION= 1
CATEGORIES= net
MASTER_SITES= # empty
DISTFILES= # empty
@@ -14,20 +15,25 @@ USE_FEATURES= nbcompat
USE_BSD_MAKEFILE= yes
-.include "../../mk/bsd.prefs.mk"
-.if !empty(FETCH_USING:Mfetch)
-CHECK_PERMS= no
-.endif
-
-INSTALLATION_DIRS= include lib ${PKGMANDIR}/cat3 ${PKGMANDIR}/man3
+INSTALLATION_DIRS+= include
+INSTALLATION_DIRS+= lib
+INSTALLATION_DIRS+= lib/pkgconfig
+INSTALLATION_DIRS+= ${PKGMANDIR}/cat3
+INSTALLATION_DIRS+= ${PKGMANDIR}/man3
BUILD_TARGET= depend all
INSTALL_TARGET= install includes
+MAKE_ENV+= SED=${SED:Q}
do-extract:
${CP} -r ${FILESDIR} ${WRKSRC}
${TOUCH} ${WRKSRC}/fetch.cat3
+SUBST_CLASSES+= pc
+SUBST_STAGE.pc= post-extract
+SUBST_FILES.pc= fetch.pc.in
+SUBST_VARS.pc= COMMENT HOMEPAGE PKGBASE PKGVERSION_NOREV
+
.include "options.mk"
.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/net/libfetch/PLIST
diff -u pkgsrc/net/libfetch/PLIST:1.2 pkgsrc/net/libfetch/PLIST:1.3
--- pkgsrc/net/libfetch/PLIST:1.2 Wed Apr 2 15:33:14 2008
+++ pkgsrc/net/libfetch/PLIST Mon Feb 10 03:52:32 2025
@@ -1,5 +1,6 @@
-@comment $NetBSD: PLIST,v 1.2 2008/04/02 15:33:14 joerg Exp $
+@comment $NetBSD: PLIST,v 1.3 2025/02/10 03:52:32 pho Exp $
include/fetch.h
lib/libfetch.a
-man/cat3/fetch.0
+lib/pkgconfig/fetch.pc
man/man3/fetch.3
+@pkgdir man/cat3
Index: pkgsrc/net/libfetch/buildlink3.mk
diff -u pkgsrc/net/libfetch/buildlink3.mk:1.19 pkgsrc/net/libfetch/buildlink3.mk:1.20
--- pkgsrc/net/libfetch/buildlink3.mk:1.19 Thu Dec 5 17:41:15 2024
+++ pkgsrc/net/libfetch/buildlink3.mk Mon Feb 10 03:52:32 2025
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.19 2024/12/05 17:41:15 jperkin Exp $
+# $NetBSD: buildlink3.mk,v 1.20 2025/02/10 03:52:32 pho Exp $
BUILDLINK_TREE+= libfetch
@@ -7,8 +7,7 @@ LIBFETCH_BUILDLINK3_MK:=
BUILDLINK_DEPMETHOD.libfetch?= build
-BUILDLINK_API_DEPENDS.libfetch+= libfetch>=2.28
-BUILDLINK_ABI_DEPENDS.libfetch?= libfetch>=2.39nb2
+BUILDLINK_API_DEPENDS.libfetch+= libfetch>=2.40nb1
BUILDLINK_PKGSRCDIR.libfetch?= ../../net/libfetch
pkgbase := libfetch
@@ -20,7 +19,7 @@ BUILDLINK_LIBS.libfetch+= -lsocket
.if ${PKG_BUILD_OPTIONS.libfetch:Mopenssl}
. include "../../security/openssl/buildlink3.mk"
-BUILDLINK_DEPMETHOD.openssl= full
+BUILDLINK_DEPMETHOD.openssl+= full
BUILDLINK_LIBS.libfetch+= -lssl -lcrypto
.endif
Index: pkgsrc/net/libfetch/options.mk
diff -u pkgsrc/net/libfetch/options.mk:1.5 pkgsrc/net/libfetch/options.mk:1.6
--- pkgsrc/net/libfetch/options.mk:1.5 Sun Dec 26 10:24:22 2021
+++ pkgsrc/net/libfetch/options.mk Mon Feb 10 03:52:32 2025
@@ -1,4 +1,4 @@
-# $NetBSD: options.mk,v 1.5 2021/12/26 10:24:22 nia Exp $
+# $NetBSD: options.mk,v 1.6 2025/02/10 03:52:32 pho Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.libfetch
PKG_SUPPORTED_OPTIONS= inet6 openssl
@@ -7,7 +7,7 @@ CHECK_BUILTIN.openssl:= yes
.include "../../security/openssl/builtin.mk"
CHECK_BUILTIN.openssl:= no
-.if !empty(USE_BUILTIN.openssl:M[yY][eE][sS])
+.if ${USE_BUILTIN.openssl:U:tl} == "yes"
PKG_SUGGESTED_OPTIONS+= openssl
.endif
Index: pkgsrc/net/libfetch/files/Makefile
diff -u pkgsrc/net/libfetch/files/Makefile:1.8 pkgsrc/net/libfetch/files/Makefile:1.9
--- pkgsrc/net/libfetch/files/Makefile:1.8 Thu Oct 27 10:05:38 2016
+++ pkgsrc/net/libfetch/files/Makefile Mon Feb 10 03:52:32 2025
@@ -1,10 +1,11 @@
-# $NetBSD: Makefile,v 1.8 2016/10/27 10:05:38 joerg Exp $
+# $NetBSD: Makefile,v 1.9 2025/02/10 03:52:32 pho Exp $
LIB= fetch
SRCS= fetch.c common.c ftp.c http.c file.c
DPSRCS= ftperr.h httperr.h
INCS= fetch.h
MAN= fetch.3
+PKGCONFIGS= fetch.pc
CLEANFILES= ftperr.h httperr.h
MKLINT= no
MKPIC= no
@@ -25,6 +26,7 @@ CPPFLAGS+= -DINET6
.if !empty(FETCH_WITH_OPENSSL:M[yY][eE][sS])
CPPFLAGS+= -DWITH_SSL
LDADD= -lssl -lcrypto
+_PC_DEPS+= libssl libcrypto
.endif
CPPFLAGS+= -DFTP_COMBINE_CWDS
@@ -42,4 +44,21 @@ httperr.h: ${.CURDIR}/http.errors ${.CUR
sh ${.CURDIR}/errlist.sh http_errlist HTTP \
${.CURDIR}/http.errors > ${.TARGET}
+.if defined(PKGCONFIGS)
+. for f in ${PKGCONFIGS}
+all: ${f}
+FILES+= ${f}
+CLEANFILES+= ${f}
+FILESDIR_${f}= ${LIBDIR}/pkgconfig
+. endfor
+.SUFFIXES: .pc.in .pc
+.pc.in.pc: ${.CURDIR}/Makefile
+ ${SED} \
+ -e "s,@libdir@,${LIBDIR}," \
+ -e "s,@includedir@,${INCSDIR}," \
+ -e "s,@requires-private@,${_PC_DEPS}," \
+ < ${.IMPSRC} > ${.TARGET}
+.endif
+
.include <bsd.lib.mk>
+.include <bsd.files.mk>
Added files:
Index: pkgsrc/net/libfetch/files/fetch.pc.in
diff -u /dev/null pkgsrc/net/libfetch/files/fetch.pc.in:1.1
--- /dev/null Mon Feb 10 03:52:32 2025
+++ pkgsrc/net/libfetch/files/fetch.pc.in Mon Feb 10 03:52:32 2025
@@ -0,0 +1,12 @@
+# $NetBSD: fetch.pc.in,v 1.1 2025/02/10 03:52:32 pho Exp $
+libdir=@libdir@
+includedir=@includedir@
+
+Name: @PKGBASE@
+Version: @PKGVERSION_NOREV@
+Description: @COMMENT@
+URL: @HOMEPAGE@
+License: BSD-3-Clause
+Requires.private: @requires-private@
+Libs: -L${libdir} -Wl,-R${libdir} -lfetch
+Cflags: -I${includedir}
Home |
Main Index |
Thread Index |
Old Index