Mingw and PSIM build
Somervill, Kevin M. (LARC-D203)
kevin.m.somervill at nasa.gov
Thu Apr 16 19:15:04 UTC 2009
Hello again,
Looking into this further, found that I did not succeed in building halekala in mingw. I've got a linux box that I can build with (version 4.10, not 4.9) and I've noticed that on the linux system, I see the CPU_FLAGS and CFLAGS_OPTIMIZE_V (from psim.cfg) get passed to the compile command. On the windows box with mingw, these aren't passed along.
<snip from make/psim.cfg>
CPU_CFLAGS = -mcpu=603e -Dppc603e
#-ffunction-sections
# optimize flag: typically -O2
CFLAGS_OPTIMIZE_V = -O2 -g -fno-keep-inline-function
</snip>
The linux box generates the compile command with the expected additions (${CPU_CFLAGS} and ${CFLAGS_OPTIMIZE_V}).
powerpc-rtems4.10-gcc --pipe -B../../../lib/ -B../../../psim/lib/ -specs bsp_specs -qrtems -DPACKAGE_NAME=\"rtems-c-src\" -DPACKAGE_TARNAME=\"rtems-c-src\" -DPACKAGE_VERSION=\"4.9.99.0\" -DPACKAGE_STRING=\"rtems-c-src\ 4.9.99.0\" -DPACKAGE_BUGREPORT=\"http://www.rtems.org/bugzilla\" -I. -I../../../../../rtems-4.10/c/src/libchip -isystem ../../../psim/lib/include -D__INSIDE_RTEMS_BSD_TCPIP_STACK__ -Wall -Wimplicit-function-declaration -Wstrict-prototypes -Wnested-externs -mcpu=603e -Dppc603e -O2 -g -fno-keep-inline-functions -MT network/libnetchip_a-dec21140.o -MD -MP -MF network/.deps/libnetchip_a-dec21140.Tpo -c -o network/libnetchip_a-dec21140.o `test -f 'network/dec21140.c' || echo '../../../../../rtems-4.10/c/src/libchip/'`network/dec21140.c
Any suggestions as to what to chase down to fix this? Any reason why these flags aren't being passed along correctly in the mingw environment?
./ks
| -----Original Message-----
| From: rtems-users-bounces at rtems.org
| [mailto:rtems-users-bounces at rtems.org] On Behalf Of
| Somervill, Kevin M. (LARC-D203)
| Sent: Wednesday, April 15, 2009 12:05 PM
| To: rtems-users at rtems.com
| Subject: Mingw and PSIM build
|
| Hello,
| I'm trying to build powerpc/psim bsp in mingw and having some
| build issues. I can build the sparc/sis bsp and run the
| ticker and hello examples.
| I followed mingw install process on the wiki for rtems 4.9
| and the 4.9.2 source.
|
| I use the following configure command:
| $ ../rtems-4.9.2/configure --target=powerpc-rtems4.9
| --enable-rtemsbsp=psim --enable-posix --enable-cxx
| --enable-tests=samples
|
| Issuing make I get the following error:
|
| powerpc-rtems4.9-gcc --pipe -B../../../lib/
| -B../../../psim/lib/ -specs bsp_specs -qrtems
| -DPACKAGE_NAME=\"rtems-c-src\"
| -DPACKAGE_TARNAME=\"rtems-c-src\" -DPACKAGE_VERSION=\"4.9.2\"
| -DPACKAGE_STRING=\"rtems-c-src\ 4.9.2\"
| -DPACKAGE_BUGREPORT=\"http://www.rtems.org/bugzilla\" -I.
| -I../../../../../rtems-4.9.2/c/src/libchip
| -I../../../psim/lib/include
| -D__INSIDE_RTEMS_BSD_TCPIP_STACK__ -Wall -pipe -O2 -MT
| network/libnetchip_a-dec21140.o -MD -MP -MF
| network/.deps/libnetchip_a-dec21140.Tpo -c -o
| network/libnetchip_a-dec21140.o `test -f 'network/dec21140.c'
| || echo
| '../../../../../rtems-4.9.2/c/src/libchip/'`network/dec21140.c
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:
| In function 'dec21140IsOn':
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:34
| 7: warning: implicit declaration of function
| 'BSP_irq_enabled_at_i8259s'
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:
| In function 'dec21140Enet_initialize_hardware':
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:45
| 5: error: 'PCI_DRAM_OFFSET' undeclared (first use in this function)
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:45
| 5: error: (Each undeclared identifier is reported only once
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:45
| 5: error: for each function it appears in.)
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:
| In function 'dec21140_rxDaemon':
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:60
| 5: error: 'PCI_DRAM_OFFSET' undeclared (first use in this function)
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:
| In function 'sendpacket':
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:64
| 5: error: 'PCI_DRAM_OFFSET' undeclared (first use in this function)
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:
| In function 'rtems_dec21140_driver_attach':
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:99
| 8: error: 'PCI_MEM_BASE' undeclared (first use in this function)
| ../../../../../rtems-4.9.2/c/src/libchip/network/dec21140.c:10
| 00: warning: assignment from incompatible pointer type
| make[3]: *** [network/libnetchip_a-dec21140.o] Error 1
| make[3]: Leaving directory
| `/home/ksomervi/rtems/b-psim/powerpc-rtems4.9/c/psim/libchip'
| make[2]: *** [all-recursive] Error 1
| make[2]: Leaving directory
| `/home/ksomervi/rtems/b-psim/powerpc-rtems4.9/c/psim'
| make[1]: *** [all-recursive] Error 1
| make[1]: Leaving directory
| `/home/ksomervi/rtems/b-psim/powerpc-rtems4.9/c'
| make: *** [all-recursive] Error 1
|
| In dec21140.c both bsp.h and and libcpu/io.h are included.
| In the io.h, it says that PCI_DRAM_OFFSET is now defined in
| bsp.h, but this isn't in the psim/include/bsp.h How is
| PCI_DRAM_OFFSET to be pulled in? The other bsps seem to
| redefine the PREP_PCI_DRAM_OFFSET or CHRP_PCI_DRM_OFFSET and
| I can't find this for the psim bsp. I can build the
| haleakala bsp, but I can't build the coldfire mcf206elite bsp
| (only hardware I have on hand and I was hoping to play with
| it). Any suggestions? Should I suspect my build environment?
| I'm new to RTEMS and I'm hoping to fiddle my way through
| porting to the embedded planet ep405pc board. Hoping to use
| the haleakala as a starting point. I want to make sure I've
| got a sain environment and get familiar first.
|
| Thanks,
| ./ks
|
| --
| Kevin Somervill:757-864-6570:Computer Engineer:NASA/LaRC/SED/ESB
| - There's no such thing as beginner's luck...
| _______________________________________________
| rtems-users mailing list
| rtems-users at rtems.com
| http://rtems.rtems.org/mailman/listinfo/rtems-users
|
More information about the users
mailing list