Change to the handling of -DCOMBINED in the makefiles. Instead of

defining it centrally per port, I think it's neater to define it for
each puzzle when adding that puzzle to the ALL list - because those
front ends which take -DCOMBINED are precisely those which use ALL.
In particular, this change opens up the possibility of compiling
both individual puzzles _and_ a combined monolith within the same
makefile.

[originally from svn r8178]
This commit is contained in:
Simon Tatham
2008-09-13 19:17:26 +00:00
parent 1d661ec46b
commit 43eafe1fdf
28 changed files with 95 additions and 93 deletions

View File

@ -4,7 +4,7 @@ blackbox : [X] GTK COMMON blackbox blackbox-icon|no-icon
blackbox : [G] WINDOWS COMMON blackbox blackbox.res|noicon.res blackbox : [G] WINDOWS COMMON blackbox blackbox.res|noicon.res
ALL += blackbox ALL += blackbox[COMBINED]
!begin gtk !begin gtk
GAMES += blackbox GAMES += blackbox

View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
BRIDGES = bridges dsf BRIDGES_EXTRA = dsf
bridges : [X] GTK COMMON BRIDGES bridges-icon|no-icon bridges : [X] GTK COMMON bridges BRIDGES_EXTRA bridges-icon|no-icon
bridges : [G] WINDOWS COMMON BRIDGES bridges.res|noicon.res bridges : [G] WINDOWS COMMON bridges BRIDGES_EXTRA bridges.res|noicon.res
ALL += BRIDGES ALL += bridges[COMBINED] BRIDGES_EXTRA
!begin gtk !begin gtk
GAMES += bridges GAMES += bridges

2
cube.R
View File

@ -4,7 +4,7 @@ cube : [X] GTK COMMON cube cube-icon|no-icon
cube : [G] WINDOWS COMMON cube cube.res|noicon.res cube : [G] WINDOWS COMMON cube cube.res|noicon.res
ALL += cube ALL += cube[COMBINED]
!begin gtk !begin gtk
GAMES += cube GAMES += cube

View File

@ -4,7 +4,7 @@ dominosa : [X] GTK COMMON dominosa dominosa-icon|no-icon
dominosa : [G] WINDOWS COMMON dominosa dominosa.res|noicon.res dominosa : [G] WINDOWS COMMON dominosa dominosa.res|noicon.res
ALL += dominosa ALL += dominosa[COMBINED]
!begin gtk !begin gtk
GAMES += dominosa GAMES += dominosa

View File

@ -4,7 +4,7 @@ fifteen : [X] GTK COMMON fifteen fifteen-icon|no-icon
fifteen : [G] WINDOWS COMMON fifteen fifteen.res|noicon.res fifteen : [G] WINDOWS COMMON fifteen fifteen.res|noicon.res
ALL += fifteen ALL += fifteen[COMBINED]
!begin gtk !begin gtk
GAMES += fifteen GAMES += fifteen

View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
FILLING = filling dsf FILLING_EXTRA = dsf
fillingsolver : [U] filling[STANDALONE_SOLVER] dsf STANDALONE fillingsolver : [U] filling[STANDALONE_SOLVER] FILLING_EXTRA STANDALONE
fillingsolver : [C] filling[STANDALONE_SOLVER] dsf STANDALONE fillingsolver : [C] filling[STANDALONE_SOLVER] FILLING_EXTRA STANDALONE
filling : [X] GTK COMMON FILLING filling-icon|no-icon filling : [X] GTK COMMON filling FILLING_EXTRA filling-icon|no-icon
filling : [G] WINDOWS COMMON FILLING filling.res|noicon.res filling : [G] WINDOWS COMMON filling FILLING_EXTRA filling.res|noicon.res
ALL += filling ALL += filling[COMBINED] FILLING_EXTRA
!begin gtk !begin gtk
GAMES += filling GAMES += filling

8
flip.R
View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
FLIP = flip tree234 FLIP_EXTRA = tree234
flip : [X] GTK COMMON FLIP flip-icon|no-icon flip : [X] GTK COMMON flip FLIP_EXTRA flip-icon|no-icon
flip : [G] WINDOWS COMMON FLIP flip.res|noicon.res flip : [G] WINDOWS COMMON flip FLIP_EXTRA flip.res|noicon.res
ALL += FLIP ALL += flip[COMBINED] FLIP_EXTRA
!begin gtk !begin gtk
GAMES += flip GAMES += flip

