printhelp() { cat <<_EOF Usage: cint-config [options] --bindir print the directory of cint executables --incdir print the directory of cint header files --cflags print the necessary flags for the compiler --libs print the necessary libs for linking --libdir print the directory of cint libraries --datadir print the location of cint data files --arch print architecture -u|--unix print unix-like paths (makes sense only on win) this arg has effect only on the following args -v|--version print cint version -h|--help print this help _EOF } if [ $# -eq 0 ]; then printhelp exit 1 fi pathconvert=echo while [ $# -gt 0 ] ; do case $1 in --unix|-u) pathconvert="echo" ;; --bindir) $pathconvert "@CMAKE_BINARY_DIR@/bin" ;; --incdir) $pathconvert "@CMAKE_BINARY_DIR@/include" ;; --cflags) $pathconvert "-I@CMAKE_BINARY_DIR@/include" ;; --libs) $pathconvert "@CMAKE_BINARY_DIR@/lib -lCint" ;; --libdir) $pathconvert "@CMAKE_BINARY_DIR@/lib" ;; --datadir) $pathconvert "@ROOTSYS@/cint/cint" ;; --version|-v) echo "5.17.00" ;; --arch) echo "@ROOT_PLATFORM@" ;; -h|--help) printhelp;; *) echo "Unknown option: $1"; exit 1;; esac shift done