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).
Introduce Icon Theme cache handling framework
Icon Theme cache files are used by GTK+ and maintained with the
gtk-update-icon-cache tool. Each Icon Theme package duplicates
its own maintainance scripts: only the specified icon theme directory
differs. With this framework, if packages have ICON_THEMES=yes,
associated icon themes will be detected and their cache files will
be maintained automatically.
Change cache handling behaviour as follows:
* Icon theme caches will be updated if either gtk2+ or gtk3+
gtk-update-icon-cache tool is available.
* With installation of gtk2+ package, not only hicolor icon theme but
also any other icon theme cache files will be updated.
* Prevent removal of icon caches at deinstall, gtk3+ may be installed and
using them.
* Ditto with gtk3+, gtk2+ may not be installed now, so caches must be
maintained by gtk3+.
If ${_USE_NEW_PKGINSTALL} is "yes", then use the new "pkgtasks",
"init", and "pkgformat/pkg"-scripts frameworks instead of the
existing "pkginstall" framework.
Assert MAKE_DIRS_PERMS and OWN_DIRS_PERMS have the right number of
words before using a multivariable .for loop over those variables.
This prevents errors in parsing the makefiles.
than on all of the rpaths. We can't always exclude the rpath being added,
for example when the compiler adds its own behind our back, so this avoids
false positives.
This works in a similar way to the ELF checks, but uses otool(1) to list the
library name and its dependencies, and the checks fail if there are WRKDIR
references or if the -install_name of the library does not match $PREFIX, as
well as ensuring that any libraries from pkgsrc are correctly registered as
full dependencies.
Removes support for the user to set USE_CHECK_SHLIBS_ELF, but there were no
reasonable reasons for doing so in the past anyway, and it may be masking
issues in platform files we should fix.
performed all installed files should have their correct mode set, and there are
no INSTALL scripts that currently change file modes under PREFIX after
installation (nor should they ever).
This change considerably speeds up the test. For example in www/firefox-l10n
the time to run the test reduces from 181 seconds (135 seconds of system time)
down to 10 seconds (6 seconds system time) on my SmartOS build systems.
awk array iteration which could result in the wrong library being chosen.
Fixes issue seen with GCC 4.9 where the libgcc from the main GCC package
was found first and caused errors, even though the RPATH correctly had
the gcc49-libs version listed first.
It is used in limited case, and does not exist by default on some platforms.
proposed at over 30 months ago, and no negative feedback (only one request).
Build depends are target packages that are needed at build-time for,
e.g., static libraries to link against, header files to include, &c.
Tool depends are native packages that are needed at build-time for,
e.g., compilers/linkers/&c. to run.
ok agc
On DragonFly, packages like devel/doc++ and net/wap-utils were failing the
file check during installation due to a present locale.alias file. Treat
it the same as charset.alias.
This is from Anton Panev's GSoC 2011 project to add RPM and DPKG
support to pkgsrc. (I am not adding that further support in this
commit.)
This is just a rename of the existing functionality. Now it will
be easy to test the GSoC work by simply putting in a single
directory (such as "rpm" or "deb"). See
http://addpackageforma.sourceforge.net/ for some details.
This is from Anton's CVS, but I made some minor changes:
- changed plural pkgformats to singular pkgformat (to be consistent)
- fixed a few places (in comments) that were missed
- catch up on some additions to flavor not in the pkgforma cvs:
PKGSRC_SETENV and _flavor-destdir-undo-replace and
undo-destdir-replace-install.
can't be disabled by setting it to "no" like the other variables.
Besides, flavor/pkg/metadata.mk has been expecting for a long time that "no"
is a valid value.
Make PKG_DEVELOPER DWIM.
_CHECK_WRKREF_FILELIST_CMD is a command which prints PLIST paths
converted to absolute path. _CHECK_WRKREF_FILELIST_CMD can run
anywhere, so cd ${DESTDIR} before that is pointless. To access files,
_CHECK_WRKREF_FILELIST_CMD's output needs to be s/^/${DESTDIR}/ when
destdir is used.
Reviewed By: joerg
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.
embedded path to the HOME directory can be a security problem if, say,
the package looks in the HOME directory of an unprivileged user for
configuration files.
Note that this has the potential to cause some short-term fallout.
PATH, in which it is not directly preceded by a quote character:
#define GDM_USER_PATH "/usr/bin:/bin:${exec_prefix}"
Catch this by complaining about "${" also when it appears after a colon.
Since this check is still disabled by default, it will not surprise anyone.
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.
check-shlibs. This allows more stricter detection (e.g. it checks
whether the package links against a build dependency). It also checks
whether the rpath contains wrkdir references (like qt3-libs). It depends
on readelf and is only available for ELF systems for now. To test it,
add USE_CHECK_SHLIBS_ELF to mk.conf.
Supported-by: Google SoC 2007
- check-perms.mk was not DESTDIR aware, prefix files before passing it
to the directory extraction
- PKG_FILELIST_CMD was calling pkg_info, which is fine for normal
installation, but fails of course for DESTDIR. Just drop the @ lines
from ${_DEPENDS_PLIST} and use that.
- To make he former work, ensure that _flavor-generate-metadata is part
of _INSTALL_ALL_TARGETS. It was normally a dependency of
_flavor-register, but that is skipped for DESTDIR.
- Remove ${_DEPENDS_PLIST} when running install-clean.
paths from .PLIST.
Changed the working directory to ${DESTDIR}${PREFIX} so files can be
accessed correctly.
Extended the relative paths to absolute paths again for better clarity.
Improved (IMHO) some wording.