OpenCores
no use no use 1/1 no use no use
or1ksim make all error
by Juzujka on Dec 22, 2011
Juzujka
Posts: 6
Joined: Dec 8, 2009
Last seen: Jul 23, 2023
I use
- Ubuntu 11.10
- GCC 4.5.1
I've download stable release or1ksim-0.4.0 from
http://opencores.org/openrisc,file,b3Ixa3NpbS0wLjQuMC50YXIuYnoy

then run:

tar jxf or1ksim-0.4.0.tar.bz2
cd or1ksim-0.4.0/
mkdir builddir_or1ksim
cd builddir_or1ksim
../configure --target=or32-elf --prefix=/opt/or1ksim
make all

and here is error after Making all in common:

In file included from ../../../cpu/common/abstract.c:33:0:
../../../port/port.h:41:8: error: expected identifier or «(» before «__extension__»
make[3]: *** [abstract.lo] error 1

the code in port.h

#ifndef HAVE_STRNDUP
char * strndup (const char *s, size_t n);
#endif
RE: or1ksim make all error
by Juzujka on Dec 22, 2011
Juzujka
Posts: 6
Joined: Dec 8, 2009
Last seen: Jul 23, 2023
or1ksim0.5.0 gives the same error:

tar jxf or1ksim-0.5.0rc2.tar.bz2
mkdir builddir_or1ksim
cd builddir_or1ksim
../or1ksim-0.5.0rc2/configure --target=or32-uclinux
make check

In file included from ../../../or1ksim-0.5.0rc2/cpu/common/abstract.c:33:0:
../../../or1ksim-0.5.0rc2/port/port.h:41:8: о�ибка: expected identifier or «(» before «__extension__»
make[2]: *** [abstract.lo] ��ибка 1
RE: or1ksim make all error
by jeremybennett on Dec 22, 2011
jeremybennett
Posts: 815
Joined: May 29, 2008
Last seen: Jun 13, 2019
or1ksim0.5.0 gives the same error:

tar jxf or1ksim-0.5.0rc2.tar.bz2
mkdir builddir_or1ksim
cd builddir_or1ksim
../or1ksim-0.5.0rc2/configure --target=or32-uclinux
make check

In file included from ../../../or1ksim-0.5.0rc2/cpu/common/abstract.c:33:0:
../../../or1ksim-0.5.0rc2/port/port.h:41:8: �¾���¸�±�º�°: expected identifier or �«(�» before �«__extension__�»
make[2]: *** [abstract.lo] �����¸�±�º�° 1

Hi Juzujka

I am not sure where these instructions came from. Would you try again using

    mkdir builddir_or1ksim
    cd builddir_or1ksim
    ../or1ksim-0.5.0rc2/configure --target=or32-elf
    make
    

If you still get errors, please retry using the latest Or1ksim from SVN.

Since you have many questions, you may find it quicker to use IRC to get your answers. Look for channel #opencores on freenode.net.

HTH

Jeremy

RE: or1ksim make all error
by Juzujka on Dec 22, 2011
Juzujka
Posts: 6
Joined: Dec 8, 2009
Last seen: Jul 23, 2023
I am not sure where these instructions came from. Would you try again using

    mkdir builddir_or1ksim
    cd builddir_or1ksim
    ../or1ksim-0.5.0rc2/configure --target=or32-elf
    make
    

error again:

Making all in common
make[3]: Entering directory `/home/aska/My_Designs/DigRec3/FPGA_OpenRISC/SW/or1ksim/builddir_or1ksim-0.5.0rc2/cpu/common'
/bin/bash ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I../../../or1ksim-0.5.0rc2/cpu/common -I../.. -I../../cpu/or32 -I../../../or1ksim-0.5.0rc2 -I../../../or1ksim-0.5.0rc2/cpu/common -I../../../or1ksim-0.5.0rc2/cpu/or1k -I../../../or1ksim-0.5.0rc2/cache -I../../../or1ksim-0.5.0rc2/mmu -I../../../or1ksim-0.5.0rc2/bpb -I../../../or1ksim-0.5.0rc2/peripheral -I../../../or1ksim-0.5.0rc2/tick -I../../../or1ksim-0.5.0rc2/peripheral/channels -I../../../or1ksim-0.5.0rc2/pm -I../../../or1ksim-0.5.0rc2/pic -I../../../or1ksim-0.5.0rc2/debug -I../../../or1ksim-0.5.0rc2/vapi -I../../../or1ksim-0.5.0rc2/support -I../../../or1ksim-0.5.0rc2/cuc -I../../../or1ksim-0.5.0rc2/port -I../../../or1ksim-0.5.0rc2/argtable2 -I../../../or1ksim-0.5.0rc2/softfloat -g -Wall -Werror -O2 -DOR32 -g -O2 -MT abstract.lo -MD -MP -MF .deps/abstract.Tpo -c -o abstract.lo ../../../or1ksim-0.5.0rc2/cpu/common/abstract.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../../../or1ksim-0.5.0rc2/cpu/common -I../.. -I../../cpu/or32 -I../../../or1ksim-0.5.0rc2 -I../../../or1ksim-0.5.0rc2/cpu/common -I../../../or1ksim-0.5.0rc2/cpu/or1k -I../../../or1ksim-0.5.0rc2/cache -I../../../or1ksim-0.5.0rc2/mmu -I../../../or1ksim-0.5.0rc2/bpb -I../../../or1ksim-0.5.0rc2/peripheral -I../../../or1ksim-0.5.0rc2/tick -I../../../or1ksim-0.5.0rc2/peripheral/channels -I../../../or1ksim-0.5.0rc2/pm -I../../../or1ksim-0.5.0rc2/pic -I../../../or1ksim-0.5.0rc2/debug -I../../../or1ksim-0.5.0rc2/vapi -I../../../or1ksim-0.5.0rc2/support -I../../../or1ksim-0.5.0rc2/cuc -I../../../or1ksim-0.5.0rc2/port -I../../../or1ksim-0.5.0rc2/argtable2 -I../../../or1ksim-0.5.0rc2/softfloat -g -Wall -Werror -O2 -DOR32 -g -O2 -MT abstract.lo -MD -MP -MF .deps/abstract.Tpo -c ../../../or1ksim-0.5.0rc2/cpu/common/abstract.c -fPIC -DPIC -o .libs/abstract.o
In file included from ../../../or1ksim-0.5.0rc2/cpu/common/abstract.c:33:0:
../../../or1ksim-0.5.0rc2/port/port.h:41:8: error: expected identifier or '(' before '__extension__'
make[3]: *** [abstract.lo] Error 1


If you still get errors, please retry using the latest Or1ksim from SVN.

HTH

Jeremy

    svn co http://opencores.org/ocsvn/openrisc/openrisc/trunk/or1ksim
    mkdir builddir_or1ksim
    cd builddir_or1ksim
    ../or1ksim/configure --target=or32-elf
    make
    sudo make install
    
build successfully, thank you!
no use no use 1/1 no use no use
© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.