Commit graph

343 commits

Author SHA1 Message Date
Zachary J. Slater
87eecd7bc1 Merge pull request #290 from rcgordon/autoupdater
Initial shot at writing an ioquake3 autoupdater. Thank you icculus, and everyone who contributed to his patreon! https://www.patreon.com/icculus
2017-06-02 22:46:22 -10:00
Ryan C. Gordon
0eb497b01b Disable the autoupdater; enable only if intentional, like for official builds. 2017-06-02 02:29:09 -04:00
Ryan C. Gordon
063875e89a Fixed linking on things that need -ldl, and compiler warnings. 2017-06-02 01:39:03 -04:00
Ryan C. Gordon
82977da9c8 Working Windows port of the autoupdater! 2017-06-02 00:49:42 -04:00
Ryan C. Gordon
d0da0724e7 Move the autoupdater launcher into its own public domain source file.
So other games can steal this piece if they want.
2017-05-31 01:22:40 -04:00
Ryan C. Gordon
f518f75149 Don't link directly to libcurl.
Lots of Linux distros have different names (libcurl-gnutls.so vs etc), and
version the symbols (curl_global_init@@CURL_LIBSSL_3), so it's more compatible
to just dlsym the basic entry points we need and just demand that libcurl is
installed at all.

Alternately: we'll use our own libcurl build, but we'll probably have to dump
SSL support to make this sane to do.
2017-05-30 20:15:59 -04:00
Ryan C. Gordon
86e71b11eb Fixed failure to link libcurl on some platforms. 2017-05-30 17:39:13 -04:00
Ryan C. Gordon
240965ddbc Removed extraneous '\' in Makefile in autoupdater source file list. 2017-05-25 22:02:33 -04:00
Ryan C. Gordon
8e001e6b99 autoupdater should build with $(CC), not $(TOOLS_CC), in Makefile. 2017-05-25 22:01:47 -04:00
Ryan C. Gordon
4729c683fd Initial shot at writing an ioquake3 autoupdater. 2017-05-25 14:13:18 -04:00
Zack Middleton
abce15055c Fix compiling Mac OS 10.5 Universal App Bundle
Need to be able to specify minimum Mac OS X version outside of the
Makefile to avoid conflicting CFLAGS.
Moved -mmacosx-version-min LDFLAGS into the Makefile.
Moved -arch x86_64 from OPTIMIZEVM to CFLAGS to fix linker errors
(previously make-macosx-ub.sh passed it to CFLAGS manually).
2017-05-24 15:50:44 -05:00
Zack Middleton
f4739e9c4d Rename (already updated) opusfile-0.5 to opusfile-0.8 2017-05-23 11:47:27 -05:00
Zack Middleton
ef8ad54421 Rename (already updated) opus-1.1 to opus-1.1.4 2017-05-23 11:47:27 -05:00
Zack Middleton
853110d5d4 Update opus from 1.1 to 1.1.4
Define FLOAT_APPROX in Makefile and misc/msvc12/quake3.vcxproj.
2017-05-23 11:47:26 -05:00
Zack Middleton
67bfe8f8d6 Rename (already updated) libvorbis-1.3.4 to libvorbis-1.3.5 2017-05-23 11:47:26 -05:00
Zack Middleton
d87bd792c3 Rename (already updated) libogg-1.3.1 to libogg-1.3.2 2017-05-23 11:47:26 -05:00
Dan Church
537d28556f
Fix build when cloned as submodule
Steps to reproduce:

    git init
    git submodule add -b master git://github.com/ioquake/ioq3.git
    cd ioq3
    make USE_GIT=1
2017-03-30 16:10:40 -05:00
Dominic Fandrey
a47ac2a451 Use -On level from CFLAGS on FreeBSD 2017-03-28 13:09:42 +02:00
Dominic Fandrey
7a237c8020 Do not pull CFLAGS into BASE_CFLAGS on FreeBSD 2017-03-28 13:09:42 +02:00
Eugene Molotov
864f66a1c0 Makefile: using generic windres if specific one is not present in mingw platform 2017-03-23 20:34:27 +05:00
Zachary J. Slater
6e4e6e8925 Merge pull request #91 from lnussel/master
a VM for ARMv7l (Thank you, Ludwig -zjs)
2017-01-24 19:27:13 -10:00
Zack Middleton
7a73646157 Prefer mingw-w64 for cross-compiling 2016-11-01 17:44:40 -05:00
Tim Angus
cce24668f7 Merge pull request #225 from smcv/reproducible-date
Pick up date from SOURCE_DATE_EPOCH, for reproducible builds
2016-09-27 21:05:24 +01:00
Simon McVittie
9c76b546e3 Pick up date from SOURCE_DATE_EPOCH, for reproducible builds
The goal of reproducible builds is that a rebuild of the same source
code with the same compiler, libraries, etc. should result in the same
binaries. SOURCE_DATE_EPOCH provides a standard way for build systems
to fill in the date of the latest source change, typically from a git
commit or from metadata like the debian/changelog in Debian packages.

