Commit 63f89f83 authored by Cyrill Gorcunov's avatar Cyrill Gorcunov Committed by Pavel Emelyanov

make: Add library building helpers

Signed-off-by: 's avatarCyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent b8a85cf5
......@@ -158,6 +158,16 @@ _all += $(obj)/built-in.o
endif
endif
##
## A rule for building library.
ifneq ($(lib-so),)
$(obj)/$(lib-so).so: $(all-objs) $(libs-e)
$(E) " LINK " $@
$(Q) $(CC) -shared $(cflags-so) -o $@ $^
_all += $(obj)/$(lib-so).so
endif
##
##
## Include deps if requested
......@@ -175,6 +185,7 @@ cleanup-y += $(obj)/*.o $(obj)/*.d
cleanup-y += $(obj)/*.i $(obj)/*.s
cleanup-y += $(obj)/*.built-in.o
cleanup-y += $(obj)/built-in.o
cleanup-y += $(obj)/*.so
##
## Predefined .PHONY targets
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment