From d5b15f56fbc93983005cf2f9cc1117a3bbb3670c Mon Sep 17 00:00:00 2001 From: Raphaƫl Hertzog Date: Fri, 16 Apr 2010 11:56:17 +0200 Subject: dpkg: export DPKG_LIBDIR to maintainer scripts It can be used to find out the location of some internal dpkg programs that might be called from maintainer scripts. That way we can avoid hardcoding /usr/lib/dpkg and maintainer scripts will still work when called from a dpkg manually installed in /usr/local for example. --- src/help.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/help.c') diff --git a/src/help.c b/src/help.c index fb5ec9309..59bed9a8a 100644 --- a/src/help.c +++ b/src/help.c @@ -261,6 +261,7 @@ do_script(struct pkginfo *pkg, struct pkginfoperfile *pif, if (setenv(MAINTSCRIPTPKGENVVAR, pkg->name, 1) || setenv(MAINTSCRIPTARCHENVVAR, pif->architecture, 1) || setenv(MAINTSCRIPTNAMEENVVAR, cmd->argv[0], 1) || + setenv(MAINTSCRIPTLIBDIRENVVAR, PKGLIBDIR, 1) || setenv(MAINTSCRIPTDPKGENVVAR, PACKAGE_VERSION, 1)) ohshite(_("unable to setenv for maintainer script")); -- cgit v1.2.3