View File

@ -1,19 +1,19 @@
# -*- makefile -*- # -*- makefile -*-
GALAXIES = galaxies dsf GALAXIES_EXTRA = dsf
galaxies : [X] GTK COMMON GALAXIES galaxies-icon|no-icon galaxies : [X] GTK COMMON galaxies GALAXIES_EXTRA galaxies-icon|no-icon
galaxies : [G] WINDOWS COMMON GALAXIES galaxies.res|noicon.res galaxies : [G] WINDOWS COMMON galaxies GALAXIES_EXTRA galaxies.res|noicon.res
galaxiessolver : [U] galaxies[STANDALONE_SOLVER] dsf STANDALONE m.lib galaxiessolver : [U] galaxies[STANDALONE_SOLVER] GALAXIES_EXTRA STANDALONE m.lib
galaxiessolver : [C] galaxies[STANDALONE_SOLVER] dsf STANDALONE galaxiessolver : [C] galaxies[STANDALONE_SOLVER] GALAXIES_EXTRA STANDALONE
galaxiespicture : [U] galaxies[STANDALONE_PICTURE_GENERATOR] dsf STANDALONE galaxiespicture : [U] galaxies[STANDALONE_PICTURE_GENERATOR] GALAXIES_EXTRA STANDALONE
+ m.lib + m.lib
galaxiespicture : [C] galaxies[STANDALONE_PICTURE_GENERATOR] dsf STANDALONE galaxiespicture : [C] galaxies[STANDALONE_PICTURE_GENERATOR] GALAXIES_EXTRA STANDALONE
ALL += galaxies ALL += galaxies[COMBINED] GALAXIES_EXTRA
!begin gtk !begin gtk
GAMES += galaxies GAMES += galaxies

View File

@ -4,7 +4,7 @@ guess : [X] GTK COMMON guess guess-icon|no-icon
guess : [G] WINDOWS COMMON guess guess.res|noicon.res guess : [G] WINDOWS COMMON guess guess.res|noicon.res
ALL += guess ALL += guess[COMBINED]
!begin gtk !begin gtk
GAMES += guess GAMES += guess

View File

@ -4,7 +4,7 @@ inertia : [X] GTK COMMON inertia inertia-icon|no-icon
inertia : [G] WINDOWS COMMON inertia inertia.res|noicon.res inertia : [G] WINDOWS COMMON inertia inertia.res|noicon.res
ALL += inertia ALL += inertia[COMBINED]
!begin gtk !begin gtk
GAMES += inertia GAMES += inertia

View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
LIGHTUP = lightup combi LIGHTUP_EXTRA = combi
lightup : [X] GTK COMMON LIGHTUP lightup-icon|no-icon lightup : [X] GTK COMMON lightup LIGHTUP_EXTRA lightup-icon|no-icon
lightup : [G] WINDOWS COMMON LIGHTUP lightup.res|noicon.res lightup : [G] WINDOWS COMMON lightup LIGHTUP_EXTRA lightup.res|noicon.res
lightupsolver : [U] lightup[STANDALONE_SOLVER] combi STANDALONE lightupsolver : [U] lightup[STANDALONE_SOLVER] LIGHTUP_EXTRA STANDALONE
lightupsolver : [C] lightup[STANDALONE_SOLVER] combi STANDALONE lightupsolver : [C] lightup[STANDALONE_SOLVER] LIGHTUP_EXTRA STANDALONE
ALL += LIGHTUP ALL += lightup[COMBINED] LIGHTUP_EXTRA
!begin gtk !begin gtk
GAMES += lightup GAMES += lightup

View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
LOOPY = loopy tree234 dsf grid LOOPY_EXTRA = tree234 dsf grid
loopy : [X] GTK COMMON LOOPY loopy-icon|no-icon loopy : [X] GTK COMMON loopy LOOPY_EXTRA loopy-icon|no-icon
loopy : [G] WINDOWS COMMON LOOPY loopy.res|noicon.res loopy : [G] WINDOWS COMMON loopy LOOPY_EXTRA loopy.res|noicon.res
ALL += LOOPY ALL += loopy[COMBINED] LOOPY_EXTRA
!begin gtk !begin gtk
GAMES += loopy GAMES += loopy

