[llvm-commits] [compiler-rt] r93319 - in /compiler-rt/trunk: Makefile make/AppleBI.mk make/config.mk make/subdir.mk make/util.mk

Daniel Dunbar daniel at zuster.org
Wed Jan 13 08:13:01 PST 2010


Author: ddunbar
Date: Wed Jan 13 10:13:01 2010
New Revision: 93319

URL: http://llvm.org/viewvc/llvm-project?rev=93319&view=rev
Log:
Tidy up comments, remove whitespace, and rename 'print-%' make debugging target
to 'make-print-%' to match LLVM.

Modified:
    compiler-rt/trunk/Makefile
    compiler-rt/trunk/make/AppleBI.mk
    compiler-rt/trunk/make/config.mk
    compiler-rt/trunk/make/subdir.mk
    compiler-rt/trunk/make/util.mk

Modified: compiler-rt/trunk/Makefile
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/Makefile?rev=93319&r1=93318&r2=93319&view=diff

==============================================================================
--- compiler-rt/trunk/Makefile (original)
+++ compiler-rt/trunk/Makefile Wed Jan 13 10:13:01 2010
@@ -5,9 +5,8 @@
 
 include make/config.mk
 include make/util.mk
-# If SRCROOT is defined, assume we are doing an Apple style build. We
-# should be able to use RC_XBS for this but that is unused during
-# "make installsrc".
+# If SRCROOT is defined, assume we are doing an Apple style build. We should be
+# able to use RC_XBS for this but that is unused during "make installsrc".
 ifdef SRCROOT
   include make/AppleBI.mk
 endif
@@ -75,7 +74,7 @@
 endef
 
 # Template: CNA_template Config Arch
-# 
+#
 # This template is used once per Config/Arch at the top-level.
 define CNA_template
 $(call Set,ActiveConfig,$1)
@@ -84,10 +83,9 @@
 $(call Set,ActiveLibGen,$(ActiveObjPath)/libcompiler_rt.Generic.a)
 $(call Set,ActiveLibOpt,$(ActiveObjPath)/libcompiler_rt.Optimized.a)
 
-# Initialize inputs lists. This are extended by the CNA_subdir
-# template. The one tricky bit is that we need to use these quoted,
-# because they are not complete until the entire makefile has been
-# processed.
+# Initialize inputs lists. This are extended by the CNA_subdir template. The one
+# tricky bit is that we need to use these quoted, because they are not complete
+# until the entire makefile has been processed.
 $(call Set,GenericInputs.$(ActiveConfig).$(ActiveArch),)
 $(call Set,OptimizedInputs.$(ActiveConfig).$(ActiveArch),)
 # Final.Inputs is created once we have loaded all the subdirectories
@@ -124,10 +122,10 @@
 ###
 # How to build things.
 
-# Define rules for building on each configuration & architecture. This
-# is not exactly obvious, but variables inside the template are being
-# expanded during the make processing, so automatic variables must be
-# quoted and normal assignment cannot be used.
+# Define rules for building on each configuration & architecture. This is not
+# exactly obvious, but variables inside the template are being expanded during
+# the make processing, so automatic variables must be quoted and normal
+# assignment cannot be used.
 
 # Template: CNA_template Config Arch Dir
 #   Uses: GetArgs, Dependencies, ObjNames
@@ -143,8 +141,7 @@
 $(call Set,ActiveFlags,$(call GetArgs,$(ActiveConfig),$(ActiveArch)))
 $(call Set,ActiveObjects,$(ObjNames:%=$(ActiveObjPath)/%))
 
-# Add to the input list for the appropriate library and update the
-# dependency.
+# Add to the input list for the appropriate library and update the dependency.
 $(call Append,$(Target).Inputs.$(ActiveConfig).$(ActiveArch),$(ActiveObjects))
 $(ProjObjRoot)/$(ActiveConfig)/$(ActiveArch)/libcompiler_rt.$(Target).a: $(ActiveObjects)
 

