problem while linking rtems and chsm
Joel Sherrill
joel.sherrill at OARcorp.com
Mon Aug 13 18:06:07 UTC 2001
JSuchotzki at de.abb.com wrote:
>
> Hi,
> I try to get familiar with rtems. On this way I want to compile an
> application.
> The application uses the chsm (a "program" to simply implement a state
> machine).
> For more information chsm see
> http://homepage.mac.com/pauljlucas/software.html
>
> When I call make (debug) the following error is shown:
>
> make -f Makefile MAKEFILE=Makefile "ARCH=o-debug" \
> "CFLAGS_DEBUG=-Wno-unused -qrtems_debug -qrtems_debug" \
> "CXXFLAGS_DEBUG= -qrtems_debug" \
> "CFLAGS_OPTIMIZE=-g" \
> "LDFLAGS_DEBUG=" all
> make[1]: Entering directory `/home/jan/develop/experimental/chsm-pmueller'
> test -d o-debug || mkdir o-debug
> m68k-rtems-g++ -B/usr/local/rtems//m68k-rtems/efi332/lib/ -specs bsp_specs
> -qrtems -g -Wall -ansi -fasm -qrtems_debug -mcpu32
> -DPJL_NO_NAMESPACES -I/home/jan/develop/pecos_demo_III/component/inc -I.
> -c -o o-debug/main.o main.cpp
> In file included from ao.chsm:6,
> from main.cpp:7:
> AnalogOut.h:52: warning: `class AnalogOut' has virtual functions but
> non-virtual destructor
> In file included from main.cpp:7:
> ao.chsm:112: warning: `class ao::state_mode::state_operational' has virtual
> functions but non-virtual destructor
> ao.chsm:117: warning: `class ao::state_mode' has virtual functions but
> non-virtual destructor
> main.cpp: In method `int ObjectManager::initialize(ObjectManager *, int)':
> main.cpp:59: warning: control reaches end of non-void function
> `ObjectManager::initialize(ObjectManager *, int)'
> m68k-rtems-g++ -B/usr/local/rtems//m68k-rtems/efi332/lib/ -specs bsp_specs
> -qrtems -g -Wall -ansi -fasm -qrtems_debug -mcpu32
> -DPJL_NO_NAMESPACES -I/home/jan/develop/pecos_demo_III/component/inc -I.
> -c -o o-debug/AnalogOut.o AnalogOut.cpp
> In file included from AnalogOut.cpp:2:
> AnalogOut.h:52: warning: `class AnalogOut' has virtual functions but
> non-virtual destructor
> AnalogOut.cpp: In method `int AnalogOut::initialize(ObjectManager *)':
> AnalogOut.cpp:19: warning: control reaches end of non-void function
> `AnalogOut::initialize(ObjectManager *)'
> m68k-rtems-gcc --pipe -B/usr/local/rtems//m68k-rtems/efi332/lib/ -specs
> bsp_specs -qrtems -g -Wall -ansi -fasm -g -Wno-unused -qrtems_debug
> -qrtems_debug -mcpu32 -DPJL_NO_NAMESPACES
> -I/home/jan/develop/pecos_demo_III/component/inc -I. -L
> /usr/local/rtems//m68k-rtems/efi332/lib -o o-debug/ao.nxe
> o-debug/main.o o-debug/AnalogOut.o
> /usr/local/rtems//m68k-rtems/efi332/lib/no-dpmem_g.rel
> /usr/local/rtems//m68k-rtems/efi332/lib/no-mp_g.rel
> /usr/local/rtems//m68k-rtems/efi332/lib/no-signal_g.rel
> /usr/local/rtems//m68k-rtems/efi332/lib/librtems++_g.a -Lchsm -lchsm
> -L/home/jan/develop/pecos_demo_III/component/inc/lib -lPecosAuxiliaries
> -lstdc++
> collect2: ld terminated with signal 11 [Speicherzugriffsfehler], core
> dumped
> make[1]: *** [o-debug/ao.exe] Error 1
> make[1]: Leaving directory `/home/jan/develop/experimental/chsm-pmueller'
> make: *** [debug] Error 2
>
> Maybe someone knows if there is a general problem with linking chsm to
> rtems code.
> The error occures only when I try to link chsm. I have attached the
> Makefile.
> Some data about my system:
> Source: Pentium II, SuSE Linux 7.2, chsm compiler 2.4.3,
> rtems-ss-20010326
> Target: m68k
I can't see anything particularly weird about chsm offhand. My
first worry is that the warnings are catching up to you and tripping
some sort of bug in m68k-elf ld.
Does this compile cleanly natively? The gcc for RTEMS is just a
normal gcc targetting m68k.
Another thing to consider is that you probably REALLY
wanting to link with m68k-rtems-g++. Some BSPs have a
"make-cxx-exe" rule. Your makefile should use that
not the make-exe rule. You may have to add one to the efi332
BSP's efi332.cfg custom file.
> Thanks in advance
>
> Jan
>
> (See attached file: makefile-for-rtems-mailinglist.txt)
>
> ------------------------------------------------------------------------
> Name: makefile-for-rtems-mailinglist.txt
> makefile-for-rtems-mailinglist.txt Type: Plain Text (text/plain)
> Encoding: base64
--
Joel Sherrill, Ph.D. Director of Research & Development
joel at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
More information about the users
mailing list