Subversion Repositories eduke32

Rev

Rev 5000 | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5000 Rev 5066
1
# Copyright (C) 2009 The Android Open Source Project
1
# Copyright (C) 2009 The Android Open Source Project
2
#
2
#
3
# Licensed under the Apache License, Version 2.0 (the "License");
3
# Licensed under the Apache License, Version 2.0 (the "License");
4
# you may not use this file except in compliance with the License.
4
# you may not use this file except in compliance with the License.
5
# You may obtain a copy of the License at
5
# You may obtain a copy of the License at
6
#
6
#
7
#      http://www.apache.crg/licenses/LICENSE-2.0
7
#      http://www.apache.crg/licenses/LICENSE-2.0
8
#
8
#
9
# Unless required by applicable law or agreed to in writing, software
9
# Unless required by applicable law or agreed to in writing, software
10
# distributed under the License is distributed on an "AS IS" BASIS,
10
# distributed under the License is distributed on an "AS IS" BASIS,
11
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
# See the License for the specific language governing permissions and
12
# See the License for the specific language governing permissions and
13
# limitations under the License.
13
# limitations under the License.
14
#
14
#
15
LOCAL_PATH := $(call my-dir)
15
LOCAL_PATH := $(call my-dir)
16
16
17
include $(CLEAR_VARS)
17
include $(CLEAR_VARS)
18
18
19
LOCAL_MODULE    := duke
19
LOCAL_MODULE    := duke
20
20
21
# -O2  -fvisibility=hidden
21
# -O2  -fvisibility=hidden
22
22
23
LOCAL_CFLAGS :=   -x c++ -std=gnu++03 -fvisibility=hidden -fPIC -O2 -funswitch-loops -fomit-frame-pointer -DNDEBUG -DUSING_LTO -flto -fno-stack-protector   -funsigned-char -fno-strict-aliasing -DNO_GCC_BUILTINS -D_FORTIFY_SOURCE=0 -fjump-tables -pthread -DHAVE_INTTYPES  -D_GNU_SOURCE=1 -D_REENTRANT
23
LOCAL_CFLAGS :=   -x c++ -std=gnu++03 -fvisibility=hidden -fPIC -O2 -DNDEBUG -DUSING_LTO -flto -fno-stack-protector -funsigned-char -fno-strict-aliasing -DNO_GCC_BUILTINS -D_FORTIFY_SOURCE=0 -pthread -DHAVE_INTTYPES  -D_GNU_SOURCE=1 -D_REENTRANT
24
LOCAL_CFLAGS += -W  -Werror-implicit-function-declaration -Wpointer-arith -Wextra  -Wno-unused-result  -Wno-char-subscripts -Wno-strict-overflow -Wno-attributes -Wno-write-strings
24
LOCAL_CFLAGS += -W  -Werror-implicit-function-declaration -Wpointer-arith -Wextra  -Wno-unused-result  -Wno-char-subscripts -Wno-strict-overflow -Wno-attributes -Wno-write-strings
25
LOCAL_CPPFLAGS := -std=gnu++03
25
LOCAL_CPPFLAGS := -std=gnu++03
26
26
27
#-DUSE_LIBPNG
-
 
28
-
 
29
LOCAL_CFLAGS += -DHAVE_SDL -DHAVE_VORBIS -DHAVE_JWZGLES -DHAVE_ANDROID -DRENDERTYPESDL=1  -DUSE_OPENGL -DNETCODE_DISABLE -DUSE_LIBVPX
27
LOCAL_CFLAGS += -DHAVE_SDL -DHAVE_VORBIS -DHAVE_JWZGLES -DHAVE_ANDROID -DRENDERTYPESDL=1  -DUSE_OPENGL -DNETCODE_DISABLE -DUSE_LIBVPX
30
28
31
#LOCAL_CFLAGS += -mhard-float -D_NDK_MATH_NO_SOFTFP=1
29
#LOCAL_CFLAGS += -mhard-float -D_NDK_MATH_NO_SOFTFP=1
32
30
33
LOCAL_LDFLAGS := -fuse-ld=bfd
31
LOCAL_LDFLAGS := -fuse-ld=bfd
34
LOCAL_ARM_NEON = true
32
LOCAL_ARM_NEON = true
35
33
36
LOCAL_C_INCLUDES :=  $(LOCAL_PATH)/source $(LOCAL_PATH)/source/jmact $(LOCAL_PATH)/source/jaudiolib/include $(LOCAL_PATH)/source/enet/include  $(LOCAL_PATH)/build/include
34
LOCAL_C_INCLUDES :=  $(LOCAL_PATH)/source $(LOCAL_PATH)/source/jmact $(LOCAL_PATH)/source/jaudiolib/include $(LOCAL_PATH)/source/enet/include  $(LOCAL_PATH)/build/include
37
LOCAL_C_INCLUDES +=    $(TOP_DIR)/ $(TOP_DIR)/Libraries/liboggvorbis/include $(TOP_DIR)/Libraries/ $(TOP_DIR)/Libraries/SDL2/include  $(TOP_DIR)/Libraries/SDL2_mixer/include $(TOP_DIR)/Libraries/libpng/include   $(TOP_DIR)/Libraries/TinyXML/include $(TOP_DIR)/TouchControls $(TOP_DIR)/Libraries/libvpx/include
35
LOCAL_C_INCLUDES +=    $(TOP_DIR)/ $(TOP_DIR)/Libraries/liboggvorbis/include $(TOP_DIR)/Libraries/ $(TOP_DIR)/Libraries/SDL2/include  $(TOP_DIR)/Libraries/SDL2_mixer/include $(TOP_DIR)/Libraries/libpng/include   $(TOP_DIR)/Libraries/TinyXML/include $(TOP_DIR)/TouchControls $(TOP_DIR)/Libraries/libvpx/include
38
36
39
ANDROID_SRC = \
37
ANDROID_SRC = \
40
	source/android/android-jni.cpp \
38
	source/android/android-jni.cpp \
41
	source/android/in_android.c \
39
	source/android/in_android.c \
42
        build/src/glbuild_android.c \
40
        build/src/glbuild_android.c \
43
        build/src/jwzgles.c
41
        build/src/jwzgles.c \
-
 
42
        source/android/rg_etc1.cpp
44
43
45
BUILD_SRC = \
44
BUILD_SRC = \
46
	build/src/a-c.c \
45
	build/src/a-c.c \
47
	build/src/baselayer.c \
46
	build/src/baselayer.c \
48
	build/src/cache1d.c \
47
	build/src/cache1d.c \
49
	build/src/compat.c \
48
	build/src/compat.c \
50
	build/src/crc32.c \
49
	build/src/crc32.c \
51
	build/src/defs.c \
50
	build/src/defs.c \
52
	build/src/engine.c \
51
	build/src/engine.c \
53
	build/src/polymost.c \
52
	build/src/polymost.c \
54
        build/src/mdsprite.c \
53
        build/src/mdsprite.c \
55
	build/src/texcache.c \
54
	build/src/texcache.c \
56
	build/src/dxtfilter.c \
55
	build/src/dxtfilter.c \
57
	build/src/hightile.c \
56
	build/src/hightile.c \
58
	build/src/textfont.c \
57
	build/src/textfont.c \
59
	build/src/smalltextfont.c \
58
	build/src/smalltextfont.c \
60
	build/src/kplib.c \
59
	build/src/kplib.c \
61
	build/src/lz4.c \
60
	build/src/lz4.c \
62
	build/src/osd.c \
61
	build/src/osd.c \
63
	build/src/md4.c \
62
	build/src/md4.c \
64
	build/src/pragmas.c \
63
	build/src/pragmas.c \
65
	build/src/scriptfile.c \
64
	build/src/scriptfile.c \
66
	build/src/mutex.c \
65
	build/src/mutex.c \
67
        build/src/xxhash.c \
66
        build/src/xxhash.c \
68
        build/src/mmulti_null.c \
67
        build/src/mmulti_null.c \
69
        build/src/voxmodel.c \
68
        build/src/voxmodel.c \
70
        build/src/common.c \
69
        build/src/common.c \
71
        build/src/sdlayer.c
70
        build/src/sdlayer.c
72
71
73
JMACT_SRC=source/jmact/file_lib.c \
72
JMACT_SRC=source/jmact/file_lib.c \
74
	source/jmact//control.c \
73
	source/jmact//control.c \
75
	source/jmact//keyboard.c \
74
	source/jmact//keyboard.c \
76
	source/jmact//mouse.c \
75
	source/jmact//mouse.c \
77
	source/jmact//joystick.c \
76
	source/jmact//joystick.c \
78
	source/jmact//mathutil.c \
77
	source/jmact//mathutil.c \
79
	source/jmact//scriplib.c \
78
	source/jmact//scriplib.c \
80
	source/jmact//animlib.c
79
	source/jmact//animlib.c
81
80
82
GAME_SRC=source/game.c \
81
GAME_SRC=source/game.c \
83
	source/actors.c \
82
	source/actors.c \
84
	source/anim.c \
83
	source/anim.c \
85
	source/animsounds.c \
84
	source/animsounds.c \
86
        source/animvpx.c \
85
        source/animvpx.c \
87
	source/common.c \
86
	source/common.c \
88
	source/config.c \
87
	source/config.c \
89
	source/demo.c \
88
	source/demo.c \
90
	source/gamedef.c \
89
	source/gamedef.c \
91
	source/gameexec.c \
90
	source/gameexec.c \
92
	source/gamevars.c \
91
	source/gamevars.c \
93
	source/global.c \
92
	source/global.c \
