Building RTT for Linux-preempt

Hi,

I'm trying to compile RTT for a Linux-rt preempt kernel and want to
point the build-system to the right linux-headers, but cmake seems to
not pick up my LINUX_SOURCE_DIR definition:

I execute cmake as follows:

cd rtt-svn/build && cmake -DCMAKE_INSTALL_PREFIX=`rospack find
rtt-1.10`/rtt/ -DOROCOS_TARGET=gnulinux -DCMAKE_PREFIX_PATH=
-DCMAKE_BUILD_TYPE="RTT" -DCORBA_IMPLEMENTATION="OMNIORB"
-DENABLE_CORBA=ON
-DLINUX_SOURCE_DIR=/usr/src/linux-headers-2.6.28-3-rt ..

but make VERBOSE does not show the include path to my kernel headers:

Building CXX object
src/CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
cd /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
&& /usr/bin/c++ -DOROCOS_TARGET=gnulinux -DRTT_DLL_EXPORT -fPIC
-I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src
-I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
-I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os
-I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os/gnulinux
-o CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
-c /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src/scripting/PropertyParser.cpp

Is this a bug in the buildsystem, or did I forget something?

Ruben

Building RTT for Linux-preempt

On Mon, Mar 8, 2010 at 11:54 AM, Ruben Smits
<ruben [dot] smits [..] ...> wrote:
> Hi,
>
> I'm trying to compile RTT for a Linux-rt preempt kernel and want to
> point the build-system to the right linux-headers, but cmake seems to
> not pick up my LINUX_SOURCE_DIR definition:
>
> I execute cmake as follows:
>
> cd rtt-svn/build && cmake -DCMAKE_INSTALL_PREFIX=`rospack find
> rtt-1.10`/rtt/ -DOROCOS_TARGET=gnulinux -DCMAKE_PREFIX_PATH=
> -DCMAKE_BUILD_TYPE="RTT" -DCORBA_IMPLEMENTATION="OMNIORB"
> -DENABLE_CORBA=ON
> -DLINUX_SOURCE_DIR=/usr/src/linux-headers-2.6.28-3-rt ..
>
> but make VERBOSE does not show the include path to my kernel headers:
>
> Building CXX object
> src/CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
> cd /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
> && /usr/bin/c++   -DOROCOS_TARGET=gnulinux -DRTT_DLL_EXPORT -fPIC
> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src
> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os
> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os/gnulinux
>  -o CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
> -c /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src/scripting/PropertyParser.cpp
>
>
> Is this a bug in the buildsystem, or did I forget something?

Why do you think RTT needs the LINUX_SOURCE_DIR for compiling?

AFAIK
<http://www.orocos.org/stable/documentation/rtt/v1.10.x/doc-xml/orocos-installation.html>,
section 1.3
it's simply not used.

Klaas

Ruben Smits's picture

Building RTT for Linux-preempt

I have different kernels, I thought I had to point the build to the
right headers, if not, even better, than i can reuse my previous
gnulinux build also for the rt-preempt kernel.

Ruben

On Mon, Mar 8, 2010 at 12:20 PM, Klaas Gadeyne <klaas [dot] gadeyne [..] ...> wrote:
> On Mon, Mar 8, 2010 at 11:54 AM, Ruben Smits
> <ruben [dot] smits [..] ...> wrote:
>> Hi,
>>
>> I'm trying to compile RTT for a Linux-rt preempt kernel and want to
>> point the build-system to the right linux-headers, but cmake seems to
>> not pick up my LINUX_SOURCE_DIR definition:
>>
>> I execute cmake as follows:
>>
>> cd rtt-svn/build && cmake -DCMAKE_INSTALL_PREFIX=`rospack find
>> rtt-1.10`/rtt/ -DOROCOS_TARGET=gnulinux -DCMAKE_PREFIX_PATH=
>> -DCMAKE_BUILD_TYPE="RTT" -DCORBA_IMPLEMENTATION="OMNIORB"
>> -DENABLE_CORBA=ON
>> -DLINUX_SOURCE_DIR=/usr/src/linux-headers-2.6.28-3-rt ..
>>
>> but make VERBOSE does not show the include path to my kernel headers:
>>
>> Building CXX object
>> src/CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
>> cd /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
>> && /usr/bin/c++   -DOROCOS_TARGET=gnulinux -DRTT_DLL_EXPORT -fPIC
>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src
>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os
>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os/gnulinux
>>  -o CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
>> -c /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src/scripting/PropertyParser.cpp
>>
>>
>> Is this a bug in the buildsystem, or did I forget something?
>
> Why do you think RTT needs the LINUX_SOURCE_DIR for compiling?
>
> AFAIK
> <http://www.orocos.org/stable/documentation/rtt/v1.10.x/doc-xml/orocos-installation.html>,
> section 1.3
> it's simply not used.
>
> Klaas
> --
> Orocos-Users mailing list
> Orocos-Users [..] ...
> http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
>

