1 ## Makefile.am -- Process this file with automake to process Makefile.in
3 AUTOMAKE_OPTIONS = foreign
5 bin_PROGRAMS = hengband
8 artifact.c artifact.h \
10 angband.h autopick.c \
14 birth.c bldg.c chest.c chest.h chuukei.c \
15 cmd2.c cmd4.c cmd-activate.c cmd-activate.h cmd-eat.c cmd-eat.h \
16 cmd-item.c cmd-item.h cmd-magiceat.c cmd-magiceat.h \
17 cmd-mane.c cmd-mane.h cmd-pet.c cmd-pet.h \
18 cmd-quaff.c cmd-quaff.h cmd-read.c cmd-read.h cmd-spell.c cmd-spell.h \
19 cmd-usestaff.c cmd-usestaff.h cmd-zaprod.c cmd-zaprod.h cmd-zapwand.c \
20 cmd-zapwand.h cmd-smith.c cmd-smith.h cmd-hissatsu.c cmd-hissatsu.h\
22 defines.h dungeon.c effects.c externs.h files.c flavor.c \
24 floor.h floor-events.c floor-events.h floor-generate.c floor-generate.h \
25 floor-save.h floor-save.c \
26 floor-streams.c floor-streams.h \
29 geometry.c geometry.h \
31 gameoption.c gameoption.h gamevalue.h \
32 generate.h grid.c grid.h h-basic.h h-config.h h-define.h \
34 h-system.h h-type.h inet.c init1.c init2.c init.h japanese.c load.c \
35 main.c main-x11.c main-gcu.c \
36 melee.h melee1.c mind.c \
39 monsterrace-hook.c monsterrace-hook.h monster-process.c \
40 monster-status.c monster-status.h monster1.c \
41 monster2.c mspells1.c mspells2.c mspells3.c mspells4.c monster-spell.h \
43 mutation.h mutation.c \
45 object-boost.c object-boost.h \
46 object-curse.c object-curse.h object-broken.c object-broken.h \
47 object-hook.c object-hook.h object1.c object2.c \
48 objectkind-hook.c objectkind-hook.h \
52 projection.h projection.c\
54 player-move.c player-move.h player-damage.c player-damage.h player-status.c player-status.h \
60 realm-arcane.h realm-chaos.c realm-chaos.h realm-craft.c realm-craft.h \
61 realm-crusade.c realm-crusade.h realm-daemon.c realm-daemon.h realm-death.c \
62 realm-death.h realm-hex.c realm-hex.h realm-hissatsu.c realm-hissatsu.h \
63 realm-life.c realm-life.h realm-nature.c realm-nature.h realm-song.c \
64 realm-song.h realm-sorcery.c realm-sorcery.h realm-trump.c realm-trump.h \
65 report.c rooms.c rooms-city.c rooms-city.h rooms-fractal.c rooms-fractal.h \
66 rooms.h rooms-normal.c rooms-normal.h rooms-pitnest.c rooms-pitnest.h \
67 rooms-special.c rooms-special.h rooms-trap.c rooms-trap.h rooms-vault.c \
68 rooms-vault.h save.c scores.c selfinfo.c selfinfo.h shoot.c shoot.h snipe.c \
73 spells1.c spells2.c spells3.c \
74 spells-diceroll.c spells-diceroll.h \
75 spells-floor.c spells-floor.h \
76 spells-object.c spells-object.h \
77 spells-status.c spells-status.h \
78 spells-summon.c spells-summon.h \
79 spells-world.c spells-world.h \
82 store.h store.c tables.c term.c term.h trap.c trap.h types.h util.c \
83 variable.c wild.h wild.c wizard1.c wizard2.c \
84 warning.c warning.h world.c world.h \
89 z-form.c z-form.h z-rand.c z-rand.h z-term.c z-term.h z-util.c z-util.h \
92 EXTRA_hengband_SOURCES = \
93 angband.ico angband.rc ang_eng.rc maid-x11.c main-mac.c main-win.c \
94 main-cap.c main-dos.c main-ibm.c main-xaw.c \
95 makefile.bcc makefile.std makefile.dos makefile.ibm \
96 readdib.c readdib.h wall.bmp
99 cocoa/hengband_Icons.icns \
103 cocoa_plist_template = cocoa/Angband-Cocoa.xml
104 cocoa_plist_strings_template = cocoa/Angband-Cocoa.strings
105 cocoa_plist_files = \
106 cocoa/CommandMenu.plist
107 cocoa_en_nib_files = \
108 cocoa/en.lproj/MainMenu.nib/designable.nib \
109 cocoa/en.lproj/MainMenu.nib/keyedobjects.nib
110 cocoa_en_strings_files = \
111 cocoa/en.lproj/Localizable.strings \
112 cocoa/en.lproj/CommandMenu.strings \
113 cocoa/en.lproj/GraphicsMenu.strings
114 cocoa_ja_nib_files = \
115 cocoa/ja.lproj/MainMenu.nib/designable.nib \
116 cocoa/ja.lproj/MainMenu.nib/keyedobjects.nib
117 cocoa_ja_strings_files = \
118 cocoa/ja.lproj/Localizable.strings \
119 cocoa/ja.lproj/CommandMenu.strings \
120 cocoa/ja.lproj/GraphicsMenu.strings
124 $(cocoa_icon_files) \
125 $(cocoa_plist_template) \
126 $(cocoa_plist_strings_template) \
127 $(cocoa_plist_files) \
128 $(cocoa_en_nib_files) \
129 $(cocoa_en_strings_files) \
130 $(cocoa_ja_nib_files) \
131 $(cocoa_ja_strings_files)
134 hengband_SOURCES += main-cocoa.m grafmode.h grafmode.c
135 AM_CFLAGS = -mmacosx-version-min=10.7 -Wunguarded-availability
136 AM_OBJCFLAGS = -mmacosx-version-min=10.7 -Wunguarded-availability
137 hengband_LDFLAGS = -framework cocoa $(AM_LDFLAGS)
138 hengband_LINK = MACOSX_DEPLOYMENT_TARGET=10.7 $(OBJCLINK) $(hengband_LDFLAGS) $(LDFLAGS) -o $@
139 APPNAME = $(PACKAGE_NAME)
141 APPDIR = $(APPNAME).app
142 BUNDLE_IDENTIFIER = jp.osdn.hengband
143 BUNDLE_VERSION = $(PACKAGE_VERSION)
144 BUNDLE_DISPLAY_NAME = $(APPNAME)
145 BUNDLE_NAME = $(BUNDLE_DISPLAY_NAME)
146 BUNDLE_DISPLAY_NAME_JA = 変愚蛮怒
147 BUNDLE_NAME_JA = $(BUNDLE_DISPLAY_NAME_JA)
148 # Be careful with characters (like '&') in the copyright that have special
150 COPYRIGHT = Copyright © Mr. Hoge and many others
151 # For now, using the English version. Should be localized to Japanese.
152 COPYRIGHT_JA = $(COPYRIGHT)
153 APPBNDL = $(bindir)/$(APPDIR)
154 APPCONT = $(APPBNDL)/Contents
155 APPBIN = $(APPCONT)/MacOS
156 APPRES = $(APPCONT)/Resources
157 appbin_PROGRAMS = $(APPEXE)
158 appbindir = $(APPBIN)
159 dist_appicon_DATA = $(cocoa_icon_files)
160 appicondir = $(APPRES)
161 appplist_DATA = $(cocoa_plist_files)
162 appplistdir = $(APPRES)
163 appennib_DATA = $(cocoa_en_nib_files)
164 appennibdir = $(APPRES)/en.lproj/MainMenu.nib
165 appen_DATA = $(cocoa_en_strings_files)
166 appendir = $(APPRES)/en.lproj
167 appjanib_DATA = $(cocoa_ja_nib_files)
168 appjanibdir = $(APPRES)/ja.lproj/MainMenu.nib
169 appja_DATA = $(cocoa_ja_strings_files)
170 appjadir = $(APPRES)/ja.lproj
172 EXTRA_hengband_SOURCES += main-cocoa.m grafmode.h grafmode.c
173 hengband_LINK = $(LINK)
176 COMPILE = $(srcdir)/gcc-wrap $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
177 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
178 OBJCCOMPILE = $(srcdir)/gcc-wrap $(OBJC) $(DEFS) $(DEFAULT_INCLUDES) \
179 $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_OBJCFLAGS) $(OBJCFLAGS)
183 chgrp "@GAMEGROUP@" "$(DESTDIR)$(bindir)/hengband"
184 chmod g+s "$(DESTDIR)$(bindir)/hengband"
188 # Create lib/info within the application bundle since not currently
189 # installing anything to it. Other relevant lib directories should
190 # be created from the Makefiles in the lib directory.
193 @mkdir -p $(appendir)
194 @mkdir -p $(appjadir)
195 @mkdir -p $(APPRES)/lib/info
196 sed -e 's/\$$VERSION\$$/$(PACKAGE_VERSION)/' \
197 -e 's/\$$COPYRIGHT\$$/$(COPYRIGHT)/' \
198 -e 's/\$$NAME\$$/$(APPNAME)/' \
199 -e 's/\$$EXECUTABLE\$$/$(APPEXE)/' \
200 -e 's/\$$BUNDLE_VERSION\$$/$(BUNDLE_VERSION)/' \
201 -e 's/\$$BUNDLE_IDENTIFIER\$$/$(BUNDLE_IDENTIFIER)/' \
202 -e 's/\$$BUNDLE_DISPLAY_NAME\$$/$(BUNDLE_DISPLAY_NAME)/' \
203 -e 's/\$$BUNDLE_NAME\$$/$(BUNDLE_NAME)/' \
204 $(srcdir)/$(cocoa_plist_template) > $(APPCONT)/Info.plist
205 sed -e 's/\$$VERSION\$$/$(PACKAGE_VERSION)/' \
206 -e 's/\$$COPYRIGHT\$$/$(COPYRIGHT)/' \
207 -e 's/\$$BUNDLE_DISPLAY_NAME\$$/$(BUNDLE_DISPLAY_NAME)/' \
208 -e 's/\$$BUNDLE_NAME\$$/$(BUNDLE_NAME)/' \
209 $(srcdir)/$(cocoa_plist_strings_template) > $(appendir)/InfoPlist.strings
210 sed -e 's/\$$VERSION\$$/$(PACKAGE_VERSION)/' \
211 -e 's/\$$COPYRIGHT\$$/$(COPYRIGHT_JA)/' \
212 -e 's/\$$BUNDLE_DISPLAY_NAME\$$/$(BUNDLE_DISPLAY_NAME_JA)/' \
213 -e 's/\$$BUNDLE_NAME\$$/$(BUNDLE_NAME_JA)/' \
214 $(srcdir)/$(cocoa_plist_strings_template) > $(appjadir)/InfoPlist.strings
217 -rm $(APPCONT)/Info.plist
218 -rm $(appendir)/InfoPlist.strings
219 -rm $(appjadir)/InfoPlist.strings