94
	source/input.c \
93
	source/input.c \
95
	source/menus.c \
94
	source/menus.c \
96
	source/namesdyn.c \
95
	source/namesdyn.c \
97
	source/net.c \
96
	source/net.c \
98
	source/player.c \
97
	source/player.c \
99
	source/premap.c \
98
	source/premap.c \
100
	source/savegame.c \
99
	source/savegame.c \
101
	source/sector.c \
100
	source/sector.c \
102
	source/rts.c \
101
	source/rts.c \
103
	source/osdfuncs.c \
102
	source/osdfuncs.c \
104
	source/osdcmds.c \
103
	source/osdcmds.c \
105
	source/grpscan.c \
104
	source/grpscan.c \
106
	source/sounds.c \
105
	source/sounds.c \
107
	source/soundsdyn.c \
106
	source/soundsdyn.c \
108
  	source/sdlmusic.c \
107
  	source/sdlmusic.c \
109
  	source/rev.c 
108
  	source/rev.c 
110
 
109
 
111
 JAUDIO_SRC=source/jaudiolib/src/drivers.c \
110
 JAUDIO_SRC=source/jaudiolib/src/drivers.c \
112
	source/jaudiolib/src//fx_man.c \
111
	source/jaudiolib/src//fx_man.c \
113
	source/jaudiolib/src//multivoc.c \
112
	source/jaudiolib/src//multivoc.c \
114
	source/jaudiolib/src//mix.c \
113
	source/jaudiolib/src//mix.c \
115
	source/jaudiolib/src//mixst.c \
114
	source/jaudiolib/src//mixst.c \
116
	source/jaudiolib/src//pitch.c \
115
	source/jaudiolib/src//pitch.c \
117
	source/jaudiolib/src//formats.c \
116
	source/jaudiolib/src//formats.c \
118
	source/jaudiolib/src//vorbis.c \
117
	source/jaudiolib/src//vorbis.c \
119
	source/jaudiolib/src//flac.c \
118
	source/jaudiolib/src//flac.c \
120
	source/jaudiolib/src//xa.c \
119
	source/jaudiolib/src//xa.c \
121
	source/jaudiolib/src//driver_nosound.c \
120
	source/jaudiolib/src//driver_nosound.c \
122
	source/jaudiolib/src//driver_sdl.c
121
	source/jaudiolib/src//driver_sdl.c
123
 
122
 
124
 
123
 
125
 ENET_SRC=source/enet/src/callbacks.c \
124
 ENET_SRC=source/enet/src/callbacks.c \
126
	source/enet/src/host.c \
125
	source/enet/src/host.c \
127
	source/enet/src/list.c \
126
	source/enet/src/list.c \
128
	source/enet/src/packet.c \
127
	source/enet/src/packet.c \
129
	source/enet/src/peer.c \
128
	source/enet/src/peer.c \
130
	source/enet/src/protocol.c \
129
	source/enet/src/protocol.c \
131
	source/enet/src/compress.c \
130
	source/enet/src/compress.c \
132
    source/enet/src/unix.c
131
    source/enet/src/unix.c
133
 
132
 
134
LOCAL_SRC_FILES = $(ANDROID_SRC) $(JAUDIO_SRC) $(JMACT_SRC) $(GAME_SRC) $(BUILD_SRC)  
133
LOCAL_SRC_FILES = $(ANDROID_SRC) $(JAUDIO_SRC) $(JMACT_SRC) $(GAME_SRC) $(BUILD_SRC)  
135
134
136
LOCAL_LDLIBS :=  -lGLESv1_CM -lEGL -ldl -llog -lOpenSLES -lz -L$(TOP_DIR)/openssl/libs/ 
135
LOCAL_LDLIBS :=  -lGLESv1_CM -lEGL -ldl -llog -lOpenSLES -lz -L$(TOP_DIR)/openssl/libs/ 
137
LOCAL_STATIC_LIBRARIES :=   libpng crypto 
136
LOCAL_STATIC_LIBRARIES :=   libpng crypto 
138
LOCAL_SHARED_LIBRARIES := touchcontrols ogg vorbis SDL2 SDL2_mixer libvpx
137
LOCAL_SHARED_LIBRARIES := touchcontrols ogg vorbis SDL2 SDL2_mixer libvpx
139
# SDL2_image
138
# SDL2_image
140
139
141
ifeq ($(GP_LIC),1)
140
ifeq ($(GP_LIC),1)
142
LOCAL_STATIC_LIBRARIES +=  s-setup
141
LOCAL_STATIC_LIBRARIES +=  s-setup
143
LOCAL_CFLAGS += -DGP_LIC
142
LOCAL_CFLAGS += -DGP_LIC
144
endif
143
endif
145
144
146
include $(BUILD_SHARED_LIBRARY)
145
include $(BUILD_SHARED_LIBRARY)