]> git.saurik.com Git - apple/boot.git/blobdiff - Makefile
boot-111.1.tar.gz
[apple/boot.git] / Makefile
index 8dd71492f731ee6dc1865bc02cef37485d123e21..7c6f3807f80f7ae88131d3c7e972bf48b95cecf6 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -2,7 +2,7 @@ export USE_APPLE_PB_SUPPORT = all
 
 #      Makefile for kernel booter
 
-# CFLAGS       = -O $(MORECPP) -arch i386 -g -munaligned-text
+# CFLAGS       = -O $(MORECPP) -arch i386 -g 
 DEFINES=
 CONFIG = hd
 LIBDIR = libsa
@@ -24,7 +24,7 @@ ARCHLESS_RC_CFLAGS=`echo $(RC_CFLAGS) | sed 's/-arch [a-z0-9]*//g'`
 
 VPATH = $(OBJROOT):$(SYMROOT)
 
-GENERIC_SUBDIRS = gen
+GENERIC_SUBDIRS =
 
 #
 # Currently builds for i386
@@ -42,6 +42,15 @@ all tags clean debug install installhdrs: $(SYMROOT) $(OBJROOT)
                ( OBJROOT=$(OBJROOT)/$${i};                               \
                  SYMROOT=$(SYMROOT)/$${i};                               \
                  DSTROOT=$(DSTROOT);                                     \
+                 XCFLAGS=$(ARCHLESS_RC_CFLAGS);                          \
+                 GENSUBDIRS="$(GENERIC_SUBDIRS)";                        \
+                 for x in $$GENSUBDIRS;                                  \
+                 do                                                      \
+                     if [ "$$x" == "$$i" ]; then                         \
+                         XCFLAGS="$(RC_CFLAGS)";                         \
+                         break;                                          \
+                     fi                                                  \
+                 done;                                                   \
                  echo "$$OBJROOT $$SYMROOT $$DSTROOT"; \
                    cd $$i; ${MAKE}                                       \
                        "OBJROOT=$$OBJROOT"                               \
@@ -52,7 +61,7 @@ all tags clean debug install installhdrs: $(SYMROOT) $(OBJROOT)
                        "TARGET=$$i"                                      \
                        "RC_KANJI=$(RC_KANJI)"                            \
                        "JAPANESE=$(JAPANESE)"                            \
-                       "RC_CFLAGS=$(ARCHLESS_RC_CFLAGS)" $@                      \
+                       "RC_CFLAGS=$$XCFLAGS" $@                          \
                ) || exit $?;                                             \
            else                                                          \
                echo "========= nothing to build for $$i =========";      \