configure.ac
author Florian Pose <fp@igh-essen.com>
Tue, 10 Dec 2013 10:42:25 +0100
branchstable-1.5
changeset 2536 15f122b0f3d2
parent 2532 bdadf6da4914
child 2540 fca12d7035d1
permissions -rw-r--r--
Device activation note.
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     1
#------------------------------------------------------------------------------
1363
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     2
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     3
#  $Id$
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     4
#
2348
abb390ec7c4a Version 1.5.0.
Florian Pose <fp@igh-essen.com>
parents: 2330
diff changeset
     5
#  Copyright (C) 2006-2012  Florian Pose, Ingenieurgemeinschaft IgH
1363
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     6
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     7
#  This file is part of the IgH EtherCAT Master.
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     8
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
     9
#  The IgH EtherCAT Master is free software; you can redistribute it and/or
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    10
#  modify it under the terms of the GNU General Public License version 2, as
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    11
#  published by the Free Software Foundation.
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    12
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    13
#  The IgH EtherCAT Master is distributed in the hope that it will be useful,
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    14
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    15
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    16
#  Public License for more details.
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    17
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    18
#  You should have received a copy of the GNU General Public License along
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    19
#  with the IgH EtherCAT Master; if not, write to the Free Software
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    20
#  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    21
#
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    22
#  ---
2384
b068951506d9 Removed whitespace.
Florian Pose <fp@igh-essen.com>
parents: 2378
diff changeset
    23
#
1363
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    24
#  The license mentioned above concerns the source code only. Using the
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    25
#  EtherCAT technology and brand is only permitted in compliance with the
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    26
#  industrial property and similar rights of Beckhoff Automation GmbH.
11c0b2caa253 Improved and added license headers.
Florian Pose <fp@igh-essen.com>
parents: 1353
diff changeset
    27
#
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    28
#------------------------------------------------------------------------------
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    29
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
    30
AC_PREREQ(2.59)
2514
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    31
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    32
#
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    33
# Release procedure
2526
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    34
# - Update Ethernet drivers up to release kernel version
2514
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    35
# - Write NEWS entry with changes since last release
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    36
# - Check for complete Doxygen comments
e2257824c563 Release procedure.
Florian Pose <fp@igh-essen.com>
parents: 2509
diff changeset
    37
# - Update version number in documentation
2526
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    38
# - Update the ChangeLog -> hg log -bstable-1.5 --style=changelog > ChangeLog
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    39
# - Update version number below
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    40
# - make dist-bzip2
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    41
#
2eff7c993a63 Version 1.5.2.
Florian Pose <fp@igh-essen.com>
parents: 2514
diff changeset
    42
AC_INIT([ethercat],[1.5.2],[fp@igh-essen.com])
387
e6e708a5d502 Improved autotools files.
Florian Pose <fp@igh-essen.com>
parents: 385
diff changeset
    43
AC_CONFIG_AUX_DIR([autoconf])
479
610ddcf35d5c Removed --foreign switch for autotools.
Florian Pose <fp@igh-essen.com>
parents: 477
diff changeset
    44
AM_INIT_AUTOMAKE([-Wall -Werror dist-bzip2])
387
e6e708a5d502 Improved autotools files.
Florian Pose <fp@igh-essen.com>
parents: 385
diff changeset
    45
AC_PREFIX_DEFAULT([/opt/etherlab])
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
    46
AC_CONFIG_HEADERS([config.h])
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
    47
AC_CONFIG_SRCDIR([config.h.in])
1432
1cda765207cd m4 macro dir.
Florian Pose <fp@igh-essen.com>
parents: 1414
diff changeset
    48
AC_CONFIG_MACRO_DIR([m4])
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    49
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    50
#------------------------------------------------------------------------------
444
31223539fc00 Compiler flag -DSVNREV only for module.c to avoid unnecessary recompiling.
Florian Pose <fp@igh-essen.com>
parents: 440
diff changeset
    51
# Global
31223539fc00 Compiler flag -DSVNREV only for module.c to avoid unnecessary recompiling.
Florian Pose <fp@igh-essen.com>
parents: 440
diff changeset
    52
#------------------------------------------------------------------------------
31223539fc00 Compiler flag -DSVNREV only for module.c to avoid unnecessary recompiling.
Florian Pose <fp@igh-essen.com>
parents: 440
diff changeset
    53
2489
5cd99a1daa7a Added AM_PROG_AR necessary for autoconf 1.12.
Florian Pose <fp@igh-essen.com>
parents: 2453
diff changeset
    54
AM_PROG_CC_C_O
5cd99a1daa7a Added AM_PROG_AR necessary for autoconf 1.12.
Florian Pose <fp@igh-essen.com>
parents: 2453
diff changeset
    55
m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
922
fede1d8f5b71 Added the new ethercat comman-line tool with lsec functionality.
Florian Pose <fp@igh-essen.com>
parents: 897
diff changeset
    56
AC_PROG_CXX
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
    57
AC_PROG_LIBTOOL
922
fede1d8f5b71 Added the new ethercat comman-line tool with lsec functionality.
Florian Pose <fp@igh-essen.com>
parents: 897
diff changeset
    58
444
31223539fc00 Compiler flag -DSVNREV only for module.c to avoid unnecessary recompiling.
Florian Pose <fp@igh-essen.com>
parents: 440
diff changeset
    59
#------------------------------------------------------------------------------
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    60
# Linux sources
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    61
#------------------------------------------------------------------------------
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    62
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    63
AC_ARG_WITH([linux-dir],
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    64
    AC_HELP_STRING(
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    65
        [--with-linux-dir=<DIR>],
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    66
        [Linux kernel sources @<:@running kernel@:>@]
367
e85e3143dc8d Autotools "--with-linux" switch; "mydist" target
Florian Pose <fp@igh-essen.com>
parents: 365
diff changeset
    67
    ),
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    68
    [
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    69
        sourcedir=[$withval]
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    70
    ],
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    71
    [
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    72
        version=[`uname -r`]
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    73
        modulesdir=/lib/modules/${version}
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    74
        if test \! -d ${modulesdir} || test \! -d ${modulesdir}/build; then
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    75
           echo
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    76
           AC_MSG_ERROR([Failed to find Linux sources. Use --with-linux-dir!])
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    77
        fi
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    78
        sourcedir=`cd ${modulesdir}/build && pwd -P`
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    79
    ]
367
e85e3143dc8d Autotools "--with-linux" switch; "mydist" target
Florian Pose <fp@igh-essen.com>
parents: 365
diff changeset
    80
)
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    81
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    82
AC_MSG_CHECKING([for Linux kernel sources])
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    83
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
    84
if test \! -r ${sourcedir}/.config; then
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    85
    echo
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    86
    AC_MSG_ERROR([No configured Linux kernel sources in $sourcedir])
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    87
fi
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    88
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    89
# Try to get kernel release string
537
c715766e0f81 Fixed bad configure behavior with complex kernel version strings.
Florian Pose <fp@igh-essen.com>
parents: 507
diff changeset
    90
if test -r ${sourcedir}/include/config/kernel.release; then
c715766e0f81 Fixed bad configure behavior with complex kernel version strings.
Florian Pose <fp@igh-essen.com>
parents: 507
diff changeset
    91
    kernelrelease=`cat $sourcedir/include/config/kernel.release`
c715766e0f81 Fixed bad configure behavior with complex kernel version strings.
Florian Pose <fp@igh-essen.com>
parents: 507
diff changeset
    92
elif test -r ${sourcedir}/.kernelrelease; then
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    93
    kernelrelease=`cat $sourcedir/.kernelrelease`
507
4687f9d8254e Configuring for kernels 2.6.18 and 2.6.19, thanks to Ralf Roesch.
Florian Pose <fp@igh-essen.com>
parents: 506
diff changeset
    94
elif test -r ${sourcedir}/include/linux/utsrelease.h; then
4687f9d8254e Configuring for kernels 2.6.18 and 2.6.19, thanks to Ralf Roesch.
Florian Pose <fp@igh-essen.com>
parents: 506
diff changeset
    95
    hdr=${sourcedir}/include/linux/utsrelease.h
4687f9d8254e Configuring for kernels 2.6.18 and 2.6.19, thanks to Ralf Roesch.
Florian Pose <fp@igh-essen.com>
parents: 506
diff changeset
    96
    kernelrelease=`grep UTS_RELEASE $hdr | cut -d " " -f 3- | tr -d \"`
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    97
elif test -r ${sourcedir}/include/linux/version.h; then
507
4687f9d8254e Configuring for kernels 2.6.18 and 2.6.19, thanks to Ralf Roesch.
Florian Pose <fp@igh-essen.com>
parents: 506
diff changeset
    98
    hdr=${sourcedir}/include/linux/version.h
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
    99
    kernelrelease=`grep UTS_RELEASE $hdr | cut -d " " -f 3- | tr -d \"`
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   100
fi
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   101
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   102
if test -z "$kernelrelease"; then
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   103
    echo
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   104
    AC_MSG_ERROR([Failed to extract Linux kernel version!])
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   105
fi
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   106
2376
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   107
if test ${kernelrelease%%.*} -gt 2; then
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   108
    regex="^[[0-9]]+\.[[0-9]]+"
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   109
else
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   110
    regex="^[[0-9]]+\.[[0-9]]+\.[[0-9]]+"
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   111
fi
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   112
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   113
# Extract numbers from kernel release
97ec7e18412e Added e100 driver for kernel 3.0.
Florian Pose <fp@igh-essen.com>
parents: 2228
diff changeset
   114
linuxversion=`echo $kernelrelease | grep -oE "$regex"`
477
69d05643041f Improved installation, added quick modules_install target.
Florian Pose <fp@igh-essen.com>
parents: 471
diff changeset
   115
367
e85e3143dc8d Autotools "--with-linux" switch; "mydist" target
Florian Pose <fp@igh-essen.com>
parents: 365
diff changeset
   116
AC_SUBST(LINUX_SOURCE_DIR,[$sourcedir])
1825
65781b048a47 Minor changes in configure output.
Florian Pose <fp@igh-essen.com>
parents: 1824
diff changeset
   117
AC_MSG_RESULT([$LINUX_SOURCE_DIR (Kernel $linuxversion)])
1824
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   118
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   119
#------------------------------------------------------------------------------
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   120
# Linux module installation subdirectory
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   121
#------------------------------------------------------------------------------
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   122
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   123
AC_ARG_WITH([module-dir],
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   124
    AC_HELP_STRING(
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   125
        [--with-module-dir=<DIR>],
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   126
        [Linux module installation dir. Default: ethercat]
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   127
    ),
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   128
    [moddir=[$withval]],
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   129
    [moddir="ethercat"]
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   130
)
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   131
AC_SUBST(INSTALL_MOD_DIR,[$moddir])
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   132
1825
65781b048a47 Minor changes in configure output.
Florian Pose <fp@igh-essen.com>
parents: 1824
diff changeset
   133
AC_MSG_CHECKING([for Linux modules installation directory])
1824
bbb70ca26f09 Use kernel's modules_install target, instead of building our own. Attention:
Florian Pose <fp@igh-essen.com>
parents: 1811
diff changeset
   134
AC_MSG_RESULT([$INSTALL_MOD_DIR])
367
e85e3143dc8d Autotools "--with-linux" switch; "mydist" target
Florian Pose <fp@igh-essen.com>
parents: 365
diff changeset
   135
e85e3143dc8d Autotools "--with-linux" switch; "mydist" target
Florian Pose <fp@igh-essen.com>
parents: 365
diff changeset
   136
#------------------------------------------------------------------------------
1540
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   137
# Generic Ethernet driver
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   138
#------------------------------------------------------------------------------
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   139
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   140
AC_ARG_ENABLE([generic],
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   141
    AS_HELP_STRING([--enable-generic],
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   142
                   [Enable generic Ethernet driver]),
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   143
    [
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   144
        case "${enableval}" in
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   145
            yes) enablegeneric=1
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   146
                ;;
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   147
            no) enablegeneric=0
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   148
                ;;
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   149
            *) AC_MSG_ERROR([Invalid value for --enable-generic])
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   150
                ;;
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   151
        esac
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   152
    ],
2330
849d250e6a4c Enable generic driver by default.
Florian Pose <fp@igh-essen.com>
parents: 2309
diff changeset
   153
    [enablegeneric=1]
1540
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   154
)
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   155
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   156
AM_CONDITIONAL(ENABLE_GENERIC, test "x$enablegeneric" = "x1")
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   157
AC_SUBST(ENABLE_GENERIC,[$enablegeneric])
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   158
49430a3fe73d Basic generic Ethernet device module.
Florian Pose <fp@igh-essen.com>
parents: 1440
diff changeset
   159
