diff options
author | Roy Marples <roy@marples.name> | 2008-02-28 11:08:49 +0000 |
---|---|---|
committer | Roy Marples <roy@marples.name> | 2008-02-28 11:08:49 +0000 |
commit | f092045650faad778d25d000d80b3128664d2e2a (patch) | |
tree | 89188e92a4d01423ee59e33e5eaf5355fa14d103 /mk/os.mk | |
parent | aabf3976db5ffb41f8f8bbd47f5015b4158e095a (diff) |
Support the use of PREFIX and PKG_PREFIX.
Diffstat (limited to 'mk/os.mk')
-rw-r--r-- | mk/os.mk | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -29,3 +29,11 @@ LIBDL?= ${_LIBDL}$(shell ${_LIBDL_SH}) _LIBKVM_SH= case `uname -s` in *BSD) echo "-lkvm";; *) echo;; esac _LIBKVM!= ${_LIBKVM_SH} LIBKVM?= ${_LIBKVM}$(shell ${_LIBKVM_SH}) + +_PREFIX_SH= if test -n "${PREFIX}" && test "${PREFIX}" != "/"; then echo "-DPREFIX=\\\"${PREFIX}\\\""; else echo ""; fi +_PREFIX!= ${_PREFIX_SH} +CFLAGS+= ${_PREFIX}$(shell ${_PREFIX_SH}) + +_PKG_PREFIX_SH= if test -n "${PKG_PREFIX}" && test "${PKG_PREFIX}" != "/"; then echo "-DPKG_PREFIX=\\\"${PKG_PREFIX}\\\""; else echo ""; fi +_PKG_PREFIX!= ${_PKG_PREFIX_SH} +CFLAGS+= ${_PKG_PREFIX}$(shell ${_PKG_PREFIX_SH}) |