ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/BasiliskII/src/MacOSX/Makefile.in
(Generate patch)

Comparing BasiliskII/src/MacOSX/Makefile.in (file contents):
Revision 1.25 by gbeauche, 2007-06-15T17:11:46Z vs.
Revision 1.32 by nigel, 2009-11-07T08:05:42Z

# Line 3 | Line 3
3   ## System specific configuration
4   SHELL = /bin/sh
5  
6 < HOST_CC = gcc
7 < HOST_CXX = g++
8 < CC = @CC@ -arch $(ARCH)
9 < CXX = @CXX@ -arch $(ARCH)
10 < CFLAGS = @CFLAGS@ -g
11 < CXXFLAGS = @CXXFLAGS@ -g
12 < CPPFLAGS = @CPPFLAGS@ -I../include -I. -I../uae_cpu
6 > HOST_CC = @CC@
7 > HOST_CXX = @CXX@
8 > CC_PROG = @CC@
9 > CXX_PROG = @CXX@
10 > CFLAGS = @CFLAGS@
11 > CXXFLAGS = @CXXFLAGS@
12 > CPPFLAGS = @CPPFLAGS@ -I../include -I. @CPUINCLUDES@ -I../slirp
13   DEFS = @DEFS@ @DEFINES@ -D_REENTRANT -DAQUA -DFPU_IEEE
14   LDFLAGS = @LDFLAGS@
15   LIBS = @LIBS@
16 < MONSRCS = @MONSRCS@
17 < BLESS = @BLESS@
16 >
17 > CFLAGS   += -g
18 > CPPFLAGS += -I../uae_cpu
19 > CXXFLAGS += -g
20   LN_S = ln -s
21  
22 < ## slirp network emulation code
23 < WANT_SLIRP = @WANT_SLIRP@
24 < ifeq ($(WANT_SLIRP), yes)
25 < CPPFLAGS += -I../slirp
22 > ## Compilers selection (XXX hackery for 10.2 cross-compilation...)
23 > SDK_VERSION.ppc = @PPC_SDK_VERSION@
24 > SDK_VERSION = $(SDK_VERSION.$(ARCH))
25 > ifeq ($(SDK_VERSION), 10.2.8)
26 >  CC_PROG = gcc-3.3
27 >  CXX_PROG = g++-3.3
28 >  SDK_ROOT = /Developer/SDKs/MacOSX10.2.8.sdk
29 >  CC_ROOT = -F$(SDK_ROOT)/System/Library/Frameworks
30 >  LDFLAGS += -Wl,-syslibroot,$(SDK_ROOT)
31 > endif
32 > ifeq ($(SDK_VERSION), 10.3.9)
33 >  CC_ROOT = -isysroot /Developer/SDKs/MacOSX10.3.9.sdk -mmacosx-version-min=10.3
34 > endif
35 > ifeq ($(SDK_VERSION), 10.4)
36 >  CC_ROOT = -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4
37 > endif
38 > CC = $(CC_PROG) $(CC_ROOT) -arch $(ARCH)
39 > CXX = $(CXX_PROG) $(CC_ROOT) -arch $(ARCH)
40 >
41   SLIRP_CFLAGS = @SLIRP_CFLAGS@
42   SLIRP_SRCS = @SLIRP_SRCS@
43   SLIRP_OBJS = $(SLIRP_SRCS:../slirp/%.c=obj/%.o)
27 endif
44  
45   ## CPU emulation code
46   WANT_JIT = @WANT_JIT@
# Line 38 | Line 54 | GEN_CPUSRCS = \
54          cpuemu1.cpp cpuemu2.cpp cpuemu3.cpp cpuemu4.cpp \
55          cpuemu5.cpp cpuemu6.cpp cpuemu7.cpp cpuemu8.cpp
56   ifeq ($(ARCH), i386)
57 < USE_JIT = $(WANT_JIT)
58 < DEFS += -DUNALIGNED_PROFITABLE -DREGPARAM="__attribute__((regparm(3)))"
59 < DEFS += -DX86_ASSEMBLY -DOPTIMIZED_FLAGS -DSAHF_SETO_PROFITABLE
57 >  USE_JIT = $(WANT_JIT)
58 >  DEFS += -DUNALIGNED_PROFITABLE -DREGPARAM="__attribute__((regparm(3)))"
59 >  DEFS += -DX86_ASSEMBLY -DOPTIMIZED_FLAGS -DSAHF_SETO_PROFITABLE
60   endif
61   ifeq ($(ARCH), x86_64)
62 < USE_JIT = $(WANT_JIT)
63 < DEFS += -DUNALIGNED_PROFITABLE
64 < DEFS += -DX86_64_ASSEMBLY -DOPTIMIZED_FLAGS
62 >  USE_JIT = $(WANT_JIT)
63 >  DEFS += -DUNALIGNED_PROFITABLE
64 >  DEFS += -DX86_64_ASSEMBLY -DOPTIMIZED_FLAGS
65   endif
66   ifeq ($(USE_JIT), yes)
67 < DEFS += -DUSE_JIT -DUSE_JIT_FPU
68 < ifeq ($(WANT_JIT_DEBUG), yes)
69 < DEFS += -DJIT_DEBUG
70 < endif
71 < CPUSRCS += \
67 >  DEFS += -DUSE_JIT -DUSE_JIT_FPU
68 >  ifeq ($(WANT_JIT_DEBUG), yes)
69 >    DEFS += -DJIT_DEBUG
70 >  endif
71 >  CPUSRCS += \
72          ../uae_cpu/compiler/compemu_support.cpp \
73          ../uae_cpu/compiler/compemu_fpp.cpp
74 < GEN_CPUSRCS += \
74 >  GEN_CPUSRCS += \
75          cpuemu1_nf.cpp cpuemu2_nf.cpp cpuemu3_nf.cpp cpuemu4_nf.cpp \
76          cpuemu5_nf.cpp cpuemu6_nf.cpp cpuemu7_nf.cpp cpuemu8_nf.cpp \
77          compemu1.cpp compemu2.cpp compemu3.cpp compemu4.cpp \
# Line 65 | Line 81 | endif
81  
82   GEN_DIR = gen
83   ifneq ($(ARCH),)
84 < GEN_DIR = gen.$(ARCH)
84 >  GEN_DIR = gen.$(ARCH)
85   endif
86   CPUSRCS += $(foreach file, $(GEN_CPUSRCS), $(GEN_DIR)/$(file))
87   CPPFLAGS += -I$(GEN_DIR)
88  
89 + ## Source files thst replace/augment the ones from the Unix directory
90 + SYSSRCS = serial_unix.cpp ../dummy/scsi_dummy.cpp \
91 +    audio_macosx.cpp AudioBackEnd.cpp AudioDevice.cpp MacOSX_sound_if.cpp \
92 +    clip_macosx.cpp Controller.mm Emulator.mm EmulatorView.mm \
93 +    ether_unix.cpp extfs_macosx.cpp  main_macosx.mm misc_macosx.mm \
94 +    NNThread.m prefs_macosx.cpp PrefsEditor.mm sys_darwin.cpp video_macosx.mm
95 +
96   ## Files
97 < UNIXSRCS = vm_alloc.cpp vm_alloc.h sigsegv.cpp sigsegv.h video_vosf.h video_blit.cpp \
98 <    xpram_unix.cpp user_strings_unix.cpp user_strings_unix.h \
76 <    serial_unix.cpp ether_unix.cpp sys_unix.cpp timer_unix.cpp \
77 <    sshpty.c sshpty.h strlcpy.c strlcpy.h semaphore.h
78 < SRCS = ../main.cpp main_macosx.mm ../prefs.cpp ../prefs_items.cpp prefs_macosx.mm \
79 <    sys_unix.cpp sys_darwin.cpp ../rom_patches.cpp ../slot_rom.cpp ../rsrc_patches.cpp \
97 > SRCS = ../main.cpp ../prefs.cpp ../prefs_items.cpp \
98 >    sys_unix.cpp ../rom_patches.cpp ../slot_rom.cpp ../rsrc_patches.cpp \
99      ../emul_op.cpp ../macos_util.cpp ../xpram.cpp xpram_unix.cpp ../timer.cpp \
100 <    timer_unix.cpp ../adb.cpp ../serial.cpp serial_unix.cpp ../ether.cpp ether_unix.cpp \
101 <    ../sony.cpp ../disk.cpp ../cdrom.cpp ../scsi.cpp ../video.cpp video_macosx.mm \
102 <    vm_alloc.cpp sigsegv.cpp ../audio.cpp ../extfs.cpp extfs_macosx.mm \
103 <    ../user_strings.cpp user_strings_unix.cpp clip_macosx.cpp misc_macosx.mm \
104 <    ../dummy/scsi_dummy.cpp \
105 <    audio_macosx.cpp AudioBackEnd.cpp AudioDevice.cpp MacOSX_sound_if.cpp \
106 <    NNThread.m Emulator.mm EmulatorView.mm Controller.mm PrefsEditor.mm \
107 <    sshpty.c strlcpy.c \
108 <    $(MONSRCS) $(CPUSRCS) $(SLIRP_SRCS)
100 >    timer_unix.cpp ../adb.cpp ../serial.cpp ../ether.cpp \
101 >    ../sony.cpp ../disk.cpp ../cdrom.cpp ../scsi.cpp ../video.cpp \
102 >    vm_alloc.cpp sigsegv.cpp ../audio.cpp ../extfs.cpp \
103 >    ../user_strings.cpp user_strings_unix.cpp sshpty.c strlcpy.c \
104 >    $(SYSSRCS) $(CPUSRCS) $(SLIRP_SRCS)
105 >
106 > ## Source files from Unix source directory that we link to
107 > UNIXSRCS = ether_unix.cpp semaphore.h serial_unix.cpp sigsegv.cpp sigsegv.h \
108 >    sshpty.c sshpty.h strlcpy.c strlcpy.h sys_unix.cpp timer_unix.cpp \
109 >    user_strings_unix.cpp user_strings_unix.h \
110 >    vm_alloc.cpp vm_alloc.h xpram_unix.cpp
111  
112   ## Documentation files
113   DOCS = README.txt Credits.html ToDo.html HowTo.html Versions.html
# Line 97 | Line 118 | APP_APP = $(APP).app
118   TARGET_ARCHES = @TARGET_ARCHES@
119   PROGS = $(foreach arch, $(TARGET_ARCHES), $(APP).$(arch))
120  
121 + BLESS = $(OBJ_DIR)/lowmem
122 +
123   ## Rules
124   .PHONY: modules install installdirs uninstall mostlyclean clean distclean depend dep
125   .SUFFIXES:
# Line 111 | Line 134 | $(UNIXSRCS): %: ../Unix/%
134  
135   OBJ_DIR = obj
136   ifneq ($(ARCH),)
137 < OBJ_DIR = obj.$(ARCH)
137 >  OBJ_DIR = obj.$(ARCH)
138   endif
139   $(OBJ_DIR)::
140          @[ -d $(OBJ_DIR) ] || mkdir $(OBJ_DIR) > /dev/null 2>&1
# Line 140 | Line 163 | $(foreach arch,$(TARGET_ARCHES),$(eval $
163  
164   links: $(UNIXSRCS)
165  
166 < $(OBJ_DIR)/$(APP): $(OBJ_DIR) $(GEN_DIR) $(OBJS)
166 > $(BLESS): $(OBJ_DIR) $(OBJ_DIR)/lowmem.o
167 >        $(HOST_CC) -o $@ $(OBJ_DIR)/lowmem.o
168 > $(OBJ_DIR)/lowmem.o: ../Unix/Darwin/lowmem.c
169 >        $(HOST_CC) -o $@ -c $<
170 >
171 > $(OBJ_DIR)/$(APP): $(OBJ_DIR) $(GEN_DIR) $(OBJS) $(BLESS)
172          $(CXX) -o $@ $(LDFLAGS) $(OBJS) $(LIBS)
173          $(BLESS) $@
174  
175   $(APP)_app: $(APP) $(DOCS) Info.plist $(APP).icns
176 +        rm -rf $(APP_APP)/Contents
177          mkdir -p $(APP_APP)/Contents
178          cp -f ../MacOSX/Info.plist $(APP_APP)/Contents/
179          echo -n 'APPL????' > $(APP_APP)/Contents/PkgInfo
180          mkdir -p $(APP_APP)/Contents/MacOS
181          cp -f $(APP) $(APP_APP)/Contents/MacOS/
182 <        strip $(APP_APP)/Contents/MacOS/$(APP)
182 >        strip -x $(APP_APP)/Contents/MacOS/$(APP)
183          mkdir -p $(APP_APP)/Contents/Resources
184          cp -Rp English.lproj $(APP_APP)/Contents/Resources/
185          cp -f $(APP).icns $(APP_APP)/Contents/Resources/
# Line 158 | Line 187 | $(APP)_app: $(APP) $(DOCS) Info.plist $(
187          find $(APP_APP) -type d -name CVS | xargs rm -rf
188  
189   mostlyclean:
190 <        rm -rf $(APP_APP)
191 <        rm -f $(PROGS) $(OBJ_DIR)/* $(OBJ_DIR).*/* core* *.core *~ *.bak
190 >        rm -f $(PROGS) $(OBJ_DIR)/* core* *.core *~ *.bak
191 >        rm -f $(foreach arch, $(TARGET_ARCHES), $(GEN_DIR).$(arch)/*)
192 >        rm -f $(foreach arch, $(TARGET_ARCHES), $(OBJ_DIR).$(arch)/*)
193  
194   clean: mostlyclean
195          rm -f $(UNIXSRCS)
196 <        rm -f $(GEN_DIR).*/*
196 >        rm -f README.txt
197  
198   distclean: clean
199 <        rm -rf $(OBJ_DIR)
199 >        rm -rf $(foreach arch, $(TARGET_ARCHES), $(GEN_DIR).$(arch))
200 >        rm -rf $(foreach arch, $(TARGET_ARCHES), $(OBJ_DIR).$(arch))
201          rm -rf autom4te.cache
202          rm -f Makefile
203 <        rm -f config.cache config.log config.status config.h
173 <        rm -f Darwin/lowmem Darwin/pagezero
203 >        rm -f config.cache config.log config.status config.h configure
204  
205   depend dep:
206          makedepend $(CPPFLAGS) -Y. $(SRCS) 2>/dev/null
# Line 193 | Line 223 | $(OBJ_DIR)/%.ho : %.cpp
223          $(HOST_CXX) $(CPPFLAGS) $(DEFS) $(CXXFLAGS) -c $< -o $@
224  
225   $(OBJ_DIR)/build68k: $(OBJ_DIR)/build68k.ho
226 <        $(HOST_CC) $(LDFLAGS) -o $@ $(OBJ_DIR)/build68k.ho
226 >        $(HOST_CC) -o $@ $(OBJ_DIR)/build68k.ho
227   $(OBJ_DIR)/gencpu: $(OBJ_DIR)/gencpu.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
228 <        $(HOST_CXX) $(LDFLAGS) -o $@ $(OBJ_DIR)/gencpu.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
228 >        $(HOST_CXX) -o $@ $(OBJ_DIR)/gencpu.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
229   $(OBJ_DIR)/gencomp: $(OBJ_DIR)/gencomp.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
230 <        $(HOST_CXX) $(LDFLAGS) -o $@ $(OBJ_DIR)/gencomp.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
230 >        $(HOST_CXX) -o $@ $(OBJ_DIR)/gencomp.ho $(OBJ_DIR)/readcpu.ho $(OBJ_DIR)/cpudefs.ho
231  
232   $(GEN_DIR)::
233          @[ -d $(GEN_DIR) ] || mkdir $(GEN_DIR) > /dev/null 2>&1
234  
235   $(GEN_DIR)/cpudefs.cpp: $(OBJ_DIR)/build68k ../uae_cpu/table68k
236          $(OBJ_DIR)/build68k <../uae_cpu/table68k > $@
237 < $(GEN_DIR)/cpustbl.cpp: $(GEN_DIR)/cpuemu.cpp
237 > $(GEN_DIR)/cpustbl.cpp:    $(GEN_DIR)/cpuemu.cpp
238   $(GEN_DIR)/cpustbl_nf.cpp: $(GEN_DIR)/cpustbl.cpp
239 < $(GEN_DIR)/compstbl.cpp: $(GEN_DIR)/compemu.cpp
240 < $(GEN_DIR)/cputbl.h: $(GEN_DIR)/cpuemu.cpp
241 < $(GEN_DIR)/comptbl.h: $(GEN_DIR)/compemu.cpp
239 > $(GEN_DIR)/compstbl.cpp:   $(GEN_DIR)/compemu.cpp
240 > $(GEN_DIR)/cputbl.h:       $(GEN_DIR)/cpuemu.cpp
241 > $(GEN_DIR)/comptbl.h:      $(GEN_DIR)/compemu.cpp
242  
243   $(GEN_DIR)/cpuemu.cpp: $(OBJ_DIR)/gencpu
244          cd $(GEN_DIR) && ../$(OBJ_DIR)/gencpu

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines