head 1.12; access; symbols pkgsrc-2023Q4:1.11.0.16 pkgsrc-2023Q4-base:1.11 pkgsrc-2023Q3:1.11.0.14 pkgsrc-2023Q3-base:1.11 pkgsrc-2023Q2:1.11.0.12 pkgsrc-2023Q2-base:1.11 pkgsrc-2023Q1:1.11.0.10 pkgsrc-2023Q1-base:1.11 pkgsrc-2022Q4:1.11.0.8 pkgsrc-2022Q4-base:1.11 pkgsrc-2022Q3:1.11.0.6 pkgsrc-2022Q3-base:1.11 pkgsrc-2022Q2:1.11.0.4 pkgsrc-2022Q2-base:1.11 pkgsrc-2022Q1:1.11.0.2 pkgsrc-2022Q1-base:1.11 pkgsrc-2021Q4:1.10.0.34 pkgsrc-2021Q4-base:1.10 pkgsrc-2021Q3:1.10.0.32 pkgsrc-2021Q3-base:1.10 pkgsrc-2021Q2:1.10.0.30 pkgsrc-2021Q2-base:1.10 pkgsrc-2021Q1:1.10.0.28 pkgsrc-2021Q1-base:1.10 pkgsrc-2020Q4:1.10.0.26 pkgsrc-2020Q4-base:1.10 pkgsrc-2020Q3:1.10.0.24 pkgsrc-2020Q3-base:1.10 pkgsrc-2020Q2:1.10.0.22 pkgsrc-2020Q2-base:1.10 pkgsrc-2020Q1:1.10.0.18 pkgsrc-2020Q1-base:1.10 pkgsrc-2019Q4:1.10.0.20 pkgsrc-2019Q4-base:1.10 pkgsrc-2019Q3:1.10.0.16 pkgsrc-2019Q3-base:1.10 pkgsrc-2019Q2:1.10.0.14 pkgsrc-2019Q2-base:1.10 pkgsrc-2019Q1:1.10.0.12 pkgsrc-2019Q1-base:1.10 pkgsrc-2018Q4:1.10.0.10 pkgsrc-2018Q4-base:1.10 pkgsrc-2018Q3:1.10.0.8 pkgsrc-2018Q3-base:1.10 pkgsrc-2018Q2:1.10.0.6 pkgsrc-2018Q2-base:1.10 pkgsrc-2018Q1:1.10.0.4 pkgsrc-2018Q1-base:1.10 pkgsrc-2017Q4:1.10.0.2 pkgsrc-2017Q4-base:1.10 pkgsrc-2017Q3:1.9.0.4 pkgsrc-2017Q3-base:1.9 pkgsrc-2017Q2:1.8.0.80 pkgsrc-2017Q2-base:1.8 pkgsrc-2017Q1:1.8.0.78 pkgsrc-2017Q1-base:1.8 pkgsrc-2016Q4:1.8.0.76 pkgsrc-2016Q4-base:1.8 pkgsrc-2016Q3:1.8.0.74 pkgsrc-2016Q3-base:1.8 pkgsrc-2016Q2:1.8.0.72 pkgsrc-2016Q2-base:1.8 pkgsrc-2016Q1:1.8.0.70 pkgsrc-2016Q1-base:1.8 pkgsrc-2015Q4:1.8.0.68 pkgsrc-2015Q4-base:1.8 pkgsrc-2015Q3:1.8.0.66 pkgsrc-2015Q3-base:1.8 pkgsrc-2015Q2:1.8.0.64 pkgsrc-2015Q2-base:1.8 pkgsrc-2015Q1:1.8.0.62 pkgsrc-2015Q1-base:1.8 pkgsrc-2014Q4:1.8.0.60 pkgsrc-2014Q4-base:1.8 pkgsrc-2014Q3:1.8.0.58 pkgsrc-2014Q3-base:1.8 pkgsrc-2014Q2:1.8.0.56 pkgsrc-2014Q2-base:1.8 pkgsrc-2014Q1:1.8.0.54 pkgsrc-2014Q1-base:1.8 pkgsrc-2013Q4:1.8.0.52 pkgsrc-2013Q4-base:1.8 pkgsrc-2013Q3:1.8.0.50 pkgsrc-2013Q3-base:1.8 pkgsrc-2013Q2:1.8.0.48 pkgsrc-2013Q2-base:1.8 pkgsrc-2013Q1:1.8.0.46 pkgsrc-2013Q1-base:1.8 pkgsrc-2012Q4:1.8.0.44 pkgsrc-2012Q4-base:1.8 pkgsrc-2012Q3:1.8.0.42 pkgsrc-2012Q3-base:1.8 pkgsrc-2012Q2:1.8.0.40 pkgsrc-2012Q2-base:1.8 pkgsrc-2012Q1:1.8.0.38 pkgsrc-2012Q1-base:1.8 pkgsrc-2011Q4:1.8.0.36 pkgsrc-2011Q4-base:1.8 pkgsrc-2011Q3:1.8.0.34 pkgsrc-2011Q3-base:1.8 pkgsrc-2011Q2:1.8.0.32 pkgsrc-2011Q2-base:1.8 pkgsrc-2011Q1:1.8.0.30 pkgsrc-2011Q1-base:1.8 pkgsrc-2010Q4:1.8.0.28 pkgsrc-2010Q4-base:1.8 pkgsrc-2010Q3:1.8.0.26 pkgsrc-2010Q3-base:1.8 pkgsrc-2010Q2:1.8.0.24 pkgsrc-2010Q2-base:1.8 pkgsrc-2010Q1:1.8.0.22 pkgsrc-2010Q1-base:1.8 pkgsrc-2009Q4:1.8.0.20 pkgsrc-2009Q4-base:1.8 pkgsrc-2009Q3:1.8.0.18 pkgsrc-2009Q3-base:1.8 pkgsrc-2009Q2:1.8.0.16 pkgsrc-2009Q2-base:1.8 pkgsrc-2009Q1:1.8.0.14 pkgsrc-2009Q1-base:1.8 pkgsrc-2008Q4:1.8.0.12 pkgsrc-2008Q4-base:1.8 pkgsrc-2008Q3:1.8.0.10 pkgsrc-2008Q3-base:1.8 cube-native-xorg:1.8.0.8 cube-native-xorg-base:1.8 pkgsrc-2008Q2:1.8.0.6 pkgsrc-2008Q2-base:1.8 cwrapper:1.8.0.4 pkgsrc-2008Q1:1.8.0.2 pkgsrc-2008Q1-base:1.8 pkgsrc-2007Q4:1.6.0.2 pkgsrc-2007Q4-base:1.6 pkgsrc-2007Q3:1.5.0.10 pkgsrc-2007Q3-base:1.5 pkgsrc-2007Q2:1.5.0.8 pkgsrc-2007Q2-base:1.5 pkgsrc-2007Q1:1.5.0.6 pkgsrc-2007Q1-base:1.5 jlam-pkgviews:1.5.0.4 jlam-pkgviews-base:1.5 pkgsrc-2006Q4:1.5.0.2 pkgsrc-2006Q4-base:1.5 pkgsrc-2006Q3:1.2.0.4 pkgsrc-2006Q3-base:1.2 pkgsrc-2006Q2:1.2.0.2 pkgsrc-2006Q2-base:1.2; locks; strict; comment @# @; 1.12 date 2024.01.19.00.25.38; author rillig; state Exp; branches; next 1.11; commitid E9wW8NImJnNRAZUE; 1.11 date 2022.01.18.01.41.09; author pho; state Exp; branches; next 1.10; commitid PnZacn3jIIBFv3pD; 1.10 date 2017.10.03.09.43.06; author jperkin; state Exp; branches; next 1.9; commitid dS5EXSkmEqjIzA9A; 1.9 date 2017.07.04.18.29.24; author khorben; state Exp; branches; next 1.8; commitid mm2EdC2mMPl8pWXz; 1.8 date 2008.02.13.15.02.20; author rillig; state Exp; branches; next 1.7; 1.7 date 2008.02.10.11.44.48; author tnn; state Exp; branches; next 1.6; 1.6 date 2007.10.13.11.04.17; author dsl; state Exp; branches; next 1.5; 1.5 date 2006.12.12.21.37.20; author rillig; state Exp; branches; next 1.4; 1.4 date 2006.11.09.02.53.15; author rillig; state Exp; branches; next 1.3; 1.3 date 2006.10.13.06.32.15; author rillig; state Exp; branches; next 1.2; 1.2 date 2006.06.07.17.04.01; author jlam; state Exp; branches; next 1.1; 1.1 date 2006.06.03.23.11.42; author jlam; state Exp; branches; next ; desc @@ 1.12 log @mk/check: remove documentation that was never implemented @ text @# $NetBSD: bsd.check.mk,v 1.11 2022/01/18 01:41:09 pho Exp $ # # This Makefile fragment is included by bsd.pkg.mk and provides all # variables and targets related to build and install checks. # # There are some predefined hooks where checks can be added: # # pre-configure-checks-hook # Is run before configuring the package. # # pre-build-checks-hook # Is run before building the package. # # The following are the "public" targets provided this module: # # check-files-pre, check-files-post, check-files # check-interpreter, check-shlibs, check-vulnerable, check-wrkref # .include "check-files.mk" .include "check-headers.mk" .include "check-interpreter.mk" .include "check-perms.mk" .include "check-pie.mk" .include "check-portability.mk" .include "check-relro.mk" .include "check-shlibs.mk" .include "check-ssp.mk" .include "check-stripped.mk" .include "check-vulnerable.mk" .include "check-wrkref.mk" .include "check-fakehome.mk" pre-configure-checks-hook \ pre-build-checks-hook: .PHONY @@${DO_NADA} ###################################################################### ### check-clean (PRIVATE) ###################################################################### ### check-clean is a helper target onto which one can hook all of the ### targets that clean up the output of "check" targets. ### .PHONY: check-clean check-clean: @@${DO_NADA} @ 1.11 log @Add a package-settable variable PKGSRC_OVERRIDE_MKPIE This is needed by packages that require hand-holding in building PIE. Also a post-build check for MKPIE is performed by default when PKG_DEVELOPER=YES. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.10 2017/10/03 09:43:06 jperkin Exp $ a13 8 # #notyet post-install-privileged-checks-hook # Is run after the installation, as the user who installed # the package. # # #notyet post-install-checks-hook # Is run after the installation, as the user who built # the package. # @ 1.10 log @mk: Add support for SSP checks. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.9 2017/07/04 18:29:24 khorben Exp $ d32 1 @ 1.9 log @Implement a check for RELRO This is only performed if PKG_DEVELOPER and RELRO are in use. After a suggestion during my talk at BSDCan 2017; thanks! Also, submitted on tech-pkg@@ for review mid-June. As a next step, it seems this can be extended to libraries, just like the check for SHLIBS does (from which this is inspired). @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.8 2008/02/13 15:02:20 rillig Exp $ d35 1 @ 1.8 log @Added a new check for binaries, so that they are installed according to the INSTALL_UNSTRIPPED variable. By default, this check is disabled, so that it does not cause any breakage. NB: The file(1) command needs the explicit locale to prevent translated messages. This file is copied from check-interpreter.mk. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.7 2008/02/10 11:44:48 tnn Exp $ d33 1 @ 1.7 log @Enable check-fakehome.mk. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.6 2007/10/13 11:04:17 dsl Exp $ d34 1 @ 1.6 log @Fix the .include lines so that make looks in the right place first. Remember .include "foo.mk" is looked for (first) in the directory that contains the makefile being processed (like in C), so remove all the ${.PARSEDIR} and ../ sequences that just cause grief. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.5 2006/12/12 21:37:20 rillig Exp $ d36 1 @ 1.5 log @Made all .include lines look the same. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.4 2006/11/09 02:53:15 rillig Exp $ d28 8 a35 8 .include "${.PARSEDIR}/check-files.mk" .include "${.PARSEDIR}/check-headers.mk" .include "${.PARSEDIR}/check-interpreter.mk" .include "${.PARSEDIR}/check-perms.mk" .include "${.PARSEDIR}/check-portability.mk" .include "${.PARSEDIR}/check-shlibs.mk" .include "${.PARSEDIR}/check-vulnerable.mk" .include "${.PARSEDIR}/check-wrkref.mk" @ 1.4 log @Moved the portability checks from the configure/ directory to checks/, since according to the comment in check/bsd.check.mk, they belong there. Added a new check for all C and C++ header files to make sure they don't contain strings like ${prefix} or ${exec_prefix}, which is currently a problem with sysutils/dbus and has been noticed in PR 35019. This check is disabled by default since I don't know anything about possible false positives, but I plan to enable it for PKG_DEVELOPERs after some testing. Added two names for hooks that are placed in the configure and in the build phase. Now the checks look more like becoming something one could call a framework, sharing a common structure and a documented interface. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.3 2006/10/13 06:32:15 rillig Exp $ d28 1 a28 6 .include "${PKGSRCDIR}/mk/check/check-files.mk" .include "${PKGSRCDIR}/mk/check/check-interpreter.mk" .include "${PKGSRCDIR}/mk/check/check-perms.mk" .include "${PKGSRCDIR}/mk/check/check-shlibs.mk" .include "${PKGSRCDIR}/mk/check/check-vulnerable.mk" .include "${PKGSRCDIR}/mk/check/check-wrkref.mk" d30 2 d33 3 @ 1.3 log @Added a new post-installation check to see whether the files have their permissions properly set. See mk/check/check-perms.mk and sysutils/checkperms for details. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.2 2006/06/07 17:04:01 jlam Exp $ d6 16 d34 6 @ 1.2 log @Note the check-clean target, which removes files related to the check-* targets. @ text @d1 1 a1 1 # $NetBSD: bsd.check.mk,v 1.1 2006/06/03 23:11:42 jlam Exp $ d14 1 @ 1.1 log @First pass at implementing support for package system flavors other than pkgsrc's current one. This is an important lead-up to any project that redesigns the pkg_* tools in that it doesn't tie us to past design (mis)choices. This commit mostly deals with rearranging code, although there was a considerable amount of rewriting done in cases where I thought the code was somewhat messy and was difficult to understand. The design I chose for supporting multiple package system flavors is that the various depends, install, package, etc. modules would define default targets and variables that may be overridden in files from pkgsrc/mk/flavor/${PKG_FLAVOR}. The default targets would do the sensible thing of doing nothing, and pkgsrc infrastructure would rely on the appropriate things to be defined in pkgsrc/mk/flavor to do the real work. The pkgsrc/mk/flavor directory contains subdirectories corresponding to each package system flavor that we support. Currently, I only have "pkg" which represents the current pkgsrc-native package flavor. I've separated out most of the code where we make assumptions about the package system flavor, mostly either because we directly use the pkg_* tools, or we make assumptions about the package meta-data directory, or we directly manipulate the package meta-data files, and placed it into pkgsrc/mk/flavor/pkg. There are several new modules that have been refactored out of bsd.pkg.mk as part of these changes: check, depends, install, package, and update. Each of these modules has been slimmed down by rewriting them to avoid some recursive make calls. I've also religiously documented which targets are "public" and which are "private" so that users won't rely on reaching into pkgsrc innards to call a private target. The "depends" module is a complete overhaul of the way that we handle dependencies. There is now a separate "depends" phase that occurs before the "extract" phase where dependencies are installed. This differs from the old way where dependencies were installed just before extraction occurred. The reduce-depends.mk file is now replaced by a script that is invoked only once during the depends phase and is used to generate a cookie file that holds the full set of reduced dependencies. It is now possible to type "make depends" in a package directory and all missing dependencies will be installed. Future work on this project include: * Resolve the workflow design in anticipation of future work on staged installations where "package" conceptually happens before "install". * Rewrite the buildlink3 framework to not assume the use of the pkgsrc pkg_* tools. * Rewrite the pkginstall framework to provide a standard pkg_* tool to perform the actions, and allowing a purely declarative file per package to describe what actions need to be taken at install or deinstall time. * Implement support for the SVR4 package flavor. This will be proof that the appropriate abstractions are in place to allow using a completely different set of package management tools. @ text @d1 1 a1 1 # $NetBSD$ d17 10 @