From: Andre Noll Date: Mon, 30 Oct 2023 16:55:24 +0000 (+0100) Subject: Add target to create a static library. X-Git-Tag: v1.0.5~18 X-Git-Url: http://git.tuebingen.mpg.de/libdai.git/tree?a=commitdiff_plain;h=92e558a3df52b9a1dcfdf1a018c5268081d52b47;p=lopsub.git Add target to create a static library. It's sometimes handy to create a static version of the library, although this is generally frowned upon. No standard target depends on the new liblopsub.a target, so the static library is not build by default. One has to explicitly run "make liblopsub.a" to build it. --- diff --git a/Makefile b/Makefile index ac9656e..89cbc2e 100644 --- a/Makefile +++ b/Makefile @@ -116,6 +116,9 @@ lopsubgen: $(lsg_objs) $(CC) -Wall -g -o $@ $(lsg_objs) $(REALNAME): $(liblopsub_objs) $(CC) --shared -Wl,-soname,liblopsub.so.$(MAJOR_VERSION) -o $@ $^ +liblopsub.a: $(liblopsub_objs) + $(AR) -rcs $@ $^ + lopsubex: $(lopsubex_objs) $(REALNAME) $(CC) -Wall -g -o $@ $(lopsubex_objs)