OpenCores
no use no use 1/1 no use no use
uClinux build problem on Solaris-7
by Unknown on Jan 6, 2004
Not available!
I am trying to build uClinux from the CVS archives at opencores.org. I have followed the directions at http://www.opencores.org/tmp/cvsget_cache/or1k/uclinux/uClinux-2.0.x/README.or32 rather closely. A summary and comments follow: # To build toochain follow these steps mkdir /tmp/tools (I'm using /tools/local.uclinux) cd /tmp/tools mkdir or32-uclinux export PATH=/tmp/tools/or32-uclinux/bin:$PATH # # Binutils: # cvs -z9 co or1k/binutils cd or1k mkdir binutils-ucl cd binutils-ucl ../binutils/configure --target=or32-uclinux --prefix=/tmp/tools/or32-uclinux make all install cd ../../ binutils was configured, built, & installed without error. # # Gcc # cvs -z9 co or1k/gcc-3.1 cd or1k mkdir gcc-ucl cd gcc-ucl ../gcc-3.1/configure --target=or32-uclinux --prefix=/tmp/tools/or32-uclinux/ --local-prefix=/tmp/tools/or32-uclinux/or32-uclinux/ --with-gnu-as --with-gnu-ld --verbose --enable-languages=c make all install cd ../../ I originally tried to build with c & c++; that died. I then backed off to "C" only as above and was able to build & install. My tool dir now looks like: /tools/local.or32-uclinux/bin total 27652 1759878 2 drwxr-xr-x 2 psc sys 1024 Jan 5 14:17 ./ 1499327 2 drwxr-xr-x 9 psc sys 512 Jan 6 00:31 ../ 1759885 1984 -rwxr-xr-x 1 psc sys 1004134 Jan 3 16:45 or32-uclinux-addr2line* 1759881 1792 -rwxr-xr-x 2 psc sys 902038 Jan 3 16:45 or32-uclinux-ar* 1759890 2688 -rwxr-xr-x 2 psc sys 1366805 Jan 3 16:46 or32-uclinux-as* 1759889 368 -rwxr-xr-x 1 psc sys 177230 Jan 3 16:45 or32-uclinux-c++filt* 1759894 448 -rwxr-xr-x 1 psc sys 218432 Jan 5 14:17 or32-uclinux-cpp* 1759891 416 -rwxr-xr-x 1 psc sys 204391 Jan 3 16:46 or32-uclinux-gasp* 1759895 448 -rwxr-xr-x 1 psc sys 215001 Jan 5 14:17 or32-uclinux-gcc* 1759893 32 -rwxr-xr-x 1 psc sys 15683 Jan 5 14:17 or32-uclinux-gccbug* 1759897 160 -rwxr-xr-x 1 psc sys 81866 Jan 5 14:17 or32-uclinux-gcov* 1759892 2752 -rwxr-xr-x 2 psc sys 1398764 Jan 3 16:46 or32-uclinux-ld* 1759887 2016 -rwxr-xr-x 2 psc sys 1016736 Jan 3 16:45 or32-uclinux-nm* 1759884 2784 -rwxr-xr-x 1 psc sys 1414756 Jan 3 16:45 or32-uclinux-objcopy* 1759880 2896 -rwxr-xr-x 1 psc sys 1473740 Jan 3 16:45 or32-uclinux-objdump* 1759883 1792 -rwxr-xr-x 2 psc sys 902037 Jan 3 16:45 or32-uclinux-ranlib* 1759886 864 -rwxr-xr-x 1 psc sys 428971 Jan 3 16:45 or32-uclinux-readelf* 1759879 1696 -rwxr-xr-x 1 psc sys 858770 Jan 3 16:45 or32-uclinux-size* 1759882 1728 -rwxr-xr-x 1 psc sys 873130 Jan 3 16:45 or32-uclinux-strings* 1759888 2784 -rwxr-xr-x 2 psc sys 1414755 Jan 3 16:45 or32-uclinux-strip* test> or32-uclinux-gcc --version or32-uclinux-gcc (GCC) 3.2.3 Copyright (C) 2002 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. test> test> or32-uclinux-as --version GNU assembler 2.11.93 20020207 Copyright 2002 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. This assembler was configured for a target of `or32-uclinux'. test> I noticed that or32-uclinux-gcc can't compile & link a simple program like int main() { return(0); } because there is no crt0.o installed. But I'm ignoring this for now. # # Building uClinux # cvs -z9 co or1k/uclinux/uClinux-2.0.x/ cd or1k/uclinux/uClinux-2.0.x/ # Edit arch/or32/Rules.make file: # LIBGCC = /tmp/tools/or32-uclinux/lib/gcc-lib/or32-uclinux/3.1/libgcc.a make oldconfig make dep make cd ../../../ On Solaris-7 I noted that I have to set the environment variable BASH=/usr/local/bin/bash to get 'make oldconfig' to run without error. I then ran 'make dep' which seemed to run OK. I then ran 'make' which died. The log of which is attached. or32-uclinux-gcc -D__KERNEL__ -I/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include -Wall -Wst rict-prototypes -Werror-implicit-function-declaration -fomit-frame-pointer -fno-strength-reduce -O2 -g -pipe -DNO_MM -DNO_FPU -DMAGI C_ROM_PTR -DNO_FORGET -DUTS_SYSNAME='"uClinux"' -c -o serial.o serial.c In file included from /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/asm/termios.h:4, from /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/termios.h:5, from /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/tty.h:20, from /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/sched.h:33, from serial.c:34: /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:18: warning: conflicting ty pes for built-in function `strncpy' /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:20: warning: conflicting ty pes for built-in function `strncat' /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:30: warning: conflicting ty pes for built-in function `strncmp' /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:33: warning: conflicting ty pes for built-in function `memset' /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:34: warning: conflicting ty pes for built-in function `memcpy' /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:35: warning: conflicting ty pes for built-in function `memcmp' serial.c:343:1: warning: "REG8" redefined In file included from serial.c:59: /t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/asm/io.h:41:1: warning: this is the locati on of the previous definition serial.c: In function `console_print_or32': serial.c:361: warning: unused variable `c' serial.c: In function `set_multiport_struct': serial.c:2173: internal error: Segmentation Fault Please submit a full bug report, with preprocessed source if appropriate. See http://gcc.gnu.org/bugs.html> for instructions. make[3]: *** [serial.o] Error 1 make[3]: Leaving directory `/sd/c0t8d0/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/drivers/char' make[2]: *** [first_rule] Error 2 make[2]: Leaving directory `/sd/c0t8d0/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/drivers/char' make[1]: *** [sub_dirs] Error 2 make[1]: Leaving directory `/sd/c0t8d0/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/drivers' make: *** [linuxsubdirs] Error 2 The seg-fault concerns me. Is the gcc-3.2.3 compiler stable? I decided to use it after seeing a posting that indicated known problems with gcc-3.1. Any guidance here would be appreciated. Thanks Paul -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.opencores.org/forums/openrisc/attachments/20040106/0a8b8b08/attachment.htm
uClinux build problem on Solaris-7
by Unknown on Jan 6, 2004
Not available!
Paul, I had build problems with everything sim,gcc and uclinux. but the ATS script work beautifully for me..albeit on Linux. you might wanna give that one a shot. Cheers! Learner --- P Caaret opencores@usd.com> wrote:
I am trying to build uClinux from the CVS archives
at opencores.org.

