1 PROJECT_NAME = I.V.A.N. ;
3 -configure-enable-disable-vars- +=
4 "sound" USE_SOUND "auto" "enable sound"
5 "zlib" USE_ZLIB "auto" "use ZLib"
6 "imlib2" USE_IMLIB2 "auto" "use imlib2"
7 "opengl" USE_OPENGL "auto" "use OpenGL renderer"
8 "libpng" USE_LIBPNG "auto" "use LibPNG to load graphics (this won't disable pcx)"
10 "wizard" USE_WIZARD "auto" "disable 'wizard' mode"
11 "global-saves" USE_GLOBAL_SAVES "auto" "enable saves in \$HOME"
12 "pngshots" USE_PNG_SHOTS "tan" "disable png savegame shots (use IPU)"
16 rule -configure-preinit- {
22 -configure-pkg-config-necessary-
27 for local ca in $(JAMCONFIGARGS) {
28 if [ Match '^--prefix=.+$' : $(ca) ] {
35 # this is 'install' version, fix options
36 if $(USE_WIZARD) == "auto" { USE_WIZARD = ; }
37 if $(USE_GLOBAL_SAVES) == "auto" { USE_GLOBAL_SAVES = tan ; }
39 if $(USE_WIZARD) == "auto" { USE_WIZARD = tan ; }
40 if $(USE_GLOBAL_SAVES) == "auto" { USE_GLOBAL_SAVES = ; }
42 #Echo "PREFIX:" $(has-prefix) ;
43 #Echo "USE_WIZARD:" $(USE_WIZARD) ;
44 #Echo "USE_GLOBAL_SAVES:" $(USE_GLOBAL_SAVES) ;
47 -configure-add-line- "# sound disabled" ;
48 -configure-add-line- "DEFINES += DISABLE_SOUND ;" ;
50 -configure-pkg-config- "SDL Mixer" : SDL_mixer : : "DEFINES += DISABLE_SOUND ;" ;
51 -configure-pkg-config- "ALSA" : alsa : "DEFINES += ENABLE_ALSA ;" : ;
54 -configure-add-line- "# OpenGL disabled" ;
55 -configure-add-line- "DEFINES += DISABLE_OPENGL ;" ;
57 -configure-pkg-config- "OpenGL" : gl : : "DEFINES += DISABLE_OPENGL ;" ;
61 -configure-add-line- "# ZLib disabled" ;
63 if ! [ -configure-pkg-config- "ZLib" : zlib : "DEFINES += USE_ZLIB ;" ] { USE_ZLIB = ; }
68 if ! [ -configure-pkg-config- "libpng" : "libpng >= 1.6" ] {
69 if ! [ -configure-pkg-config- "libpng16" : "libpng16 >= 1.6" ] {
75 -configure-add-line- "# libpng disabled" ;
77 -configure-add-line- "# imlib2 disabled" ;
79 #if ! [ -configure-pkg-config- "imlib2" : imlib2 : "DEFINES += HAVE_IMLIB2 ;" ] { USE_IMLIB2 = ; }
81 Exit "FATAL: LibPNG 1.6 not found!" ;
83 -configure-add-line- "DEFINES += HAVE_LIBPNG ;" ;
86 ### if $(HAVE_LIBPNG) {
87 ### Echo "MSG: libpng found" ;
88 ### lib-config "pkg-config libpng" ;
89 ### DEFINES += HAVE_LIBPNG ;
92 if $(OSPLAT) = 'X86_64' {
93 Echo "MSG: 64bit arches aren't supported. forcing 32-bit build." ;
94 -configure-add-line- "# 64shit found" ;
95 -configure-add-line- "CFLAGS.all += -m32 ;" ;
96 -configure-add-line- "LINKFLAGS.all += -m32 ;" ;
99 -configure-add-line- "# other options" ;
101 Echo "CFG: wizard mode enabled" ;
102 -configure-add-line- "DEFINES += WIZARD ;" ;
105 if $(USE_GLOBAL_SAVES) {
106 Echo "CFG: using saves in \$HOME" ;
108 Echo "CFG: using local saves" ;
109 -configure-add-line- "DEFINES += LOCAL_SAVES ;" ;
113 Echo "CFG: support for compressed saves turned on" ;
116 if $(USE_PNG_SHOTS) {
117 Echo "CFG: savegame screenshots will be in PNG format" ;
119 Echo "CFG: savegame screenshots will be in internal format" ;
120 -configure-add-line- "DEFINES += SGAME_SHOTS_IPU ;" ;