12
map.R
View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
MAP = map dsf MAP_EXTRA = dsf
map : [X] GTK COMMON MAP map-icon|no-icon map : [X] GTK COMMON map MAP_EXTRA map-icon|no-icon
map : [G] WINDOWS COMMON MAP map.res|noicon.res map : [G] WINDOWS COMMON map MAP_EXTRA map.res|noicon.res
mapsolver : [U] map[STANDALONE_SOLVER] dsf STANDALONE m.lib mapsolver : [U] map[STANDALONE_SOLVER] MAP_EXTRA STANDALONE m.lib
mapsolver : [C] map[STANDALONE_SOLVER] dsf STANDALONE mapsolver : [C] map[STANDALONE_SOLVER] MAP_EXTRA STANDALONE
ALL += MAP ALL += map[COMBINED] MAP_EXTRA
!begin gtk !begin gtk
GAMES += map GAMES += map

12
mines.R
View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
MINES = mines tree234 MINES_EXTRA = tree234
mines : [X] GTK COMMON MINES mines-icon|no-icon mines : [X] GTK COMMON mines MINES_EXTRA mines-icon|no-icon
mines : [G] WINDOWS COMMON MINES mines.res|noicon.res mines : [G] WINDOWS COMMON mines MINES_EXTRA mines.res|noicon.res
mineobfusc : [U] mines[STANDALONE_OBFUSCATOR] tree234 STANDALONE mineobfusc : [U] mines[STANDALONE_OBFUSCATOR] MINES_EXTRA STANDALONE
mineobfusc : [C] mines[STANDALONE_OBFUSCATOR] tree234 STANDALONE mineobfusc : [C] mines[STANDALONE_OBFUSCATOR] MINES_EXTRA STANDALONE
ALL += MINES ALL += mines[COMBINED] MINES_EXTRA
!begin gtk !begin gtk
GAMES += mines GAMES += mines

8
net.R
View File

@ -1,14 +1,14 @@
# -*- makefile -*- # -*- makefile -*-
NET = net tree234 dsf NET_EXTRA = tree234 dsf
net : [X] GTK COMMON NET net-icon|no-icon net : [X] GTK COMMON net NET_EXTRA net-icon|no-icon
# The Windows Net shouldn't be called `net.exe' since Windows # The Windows Net shouldn't be called `net.exe' since Windows
# already has a reasonably important utility program by that name! # already has a reasonably important utility program by that name!
netgame : [G] WINDOWS COMMON NET net.res|noicon.res netgame : [G] WINDOWS COMMON net NET_EXTRA net.res|noicon.res
ALL += NET ALL += net[COMBINED] NET_EXTRA
!begin gtk !begin gtk
GAMES += net GAMES += net

View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
NETSLIDE = netslide tree234 NETSLIDE_EXTRA = tree234
netslide : [X] GTK COMMON NETSLIDE netslide-icon|no-icon netslide : [X] GTK COMMON netslide NETSLIDE_EXTRA netslide-icon|no-icon
netslide : [G] WINDOWS COMMON NETSLIDE netslide.res|noicon.res netslide : [G] WINDOWS COMMON netslide NETSLIDE_EXTRA netslide.res|noicon.res
ALL += NETSLIDE ALL += netslide[COMBINED] NETSLIDE_EXTRA
!begin gtk !begin gtk
GAMES += netslide GAMES += netslide

2
osx.m
View File

@ -77,6 +77,8 @@
* recreate it. * recreate it.
*/ */
#define COMBINED /* we put all the puzzles in one binary in this port */
#include <ctype.h> #include <ctype.h>
#include <sys/time.h> #include <sys/time.h>
#import <Cocoa/Cocoa.h> #import <Cocoa/Cocoa.h>

View File

