From 58f0a7ec08f259f5068ca7cb7dc0a9bc813fce05 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Sun, 24 Jan 2021 11:31:23 +0100 Subject: [PATCH] pkg: better fix, /usr/sbin/pkg is used always :/ --- Mk/defaults.mk | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Mk/defaults.mk b/Mk/defaults.mk index d6823ece7..10bd56569 100644 --- a/Mk/defaults.mk +++ b/Mk/defaults.mk @@ -1,4 +1,4 @@ -# Copyright (c) 2016-2020 Franco Fichtner +# Copyright (c) 2016-2021 Franco Fichtner # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions @@ -26,7 +26,10 @@ LOCALBASE?= /usr/local PAGER?= less -PKG!= which pkg || echo true +PKG= ${LOCALBASE}/sbin/pkg +.if ! exists(${PKG}) +PKG= true +.endif GIT!= which git || echo true GITVERSION= ${.CURDIR}/Scripts/version.sh @@ -67,7 +70,7 @@ _CORE_PYTHON!= ${PYTHONLINK} -V CORE_PYTHON?= ${_CORE_PYTHON:[2]:S/./ /g:[1..2]:tW:S/ //} .endif -.if exists(${PKG}) && ${PKG} != "/usr/sbin/pkg" +.if exists(${PKG}) _CORE_SYSLOGNG!= ${PKG} query %v syslog-ng CORE_SYSLOGNG?= ${_CORE_SYSLOGNG:S/./ /g:[1..2]:tW:S/ /./g} .endif