[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

silo problem



Ciao,
	I'm still trying to have a silo working with glibc.

I had some problems, with some assembler code.

There is a file, called jmp.S which defines the symbol
__setjmp, which is also defined in /usr/lib/libc.a

So, when it is time to link silo, I had this error:
/usr/lib/libc.a(setjmp.o): In function `_setjmp':
setjmp.o(.text+0x0): multiple definition of `__setjmp'
jmp.o(.text+0x0): first defined here
make: *** [second] Error 1


This is the jmp.S file:

/* setjmp/longjmp code 
   [skipping copyright statement]
*/

#define _SV save %sp, -0x40, %sp
#define _RV restore
#define FLUSH_ALL_WINDOWS \
	_SV; _SV; _SV; _SV; _SV; _SV; _SV; \
	_RV; _RV; _RV; _RV; _RV; _RV; _RV;

	/* Save our return PC and SP.  */
	.global __setjmp, setjmp
setjmp:
__setjmp:
	st %o7, [%o0]
	st %sp, [%o0 + 4]
	retl
	clr %o0

	.global __longjmp, longjmp
longjmp:
__longjmp:
	/* Flush register windows.
	   Write all the register windows to their stack slots, and
	   mark them all as invalid (needing to be sucked up from the
	   stack when used).  This ensures that all information needed to
	   unwind to these callers is in memory, not in the register
	   windows.  */
	FLUSH_ALL_WINDOWS
	ld [%o0], %o7		/* Return PC.  */
	ld [%o0 + 4], %fp	/* Saved SP.  */
	sub %fp, 64, %sp	/* Allocate a register save area.  */
	tst %o1
	be,a 1f
	mov 1, %o1
1:	retl
	/* On the way out, put the return value in %o0.  */
	restore %o1, 0, %o0


So, what I have to do? I can change the symbol in jmp.S, but
I got a warning:

BFD: sta13957: warning: allocated section `.bss' not in segment

anyway, it compiles succesfully, but it doesn't work

paci@test> ./silo
Fatal: cannot read superblock on /dev/sd (READ_ONLY)

even if I'm root.


Any help, would be appreciated.

Thanks
-- 
Davide Barbieri - paci@linux.it - paci@debian.org (Sparc Debian)
PGP fingerprint =  CD 8D A9 1E DB 0C B0 16  F8 2F BF 63 52 49 8B A8
-- 
Davide Barbieri - paci@linux.it - paci@debian.org (Sparc Debian)
PGP fingerprint =  CD 8D A9 1E DB 0C B0 16  F8 2F BF 63 52 49 8B A8


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-sparc-request@lists.debian.org . 
Trouble?  e-mail to templin@bucknell.edu .


Reply to: