Move config files around, and clean up the mess in the config/ directory.
config/kernel/kernel_linux.in | 12 6 6 0 +-
config/paths.in | 89 0 89 0 ----------------
config/kernel_linux_headers_install.in | 168 0 168 0 ------------------------------
config/kernel.in | 2 1 1 0
config/kernel_linux_headers_copy.in | 42 0 42 0 --------
config/cc.in | 2 1 1 0
config/logging.in | 110 0 110 0 --------------------
config/build-behave.in | 45 0 45 0 --------
config/libc_uClibc.in | 101 0 101 0 ------------------
config/kernel_linux_headers_sanitised.in | 62 0 62 0 -----------
config/ct-behave.in | 82 0 82 0 ---------------
config/kernel_linux.in | 134 0 134 0 ------------------------
config/global.in | 10 5 5 0 +-
config/download_extract.in | 171 0 171 0 -------------------------------
config/cc_gcc.in | 130 0 130 0 ------------------------
config/libc_glibc.in | 124 0 124 0 ----------------------
config/libc.in | 4 2 2 0
17 files changed, 15 insertions(+), 1273 deletions(-)
3 VERSION=$(cat .version)
6 PREFIX_DEFAULT=/usr/local
18 echo "${1}" |cut -d '=' -f 2-
30 PREFIX=$(get_optval "$1" "$2")
36 BINDIR=$(get_optval "$1" "$2")
42 LIBDIR=$(get_optval "$1" "$2")
48 DOCDIR=$(get_optval "$1" "$2")
54 MANDIR=$(get_optval "$1" "$2")
60 \`configure' configures crosstool-NG ${VERSION} to adapt to many kind of systems.
62 USAGE: ./configure [OPTION]...
64 Defaults for the options are specified in brackets.
67 -h, --help display this help and exit
68 --prefix=PREFIX install files in PREFIX [${PREFIX_DEFAULT}]
69 --local don't install, and use current directory
71 By default, \`make install' will install all the files in
72 \`${PREFIX_DEFAULT}/bin', \`${PREFIX_DEFAULT}/lib' etc. You can specify
73 an installation prefix other than \`${PREFIX_DEFAULT}' using \`--prefix',
74 for instance \`--prefix=\${HOME}'.
76 For better control, use the options below.
78 Fine tuning of the installation directories:
79 --bindir=DIR user executables [PREFIX/bin]
80 --libdir=DIR object code libraries [PREFIX/lib]
81 --docdir=DIR info documentation [PREFIX/share/doc]
82 --mandir=DIR man documentation [PREFIX/share/man]
91 #---------------------------------------------------------------------
94 while [ $# -ne 0 ]; do
96 --prefix*) set_prefix "$1" "$2" && shift || shift 2;;
97 --bindir*) set_bindir "$1" "$2" && shift || shift 2;;
98 --libdir*) set_libdir "$1" "$2" && shift || shift 2;;
99 --docdir*) set_docdir "$1" "$2" && shift || shift 2;;
100 --mandir*) set_mandir "$1" "$2" && shift || shift 2;;
101 --local) LOCAL_set=1; shift;;
102 --help|-h) do_help; exit 0;;
107 [ -z "${PREFIX}" ] && set_prefix "" "${PREFIX_DEFAULT}"
108 if [ "${LOCAL_set}" = "1" ]; then
112 set_docdir "" $(pwd)/docs
113 set_mandir "" $(pwd)/docs
116 [ -z "${BINDIR_set}" ] && BINDIR="${PREFIX}/bin"
117 [ -z "${LIBDIR_set}" ] && LIBDIR="${PREFIX}/lib/ct-ng-${VERSION}"
118 [ -z "${DOCDIR_set}" ] && DOCDIR="${PREFIX}/share/doc/ct-ng-${VERSION}"
119 [ -z "${MANDIR_set}" ] && MANDIR="${PREFIX}/share/man/man1"
121 #---------------------------------------------------------------------
122 # Some sanity checks, now
124 # If this version is a svn snapshot, try to get the revision number
125 # If we can't get the revision number, use date
128 REVISION=$(svnversion)
129 case "${REVISION}" in
131 VERSION="${VERSION}:unknown@$(date +%Y%m%d.%H%M%S)";;
133 URL=$(LANG=C svn info 2>/dev/null |egrep 'URL: ' |cut -d ' ' -f 2-)
134 ROOT=$(LANG=C svn info 2>/dev/null |egrep 'Repository Root: ' |cut -d ' ' -f 3-)
135 VERSION="${VERSION}:${URL#${ROOT}}@${REVISION}"
141 # Check bash is present, and at least version 3.0
142 [ -x /bin/bash ] || do_error "bash 3.0 or above was not found in /bin/bash"
143 bash_version=$(/bin/bash -c 'echo ${BASH_VERSION}')
144 bash_major=$(/bin/bash -c 'echo ${BASH_VERSINFO[0]}')
145 [ ${bash_major} -ge 3 ] || do_error "bash 3.0 or above is needed (/bin/bash is ${bash_version})"
147 sed -r -e "s,@@BINDIR@@,${BINDIR},g;" \
148 -e "s,@@LIBDIR@@,${LIBDIR},g;" \
149 -e "s,@@DOCDIR@@,${DOCDIR},g;" \
150 -e "s,@@MANDIR@@,${MANDIR},g;" \
151 -e "s,@@VERSION@@,${VERSION},g;" \
152 -e "s,@@DATE@@,${DATE},g;" \
153 -e "s,@@LOCAL@@,${LOCAL_set},g;" \
154 Makefile.in >Makefile
157 crosstool-NG configured as follows: