kukugt / mupen64plus

Automatically exported from code.google.com/p/mupen64plus
0 stars 0 forks source link

Compatiblity issues on OS X and other non-linux systems #105

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
These are some changes required to build mupenplus on mac OS X PPC. These
changes could however apply to other systems than macs.

* glide64.patch fixes incorrect/outdated detection of mac computers
* oglft.patch contains the changes I needed to perform to get it to build.
I am unsure whether my changes would work on linux too though. It may be a
difference in implementation
* malloc.patch changes #include <malloc.h> into #include <stdlib.h> since
malloc.h is apparently not standard. Another way to fix this would be
including a flag like -I/usr/include/sys/, but this seems less portable to me
* makefiles.patch removes hardcoded flags from makefiles and makes them use
the ones from pre.mk instead (VERY important for compatibility with
different systems)
* glTypes casts C types into GL* types where needed. This is most likely
not needed on intel macs, though on some systems it could be. However, my
current patch casts the pointers. While this compiles correctly, it might
result in incorrect behaviour if casting between incompatible types. A
proper solution, if one is wished, would be to use GL* types like OpenGL
usually requires

Original issue reported on code.google.com by auria...@gmail.com on 7 Jun 2008 at 1:13

Attachments:

GoogleCodeExporter commented 8 years ago
Malloc patch unnecessary on trunk as of r810.

Original comment by sknau...@wesleyan.edu on 26 Jul 2008 at 5:08

GoogleCodeExporter commented 8 years ago
For this bit from pre.mk :

-PLUGIN_LDFLAGS = -Wl,-Bsymbolic -shared
+PLUGIN_LDFLAGS = -bundle

and maybe "-read_only_relocs suppress" too, the previous mac porter used that

-LIBGL_LIBS     = -L/usr/X11R6/lib -lGL -lGLU
+LIBGL_LIBS     = -framework OpenGL

Original comment by auria...@gmail.com on 27 Jul 2008 at 12:09

GoogleCodeExporter commented 8 years ago
Most of the OGLFT patch made unnecessary by r682. Totally unnecessary as of 
r820.

Original comment by sknau...@wesleyan.edu on 28 Jul 2008 at 4:00

GoogleCodeExporter commented 8 years ago
The glide64 patch is technically incorrect. The glide wrapper's macintosh 
support 
is for OS9. I think __APPLE__ (i.e. OSX) needs to be added to the UNIX OSes. 
Not 
100% sure about this.

Makefile patch (only patches plugin makefiles) unnecessary as of r819.

GlTyes patch won't be applied. We need to refactor into OpenGL types. Are we at 
the 
point where this can be marked fixed?

Original comment by sknau...@wesleyan.edu on 28 Jul 2008 at 4:08

GoogleCodeExporter commented 8 years ago
Great. 
The gltypes patch was more meant to point errors i guess

Before closing this, we'd need to add the needed changes to pre.mk

Original comment by auria...@gmail.com on 28 Jul 2008 at 11:39

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Okay, the pre.mk GL flags need to be changed in a way that doesn't break linux 
support. I.e. we can't use the -framework option without detecting OS X. 

Again the -bundle option is not cross-platform. I'm not 100% if we need 
-Bsymbolic 
on linux (looks like its depreciated) but I'm still hesitant to change it since 
we 
do some weird C/C++ mixing in plugins which might require odd overloading 
protection.

Original comment by sknau...@wesleyan.edu on 29 Jul 2008 at 7:43

GoogleCodeExporter commented 8 years ago
Yes, these patches were not meant to be applied directly but rather to show 
where
improvements need to be done

And indeed, the mix of C and C++ caused my problems, i needed to switch the 
linker
from gcc to g++

Original comment by auria...@gmail.com on 29 Jul 2008 at 11:35

GoogleCodeExporter commented 8 years ago
I've attached a cleaner OpenGL types patch. Hopefully this one should be 
portable and
clean enough to be acceptable.

I also added a small patch for Glide platform #if's.

Original comment by auria...@gmail.com on 20 Aug 2008 at 1:01

Attachments:

GoogleCodeExporter commented 8 years ago
Here's an improved OpenGL types patch

Original comment by auria...@gmail.com on 20 Aug 2008 at 1:29

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks for the patches. The glide one actually was rendered unnecessary by some 
recent work by Richard42 to fix our glide wrapper license issue (also fixed 
some 
automated regtest issues). 

I applied all the GLtypes patches, no problems on my linux box and commited as 
of 
r939.

As far as the NO_ASM issues, nobody has checked the plugins with the NO_ASM 
option 
in awhile. Rice won't compile on my machine without the SSE functions and glide 
gives errors in a lot of games.

Original comment by sknau...@wesleyan.edu on 27 Aug 2008 at 6:47

GoogleCodeExporter commented 8 years ago
A few bits of gltypes changes were lost - here they are.

Original comment by auria...@gmail.com on 29 Aug 2008 at 1:04

Attachments:

GoogleCodeExporter commented 8 years ago
As trunk now builds on OSX (pending some minor plugin work) this issue can be 
closed and all OSX porting discussion moved to 106.

Original comment by sknau...@wesleyan.edu on 11 Sep 2008 at 5:59