Commit graph

65 commits

Author SHA1 Message Date
Sven Eckelmann
dccdaa03ee Allow to statically set SDL_(CFLAGS|LIBS) without sdl-config
n.pepinpe requested in #540 to allow overwriting the automatically searched
CFLAGS and LIBS for used libraries. This should allow distributors to set the
build configuration without patching the makefile. This is important for
systems were pkg-config or sdl-config aren't normally used.
2013-05-11 12:26:18 +02:00
Sven Eckelmann
ff73a2f421 Enable Link-time optimization by default
The GCC introduced Link-time optimization in GCC 4.5 (2010-04-14). This should
be long enough available that interested users have upgraded to a compiler
supporting it.

The MSVC project already enabled WholeProgramOptimization since a long time.
Enabling it by default in GCC seems to be equally valid.
2013-05-11 11:25:56 +02:00
Sven Eckelmann
ef07d7d1c7 Add CFLAGS to the linker step
The GCC manual states for different parameters that the options for compilation
must also be used when linking. The options for compilation are stored in
CFLAGS and added to LINK.o to fix the behavior.

Option which need this are for example -fPIC/-fPIE or -flto.
2013-05-11 10:51:36 +02:00
richard42
f7532d62cd OSX build fix 2013-02-02 22:16:48 -08:00
Sven Eckelmann
aa3e838d0a Introduce WARNFLAGS for default (removable) compiler warning flags 2013-01-02 16:13:45 +01:00
n pepinpe
f8827b148a Fix path to OSX SDK with XCode >=4.3 2012-12-31 10:43:00 +01:00
Richard Goedeken
b7ce0a97a4 merged heads 2012-12-30 15:48:49 -08:00
Anthony J. Bentley
c17d2bae69 Decompress the manual page. 2012-12-24 02:43:03 -07:00
Sven Eckelmann
42f26b8a03 Use $(OBJDIR) in clean target instead of hardcoded path 2012-12-13 14:53:05 +01:00
Sven Eckelmann
14af485493 Allow to add a postfix for each build
The POSTFIX make option is useful for distributions to compile different
versions of the plugin in parallel. The object files will be stored in a
directory with the postfix appended and the linker result will also have this
postfix appended.
2012-12-13 14:47:33 +01:00
Sven Eckelmann
25217eacdd Fix clean of mupen64plus.exe 2012-12-13 14:19:37 +01:00
Sven Eckelmann
3b7bee6a33 Add CROSS_COMPILE make option
The CROSS_COMPILE make option can be used to automatically prepend the prefix
to all build relevant tools to seamlessly allow cross compilation without
setting each tool name separately.

