Blob Blame History Raw
--- ./Makefile.orig	2014-12-01 12:00:00.000000000 -0700
+++ ./Makefile	2014-12-01 12:00:00.000000000 -0700
@@ -44,7 +44,7 @@ arch_flags : arch_flags.c
 ARCHFLAGS ?= $(shell $(CC) arch_flags.c -o arch_flags && ./arch_flags)
 OPTFLAGS  ?= -g -O #-DABC_NAMESPACE=xxx
 
-CFLAGS   += -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare $(OPTFLAGS) $(ARCHFLAGS) -Isrc
+CFLAGS   += -Wno-unused-function $(OPTFLAGS) $(ARCHFLAGS) -Isrc
 
 # Set -Wno-unused-bug-set-variable for GCC 4.6.0 and greater only
 ifneq ($(or $(findstring gcc,$(CC)),$(findstring g++,$(CC))),)
@@ -143,6 +143,12 @@ $(PROG): $(OBJ)
 	@echo "$(MSG_PREFIX)\`\` Building binary:" $(notdir $@)
 	@$(LD) -o $@ $^ $(LIBS)
 
+lib$(PROG).so: $(OBJ)
+	@echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@)
+	$(LD) -shared -Wl,-h,lib$(PROG).so.0 -o lib$(PROG).so.0.0.0 $^ $(LIBS)
+	@ln -s lib$(PROG).so.0.0.0 lib$(PROG).so.0
+	@ln -s lib$(PROG).so.0 $@
+
 lib$(PROG).a: $(OBJ)
 	@echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@)
 	@ar rv $@ $?