@ -7,7 +7,7 @@ pattern : [G] WINDOWS COMMON pattern pattern.res|noicon.res
patternsolver : [U] pattern[STANDALONE_SOLVER] STANDALONE patternsolver : [U] pattern[STANDALONE_SOLVER] STANDALONE
patternsolver : [C] pattern[STANDALONE_SOLVER] STANDALONE patternsolver : [C] pattern[STANDALONE_SOLVER] STANDALONE
ALL += pattern ALL += pattern[COMBINED]
!begin gtk !begin gtk
GAMES += pattern GAMES += pattern

8
pegs.R
View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
PEGS = pegs tree234 PEGS_EXTRA = tree234
pegs : [X] GTK COMMON PEGS pegs-icon|no-icon pegs : [X] GTK COMMON pegs PEGS_EXTRA pegs-icon|no-icon
pegs : [G] WINDOWS COMMON PEGS pegs.res|noicon.res pegs : [G] WINDOWS COMMON pegs PEGS_EXTRA pegs.res|noicon.res
ALL += PEGS ALL += pegs[COMBINED] PEGS_EXTRA
!begin gtk !begin gtk
GAMES += pegs GAMES += pegs

2
rect.R
View File

@ -4,7 +4,7 @@ rect : [X] GTK COMMON rect rect-icon|no-icon
rect : [G] WINDOWS COMMON rect rect.res|noicon.res rect : [G] WINDOWS COMMON rect rect.res|noicon.res
ALL += rect ALL += rect[COMBINED]
!begin gtk !begin gtk
GAMES += rect GAMES += rect

View File

@ -4,7 +4,7 @@ samegame : [X] GTK COMMON samegame samegame-icon|no-icon
samegame : [G] WINDOWS COMMON samegame samegame.res|noicon.res samegame : [G] WINDOWS COMMON samegame samegame.res|noicon.res
ALL += samegame ALL += samegame[COMBINED]
!begin gtk !begin gtk
GAMES += samegame GAMES += samegame

View File

@ -4,7 +4,7 @@ sixteen : [X] GTK COMMON sixteen sixteen-icon|no-icon
sixteen : [G] WINDOWS COMMON sixteen sixteen.res|noicon.res sixteen : [G] WINDOWS COMMON sixteen sixteen.res|noicon.res
ALL += sixteen ALL += sixteen[COMBINED]
!begin gtk !begin gtk
GAMES += sixteen GAMES += sixteen

12
slant.R
View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
SLANT = slant dsf SLANT_EXTRA = dsf
slant : [X] GTK COMMON SLANT slant-icon|no-icon slant : [X] GTK COMMON slant SLANT_EXTRA slant-icon|no-icon
slant : [G] WINDOWS COMMON SLANT slant.res|noicon.res slant : [G] WINDOWS COMMON slant SLANT_EXTRA slant.res|noicon.res
slantsolver : [U] slant[STANDALONE_SOLVER] dsf STANDALONE slantsolver : [U] slant[STANDALONE_SOLVER] SLANT_EXTRA STANDALONE
slantsolver : [C] slant[STANDALONE_SOLVER] dsf STANDALONE slantsolver : [C] slant[STANDALONE_SOLVER] SLANT_EXTRA STANDALONE
ALL += SLANT ALL += slant[COMBINED] SLANT_EXTRA
!begin gtk !begin gtk
GAMES += slant GAMES += slant

12
solo.R
View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
SOLO = solo divvy dsf SOLO_EXTRA = divvy dsf
solo : [X] GTK COMMON SOLO solo-icon|no-icon solo : [X] GTK COMMON solo SOLO_EXTRA solo-icon|no-icon
solo : [G] WINDOWS COMMON SOLO solo.res|noicon.res solo : [G] WINDOWS COMMON solo SOLO_EXTRA solo.res|noicon.res
solosolver : [U] solo[STANDALONE_SOLVER] divvy dsf STANDALONE solosolver : [U] solo[STANDALONE_SOLVER] SOLO_EXTRA STANDALONE
solosolver : [C] solo[STANDALONE_SOLVER] divvy dsf STANDALONE solosolver : [C] solo[STANDALONE_SOLVER] SOLO_EXTRA STANDALONE
ALL += SOLO ALL += solo[COMBINED] SOLO_EXTRA
!begin gtk !begin gtk
GAMES += solo GAMES += solo