This does not change anything if SOURCE_DATE_EPOCH is not defined;
the intention is that a larger build system like a Debian package
will define it.

Please see https://reproducible-builds.org/ for more information about
reproducible builds.
2016-09-22 09:02:20 +01:00
Simon McVittie
cab94d0559 Introduce NOTSHLIBLDFLAGS, used to link executables only
This can be used for LDFLAGS that would be inappropriate for shared
libraries, such as the "-fPIE -pie" used to link position-independent
executables. PIEs make it more difficult to exploit various classes
of security vulnerability.
2016-09-22 08:58:18 +01:00
Zack Middleton
0ad4381a11 Make using Yacc optional, disabled by default
A built-in GNU Make rule causes code/tools/lcc/lburg/gram.y to replace
gram.c if gram.y has a newer modified time. This causes git diff to
pick up changes to gram.c, which seems to have been manually modified
to fix warnings and may vary by Yacc used to create it. It also
requires installing a program to generate a file that already exists
in a usable state in the code repository.

So replace the built-in rule so it is only used if USE_YACC is 1
(defaults to 0). The Yacc executable name can be overriden using
`make YACC=yacc` like before.

I preferred to touch gram.c instead of installing Yacc because of the
problems it causes. It doesn't really seem like a good idea to recommend
others do that instead of disabling Yacc the Makefile though.
2016-07-11 07:51:34 -05:00
Victor Roemer
398dea397c Fix Makefile for OSX
Bump base SDK from 10.5 -> 10.7
Just use the builtin __APPLE__
2016-06-12 17:17:33 -04:00
Zack Middleton
d8afce6805 Cross-compiling using mingw should only pick one gcc executable
If multiple mingw toolchains are installed, the Makefile set CC to all
present gcc executables. Pick only the first one instead of passing the
others as arguments.

"CC: /usr/bin/i686-w64-mingw32-gcc /usr/bin/i686-pc-mingw32-gcc"
2016-05-08 20:17:39 -05:00
SmileTheory
275317fefb OpenGL2: Direct state access, part 1: Texture binds 2016-01-18 04:46:01 -08:00
Zack Middleton
615b73288f Use Opus for VoIP
Server/client VoIP protocol is handled by adding new cvars
cl_voipProtocol and sv_voipProtocol, sv_voip and cl_voip
are used to auto set/clear them. All users need to touch
are cl/sv_voip as 0 or 1 just like before.

Old Speex VoIP packets in demos are skipped.
New VoIP packets are skipped in demos if sv_voipProtocol
doesn't match cl_voipProtocol.

Notable difference between usage of speex and opus codecs,
when using Speex client would be sent 80ms at a time.
Using Opus, 60ms is sent at a time. This was changed because
the Opus codec supports encoding up to 60ms at a time.
(Simpler to send only one codec frame in a packet.)
2016-01-06 05:19:10 -06:00
SmileTheory
f965f3c66e OpenGL2: DDS (compressed textures) support. 2015-12-18 06:53:20 -08:00
Zack Middleton
fad66ae222 Maybe fix old MSYS when there is an empty for loop
Based on ioquake3 svn r1485.
2015-10-04 17:20:56 -05:00
Simon McVittie
ad24cfcd55 build: if tput fails, fall back to a reasonable text width
If TERM is not set (which can happen in autobuilders and other
batch environments), or if tput cannot determine the number of
columns for some other reason, then it can fail and not produce
any output. Prior to this change, that would result in passing
field width -4 to fmt, which is an error and causes fmt to
produce no output.
2015-07-22 08:16:02 +01:00
Simon McVittie
2a71948f21 build: define ARCH_STRING in Makefile on Linux and other GNU platforms
GNU platforms (Linux, kFreeBSD, Hurd) have endian.h to determine
endianness, so all architectures except x86_64 are in fact treated
identically, except that their ARCH_STRING is different.
The ARCH_STRING must always be identical to the ARCH from the Makefile,
otherwise the engine will not find its cgame, game and ui plugins
under their expected names and startup will fail. If we pass it in
from the Makefile, then an identical value is guaranteed, and we can
get rid of an increasingly long list of defined(__some_cpu__) tests.

