-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigure.ac
98 lines (77 loc) · 2.27 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# use: autoreconf -i
AC_PREREQ(2.65)
define(PNAME,[OXNAS Tools])dnl
define(PVERS,[1.1.0])dnl
define(TNAME,[oxnas-tools])dnl
syscmd(test -e .svn)dnl
ifelse(sysval, 0,dnl
syscmd(test -n "${PACKAGE_VERSION}")dnl
ifelse(sysval, 0,dnl
[define([PVERS], esyscmd([echo -n ${PACKAGE_VERSION}]))]dnl
)dnl
)dnl
AC_INIT(PNAME,PVERS,[[email protected]],TNAME,[http://www.li-pro.de/soho:ihmnhd:start])
AC_CANONICAL_TARGET
#AC_USE_SYSTEM_EXTENSIONS
AC_CONFIG_SRCDIR([src/Makefile.am])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([1.10 dist-bzip2 dist-zip])
AM_MAINTAINER_MODE
AC_PREFIX_DEFAULT("/usr/local")
# Create build informations
BUILDDATE=`LC_ALL=C date +'%b %d %C%y'`
AC_SUBST(BUILDDATE)
AC_DEFINE_UNQUOTED(BUILDDATE,"$BUILDDATE",[Build date of package])
BUILDTIME=`LC_ALL=C date +%T`
AC_SUBST(BUILDTIME)
AC_DEFINE_UNQUOTED(BUILDTIME,"$BUILDTIME",[Build date of package])
# Check system type.
AC_MSG_CHECKING([checking system type])
case "$host_os" in
linux*)
AC_MSG_RESULT([Linux])
AC_DEFINE_UNQUOTED(LINUX,1,[This is a Linux system])
;;
*)
AC_MSG_RESULT(Unrecognised OS $host_os)
AC_DEFINE_UNQUOTED(OTHEROS,1,[Some strange OS])
;;
esac
# Checks for programs.
#AC_PROG_CC
#AC_PROG_CPP
#AC_PROG_CXX
AC_PROG_INSTALL
AC_PROG_LN_S
#PKG_PROG_PKG_CONFIG
# Checks for libraries.
#REQUIRES_LIBANY="anylib >= 0.0-0"
#AC_SUBST(REQUIRES_LIBANY)
#PKG_CHECK_MODULES(anylib, $REQUIRES_LIBANY)
# Checks for header files.
#AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/ioctl.h sys/time.h termios.h unistd.h])
# Checks for typedefs, structures, and compiler characteristics.
#AC_HEADER_STDBOOL
#AC_HEADER_STDC
# Checks for library functions.
#AC_CHECK_FUNCS([memset strrchr strstr])
# Output configuration files.
AC_CONFIG_FILES([
Makefile
src/Makefile
doc/Makefile
doc/mkoxnasblob.1
doc/setupoxnasmbr.1
])
AC_CONFIG_FILES([src/mkoxnasblob.sh],[chmod +x src/mkoxnasblob.sh])
AC_CONFIG_FILES([src/setupoxnasmbr.sh],[chmod +x src/setupoxnasmbr.sh])
AC_OUTPUT
# ==========================================================================
AS_AC_EXPAND(EXPANDED_BINDIR, "$bindir")
echo "
---{ $PACKAGE_NAME $VERSION }---
host os: ${host_os}
prefix: ${prefix}
bindir: ${EXPANDED_BINDIR}
"