12
tents.R
View File

@ -1,15 +1,15 @@
# -*- makefile -*- # -*- makefile -*-
TENTS = tents maxflow TENTS_EXTRA = maxflow
tents : [X] GTK COMMON TENTS tents-icon|no-icon tents : [X] GTK COMMON tents TENTS_EXTRA tents-icon|no-icon
tents : [G] WINDOWS COMMON TENTS tents.res|noicon.res tents : [G] WINDOWS COMMON tents TENTS_EXTRA tents.res|noicon.res
ALL += TENTS ALL += tents[COMBINED] TENTS_EXTRA
tentssolver : [U] tents[STANDALONE_SOLVER] maxflow STANDALONE tentssolver : [U] tents[STANDALONE_SOLVER] TENTS_EXTRA STANDALONE
tentssolver : [C] tents[STANDALONE_SOLVER] maxflow STANDALONE tentssolver : [C] tents[STANDALONE_SOLVER] TENTS_EXTRA STANDALONE
!begin gtk !begin gtk
GAMES += tents GAMES += tents

View File

@ -4,7 +4,7 @@ twiddle : [X] GTK COMMON twiddle twiddle-icon|no-icon
twiddle : [G] WINDOWS COMMON twiddle twiddle.res|noicon.res twiddle : [G] WINDOWS COMMON twiddle twiddle.res|noicon.res
ALL += twiddle ALL += twiddle[COMBINED]
!begin gtk !begin gtk
GAMES += twiddle GAMES += twiddle

View File

@ -1,10 +1,10 @@
# -*- makefile -*- # -*- makefile -*-
UNEQUAL = unequal latin tree234 maxflow UNEQUAL_EXTRA = latin tree234 maxflow
unequal : [X] GTK COMMON UNEQUAL unequal-icon|no-icon unequal : [X] GTK COMMON unequal UNEQUAL_EXTRA unequal-icon|no-icon
unequal : [G] WINDOWS COMMON UNEQUAL unequal.res|noicon.res unequal : [G] WINDOWS COMMON unequal UNEQUAL_EXTRA unequal.res|noicon.res
unequalsolver : [U] unequal[STANDALONE_SOLVER] latin[STANDALONE_SOLVER] tree234 maxflow STANDALONE unequalsolver : [U] unequal[STANDALONE_SOLVER] latin[STANDALONE_SOLVER] tree234 maxflow STANDALONE
unequalsolver : [C] unequal[STANDALONE_SOLVER] latin[STANDALONE_SOLVER] tree234 maxflow STANDALONE unequalsolver : [C] unequal[STANDALONE_SOLVER] latin[STANDALONE_SOLVER] tree234 maxflow STANDALONE
@ -12,7 +12,7 @@ unequalsolver : [C] unequal[STANDALONE_SOLVER] latin[STANDALONE_SOLVER] tree234
latincheck : [U] latin[STANDALONE_LATIN_TEST] tree234 maxflow STANDALONE latincheck : [U] latin[STANDALONE_LATIN_TEST] tree234 maxflow STANDALONE
latincheck : [C] latin[STANDALONE_LATIN_TEST] tree234 maxflow STANDALONE latincheck : [C] latin[STANDALONE_LATIN_TEST] tree234 maxflow STANDALONE
ALL += UNEQUAL ALL += unequal[COMBINED] UNEQUAL_EXTRA
!begin gtk !begin gtk
GAMES += unequal GAMES += unequal

View File

@ -1,12 +1,12 @@
# -*- makefile -*- # -*- makefile -*-
UNTANGLE = untangle tree234 UNTANGLE_EXTRA = tree234
untangle : [X] GTK COMMON UNTANGLE untangle-icon|no-icon untangle : [X] GTK COMMON untangle UNTANGLE_EXTRA untangle-icon|no-icon
untangle : [G] WINDOWS COMMON UNTANGLE untangle.res|noicon.res untangle : [G] WINDOWS COMMON untangle UNTANGLE_EXTRA untangle.res|noicon.res
ALL += UNTANGLE ALL += untangle[COMBINED] UNTANGLE_EXTRA
!begin gtk !begin gtk
GAMES += untangle GAMES += untangle