#------------------------------------------------------------------------------
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   160
# 8139too driver
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   161
#------------------------------------------------------------------------------
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   162
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   163
AC_ARG_ENABLE([8139too],
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   164
    AS_HELP_STRING([--enable-8139too],
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   165
                   [Enable 8139too driver]),
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   166
    [
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   167
        case "${enableval}" in
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   168
            yes) enable8139too=1
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   169
                ;;
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   170
            no) enable8139too=0
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   171
                ;;
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   172
            *) AC_MSG_ERROR([Invalid value for --enable-8139too])
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   173
                ;;
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   174
        esac
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   175
    ],
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   176
    [enable8139too=1]
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   177
)
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   178
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   179
AM_CONDITIONAL(ENABLE_8139TOO, test "x$enable8139too" = "x1")
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   180
AC_SUBST(ENABLE_8139TOO,[$enable8139too])
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   181
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   182
AC_ARG_WITH([8139too-kernel],
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   183
    AC_HELP_STRING(
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   184
        [--with-8139too-kernel=<X.Y.Z>],
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   185
        [8139too kernel (only if differing)]
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   186
    ),
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   187
    [
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   188
        kernel8139too=[$withval]
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   189
    ],
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   190
    [
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   191
        kernel8139too=$linuxversion
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   192
    ]
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   193
)
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   194
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   195
if test "x${enable8139too}" = "x1"; then
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   196
    AC_MSG_CHECKING([for kernel for 8139too driver])
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   197
945
a5907351e13e Improved out-of-place build.
Florian Pose <fp@igh-essen.com>
parents: 922
diff changeset
   198
    kernels=`ls -1 ${srcdir}/devices/ | grep -oE "^8139too-.*-" | cut -d "-" -f 2 | uniq`
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   199
    found=0
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   200
    for k in $kernels; do
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   201
        if test "$kernel8139too" = "$k"; then
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   202
            found=1
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   203
        fi
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   204
    done
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   205
    if test $found -ne 1; then
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   206
        AC_MSG_ERROR([kernel $kernel8139too not available for 8139too driver!])
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   207
    fi
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   208
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   209
    AC_MSG_RESULT([$kernel8139too])
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   210
fi
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   211
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   212
AC_SUBST(KERNEL_8139TOO,[$kernel8139too])
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   213
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   214
#------------------------------------------------------------------------------
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   215
# e100 driver
569
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   216
#------------------------------------------------------------------------------
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   217
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   218
AC_ARG_ENABLE([e100],
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   219
    AS_HELP_STRING([--enable-e100],
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   220
                   [Enable e100 driver]),
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   221
    [
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   222
        case "${enableval}" in
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   223
            yes) enablee100=1
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   224
                ;;
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   225
            no) enablee100=0
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   226
                ;;
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   227
            *) AC_MSG_ERROR([Invalid value for --enable-e100])
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   228
                ;;
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   229
        esac
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   230
    ],
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   231
    [enablee100=0] # disabled by default
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   232
)
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   233
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   234
AM_CONDITIONAL(ENABLE_E100, test "x$enablee100" = "x1")
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   235
AC_SUBST(ENABLE_E100,[$enablee100])
568
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   236
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   237
AC_ARG_WITH([e100-kernel],
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   238
    AC_HELP_STRING(
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   239
        [--with-e100-kernel=<X.Y.Z>],
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   240
        [e100 kernel (only if differing)]
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   241
    ),
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   242
    [
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   243
        kernele100=[$withval]
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   244
    ],
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   245
    [
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   246
        kernele100=$linuxversion
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   247
    ]
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   248
)
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   249
582
39f1704b0c99 Added --enable-8139too; cleaned up configure.ac and devices/Kbuild.
Florian Pose <fp@igh-essen.com>
parents: 581
diff changeset
   250
if test "x${enablee100}" = "x1"; then
569
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   251
    AC_MSG_CHECKING([for kernel for e100 driver])
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   252
945
a5907351e13e Improved out-of-place build.
Florian Pose <fp@igh-essen.com>
parents: 922
diff changeset
   253
    kernels=`ls -1 ${srcdir}/devices/ | grep -oE "^e100-.*-" | cut -d "-" -f 2 | uniq`
569
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   254
    found=0
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   255
    for k in $kernels; do
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   256
        if test "$kernele100" = "$k"; then
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   257
            found=1
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   258
        fi
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   259
    done
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   260
    if test $found -ne 1; then
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   261
        AC_MSG_ERROR([kernel $kernele100 not available for e100 driver!])
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   262
    fi
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   263
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   264
    AC_MSG_RESULT([$kernele100])
87dd7f374593 Added --enable-e100 switch to configure.
Florian Pose <fp@igh-essen.com>
parents: 568
diff changeset
   265
fi
568
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   266
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   267
AC_SUBST(KERNEL_E100,[$kernele100])
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   268
568
3edb8f45bdc1 First experimental version of e100 driver.
Florian Pose <fp@igh-essen.com>
parents: 565
diff changeset
   269
#------------------------------------------------------------------------------
667
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   270
# e1000 driver
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   271
#------------------------------------------------------------------------------
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   272
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   273
AC_ARG_ENABLE([e1000],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   274
    AS_HELP_STRING([--enable-e1000],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   275
                   [Enable e1000 driver]),
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   276
    [
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   277
        case "${enableval}" in
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   278
            yes) enablee1000=1
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   279
                ;;
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   280
            no) enablee1000=0
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   281
                ;;
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   282
            *) AC_MSG_ERROR([Invalid value for --enable-e1000])
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   283
                ;;
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   284
        esac
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   285
    ],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   286
    [enablee1000=0] # disabled by default
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   287
)
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   288
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   289
AM_CONDITIONAL(ENABLE_E1000, test "x$enablee1000" = "x1")
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   290
AC_SUBST(ENABLE_E1000,[$enablee1000])
667
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   291
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   292
AC_ARG_WITH([e1000-kernel],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   293
    AC_HELP_STRING(
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   294
        [--with-e1000-kernel=<X.Y.Z>],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   295
        [e1000 kernel (only if differing)]
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   296
    ),
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   297
    [
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   298
        kernele1000=[$withval]
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   299
    ],
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   300
    [
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   301
        kernele1000=$linuxversion
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   302
    ]
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   303
)
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   304
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   305
if test "x${enablee1000}" = "x1"; then
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   306
    AC_MSG_CHECKING([for kernel for e1000 driver])
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   307
945
a5907351e13e Improved out-of-place build.
Florian Pose <fp@igh-essen.com>
parents: 922
diff changeset
   308
    kernels=`ls -1 ${srcdir}/devices/e1000/ | grep -oE "^e1000_main-.*" | cut -d "-" -f 2 | uniq`
667
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   309
    found=0
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   310
    for k in $kernels; do
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   311
        if test "$kernele1000" = "$k"; then
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   312
            found=1
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   313
        fi
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   314
    done
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   315
    if test $found -ne 1; then
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   316
        AC_MSG_ERROR([kernel $kernele1000 not available for e1000 driver!])
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   317
    fi
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   318
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   319
    AC_MSG_RESULT([$kernele1000])
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   320
fi
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   321
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   322
AC_SUBST(KERNEL_E1000,[$kernele1000])
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   323
667
9feff35c9617 First version with e1000 driver (to be continued...)
Florian Pose <fp@igh-essen.com>
parents: 665
diff changeset
   324
#------------------------------------------------------------------------------
2133
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   325
# e1000e driver
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   326
#------------------------------------------------------------------------------
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   327
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   328
AC_ARG_ENABLE([e1000e],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   329
    AS_HELP_STRING([--enable-e1000e],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   330
                   [Enable e1000e driver]),
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   331
    [
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   332
        case "${enableval}" in
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   333
            yes) enablee1000e=1
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   334
                ;;
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   335
            no) enablee1000e=0
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   336
                ;;
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   337
            *) AC_MSG_ERROR([Invalid value for --enable-e1000e])
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   338
                ;;
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   339
        esac
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   340
    ],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   341
    [enablee1000e=0] # disabled by default
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   342
)
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   343
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   344
AM_CONDITIONAL(ENABLE_E1000E, test "x$enablee1000e" = "x1")
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   345
AC_SUBST(ENABLE_E1000E,[$enablee1000e])
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   346
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   347
AC_ARG_WITH([e1000e-kernel],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   348
    AC_HELP_STRING(
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   349
        [--with-e1000e-kernel=<X.Y.Z>],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   350
        [e1000e kernel (only if differing)]
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   351
    ),
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   352
    [
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   353
        kernele1000e=[$withval]
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   354
    ],
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   355
    [
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   356
        kernele1000e=$linuxversion
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   357
    ]
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   358
)
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   359
2491
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   360
e1000elayout34=0
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   361
2133
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   362
if test "x${enablee1000e}" = "x1"; then
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   363
    AC_MSG_CHECKING([for kernel for e1000e driver])
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   364
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   365
    kernels=`ls -1 ${srcdir}/devices/e1000e/ | grep -oE "^netdev-.*" | cut -d "-" -f 2 | uniq`
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   366
    found=0
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   367
    for k in $kernels; do
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   368
        if test "$kernele1000e" = "$k"; then
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   369
            found=1
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   370
        fi
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   371
    done
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   372
    if test $found -ne 1; then
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   373
        AC_MSG_ERROR([kernel $kernele1000e not available for e1000e driver!])
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   374
    fi
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   375
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   376
    AC_MSG_RESULT([$kernele1000e])
2491
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   377
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   378
    # check for e1000e file layout (changed in kernel 3.4)
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   379
    AC_MSG_CHECKING([for e1000e source layout])
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   380
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   381
    file34="${srcdir}/devices/e1000e/80003es2lan-$kernele1000e-ethercat.c"
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   382
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   383
    if test -r "$file34"; then
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   384
        AC_MSG_RESULT([>= 3.4])
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   385
        e1000elayout34=1
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   386
    else
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   387
        AC_MSG_RESULT([before 3.4])
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   388
    fi
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   389
2133
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   390
fi
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   391
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   392
AC_SUBST(KERNEL_E1000E,[$kernele1000e])
2491
5e9221a78855 Added e1000e driver for kernel 3.4.
Florian Pose <fp@igh-essen.com>
parents: 2489
diff changeset
   393
AC_SUBST(E1000E_LAYOUT_3_4, [$e1000elayout34])
2133
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   394
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   395
#------------------------------------------------------------------------------
1353
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   396
# r8169 driver
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   397
#------------------------------------------------------------------------------
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   398
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   399
AC_ARG_ENABLE([r8169],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   400
    AS_HELP_STRING([--enable-r8169],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   401
                   [Enable r8169 driver]),
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   402
    [
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   403
        case "${enableval}" in
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   404
            yes) enable_r8169=1
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   405
                ;;
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   406
            no) enable_r8169=0
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   407
                ;;
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   408
            *) AC_MSG_ERROR([Invalid value for --enable-r8169])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   409
                ;;
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   410
        esac
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   411
    ],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   412
    [enable_r8169=0] # disabled by default
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   413
)
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   414
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   415
AM_CONDITIONAL(ENABLE_R8169, test "x$enable_r8169" = "x1")
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   416
AC_SUBST(ENABLE_R8169,[$enable_r8169])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   417
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   418
AC_ARG_WITH([r8169-kernel],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   419
    AC_HELP_STRING(
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   420
        [--with-r8169-kernel=<X.Y.Z>],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   421
        [r8169 kernel (only if differing)]
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   422
    ),
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   423
    [
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   424
        kernel_r8169=[$withval]
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   425
    ],
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   426
    [
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   427
        kernel_r8169=$linuxversion
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   428
    ]
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   429
)
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   430
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   431
if test "x${enable_r8169}" = "x1"; then
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   432
    AC_MSG_CHECKING([for kernel for r8169 driver])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   433
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   434
    kernels=`ls -1 ${srcdir}/devices/ | grep -oE "^r8169-.*-" | cut -d "-" -f 2 | uniq`
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   435
    found=0
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   436
    for k in $kernels; do
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   437
        if test "$kernel_r8169" = "$k"; then
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   438
            found=1
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   439
        fi
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   440
    done
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   441
    if test $found -ne 1; then
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   442
        AC_MSG_ERROR([kernel $kernel_r8169 not available for r8169 driver!])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   443
    fi
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   444
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   445
    AC_MSG_RESULT([$kernel_r8169])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   446
fi
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   447
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   448
AC_SUBST(KERNEL_R8169,[$kernel_r8169])
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   449
22b1de4c74e4 First version of r8169 driver.
Florian Pose <fp@igh-essen.com>
parents: 1327
diff changeset
   450
#------------------------------------------------------------------------------
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   451
# RTAI path (optional)
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   452
#------------------------------------------------------------------------------
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   453
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   454
AC_ARG_WITH([rtai-dir],
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   455
    AC_HELP_STRING(
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   456
        [--with-rtai-dir=<DIR>],
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   457
        [RTAI path, for RTDM interface and RTAI examples]
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   458
    ),
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   459
    [
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   460
        rtaidir=[$withval]
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   461
        rtai=1
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   462
    ],
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   463
    [
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   464
        rtaidir=""
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   465
        rtai=0
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   466
    ]
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   467
)
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   468
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   469
AC_MSG_CHECKING([for RTAI path])
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   470
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   471
if test -z "${rtaidir}"; then
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   472
    AC_MSG_RESULT([not specified.])
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   473
else
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   474
    if test \! -r ${rtaidir}/include/rtai.h; then
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   475
        AC_MSG_ERROR([no RTAI installation found in ${rtaidir}!])
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   476
    fi
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   477
    AC_MSG_RESULT([$rtaidir])
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   478
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   479
    rtai_lxrt_cflags=`$rtaidir/bin/rtai-config --lxrt-cflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   480
    rtai_lxrt_ldflags=`$rtaidir/bin/rtai-config --lxrt-ldflags`
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   481
fi
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   482
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   483
AC_SUBST(RTAI_DIR,[$rtaidir])
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   484
AM_CONDITIONAL(ENABLE_RTAI, test "x$rtai" = "x1")
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   485
AC_SUBST(ENABLE_RTAI,[$rtai])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   486
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   487
AC_SUBST(RTAI_LXRT_CFLAGS,[$rtai_lxrt_cflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   488
AC_SUBST(RTAI_LXRT_LDFLAGS,[$rtai_lxrt_ldflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   489
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   490
#------------------------------------------------------------------------------
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   491
# Xenomai path (optional)
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   492
#------------------------------------------------------------------------------
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   493
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   494
AC_ARG_WITH([xenomai-dir],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   495
    AC_HELP_STRING(
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   496
        [--with-xenomai-dir=<DIR>],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   497
        [Xenomai path, for RTDM interface and Xenomai examples]
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   498
    ),
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   499
    [
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   500
        xenomaidir=[$withval]
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   501
        xeno=1
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   502
    ],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   503
    [
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   504
        xenomaidir=""
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   505
        xeno=0
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   506
    ]
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   507
)
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   508
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   509
AC_MSG_CHECKING([for Xenomai path])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   510
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   511
if test -z "${xenomaidir}"; then
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   512
    AC_MSG_RESULT([not specified.])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   513
else
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   514
    if test \! -r ${xenomaidir}/include/xeno_config.h; then
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   515
        AC_MSG_ERROR([no Xenomai installation found in ${xenomaidir}!])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   516
    fi
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   517
    AC_MSG_RESULT([$xenomaidir])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   518
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   519
    xeno_native_cflags=`$xenomaidir/bin/xeno-config --skin native --cflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   520
    xeno_native_ldflags=`$xenomaidir/bin/xeno-config --skin native --ldflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   521
    xeno_posix_cflags=`$xenomaidir/bin/xeno-config --skin posix --cflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   522
    xeno_posix_ldflags=`$xenomaidir/bin/xeno-config --skin posix --ldflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   523
    xeno_rtdm_cflags=`$xenomaidir/bin/xeno-config --skin rtdm --cflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   524
    xeno_rtdm_ldflags=`$xenomaidir/bin/xeno-config --skin rtdm --ldflags`
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   525
fi
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   526
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   527
AC_SUBST(XENOMAI_DIR,[$xenomaidir])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   528
AM_CONDITIONAL(ENABLE_XENOMAI, test "x$xeno" = "x1")
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   529
AC_SUBST(ENABLE_XENOMAI,[$xeno])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   530
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   531
AC_SUBST(XENOMAI_NATIVE_CFLAGS,[$xeno_native_cflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   532
AC_SUBST(XENOMAI_NATIVE_LDFLAGS,[$xeno_native_ldflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   533
AC_SUBST(XENOMAI_POSIX_CFLAGS,[$xeno_posix_cflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   534
AC_SUBST(XENOMAI_POSIX_LDFLAGS,[$xeno_posix_ldflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   535
AC_SUBST(XENOMAI_RTDM_CFLAGS,[$xeno_rtdm_cflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   536
AC_SUBST(XENOMAI_RTDM_LDFLAGS,[$xeno_rtdm_ldflags])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   537
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   538
#------------------------------------------------------------------------------
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   539
# RTDM interface (optional)
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   540
#------------------------------------------------------------------------------
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   541
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   542
AC_ARG_ENABLE([rtdm],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   543
    AC_HELP_STRING(
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   544
        [--enable-rtdm],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   545
        [Enable RTDM interface, depends on RTAI or Xenomai]
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   546
    ),
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   547
    [
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   548
        case "${enableval}" in
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   549
            yes) rtdm=1
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   550
                ;;
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   551
            no) rtdm=0
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   552
                ;;
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   553
            *) AC_MSG_ERROR([Invalid value for --enable-rtdm])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   554
                ;;
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   555
        esac
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   556
    ],
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   557
    [rtdm=0]
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   558
)
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   559
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   560
AC_MSG_CHECKING([whether to build RTDM interface])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   561
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   562
if test "x${rtdm}" = "x1"; then
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   563
    AC_DEFINE([EC_RTDM], [1], [RTDM interface enabled])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   564
    AC_MSG_RESULT([yes])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   565
else
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   566
    AC_MSG_RESULT([no])
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   567
fi
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   568
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   569
AM_CONDITIONAL(ENABLE_RTDM, test "x$rtdm" = "x1")
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   570
AC_SUBST(ENABLE_RTDM,[$rtdm])
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   571
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   572
#------------------------------------------------------------------------------
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   573
# Debug interface
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   574
#------------------------------------------------------------------------------
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   575
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   576
AC_MSG_CHECKING([whether to build the debug interface])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   577
679
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   578
AC_ARG_ENABLE([debug-if],
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   579
    AS_HELP_STRING([--enable-debug-if],
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   580
                   [Create a debug interface for each master @<:@NO@:>@]),
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   581
    [
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   582
        case "${enableval}" in
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   583
            yes) dbg=1
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   584
                ;;
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   585
            no) dbg=0
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   586
                ;;
679
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   587
            *) AC_MSG_ERROR([Invalid value for --enable-debug-if])
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   588
                ;;
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   589
        esac
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   590
    ],
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   591
    [dbg=0]
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   592
)
440
16fddae16c94 Altered configure --with-linux parameter to --with-linux-dir; removed depmod call.
Florian Pose <fp@igh-essen.com>
parents: 393
diff changeset
   593
679
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   594
if test "x${dbg}" = "x1"; then
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   595
    AC_DEFINE([EC_DEBUG_IF], [1], [Debug interfaces enabled])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   596
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   597
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   598
    AC_MSG_RESULT([no])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   599
fi
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   600
679
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   601
AM_CONDITIONAL(ENABLE_DEBUG_IF, test "x$dbg" = "x1")
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   602
AC_SUBST(ENABLE_DEBUG_IF,[$dbg])
679
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   603
62fc387ec928 Added --enable-dummy; renamed EC_DBG_IF to EC_DEBUG_IF, ENABLE_DEBUG_IF
Florian Pose <fp@igh-essen.com>
parents: 667
diff changeset
   604
#------------------------------------------------------------------------------
692
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   605
# Debug ring
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   606
#------------------------------------------------------------------------------
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   607
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   608
AC_MSG_CHECKING([whether to build the debug ring])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   609
692
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   610
AC_ARG_ENABLE([debug-ring],
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   611
    AS_HELP_STRING([--enable-debug-ring],
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   612
                   [Create a debug ring to record frames @<:@NO@:>@]),
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   613
    [
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   614
        case "${enableval}" in
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   615
            yes) debugring=1
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   616
                ;;
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   617
            no) debugring=0
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   618
                ;;
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   619
            *) AC_MSG_ERROR([Invalid value for --enable-debug-ring])
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   620
                ;;
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   621
        esac
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   622
    ],
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   623
    [debugring=0]
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   624
)
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   625
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   626
if test "x${debugring}" = "x1"; then
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   627
    AC_DEFINE([EC_DEBUG_RING], [1], [Debug ring enabled])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   628
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   629
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   630
    AC_MSG_RESULT([no])
692
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   631
fi
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   632
fe7cf37c33f1 Implemented debug frame ring to output the last n frames for debugging
Florian Pose <fp@igh-essen.com>
parents: 686
diff changeset
   633
#------------------------------------------------------------------------------
1327
4d179b06dd3c merge -c1604 branches/stable-1.4: Fixed spelling of EtherCAT terms.
Florian Pose <fp@igh-essen.com>
parents: 1302
diff changeset
   634
# Ethernet over EtherCAT support
715
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   635
#------------------------------------------------------------------------------
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   636
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   637
AC_MSG_CHECKING([whether to build with EoE support])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   638
715
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   639
AC_ARG_ENABLE([eoe],
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   640
    AS_HELP_STRING([--enable-eoe],
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   641
                   [Enable EoE support (default: yes)]),
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   642
    [
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   643
        case "${enableval}" in
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   644
            yes) eoe=1
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   645
                ;;
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   646
            no) eoe=0
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   647
                ;;
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   648
            *) AC_MSG_ERROR([Invalid value for --enable-eoe])
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   649
                ;;
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   650
        esac
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   651
    ],
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   652
    [eoe=1]
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   653
)
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   654
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   655
if test "x${eoe}" = "x1"; then
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   656
    AC_DEFINE([EC_EOE], [1], [EoE support enabled])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   657
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   658
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   659
    AC_MSG_RESULT([no])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   660
