build: abbreviate AR command, too

Summary:
The "ar" command was excessively verbose.
This abbreviates it to be like CC and LD.
Also, factor "rs" options into ARFLAGS.

Test Plan:
  $ rm librocksdb.a
  $ make librocksdb.a
  AR       librocksdb.a
  ar: creating librocksdb.a

Reviewers: ljin, sdong, igor.sugak, igor

Reviewed By: igor

Subscribers: dhruba

Differential Revision: https://reviews.facebook.net/D33699
This commit is contained in:
Jim Meyering 2015-02-19 11:48:09 -08:00
parent b8ac71ba18
commit 11581b7415
2 changed files with 17 additions and 3 deletions

View File

@ -6,5 +6,10 @@
"linters" "linters"
], ],
"lint.engine" : "FacebookFbcodeLintEngine", "lint.engine" : "FacebookFbcodeLintEngine",
"lint.engine.single.linter" : "FbcodeCppLinter" "lint.engine.single.linter" : "FbcodeCppLinter",
"base" : "git:HEAD^, hg:.^",
"git.default-relative-commit" : "HEAD^",
"git:arc.feature.start.default" : "origin/master",
"arc.feature.start.default" : "master",
"history.immutable" : false
} }

View File

@ -10,6 +10,7 @@ CFLAGS += ${EXTRA_CFLAGS}
CXXFLAGS += ${EXTRA_CXXFLAGS} CXXFLAGS += ${EXTRA_CXXFLAGS}
LDFLAGS += $(EXTRA_LDFLAGS) LDFLAGS += $(EXTRA_LDFLAGS)
MACHINE ?= $(shell uname -m) MACHINE ?= $(shell uname -m)
ARFLAGS = rs
ifneq ($(MAKECMDGOALS),dbg) ifneq ($(MAKECMDGOALS),dbg)
OPT += -O2 -fno-omit-frame-pointer OPT += -O2 -fno-omit-frame-pointer
@ -36,6 +37,10 @@ AM_V_GEN = $(am__v_GEN_$(V))
am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 = am__v_GEN_1 =
AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
am__v_at_1 =
AM_V_CC = $(am__v_CC_$(V)) AM_V_CC = $(am__v_CC_$(V))
am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY)) am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
@ -47,6 +52,10 @@ AM_V_CCLD = $(am__v_CCLD_$(V))
am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY)) am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 = am__v_CCLD_1 =
AM_V_AR = $(am__v_AR_$(V))
am__v_AR_ = $(am__v_AR_$(AM_DEFAULT_VERBOSITY))
am__v_AR_0 = @echo " AR " $@;
am__v_AR_1 =
AM_LINK = $(AM_V_CCLD)$(CXX) $^ $(EXEC_LDFLAGS) -o $@ $(LDFLAGS) $(COVERAGEFLAGS) AM_LINK = $(AM_V_CCLD)$(CXX) $^ $(EXEC_LDFLAGS) -o $@ $(LDFLAGS) $(COVERAGEFLAGS)
@ -356,8 +365,8 @@ package:
# Unit tests and tools # Unit tests and tools
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
$(LIBRARY): $(LIBOBJECTS) $(LIBRARY): $(LIBOBJECTS)
rm -f $@ $(AM_V_AR)rm -f $@
$(AR) -rs $@ $(LIBOBJECTS) $(AM_V_at)$(AR) $(ARFLAGS) $@ $(LIBOBJECTS)
db_bench: db/db_bench.o $(LIBOBJECTS) $(TESTUTIL) db_bench: db/db_bench.o $(LIBOBJECTS) $(TESTUTIL)
$(AM_LINK) $(AM_LINK)