pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/security/openssh
Module Name: pkgsrc
Committed By: vins
Date: Sun Jun 1 08:11:47 UTC 2025
Added Files:
pkgsrc/security/openssh: buildlink3.mk builtin.mk
Log Message:
security/openssh: add buidlink/builtin.mk support
To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 pkgsrc/security/openssh/buildlink3.mk \
pkgsrc/security/openssh/builtin.mk
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Added files:
Index: pkgsrc/security/openssh/buildlink3.mk
diff -u /dev/null pkgsrc/security/openssh/buildlink3.mk:1.1
--- /dev/null Sun Jun 1 08:11:47 2025
+++ pkgsrc/security/openssh/buildlink3.mk Sun Jun 1 08:11:47 2025
@@ -0,0 +1,14 @@
+# $NetBSD: buildlink3.mk,v 1.1 2025/06/01 08:11:47 vins Exp $
+
+BUILDLINK_TREE+= openssh
+
+.if !defined(OPENSSH_BUILDLINK3_MK)
+OPENSSH_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.openssh+= openssh>=9.6
+BUILDLINK_PKGSRCDIR.openssh?= ../../security/openssh
+
+.include "../../devel/zlib/buildlink3.mk"
+.endif # OPENSSH_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -openssh
Index: pkgsrc/security/openssh/builtin.mk
diff -u /dev/null pkgsrc/security/openssh/builtin.mk:1.1
--- /dev/null Sun Jun 1 08:11:47 2025
+++ pkgsrc/security/openssh/builtin.mk Sun Jun 1 08:11:47 2025
@@ -0,0 +1,63 @@
+# $NetBSD: builtin.mk,v 1.1 2025/06/01 08:11:47 vins Exp $
+
+BUILTIN_PKG:= openssh
+
+BUILTIN_FIND_FILES_VAR:= SSH
+BUILTIN_FIND_FILES.SSH= \
+ /bin/ssh \
+ /usr/bin/ssh \
+ /usr/local/bin/ssh
+
+.include "../../mk/buildlink3/bsd.builtin.mk"
+
+###
+### Determine if there is a built-in implementation of the package and
+### set IS_BUILTIN.<pkg> appropriately ("yes" or "no").
+###
+.if !defined(IS_BUILTIN.openssh)
+. if empty(SSH:M__nonexistent__)
+IS_BUILTIN.openssh= yes
+. else
+IS_BUILTIN.openssh= no
+. endif
+.endif
+MAKEVARS+= IS_BUILTIN.openssh
+
+###
+### If there is a built-in implementation, then set BUILTIN_PKG.<pkg> to
+### a package name to represent the built-in package.
+###
+.if ${USE_CROSS_COMPILE:tl} != "yes" && \
+ !defined(BUILTIN_PKG.openssh) && \
+ ${IS_BUILTIN.openssh:tl} == yes
+BUILTIN_VERSION.openssh!= ${SSH} -V 2>&1 | sed -e 's/.*_\([0-9][0-9\.]*\).*/\1/'
+BUILTIN_PKG.openssh= openssh-${BUILTIN_VERSION.openssh}
+.endif
+MAKEVARS+= BUILTIN_PKG.openssh
+
+###
+### Determine whether we should use the built-in implementation if it
+### exists, and set USE_BUILTIN.<pkg> appropriate ("yes" or "no").
+###
+.if !defined(USE_BUILTIN.openssh)
+. if ${PREFER.openssh} == "pkgsrc"
+USE_BUILTIN.openssh= no
+. else
+USE_BUILTIN.openssh= ${IS_BUILTIN.openssh}
+. if defined(BUILTIN_PKG.openssh) && \
+ ${IS_BUILTIN.openssh:tl} == yes
+USE_BUILTIN.openssh= yes
+. for _dep_ in ${BUILDLINK_API_DEPENDS.openssh}
+. if ${USE_BUILTIN.openssh:tl} == yes
+USE_BUILTIN.openssh!= \
+ if ${PKG_ADMIN} pmatch ${_dep_:Q} ${BUILTIN_PKG.openssh:Q}; then \
+ ${ECHO} "yes"; \
+ else \
+ ${ECHO} "no"; \
+ fi
+. endif
+. endfor
+. endif
+. endif
+.endif
+MAKEVARS+= USE_BUILTIN.openssh
Home |
Main Index |
Thread Index |
Old Index