Cross compiling for MinGW32 would can be done using
$ make -C projects/unix/ CROSS_COMPILE=i686-pc-mingw32- HOST_CPU=i686 UNAME=MINGW
2012-12-13 12:25:38 +01:00
Sven Eckelmann
10b90e4647 Allow to change names of *-config tools for cross compiles 2012-12-13 11:33:49 +01:00
Sven Eckelmann
08b53f2444 Synchronize usage of environmental variables for UNAME with HOST_CPU 2012-12-13 10:52:49 +01:00
Sven Eckelmann
68a5b42c15 Remove duplicated definition of CC for MinGW 2012-12-13 10:46:17 +01:00
Sven Eckelmann
bbe021bc01 Really build mupen64plus.exe on MinGW 2012-12-12 23:19:39 +01:00
veganaize
b65642a899 Add support for MingW32 2012-12-04 21:17:52 +01:00
Anthony J. Bentley
79e0f12a6a Detect OpenBSD PowerPC platforms macppc and socppc. 2012-11-12 18:03:52 -07:00
Sven Eckelmann
b05ff7522a Add configuration for semi-supported architecture armel 2012-11-04 01:26:41 +01:00
Sven Eckelmann
56159acc29 Enable experimental support for link-time optimization 2012-06-09 01:11:18 +02:00
Sven Eckelmann
e24f33b2c7 Remove additional -O3 on MacOSX 2011-10-14 19:58:42 +02:00
Sven Eckelmann
042700252e Explicitly disable PIC in case of PIC=0 2011-10-13 00:01:02 +02:00
Sven Eckelmann
db675f1052 Enable ppc(64) as experimental target
nogagplz tested mupen64plus on 32-bit ppc and didn't detect any big show
stoppers with interpreter cores and the mupen64plus example rom. This makes the
PowerPC an interesting target for further tests and may reveal other endianness
problems.
2011-08-05 10:46:16 +02:00
Sven Eckelmann
2894af52e3 Enable big endian mode on ppc and ppc64 2011-08-05 10:19:21 +02:00
Sven Eckelmann
c33e0725b1 Strip binaries during install 2011-07-23 21:22:52 +02:00
Sven Eckelmann
a755ced05a Allow PIE similar to PIC in the plugins 2011-07-10 13:23:40 +02:00
Sven Eckelmann
71b99273f8 Fix linker search for libstdc++.so 2011-07-08 08:24:36 +00:00
Sven Eckelmann
414ba078a3 Inform user about the possibility to make the build verbose 2011-07-03 18:04:48 +02:00
Sven Eckelmann
851ba40977 Set changeable default compiler optimization option 2011-07-03 18:03:15 +02:00
Sven Eckelmann
9772c338a2 Remove mupen64plus.6.gz in uninstall target 2011-06-27 13:21:45 +02:00
Sven Eckelmann
2acfd02362 Synchronize build rules with standard gnu make rules 2011-06-27 13:00:04 +02:00
Sven Eckelmann
ccfea343af Add OpenBSD as half-supported OS with FreeBSD userspace tools 2011-06-26 18:37:19 +02:00
Sven Eckelmann
f9c62d0081 Remove -v parameter of install which is not available everywhere 2011-06-26 18:29:25 +02:00
Sven Eckelmann
6b5de19fe7 Use FHS directory PREFIX/share/man as default man root dir 2011-06-26 02:21:18 +02:00
Sven Eckelmann
0f679f3a53 Only allow to configure man top level in install target 2011-06-26 02:02:22 +02:00
Sven Eckelmann
f4a9e8699f Fix compilation with BITS=32 when using gcc-4.6 2011-06-25 21:29:58 +02:00
Sven Eckelmann
082aba7f75 Don't override optimisations set by linux build environment 2011-06-25 11:56:03 +02:00
Sven Eckelmann
753373768e Use -pthread gcc option to support systems with differently named pthread library 2011-06-25 10:33:27 +02:00
Sven Eckelmann
ded3973463 Add GNU/Hurd as operating system with "linux" userland
---
2010-07-13 21:33:36 +02:00
Richard Goedeken
f79205201e FreeBSD makefile patches from David Demelier 2010-05-16 12:47:07 -04:00
Sven Eckelmann
9e015d30a8 Build kfreebsd and GNU/kFreeBSD like Linux 2010-03-19 12:16:37 +01:00
Sven Eckelmann
adb7b2e44c Reduced console output when running make without V=1 2010-03-18 10:59:21 +01:00
Sven Eckelmann
b1570a4b2c Use separate CXXFLAGS environment variable when calling CXX 2010-03-18 10:10:50 +01:00
Richard Goedeken
d07cf9f8a2 add pthread back into link libs, so running in the debugger works 2010-03-05 12:58:16 -05:00
Sven Eckelmann
94877f6b77 Add automatically dependency tracking for C/C++ files
Every time a header is changed, the user had to cleanup the whole project and
then rebuild it. It is quite easy to fix and should help a lot when working on
the project. The dependency files will be created at the first run (when
dependency tracking isn't useful anyway) and should create nearly no overhead.
2010-03-04 22:52:18 +01:00
Richard Goedeken
37550982da makefile updates: use CFLAGS+= instead of CFLAGS=, rmdir _obj, add APIDIR to targets help 2010-02-20 11:08:14 -05:00
Richard Goedeken
3b0d8c7317 add pthread to libs when linking so that GDB will run the emulator without throwing up a warning/error right after starting: Cannot find new threads: generic error 2010-01-26 23:48:36 -05:00
Richard Goedeken
5951bba95e bugfix #257: added to makefile OS type GNU/kFreeBSD 2010-01-20 21:57:41 -05:00
Richard Goedeken
945aea3c7b Makefile improvements: throw error if OS/CPU not supported, use DESTDIR in install/uninstall paths, per Lazhur request. Allow user-specified CC/CXX/LD paths, per Auria request 2009-12-19 20:09:42 -05:00
Richard Goedeken
a3fa1b7969 makefile fix for install target; MANDIR wasnt set by default 2009-12-14 11:31:44 -05:00