I have followed the directions at
http://www.opencores.org/tmp/cvsget_cache/or1k/uclinux/uClinux-2.0.x/README.or32
rather closely. A summary and comments follow:

# To build toochain follow these steps

mkdir /tmp/tools


(I'm using /tools/local.uclinux)

cd /tmp/tools
mkdir or32-uclinux
export PATH=/tmp/tools/or32-uclinux/bin:$PATH

#
# Binutils:
#

cvs -z9 co or1k/binutils
cd or1k
mkdir binutils-ucl
cd binutils-ucl
../binutils/configure --target=or32-uclinux
--prefix=/tmp/tools/or32-uclinux
make all install
cd ../../


binutils was configured, built, & installed without
error.


#
# Gcc
#

cvs -z9 co or1k/gcc-3.1
cd or1k
mkdir gcc-ucl
cd gcc-ucl
../gcc-3.1/configure --target=or32-uclinux
--prefix=/tmp/tools/or32-uclinux/
--local-prefix=/tmp/tools/or32-uclinux/or32-uclinux/
--with-gnu-as --with-gnu-ld --verbose
--enable-languages=c
make all install
cd ../../


I originally tried to build with c & c++; that
died.
I then backed off to "C" only as above and was able
to build & install.
My tool dir now looks like:

/tools/local.or32-uclinux/bin
total 27652
1759878 2 drwxr-xr-x 2 psc sys 1024 Jan 5 14:17
./
1499327 2 drwxr-xr-x 9 psc sys 512 Jan 6 00:31
../
1759885 1984 -rwxr-xr-x 1 psc sys 1004134 Jan 3
16:45
or32-uclinux-addr2line*
1759881 1792 -rwxr-xr-x 2 psc sys 902038 Jan 3
16:45 or32-uclinux-ar*
1759890 2688 -rwxr-xr-x 2 psc sys 1366805 Jan 3
16:46 or32-uclinux-as*
1759889 368 -rwxr-xr-x 1 psc sys 177230 Jan 3
16:45
or32-uclinux-c++filt*
1759894 448 -rwxr-xr-x 1 psc sys 218432 Jan 5
14:17 or32-uclinux-cpp*
1759891 416 -rwxr-xr-x 1 psc sys 204391 Jan 3
16:46 or32-uclinux-gasp*
1759895 448 -rwxr-xr-x 1 psc sys 215001 Jan 5
14:17 or32-uclinux-gcc*
1759893 32 -rwxr-xr-x 1 psc sys 15683 Jan 5
14:17 or32-uclinux-gccbug*
1759897 160 -rwxr-xr-x 1 psc sys 81866 Jan 5
14:17 or32-uclinux-gcov*
1759892 2752 -rwxr-xr-x 2 psc sys 1398764 Jan 3
16:46 or32-uclinux-ld*
1759887 2016 -rwxr-xr-x 2 psc sys 1016736 Jan 3
16:45 or32-uclinux-nm*
1759884 2784 -rwxr-xr-x 1 psc sys 1414756 Jan 3
16:45
or32-uclinux-objcopy*
1759880 2896 -rwxr-xr-x 1 psc sys 1473740 Jan 3
16:45
or32-uclinux-objdump*
1759883 1792 -rwxr-xr-x 2 psc sys 902037 Jan 3
16:45
or32-uclinux-ranlib*
1759886 864 -rwxr-xr-x 1 psc sys 428971 Jan 3
16:45
or32-uclinux-readelf*
1759879 1696 -rwxr-xr-x 1 psc sys 858770 Jan 3
16:45 or32-uclinux-size*
1759882 1728 -rwxr-xr-x 1 psc sys 873130 Jan 3
16:45
or32-uclinux-strings*
1759888 2784 -rwxr-xr-x 2 psc sys 1414755 Jan 3
16:45
or32-uclinux-strip*

test> or32-uclinux-gcc --version
or32-uclinux-gcc (GCC) 3.2.3
Copyright (C) 2002 Free Software Foundation,
Inc.
This is free software; see the source for
copying conditions. There
is NO
warranty; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR
PURPOSE.

test>
test> or32-uclinux-as --version
GNU assembler 2.11.93 20020207
Copyright 2002 Free Software Foundation, Inc.
This program is free software; you may
redistribute it under the
terms of
the GNU General Public License. This program
has absolutely no
warranty.
This assembler was configured for a target of
`or32-uclinux'.
test>

I noticed that or32-uclinux-gcc can't compile & link
a simple program like

int
main()
{
return(0);
}

because there is no crt0.o installed. But I'm
ignoring this for now.

#
# Building uClinux
#

cvs -z9 co or1k/uclinux/uClinux-2.0.x/
cd or1k/uclinux/uClinux-2.0.x/
# Edit arch/or32/Rules.make file:
# LIBGCC =

/tmp/tools/or32-uclinux/lib/gcc-lib/or32-uclinux/3.1/libgcc.a
make oldconfig
make dep
make
cd ../../../

On Solaris-7 I noted that I have to set the
environment variable
BASH=/usr/local/bin/bash to get
'make oldconfig' to run without error.
I then ran 'make dep' which seemed to run OK.
I then ran 'make' which died. The log of which is
attached.

or32-uclinux-gcc -D__KERNEL__


-I/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include
-Wall -Wst
rict-prototypes
-Werror-implicit-function-declaration
-fomit-frame-pointer -fno-strength-reduce -O2 -g
-pipe -DNO_MM
-DNO_FPU -DMAGI
C_ROM_PTR -DNO_FORGET -DUTS_SYSNAME='"uClinux"'
-c -o serial.o serial.c
In file included from


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/asm/termios.h:4,
from


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/termios.h:5,
from


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/tty.h:20,
from


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/sched.h:33,
from serial.c:34:


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:18:
warning: conflicting ty
pes for built-in function `strncpy'


/t8/opt1/web/sites/www.opencores.org/openrisc_1000/cvs/or1k/uclinux/uClinux-2.0.x/include/linux/string.h:20:
warning: conflicting ty
pes for built-in function `strncat'

=== message truncated ===>
_______________________________________________
__________________________________ Do you Yahoo!? Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes http://hotjobs.sweepstakes.yahoo.com/signingbonus
no use no use 1/1 no use no use
© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.