Open GoogleCodeExporter opened 9 years ago
Upgraded O/S to 10.5.8 and Xcode from 2.? to 3.1.
Now works.
I believe those functions in "fpuctl.h" should be "static" at least, possibly
"static __inline__" like others in the file.
Original comment by stevej...@gmail.com
on 26 Aug 2011 at 2:27
My mistake, not fixed...
Thought I'd reverted "os.c", but hadn't.
Started from a fresh install into /usr/inferno, "hg pull -uv", "mk install",
then fail the same conflict:
ld: duplicate symbol _setfcr in
/usr/inferno/MacOSX/power/lib/libmath.a(FPcontrol-MacOSX.o) and os.o
gcc --version
powerpc-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5493)
Copyright (C) 2005 Free Software Foundation, Inc.
Original comment by stevej...@gmail.com
on 26 Aug 2011 at 5:44
The functions are static in my copy of fpuctl.h
Original comment by Charles....@gmail.com
on 26 Aug 2011 at 10:51
sorry: it wasn't clear that "my copy" meant "the mercurial archive that's the
primary for googlecode and there aren't any changes noted"
Original comment by Charles....@gmail.com
on 26 Aug 2011 at 10:53
inferno-os@googlecode.com wrote on 27/08/11 8:57 AM:
In my up-to-date version, the 386 include file has 'static' functions,
the powerpc doesn't.
==============================================================
Mac-mini:inferno steve$ pwd
/usr/inferno
Mac-mini:inferno steve$ hg pull
pulling from https://inferno-os.googlecode.com/hg
searching for changes
no changes found
Mac-mini:inferno steve$ less MacOSX/386/include/fpuctl.h
MacOSX/power/include/fpuctl.h
==========================
/*
* Linux 386 fpu support
* Mimic Plan9 floating point support
*/
static void
setfcr(ulong fcr)
---
static ulong
getfcr(void)
{
---
static ulong
getfsr(void)
{
---
static ulong
getfsr(void)
{
----
static void
setfsr(ulong fsr)
{
==========================
versus
==========================
/*
* MacOSX/Darwin ppc fpu support
* Mimic Plan9 floating point support
*/
#include <architecture/ppc/fp_regs.h>
static __inline__ ulong
getfcr(void)
{
---
ulong
getfsr(void)
{
---
void
setfsr(ulong fsr)
{
Original comment by stevej...@gmail.com
on 27 Aug 2011 at 12:46
This is still an issue
As mentioned earlier the attached patch sets the functions declared in
MacOSX/power/include/fpuctl.h to static __inline__
This resolved the build issue I experienced when trying to build the latest
source on OS X 10.4.11 running on a PowerBook G4
You can confirm the functions are not set to static from here
https://code.google.com/p/inferno-os/source/browse/MacOSX/power/include/fpuctl.h
Original comment by ventur...@gmail.com
on 14 Jun 2014 at 11:21
Attachments:
Original issue reported on code.google.com by
stevej...@gmail.com
on 22 Aug 2011 at 4:48