Building RTT for Linux-preempt

On Monday 08 March 2010 12:46:53 Ruben Smits wrote:
> I have different kernels, I thought I had to point the build to the
> right headers, if not, even better, than i can reuse my previous
> gnulinux build also for the rt-preempt kernel.

Indeed. No need to point to kernel headers. Only some RTAI
versions/configurations require kernel headers, all other targets don't.

Peter

Building RTT for Linux-preempt

On Mar 8, 2010, at 06:46 , Ruben Smits wrote:

> I have different kernels, I thought I had to point the build to the
> right headers, if not, even better, than i can reuse my previous
> gnulinux build also for the rt-preempt kernel.
>
> Ruben
>
> On Mon, Mar 8, 2010 at 12:20 PM, Klaas Gadeyne <klaas [dot] gadeyne [..] ...> wrote:
>> On Mon, Mar 8, 2010 at 11:54 AM, Ruben Smits
>> <ruben [dot] smits [..] ...> wrote:
>>> Hi,
>>>
>>> I'm trying to compile RTT for a Linux-rt preempt kernel and want to
>>> point the build-system to the right linux-headers, but cmake seems to
>>> not pick up my LINUX_SOURCE_DIR definition:
>>>
>>> I execute cmake as follows:
>>>
>>> cd rtt-svn/build && cmake -DCMAKE_INSTALL_PREFIX=`rospack find
>>> rtt-1.10`/rtt/ -DOROCOS_TARGET=gnulinux -DCMAKE_PREFIX_PATH=
>>> -DCMAKE_BUILD_TYPE="RTT" -DCORBA_IMPLEMENTATION="OMNIORB"
>>> -DENABLE_CORBA=ON
>>> -DLINUX_SOURCE_DIR=/usr/src/linux-headers-2.6.28-3-rt ..
>>>
>>> but make VERBOSE does not show the include path to my kernel headers:
>>>
>>> Building CXX object
>>> src/CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
>>> cd /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
>>> && /usr/bin/c++ -DOROCOS_TARGET=gnulinux -DRTT_DLL_EXPORT -fPIC
>>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src
>>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src
>>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os
>>> -I/home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/build/src/os/gnulinux
>>> -o CMakeFiles/orocos-rtt-dynamic_gnulinux.dir/scripting/PropertyParser.cpp.o
>>> -c /home/common/src/svn/robotics-ros/packages/orocos/rtt/rtt-1.10-rt/rtt-svn/src/scripting/PropertyParser.cpp
>>>
>>>
>>> Is this a bug in the buildsystem, or did I forget something?
>>
>> Why do you think RTT needs the LINUX_SOURCE_DIR for compiling?
>>
>> AFAIK
>> <http://www.orocos.org/stable/documentation/rtt/v1.10.x/doc-xml/orocos-installation.html>,
>> section 1.3
>> it's simply not used.
>>
>> Klaas

No kernel-specific include line shows up in our Ubuntu w/ RT builds. We've never had to do this, but then we don't hand build any kernels either. If you've done that, maybe you'll have trouble?
S