Modified: compiler-rt/trunk/make/AppleBI.mk
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/make/AppleBI.mk?rev=93319&r1=93318&r2=93319&view=diff

==============================================================================
--- compiler-rt/trunk/make/AppleBI.mk (original)
+++ compiler-rt/trunk/make/AppleBI.mk Wed Jan 13 10:13:01 2010
@@ -12,17 +12,16 @@
   ProjObjRoot := $(ProjSrcRoot)
 endif
 
-# We override this with RC_ARCHS because B&I may want to build on an
-# ARCH we haven't explicitly defined support for. If all goes well,
-# this will just work and the resulting lib will just have generic
-# versions for anything unknown.
+# We override this with RC_ARCHS because B&I may want to build on an ARCH we
+# haven't explicitly defined support for. If all goes well, this will just work
+# and the resulting lib will just have generic versions for anything unknown.
 Archs := $(RC_ARCHS)
 
-# log full compile lines in B&I logs and omit summary lines
-Verb := 
+# Log full compile lines in B&I logs and omit summary lines.
+Verb :=
 Summary := @true
 
-# list of functions needed for each architecture
+# List of functions needed for each architecture.
 Funcs_all = absvdi2.o absvsi2.o addvdi3.o addvsi3.o ashldi3.o ashrdi3.o \
             clzdi2.o clzsi2.o cmpdi2.o ctzdi2.o ctzsi2.o \
             divdc3.o divdi3.o divsc3.o ffsdi2.o \
@@ -32,14 +31,14 @@
             mulsc3.o mulvdi3.o mulvsi3.o negdi2.o negvdi2.o negvsi2.o \
             paritydi2.o paritysi2.o popcountdi2.o popcountsi2.o powidf2.o \
             powisf2.o subvdi3.o subvsi3.o ucmpdi2.o udivdi3.o \
-            udivmoddi4.o umoddi3.o apple_versioning.o eprintf.o 
+            udivmoddi4.o umoddi3.o apple_versioning.o eprintf.o
 Funcs_i386    = divxc3.o fixunsxfdi.o fixunsxfsi.o fixxfdi.o floatdixf.o \
                 floatundixf.o mulxc3.o powixf2.o clear_cache.o \
-				enable_execute_stack.o 
+                enable_execute_stack.o
 Funcs_ppc     = divtc3.o fixtfdi.o fixunstfdi.o floatditf.o floatunditf.o \
                 gcc_qadd.o gcc_qdiv.o gcc_qmul.o gcc_qsub.o multc3.o \
                 powitf2.o restFP.o saveFP.o trampoline_setup.o \
-				clear_cache.o enable_execute_stack.o
+                clear_cache.o enable_execute_stack.o
 Funcs_x86_64  = absvti2.o addvti3.o ashlti3.o ashrti3.o clzti2.o cmpti2.o \
                 ctzti2.o divti3.o divxc3.o ffsti2.o fixdfti.o fixsfti.o \
                 fixunsdfti.o fixunssfti.o fixunsxfdi.o fixunsxfsi.o \
@@ -49,50 +48,49 @@
                 mulvti3.o mulxc3.o negti2.o negvti2.o parityti2.o \
                 popcountti2.o powixf2.o subvti3.o ucmpti2.o udivmodti4.o \
                 udivti3.o umodti3.o clear_cache.o enable_execute_stack.o
-Funcs_armv6 =	adddf3vfp.o addsf3vfp.o bswapdi2.o bswapsi2.o divdf3vfp.o \
-				divsf3vfp.o eqdf2vfp.o eqsf2vfp.o extendsfdf2vfp.o \
-				fixdfsivfp.o fixsfsivfp.o fixunsdfsivfp.o fixunssfsivfp.o \
-				floatsidfvfp.o floatsisfvfp.o floatunssidfvfp.o floatunssisfvfp.o \
-				gedf2vfp.o gesf2vfp.o gtdf2vfp.o gtsf2vfp.o \
-				ledf2vfp.o lesf2vfp.o ltdf2vfp.o ltsf2vfp.o \
-				muldf3vfp.o mulsf3vfp.o \
-				nedf2vfp.o negdf2vfp.o negsf2vfp.o nesf2vfp.o \
-				subdf3vfp.o subsf3vfp.o truncdfsf2vfp.o unorddf2vfp.o unordsf2vfp.o \
-				modsi3.o umodsi3.o udivsi3.o divsi3.o switch.o save_restore_d8_d15.o
+Funcs_armv6 =   adddf3vfp.o addsf3vfp.o bswapdi2.o bswapsi2.o divdf3vfp.o \
+                divsf3vfp.o eqdf2vfp.o eqsf2vfp.o extendsfdf2vfp.o \
+                fixdfsivfp.o fixsfsivfp.o fixunsdfsivfp.o fixunssfsivfp.o \
+                floatsidfvfp.o floatsisfvfp.o floatunssidfvfp.o floatunssisfvfp.o \
+                gedf2vfp.o gesf2vfp.o gtdf2vfp.o gtsf2vfp.o \
+                ledf2vfp.o lesf2vfp.o ltdf2vfp.o ltsf2vfp.o \
+                muldf3vfp.o mulsf3vfp.o \
+                nedf2vfp.o negdf2vfp.o negsf2vfp.o nesf2vfp.o \
+                subdf3vfp.o subsf3vfp.o truncdfsf2vfp.o unorddf2vfp.o unordsf2vfp.o \
+                modsi3.o umodsi3.o udivsi3.o divsi3.o switch.o save_restore_d8_d15.o
 
 
-# copies any public headers to DSTROOT
+# Copies any public headers to DSTROOT.
 installhdrs:
 
 
-# copies source code to SRCROOT
+# Copies source code to SRCROOT.
 installsrc:
-	cp -r . $(SRCROOT)
+    cp -r . $(SRCROOT)
 
 
-# copy results to DSTROOT
+# Copy results to DSTROOT.
 install:  $(SYMROOT)/usr/local/lib/system/libcompiler_rt.a
-	mkdir -p $(DSTROOT)/usr/local/lib/system
-	cp $(SYMROOT)/usr/local/lib/system/libcompiler_rt.a \
-				$(DSTROOT)/usr/local/lib/system/libcompiler_rt.a
-	cd $(DSTROOT)/usr/local/lib/system; \
-	ln -s libcompiler_rt.a libcompiler_rt_profile.a; \
-	ln -s libcompiler_rt.a libcompiler_rt_debug.a
+    mkdir -p $(DSTROOT)/usr/local/lib/system
+    cp $(SYMROOT)/usr/local/lib/system/libcompiler_rt.a \
+                $(DSTROOT)/usr/local/lib/system/libcompiler_rt.a
+    cd $(DSTROOT)/usr/local/lib/system; \
+    ln -s libcompiler_rt.a libcompiler_rt_profile.a; \
+    ln -s libcompiler_rt.a libcompiler_rt_debug.a
 
 
-# rule to make fat libcompiler_rt.a
+# Rule to make fat libcompiler_rt.a.
 $(SYMROOT)/usr/local/lib/system/libcompiler_rt.a : $(foreach arch,$(Archs), \
                                                     $(OBJROOT)/$(arch)-pruned.a)
-	mkdir -p $(SYMROOT)/usr/local/lib/system
-	lipo -create $^ -o  $@
+    mkdir -p $(SYMROOT)/usr/local/lib/system
+    lipo -create $^ -o  $@
 
 
-# rule to make filter each architecture of libcompiler_rt.a
-# adds project info so that "what /usr/lib/libSystem.B.dylib" will work
+# Rule to add project info so that "what /usr/lib/libSystem.B.dylib" will work.
 $(OBJROOT)/%-pruned.a : $(OBJROOT)/Release/%/libcompiler_rt.Optimized.a
-	mkdir -p $(OBJROOT)/$*.tmp	
-	cd $(OBJROOT)/$*.tmp; \
-	/Developer/Makefiles/bin/version.pl $(RC_ProjectName) > $(OBJROOT)/version.c; \
-	gcc -arch $* -c ${OBJROOT}/version.c -o version.o; \
-	ar -x $<  $(Funcs_all) $(Funcs_$*); \
-	libtool -static *.o -o $@
+    mkdir -p $(OBJROOT)/$*.tmp
+    cd $(OBJROOT)/$*.tmp; \
+    /Developer/Makefiles/bin/version.pl $(RC_ProjectName) > $(OBJROOT)/version.c; \
+    gcc -arch $* -c ${OBJROOT}/version.c -o version.o; \
+    ar -x $<  $(Funcs_all) $(Funcs_$*); \
+    libtool -static *.o -o $@

Modified: compiler-rt/trunk/make/config.mk
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/make/config.mk?rev=93319&r1=93318&r2=93319&view=diff

==============================================================================
--- compiler-rt/trunk/make/config.mk (original)
+++ compiler-rt/trunk/make/config.mk Wed Jan 13 10:13:01 2010
@@ -3,9 +3,8 @@
 
 OS := $(shell uname)
 
-# Assume make is always run from top-level of source directory. Note
-# than an Apple style build overrides these variables later in the
-# makefile.
+# Assume make is always run from top-level of source directory. Note than an
+# Apple style build overrides these variables later in the makefile.
 ProjSrcRoot := $(shell pwd)
 ProjObjRoot := $(ProjSrcRoot)
 
@@ -73,7 +72,7 @@
 ifndef VERBOSE
   Verb := @
 else
-  Verb := 
+  Verb :=
 endif
 
 Echo := @echo

Modified: compiler-rt/trunk/make/subdir.mk
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/make/subdir.mk?rev=93319&r1=93318&r2=93319&view=diff

==============================================================================
--- compiler-rt/trunk/make/subdir.mk (original)
+++ compiler-rt/trunk/make/subdir.mk Wed Jan 13 10:13:01 2010
@@ -1,5 +1,4 @@
-# This file is intended to be included from each subdirectory
-# makefile.
+# This file is intended to be included from each subdirectory makefile.
 
 ifeq ($(Dir),)
   $(error "No Dir variable defined.")
@@ -10,6 +9,7 @@
 endif
 
 # Expand template for each configuration and architecture.
+#
 # FIXME: This level of logic should be in primary Makefile?
 ifeq ($(OnlyConfigs),)
   ConfigsToTraverse := $(Configs)
@@ -35,8 +35,7 @@
 ###
 # Include child makefile fragments
 
-# Evaluate this now so we do not have to worry about order of
-# evaluation.
+# Evaluate this now so we do not have to worry about order of evaluation.
 SubDirsList := $(SubDirs:%=$(Dir)/%)
 ifeq ($(SubDirsList),)
 else

Modified: compiler-rt/trunk/make/util.mk
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/make/util.mk?rev=93319&r1=93318&r2=93319&view=diff

==============================================================================
--- compiler-rt/trunk/make/util.mk (original)
+++ compiler-rt/trunk/make/util.mk Wed Jan 13 10:13:01 2010
@@ -22,8 +22,8 @@
 ###
 # Debugging
 
-# General debugging rule, use 'make print-XXX' to print the
-# definition, value and origin of XXX.
-print-%: 
+# General debugging rule, use 'make print-XXX' to print the definition, value
+# and origin of XXX.
+make-print-%:
 	$(error PRINT: $(value $*) = "$($*)" (from $(origin $*)))
 





More information about the llvm-commits mailing list