Subject: Re: compat_netbsd32 problems
To: Raymond Meyer <raymond.meyer@rambler.ru>
From: Tobias Nygren <tnn@NetBSD.org>
List: port-sparc64
Date: 04/16/2007 10:12:33
Raymond Meyer wrote:
> Hi, I've got 32-bit sparc sets extracted into /emul/netbsd32. I'm trying to
> use /emul/netbsd32/usr/bin/gcc to compile 32-bit packages. I've come across the
> following problem:
>
> ultra10# /emul/netbsd32/usr/bin/gcc -Wl,-R/no/such/dir test.c; echo $?
> ld: /no/such/dir: No such file: No such file or directory
> 1
>
> but:
>
> ultra10# /usr/bin/gcc -Wl,-R/no/such/dir test.c; echo $?
> 0
>
> Many software packages pass linker options to gcc via -Wl compiler flag. It
> fails to compile because it complains about directories that don't exist. Any
> idea how to fix this?
>
> ultra10# uname -a
> NetBSD ultra10 4.99.16 NetBSD 4.99.16 (GENERIC) #0: Tue Apr 10 07:44:12 BST 2007  root@ultra10:/opt/obj.sparc64/sys/arch/sparc64/compile/GENERIC sparc64
>
>   

Looks like something is broken on a more basic level.
I ran in compat32 chroot:

# ls -la
total 8
drwxrwxrwt   2 root  wheel  512 Apr 16 10:07 .
drwxr-xr-x  20 root  wheel  512 Apr 13 17:54 ..
# touch test.c
touch: test.c: Inappropriate file type or format
# echo hello > test.c
# touch test.c
# ls -l test.c
-rw-r--r--  1 root  wheel  6 Apr 16 10:07 test.c

Sparc64 kernel is from yesterday, sparc userland from Feb 28.