Support matrices and vectors for Simulink

Further, added the information for Simulink that only double
as input is supported and fixed the casting from float to double.
Even without explicitly stating that the input must be double,
Simulink assumes double so float was not correct!

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
Re-add autoconf files

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
Force 16-byte stack alignment

Allow SSE instructions in kernel modules

Seen on Debian jessie and other places:

[...]/testsuite/kern/latency/latency-module.c:1:0: error:
    -mpreferred-stack-boundary=3 is not between 4 and 12

http://mail.rtai.org/pipermail/rtai/2013-December/026198.html

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
x86 default .config:  CONFIG_RTAI_CPUS="8"

Reported by Mick/Schooner/@ArcEye

Kernel crashes if number of host CPUs is greater than
`CONFIG_RTAI_CPUS`

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
Suppress unused variable warnings

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
Update README.md
Enable multiple RTAI versions on a single system

/usr/bin/rtai-config becomes a stub script that helps select another
kernel-specific /usr/bin/rtai-config-<kver>.

Closes #16

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
rtai-config now doesn't complain on single RTAI kernel

Previously, the user was warned if no kernel selection option was given
but the script would default to running kernel.  This covers the
majority of RTAI users.

The new behavior is as follows.  If no kernel selection option was
given, then the number of available rtai-config-* files is counted.

- If this number is 1, the script defaults to the running kernel
  * If that rtai-config was indeed for the running kernel, all is ok
  * If that rtai-config was for a different kernel, the script prints an
    error saying that it refuses to proceed because this could be not
    what the user wants.  The reason is that normally if the user has a
    single RTAI kernel, s/he would built booting in that kernel.  If
    s/he is in a different kernel, it is likely that _that_ kernel was
    supposed to be an RTAI kernel as well, but perhaps there was a
    problem with the installation.  Either way, it doesn't hurt to make
    the user clarify the intention.
- If this number is different from 1, it's ambiguous which kernel the
  user is referring to.  The script gives an error and refuses to
  proceed.  This is to make sure the user doesn't accidentally run the
  wrong script by forgetting the -v or -r option, especially in a
  script!

See issue #16 for further discussion.

Signed-off-by: Shahbaz Youssefi <ShabbyX@gmail.com>
m4/docbook.m4:  if fop.sh isn't found, also check for fop

`fop.sh` is renamed to `fop` in Debian packages
Merge pull request #20 from zultron/fop-detection-fix

m4/docbook.m4:  if fop.sh isn't found, also check for fop
Fix comedilib headers

This is a patch from the upstream Debian RTAI packaging, maintained by
Roland Stigge.

It fixes the autoconf m4 macros to look for `comedilib.h` in `/usr/include` rather than `/usr/include/linux`:

    $ find /usr/include -name comedilib.h
    /usr/include/comedilib.h
    $ dpkg-query -S /usr/include/comedilib.h
    libcomedi-dev: /usr/include/comedilib.h
    $ dpkg-query -L libcomedi-dev | grep linux/
    $

After investigation, I found no case where the header's location might
be in `/usr/include/linux/comedilib.h`.  Debian, Ubuntu and Fedora all
install into `/usr/include/comedilib.h`, and building comedilib from
source apparently does, too.  It's starting to look like
`/usr/include/linux/comedilib.h` is an outdated location, or maybe
completely bogus:  this problem has been [reported since at least
2004][1], and hacking around the problem with a symlink is part of [at
least one RTAI tutorial][2]!

This is related to discussion in [my GitHub RTAI package repo][3].

[1]: http://mail.rtai.org/pipermail/rtai/2004-October/009196.html
[2]: http://marc.info/?l=comedi&m=117981204228094
[3]: https://github.com/zultron/rtai-deb/issues/1#issuecomment-57822869
rtai-config stub script:  add `-o` arg to select the 'only' headers found

(Fixup for ShabbyX/RTAI#16)

If only one set of headers is found on the system, the `-o` option
selects this kernel to build against.  If more than one is found,
error out.

The use case for this is on a build system where the running kernel is
not an RTAI kernel, where exactly one set of RTAI kernel headers
should be installed, and where it would be an irritating exercise to
ask the build scripts to repeat many of the checks found in this
script.  ;)
Merge pull request #21 from zultron/comedilib-headers

Fix comedilib headers
Merge pull request #22 from zultron/rtai-config

rtai-config stub script:  add `-o` arg to select the 'only' headers found