diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/librc/rc.h.in | 1 | ||||
-rw-r--r-- | src/rc/rc-misc.c | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/librc/rc.h.in b/src/librc/rc.h.in index e4cb60dd..32dbef08 100644 --- a/src/librc/rc.h.in +++ b/src/librc/rc.h.in @@ -33,6 +33,7 @@ __BEGIN_DECLS +#define RC_PREFIX "@PREFIX@" #define RC_SYSCONFDIR "@SYSCONFDIR@" #define RC_LIBDIR "@PREFIX@/@LIB@/rc" #define RC_LIBEXECDIR "@LIBEXECDIR@" diff --git a/src/rc/rc-misc.c b/src/rc/rc-misc.c index 27397d71..e8f6ca6e 100644 --- a/src/rc/rc-misc.c +++ b/src/rc/rc-misc.c @@ -191,6 +191,10 @@ env_config(void) if (sys) setenv("RC_SYS", sys, 1); +#ifdef PREFIX + setenv("RC_PREFIX", RC_PREFIX, 1); +#endif + /* Some scripts may need to take a different code path if Linux/FreeBSD, etc To save on calling uname, we store it in an environment variable */ |