Port-mips archive

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

build playstation2 kernel?



I see a recent update that touched

  "sys/arch/playstation2/playstation2/interrupt.c"

with a commit message including the phrase "Make this compile again".

So, I hoped I might actually be able to build GENERIC for playstation2
(kernels have been unbuildable ever since MIPS-R5900 support returned
to GCC.  I've been building distribution and sets routinely, but kernels
have remained elusive).

Alas, no joy.  The build fails in "interrupt.c" with:

[...]
#   compile  GENERIC/interrupt.o
/r0/build/current/tools/amd64/bin/mipsel--netbsd-gcc -mabi=n32 -march=r5900 -fno-pic -msoft-float -G 0 -mno-abicalls -msoft-float -ffixed-24 -ffreestanding -fno-zero-initialized-in-bss -fno-delete-null-pointer-checks -Os -mmemcpy -fstack-usage -Wstack-usage=3584 -fno-strict-aliasing -fno-common -std=gnu99 -Werror -Wall -Wno-main -Wno-format-zero-length -Wpointer-arith -Wmissing-prototypes -Wstrict-prototypes -Wold-style-definition -Wswitch -Wshadow -Wcast-qual -Wwrite-strings -Wno-unreachable-code -Wno-pointer-sign -Wno-attributes -Wno-sign-compare -Walloca -Wno-address-of-packed-member --sysroot=/r0/build/current/DEST/playstation2 -Dplaystation2 -I. -I/x/current/src/sys/external/bsd/libnv/dist -I/x/current/src/sys/../common/lib/libx86emu -I/x/current/src/sys/../common/lib/libc/misc -I/x/current/src/sys/../common/include -I/x/current/src/sys/arch -I/x/current/src/sys -nostdinc -DCOMPAT_UTILS -DMIPS3 -DMIPS3_5900 -DIPL_ICU_MASK -DSOFTFLOAT -D__NO_LEADING_UNDERSCORES__ -D__GP_SUPPORT__ -D_KERNEL -D_KERNEL_OPT -std=gnu99 -I/x/current/src/sys/lib/libkern/../../../common/lib/libc/quad -I/x/current/src/sys/lib/libkern/../../../common/lib/libc/string -I/x/current/src/sys/lib/libkern/../../../common/lib/libc/arch/mips/string -I/x/current/src/sys/lib/libkern/../../../common/lib/libc/arch/mips/atomic -I/x/current/src/sys/lib/libkern/../../../common/lib/libc/hash/sha3 -I/x/current/src/sys/external/bsd/libnv/dist -c /x/current/src/sys/arch/playstation2/playstation2/interrupt.c -o interrupt.o
/x/current/src/sys/arch/playstation2/playstation2/interrupt.c:154:1: error: no previous prototype for 'setsoft' [-Werror=missing-prototypes]
  154 | setsoft(int ipl)
      | ^~~~~~~
/x/current/src/sys/arch/playstation2/playstation2/interrupt.c:203:1: error: no previous prototype for 'splset' [-Werror=missing-prototypes]
  203 | splset(int npl)
      | ^~~~~~
/x/current/src/sys/arch/playstation2/playstation2/interrupt.c: In function 'spl0':
/x/current/src/sys/arch/playstation2/playstation2/interrupt.c:218:2: error: implicit declaration of function '_spllower'; did you mean 'islower'? [-Werror=implicit-function-declaration]
  218 |  _spllower(0);
      |  ^~~~~~~~~
      |  islower
cc1: all warnings being treated as errors

*** Failed target: interrupt.o
*** Failed commands:
        ${NORMAL_C}
*** [interrupt.o] Error code 1

nbmake: stopped in /r0/build/current/obj/playstation2/sys/arch/playstation2/compile/GENERIC
1 error

nbmake: stopped in /r0/build/current/obj/playstation2/sys/arch/playstation2/compile/GENERIC

ERROR: Failed to make all in "/r0/build/current/obj/playstation2/sys/arch/playstation2/compile/GENERIC"
*** BUILD ABORTED ***


I'm not sure why its complaining about "no previous prototype" for
"setsoft()" or "splset()" as it's parsing the function definitions
themselves.  "setsoft()" is not used anywhere in "interrupt.c" and
"splset()" is used just after its definition.

Can't speak to "_spllower()".  It doesn't seem to be defined anywhere
in the MD playstation2 subtree.

I seem to recall a lot of MIPS-related refactoring during the period
when GCC lacked MIPS-R5900 support, but playstation2 has mostly not
been updated to match.

-- 
|/"\ John D. Baker, KN5UKS               NetBSD     Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net  OpenBSD            FreeBSD
| X  No HTML/proprietary data in email.   BSD just sits there and works!
|/ \ GPGkeyID:  D703 4A7E 479F 63F8 D3F4  BD99 9572 8F23 E4AD 1645


Home | Main Index | Thread Index | Old Index