fi
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   661
715
f12ff7c08623 Added --enable-eoe conditional.
Florian Pose <fp@igh-essen.com>
parents: 709
diff changeset
   662
AM_CONDITIONAL(ENABLE_EOE, test "x$eoe" = "x1")
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   663
AC_SUBST(ENABLE_EOE,[$eoe])
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   664
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   665
#------------------------------------------------------------------------------
1040
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   666
# CPU timestamp counter support
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   667
#------------------------------------------------------------------------------
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   668
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   669
AC_MSG_CHECKING([whether to use the CPU timestamp counter])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   670
1040
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   671
AC_ARG_ENABLE([cycles],
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   672
    AS_HELP_STRING([--enable-cycles],
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   673
                   [Use CPU timestamp counter (default: no)]),
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   674
    [
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   675
        case "${enableval}" in
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   676
            yes) cycles=1
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   677
                ;;
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   678
            no) cycles=0
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   679
                ;;
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   680
            *) AC_MSG_ERROR([Invalid value for --enable-cycles])
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   681
                ;;
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   682
        esac
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   683
    ],
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   684
    [cycles=0]
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   685
)
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   686
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   687
if test "x${cycles}" = "x1"; then
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   688
    AC_DEFINE([EC_HAVE_CYCLES], [1], [Use CPU timestamp counter])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   689
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   690
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   691
    AC_MSG_RESULT([no])
1040
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   692
fi
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   693
d2527675cdd5 Disable use of CPU timestamp counter by default.
Florian Pose <fp@igh-essen.com>
parents: 945
diff changeset
   694
#------------------------------------------------------------------------------
1773
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   695
# High-resolution timer support
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   696
#------------------------------------------------------------------------------
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   697
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   698
AC_MSG_CHECKING([whether to use high-resolution timers for scheduling])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   699
1773
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   700
AC_ARG_ENABLE([hrtimer],
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   701
    AS_HELP_STRING([--enable-hrtimer],
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   702
                   [Use high-resolution timer for scheduling (default: no)]),
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   703
    [
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   704
        case "${enableval}" in
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   705
            yes) hrtimer=1
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   706
                ;;
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   707
            no) hrtimer=0
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   708
                ;;
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   709
            *) AC_MSG_ERROR([Invalid value for --enable-hrtimer])
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   710
                ;;
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   711
        esac
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   712
    ],
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   713
    [hrtimer=0]
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   714
)
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   715
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   716
if test "x${hrtimer}" = "x1"; then
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   717
    AC_DEFINE([EC_USE_HRTIMER], [1], [Use hrtimer for scheduling])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   718
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   719
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   720
    AC_MSG_RESULT([no])
1773
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   721
fi
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   722
5371f3e5f6a1 Disable use of hrtimer for scheduling by default. Does not work on some PPC targets.
Florian Pose <fp@igh-essen.com>
parents: 1567
diff changeset
   723
#------------------------------------------------------------------------------
1934
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   724
# Read alias address from register
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   725
#------------------------------------------------------------------------------
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   726
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   727
AC_MSG_CHECKING([whether to read alias addresses from registers])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   728
1934
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   729
AC_ARG_ENABLE([regalias],
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   730
    AS_HELP_STRING([--enable-regalias],
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   731
                   [Read alias adresses from register (default: no)]),
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   732
    [
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   733
        case "${enableval}" in
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   734
            yes) regalias=1
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   735
                ;;
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   736
            no) regalias=0
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   737
                ;;
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   738
            *) AC_MSG_ERROR([Invalid value for --enable-regalias])
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   739
                ;;
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   740
        esac
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   741
    ],
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   742
    [regalias=0]
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   743
)
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   744
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   745
if test "x${regalias}" = "x1"; then
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   746
    AC_DEFINE([EC_REGALIAS], [1], [Read alias adresses from register])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   747
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   748
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   749
    AC_MSG_RESULT([no])
1934
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   750
fi
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   751
f00951ab7399 Introduced configure switch --enable-regalias for enabling reading alias
Florian Pose <fp@igh-essen.com>
parents: 1825
diff changeset
   752
#------------------------------------------------------------------------------
1253
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   753
# Command-line tool
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   754
#-----------------------------------------------------------------------------
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   755
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   756
AC_MSG_CHECKING([whether to build the command-line tool])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   757
1253
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   758
AC_ARG_ENABLE([tool],
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   759
    AS_HELP_STRING([--enable-tool],
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   760
                   [Build command-line tool (default: yes)]),
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   761
    [
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   762
        case "${enableval}" in
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   763
            yes) tool=1
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   764
                ;;
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   765
            no) tool=0
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   766
                ;;
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   767
            *) AC_MSG_ERROR([Invalid value for --enable-tool])
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   768
                ;;
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   769
        esac
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   770
    ],
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   771
    [tool=1]
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   772
)
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   773
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   774
if test "x${tool}" = "x1"; then
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   775
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   776
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   777
    AC_MSG_RESULT([no])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   778
