-
Notifications
You must be signed in to change notification settings - Fork 15
/
dev-readme.txt
143 lines (82 loc) · 4.07 KB
/
dev-readme.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
MacOS version used: macOS Sierra 10.12.6
----
32-bit Windows build from Linux:
ARCH=x86 ./cross.sh
64-bit Windows build from Linux:
./cross.sh
-------
#compile zlib win32 from linux
----
compile external ogg and vorbis mac os x:
2014-09-11
ogg and vorbis ./configure CFLAGS="-arch i386" --host=i386
compile freetype mac os x:
# zlib has version information, try to use the same one
CPPFLAGS="-I/Users/acano/share/zlib-1.3.1" CFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.7" ./configure --with-zlib=yes --with-bzip2=no --with-png=no --with-brotli=no
make
cp objs/.libs/libfreetype.a ...
----
compile freetype win32 (from linux):
# zlib has version information, try to use the same one
CPPFLAGS=-I/home/acano/work/hg/ioquakelive-demo-player/code/zlib-1.3.1 ./configure --host=i686-w64-mingw32 --with-zlib=yes --with-bzip2=no --with-png=no --with-brotli=no
make
cp objs/.libs/libfreetype.a ...
for 64 bit: --host=x86_64-w64-mingw32
----
6014:cc46e2efef98 ioquake3 patch: 2014-03-08-02 Update SDL2 to 2.0.2
Update to SDL2 2.0.2 crashes with i686-w64-mingw32-gcc 4.9.1 and '-O3'. This is with Debian 8 oldstable (jessie). Compiling with '-O2' or less avoids crash. This also appears to be fixed with i686-w64-mingw32-gcc 6.3.0 2017516. That's with Debian 9 stable (stretch).
----
convert -background none wolfcamql.svg -define icon:auto-resize=256,128,64,48,32,16 -border 0 quake3.ico
----
2020-11-27 updating to speex-1.2.0 from speex-1.2beta3 takes out needed structure: SpeexPreprocessState -- 2022-04-19 dsp functions were put in a separate library: speexdsp-1.2rc3.tar.gz
2022-04-21 for libspeex copy win32/config.h into main source directory -- not needed
for both libspeex and libspeexdsp:
include/speex/speexdsp_config_types.h add '#ifdef _MSC_VER' wrapper
libspeexdsp-1.2rc3/fftwrap.c add '#define USE_KISS_FFT'
----
compile curl win32 (from linux):
# libcurl.a linked with -lcrypt32
CPPFLAGS=-I/home/acano/work/hg/ioquakelive-demo-player/code/zlib-1.3.1 ./configure --host=i686-w64-mingw32 --with-schannel
...
checking for sys/types.h... (cached) yes
checking for poll.h... (cached) no
checking for sys/poll.h... (cached) no
checking for in_addr_t... no
checking for in_addr_t equivalent... unknown
configure: error: Cannot find a type to use in place of in_addr_t
# 2022-05-25 current ioq3 version has progress meter enabled
compile curl win32 (from Windows mysys2)
pacman -S --needed base-devel mingw-w64-x86_64-toolchain mingw-w64-i686-toolchain
pacman -S mingw-w64-cross-binutils
open terminal with mingw32.exe / mingw64.exe
CPPFLAGS="-I/home/acano/zlib-1.3.1" ./configure --with-schannel --disable-shared --disable-ldap --disable-pthreads --without-zstd --enable-progress-meter
make
-------
SDL 2.0.16
win32:
./configure --host=i686-w64-mingw32
win64:
in Makefile.in change libSDL2 references to libSDL264
./configure --host=x86_64-w64-mingw32
macosx:
how to combine libraries from different architectures:
lipo lib1.dylib lib2.dylib -output combined.dylib -create
how to separate libraries:
lipo libx.a -thin armv6 -output libx-armv6.a
how to change dylib loading path:
#install_name_tool -change /usr/local/lib/libSDL2-2.0.0.dylib @executable_path/libSDL2-2.0.0.dylib libSDL2-2.0.0.dylib
# but the first one will be 'id'
install_name_tool -id @executable_path/libSDL2-2.0.0.dylib libSDL2-2.0.0.dylib
how to check dylib loading paths:
otool -L libSDL2-2.0.0.dylib
CFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.7" LDFLAGS="-arch i386 -arch x86_64" ./configure
make
mkdir out
cp build/.libs/libSDL2main.a out/libsdl2main-both.a
cp build/.libs/libSDL2-2.0.0.dylib out/libsdl2-both.dylib
copy ppc versions into out/
cd out/
lipo libsdl2-both.dylib libSDL2-ppc.dylib -output libSDL2-2.0.0.dylib -create
install_name_tool -id @executable_path/libSDL2-2.0.0.dylib libSDL2-2.0.0.dylib
lipo libsdl2main-both.a libsdl2main-ppc.a -output libSDL2main.a -create
old ppc versions (libSDL2-ppc.dylib and libsdl2main-ppc.a) are kept in code/libs/macosx/ppc