The one remaining quirk is that we test __x86_64__ to determine
whether to define idx64; I've kept that, but separated it from
the ARCH_STRING.

On non-Linux platforms we only support a few architectures anyway,
so keeping the list up to date is less of a burden; *BSD porters
could probably use the same technique to get support for lots of
architectures with little effort, but I have not done that here,
because I cannot test it.

Windows must continue to support preprocessor-based architecture tests
in any case, so that the MSVC solutions (which do not use the Makefile)
can continue to work. However, Windows only runs on a few CPU families,
so this shouldn't be a significant burden in practice.

When cross-compiling, the tools are compiled for the build architecture
(COMPILE_PLATFORM, COMPILE_ARCH) rather than the host architecture
(PLATFORM, ARCH), so define ARCH_STRING to COMPILE_ARCH on a GNU
COMPILE_PLATFORM.
2015-07-14 22:51:57 +01:00
Simon McVittie
c91fab3900 build: canonicalize all ARM variants to "arm", matching q_platform.h
The ARCH in the Makefile must match the ARCH_STRING in q_platform.h;
otherwise, ioquake3 will install (for instance) uiARCH.so but look for
uiARCH_STRING.so, which isn't going to go well (particularly for
the modular renderer).

Like i386, but unlike most (all?) other Linux platforms, uname -m on
32-bit ARM machines can have various results starting with "arm",
depending on the specific CPU version (e.g. Raspberry Pi is armv6l,
RPi2 is armv7l). Again similar to the x86 family,
it's appropriate for them to share an architecture suffix;
q_platform.h has traditionally used "arm" so let's use that.

64-bit ARM makes a clean break from this, much like 64-bit x86 does:
uname -m produces a string not starting with arm (specifically
"aarch64"), and gcc predefines __aarch64__ instead of __arm__.
As a result, it is unaffected by this change.
2015-07-14 22:51:55 +01:00
Simon McVittie
071965b3f0 Makefile: confine $(LIB) to the one platform that needs it, namely irix64
It isn't mentioned anywhere else, and deleting it from the Linux code
path means we don't need to maintain an exhaustive list of 64-bit
architectures.
2015-07-14 22:51:53 +01:00
Zack Middleton
6a03817a9c Merge pull request #4 from smcv/hurd
Add support for the GNU/Hurd architecture
2015-06-30 19:02:46 -05:00
Martin Michlmayr
ebb69f699c Add support for Aarch64 (ARM64)
Add support for Aarch64, the 64-bit ARM architecture.
2015-06-30 14:22:49 -04:00
Zack Middleton
d0a3ba301b Merge pull request #89 from bostick/master
Add mingw prefix for cygwin32 and mingw32
2015-06-18 13:13:16 -05:00
Zack Middleton
9522028a0e Sort tr_image_*.c filenames in Makefile 2015-06-12 14:31:58 -05:00
Tim Angus
76e0c51a1a Merge pull request #110 from zsoltm/mingw64
added mingw64 (msys2) platform support
2015-06-12 16:28:13 +01:00
Tim Angus
708fe6937a use osxcross compilers 2015-06-07 03:48:09 -07:00
Tim Angus
92b74e58cc clang gets upset by some of these compiler options (and they're probably pretty pointless in 2015 anyway) 2015-06-06 22:42:10 +01:00
Simon McVittie
0fc86e9632 Use pkg-config for a system libjpeg if available: libjpeg-turbo has it
Bug: https://github.com/ioquake/ioq3/pull/116
2015-03-18 17:37:42 +00:00
ZsoltM
31fea24321 added mingw64 (msys2) platform support 2015-01-30 22:52:53 +01:00
Zack Middleton
4e029b1f6b Fix compiling lcc using mingw under cygwin
Also have 'make' under cygwin automatically use mingw.
2015-01-27 04:51:03 -06:00
Ludwig Nussel
6214f73af5 a VM for ARMv7l 2014-10-24 13:44:23 +02:00
Brenton Bostick
66edc4b296 Add mingw prefix for cygwin32 and mingw32 2014-10-03 21:59:26 -04:00
Tim Angus
02d197ca08 Bullshit change to test jenkins configuration 2014-08-27 10:36:56 +01:00
Tim Angus
00909a4c16 Add SDL libraries to the builds 2014-08-26 16:59:33 +01:00