mirror of https://github.com/xzeldon/htop.git
Add HTOP_$platform defines to config.h header
Can be used to conditionally compile platform specific code.
This commit is contained in:
parent
03b773b701
commit
ddbb0c2c35
|
@ -26,24 +26,31 @@ AC_USE_SYSTEM_EXTENSIONS
|
||||||
case "$target_os" in
|
case "$target_os" in
|
||||||
linux*|gnu*)
|
linux*|gnu*)
|
||||||
my_htop_platform=linux
|
my_htop_platform=linux
|
||||||
|
AC_DEFINE([HTOP_LINUX], [], [Building for Linux])
|
||||||
;;
|
;;
|
||||||
freebsd*|kfreebsd*)
|
freebsd*|kfreebsd*)
|
||||||
my_htop_platform=freebsd
|
my_htop_platform=freebsd
|
||||||
|
AC_DEFINE([HTOP_FREEBSD], [], [Building for FreeBSD])
|
||||||
;;
|
;;
|
||||||
openbsd*)
|
openbsd*)
|
||||||
my_htop_platform=openbsd
|
my_htop_platform=openbsd
|
||||||
|
AC_DEFINE([HTOP_OPENBSD], [], [Building for OpenBSD])
|
||||||
;;
|
;;
|
||||||
dragonfly*)
|
dragonfly*)
|
||||||
my_htop_platform=dragonflybsd
|
my_htop_platform=dragonflybsd
|
||||||
|
AC_DEFINE([HTOP_DRAGONFLYBSD], [], [Building for DragonFlyBSD])
|
||||||
;;
|
;;
|
||||||
darwin*)
|
darwin*)
|
||||||
my_htop_platform=darwin
|
my_htop_platform=darwin
|
||||||
|
AC_DEFINE([HTOP_DARWIN], [], [Building for Darwin])
|
||||||
;;
|
;;
|
||||||
solaris*)
|
solaris*)
|
||||||
my_htop_platform=solaris
|
my_htop_platform=solaris
|
||||||
|
AC_DEFINE([HTOP_SOLARIS], [], [Building for Solaris])
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
my_htop_platform=unsupported
|
my_htop_platform=unsupported
|
||||||
|
AC_DEFINE([HTOP_UNSUPPORTED], [], [Building for an unsupported platform])
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue