From: Mark Hymers Date: Wed, 4 Feb 2009 10:59:19 +0000 (+0000) Subject: build a static library X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=7414aedb05ac32955797deba118013c84e0acf1e;p=dak.git build a static library Signed-off-by: Mark Hymers --- diff --git a/tools/dsync-0.0/buildlib/library.mak b/tools/dsync-0.0/buildlib/library.mak index 565baa39..f6fc1f02 100644 --- a/tools/dsync-0.0/buildlib/library.mak +++ b/tools/dsync-0.0/buildlib/library.mak @@ -25,7 +25,7 @@ $(LOCAL)-LIBRARY := $(LIBRARY) # Install the command hooks headers: $($(LOCAL)-HEADERS) -library: $(LIB)/lib$(LIBRARY).so $(LIB)/lib$(LIBRARY).so.$(MAJOR) +library: $(LIB)/lib$(LIBRARY).so $(LIB)/lib$(LIBRARY).so.$(MAJOR) $(LIB)/lib$(LIBRARY).a clean: clean/$(LOCAL) veryclean: veryclean/$(LOCAL) @@ -51,6 +51,12 @@ $(LIB)/lib$(LIBRARY).so.$(MAJOR).$(MINOR): $($(LOCAL)-HEADERS) $($(LOCAL)-OBJS) $(LFLAGS_SO) $(SONAME_MAGIC)$($(@F)-SONAME) -shared \ $(filter %.opic,$^) $($(@F)-SLIBS) +$(LIB)/lib$(LIBRARY).a: $($(LOCAL)-HEADERS) $($(LOCAL)-OBJS) + -rm -f $(LIB)/lib$($(@F)-LIBRARY).a 2> /dev/null + echo Building static library $@ + $(AR) rc $@ $(filter %.opic,$^) + ranlib $@ + # Compilation rules vpath %.cc $(SUBDIRS) $(OBJ)/%.opic: %.cc