fi
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   779
1253
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   780
AM_CONDITIONAL(BUILD_TOOL, test "x$tool" = "x1")
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   781
8a081444a89a Added configure switch for disabling the command-line tool.
Florian Pose <fp@igh-essen.com>
parents: 1242
diff changeset
   782
#------------------------------------------------------------------------------
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   783
# Userspace library generation
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   784
#------------------------------------------------------------------------------
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   785
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   786
AC_MSG_CHECKING([whether to build the userspace library])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   787
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   788
AC_ARG_ENABLE([userlib],
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   789
    AS_HELP_STRING([--enable-userlib],
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   790
                   [Generation of the userspace library (default: yes)]),
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   791
    [
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   792
        case "${enableval}" in
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   793
            yes) userlib=1
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   794
                ;;
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   795
            no) userlib=0
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   796
                ;;
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   797
            *) AC_MSG_ERROR([Invalid value for --enable-userlib])
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   798
                ;;
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   799
        esac
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   800
    ],
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   801
    [userlib=1]
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   802
)
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   803
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   804
if test "x${userlib}" = "x1"; then
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   805
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   806
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   807
    AC_MSG_RESULT([no])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   808
fi
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   809
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   810
AM_CONDITIONAL(ENABLE_USERLIB, test "x$userlib" = "x1")
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   811
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   812
#------------------------------------------------------------------------------
1565
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   813
# TTY driver
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   814
#------------------------------------------------------------------------------
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   815
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   816
AC_MSG_CHECKING([whether to build the tty driver])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   817
1565
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   818
AC_ARG_ENABLE([tty],
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   819
    AS_HELP_STRING([--enable-tty],
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   820
                   [Generation of the ec_tty module (default: no)]),
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   821
    [
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   822
        case "${enableval}" in
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   823
            yes) tty=1
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   824
                ;;
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   825
            no) tty=0
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   826
                ;;
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   827
            *) AC_MSG_ERROR([Invalid value for --enable-tty])
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   828
                ;;
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   829
        esac
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   830
    ],
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   831
    [tty=0]
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   832
)
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   833
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   834
if test "x${tty}" = "x1"; then
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   835
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   836
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   837
    AC_MSG_RESULT([no])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   838
fi
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   839
1565
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   840
AM_CONDITIONAL(ENABLE_TTY, test "x$tty" = "x1")
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   841
AC_SUBST(ENABLE_TTY,[$tty])
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   842
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
   843
#------------------------------------------------------------------------------
2295
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   844
# Slave identification wildcards
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   845
#------------------------------------------------------------------------------
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   846
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   847
AC_MSG_CHECKING([whether to allow identification wildcards])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   848
2295
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   849
AC_ARG_ENABLE([wildcards],
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   850
    AS_HELP_STRING([--enable-wildcards],
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   851
                   [Enable vendor ID / product code wildcards (default: no)]),
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   852
    [
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   853
        case "${enableval}" in
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   854
            yes) wildcards=1
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   855
                ;;
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   856
            no) wildcards=0
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   857
                ;;
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   858
            *) AC_MSG_ERROR([Invalid value for --enable-wildcards])
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   859
                ;;
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   860
        esac
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   861
    ],
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   862
    [wildcards=0]
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   863
)
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   864
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   865
if test "x${wildcards}" = "x1"; then
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   866
    AC_DEFINE([EC_IDENT_WILDCARDS], [1],
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   867
        [Use vendor id / product code wildcards])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   868
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   869
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   870
    AC_MSG_RESULT([no])
2295
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   871
fi
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   872
4e4c018573c0 Added --enable-wildcards to use 0xffffffff as wildcard for vendor ID and
Florian Pose <fp@igh-essen.com>
parents: 2133
diff changeset
   873
#------------------------------------------------------------------------------
2453
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   874
# Redundancy (number of devices)
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   875
#------------------------------------------------------------------------------
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   876
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   877
AC_ARG_WITH([devices],
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   878
    AC_HELP_STRING(
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   879
        [--with-devices=<NUMBER>],
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   880
        [Number of Ethernet devices per master. Default: 1]
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   881
    ),
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   882
    [
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   883
        devices=[$withval]
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   884
    ],
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   885
    [
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   886
        devices=1
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   887
    ]
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   888
)
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   889
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   890
AC_MSG_CHECKING([for number of Ethernet devices])
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   891
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   892
if test "${devices}" -lt 1; then
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   893
    AC_MSG_ERROR([Number must be greater zero!])
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   894
else
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   895
    if test "${devices}" -gt 1; then
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   896
        AC_MSG_RESULT([$devices (Redundancy enabled)])
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   897
    else
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   898
        AC_MSG_RESULT([$devices (Redundancy disabled)])
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   899
    fi
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   900
fi
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   901
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   902
AC_DEFINE_UNQUOTED([EC_MAX_NUM_DEVICES], $devices,
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   903
    [Max. number of Ethernet devices per master])
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   904
d461b1f07296 Added configure option for redundancy (--with-devices).
Florian Pose <fp@igh-essen.com>
parents: 2447
diff changeset
   905
#------------------------------------------------------------------------------
2508
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   906
# SII assignment
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   907
#------------------------------------------------------------------------------
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   908
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   909
AC_MSG_CHECKING([whether to assign the SII to PDI])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   910
2508
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   911
AC_ARG_ENABLE([sii-assign],
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   912
    AS_HELP_STRING([--enable-sii-assign],
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   913
                   [Enable SII assignment to PDI (default: no)]),
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   914
    [
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   915
        case "${enableval}" in
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   916
            yes) siiassign=1
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   917
                ;;
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   918
            no) siiassign=0
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   919
                ;;
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   920
            *) AC_MSG_ERROR([Invalid value for --enable-sii-assign])
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   921
                ;;
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   922
        esac
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   923
    ],
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   924
    [siiassign=0]
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   925
)
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   926
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   927
if test "x${siiassign}" = "x1"; then
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   928
    AC_DEFINE([EC_SII_ASSIGN], [1], [Assign SII to PDI])
2509
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   929
    AC_MSG_RESULT([yes])
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   930
else
232831b6249b More detailed output of configure script.
Florian Pose <fp@igh-essen.com>
parents: 2508
diff changeset
   931
    AC_MSG_RESULT([no])
2508
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   932
fi
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   933
6b21b3f88a9a Introduced --enable-sii-assign.
Florian Pose <fp@igh-essen.com>
parents: 2491
diff changeset
   934
#------------------------------------------------------------------------------
2532
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   935
# syslog output in realtime context
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   936
#------------------------------------------------------------------------------
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   937
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   938
AC_MSG_CHECKING([whether to syslog in realtime context])
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   939
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   940
AC_ARG_ENABLE([rt-syslog],
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   941
    AS_HELP_STRING([--enable-rt-syslog],
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   942
                   [Enable RT syslog (default: yes)]),
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   943
    [
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   944
        case "${enableval}" in
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   945
            yes) rtsyslog=1
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   946
                ;;
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   947
            no) rtsyslog=0
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   948
                ;;
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   949
            *) AC_MSG_ERROR([Invalid value for --enable-rt-syslog])
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   950
                ;;
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   951
        esac
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   952
    ],
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   953
    [rtsyslog=1]
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   954
)
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   955
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   956
if test "x${rtsyslog}" = "x1"; then
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   957
    AC_DEFINE([EC_RT_SYSLOG], [1], [Output to syslog in RT context])
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   958
    AC_MSG_RESULT([yes])
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   959
else
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   960
    AC_MSG_RESULT([no])
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   961
fi
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   962
bdadf6da4914 Added configure switch --disable-rt-syslog.
Florian Pose <fp@igh-essen.com>
parents: 2526
diff changeset
   963
#------------------------------------------------------------------------------
485
8354ddf38481 Improved autotools, added config.kbuild, --with-msr-dir, --with-rtai-dir, --with-8139too-kernel.
Florian Pose <fp@igh-essen.com>
parents: 479
diff changeset
   964
385
c33367851350 Added file ./bootstrap; Added $(DESTDIR) to */Makefile.am make alternate root installs possible
Richard Hacker <ha@igh-essen.com>
parents: 373
diff changeset
   965
AC_CONFIG_FILES([
757
6210c4260899 Added Doxyfile to configuration files.
Florian Pose <fp@igh-essen.com>
parents: 732
diff changeset
   966
        Doxyfile
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   967
        Kbuild
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   968
        Makefile
882
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   969
        devices/Kbuild
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   970
        devices/Makefile
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   971
        devices/e1000/Kbuild
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   972
        devices/e1000/Makefile
2133
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   973
        devices/e1000e/Kbuild
74dbd0b7d6aa Added e1000e driver for 2.6.34. Thanks to Siwei Zhuang.
Florian Pose <fp@igh-essen.com>
parents: 2064
diff changeset
   974
        devices/e1000e/Makefile
1810
a352f3e4f95d Added spec file for building an RPM package.
Florian Pose <fp@igh-essen.com>
parents: 1809
diff changeset
   975
        ethercat.spec
1286
88e573e033f1 Build examples by default.
Florian Pose <fp@igh-essen.com>
parents: 1253
diff changeset
   976
        examples/Kbuild
882
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   977
        examples/Makefile
1414
0037a63d3cc5 DC example applications.
Florian Pose <fp@igh-essen.com>
parents: 1363
diff changeset
   978
        examples/dc_rtai/Kbuild
0037a63d3cc5 DC example applications.
Florian Pose <fp@igh-essen.com>
parents: 1363
diff changeset
   979
        examples/dc_rtai/Makefile
0037a63d3cc5 DC example applications.
Florian Pose <fp@igh-essen.com>
parents: 1363
diff changeset
   980
        examples/dc_user/Makefile
882
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   981
        examples/mini/Kbuild
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   982
        examples/mini/Makefile
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   983
        examples/rtai/Kbuild
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   984
        examples/rtai/Makefile
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   985
        examples/rtai_rtdm/Makefile
2447
e93efb4af231 Added interface to select the reference clock and to sync to it.
Florian Pose <fp@igh-essen.com>
parents: 2446
diff changeset
   986
        examples/rtai_rtdm_dc/Makefile
1810
a352f3e4f95d Added spec file for building an RPM package.
Florian Pose <fp@igh-essen.com>
parents: 1809
diff changeset
   987
        examples/tty/Kbuild
1567
1babaa430b7b Added tty example.
Florian Pose <fp@igh-essen.com>
parents: 1565
diff changeset
   988
        examples/tty/Makefile
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   989
        examples/user/Makefile
2433
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   990
        examples/xenomai/Makefile
3bdd7a747fae Re-worked and seamlessly integrated RTDM interface.
Florian Pose <fp@igh-essen.com>
parents: 2419
diff changeset
   991
        examples/xenomai_posix/Makefile
882
a7222d7fb7a8 Removed dummy master.
Florian Pose <fp@igh-essen.com>
parents: 777
diff changeset
   992
        include/Makefile
1242
632a6b91f8e4 First version of userspace library with requesting/releasing.
Florian Pose <fp@igh-essen.com>
parents: 1234
diff changeset
   993
        lib/Makefile
1440
1b32fe09c689 Added deummy Makefile.am for m4 directory.
Florian Pose <fp@igh-essen.com>
parents: 1432
diff changeset
   994
        m4/Makefile
732
0e6e1ef2b6bc Removed config.kbuild and replaced Kbuild files by Kbuild.in files.
Florian Pose <fp@igh-essen.com>
parents: 726
diff changeset
   995
        master/Kbuild
392
eaee3c8d6ae0 Debug interfaces not compiled by default.
Florian Pose <fp@igh-essen.com>
parents: 387
diff changeset
   996
        master/Makefile
385
c33367851350 Added file ./bootstrap; Added $(DESTDIR) to */Makefile.am make alternate root installs possible
Richard Hacker <ha@igh-essen.com>
parents: 373
diff changeset
   997
        script/Makefile
2309
b0ddf0ea0a60 Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents: 2295
diff changeset
   998
        script/ethercat.service
b0ddf0ea0a60 Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents: 2295
diff changeset
   999
        script/ethercatctl
563
d113b63c55c4 Changed structure of scripts subdirectory.
Florian Pose <fp@igh-essen.com>
parents: 546
diff changeset
  1000
        script/init.d/Makefile
1185
337ce4fc2383 Repaired init script status command.
Florian Pose <fp@igh-essen.com>
parents: 1120
diff changeset
  1001
        script/init.d/ethercat
563
d113b63c55c4 Changed structure of scripts subdirectory.
Florian Pose <fp@igh-essen.com>
parents: 546
diff changeset
  1002
        script/sysconfig/Makefile
1120
0ae26760c12d Moved tools to tool.
Florian Pose <fp@igh-essen.com>
parents: 1080
diff changeset
  1003
        tool/Makefile
1810
a352f3e4f95d Added spec file for building an RPM package.
Florian Pose <fp@igh-essen.com>
parents: 1809
diff changeset
  1004
        tty/Kbuild
1565
8c526cfe1399 Base files for new TTY driver.
Florian Pose <fp@igh-essen.com>
parents: 1540
diff changeset
  1005
        tty/Makefile
385
c33367851350 Added file ./bootstrap; Added $(DESTDIR) to */Makefile.am make alternate root installs possible
Richard Hacker <ha@igh-essen.com>
parents: 373
diff changeset
  1006
])
365
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
  1007
AC_OUTPUT
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
  1008
7aede8ed6025 Corrected autotools.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
  1009
#------------------------------------------------------------------------------