Blob Blame Raw
--- makefile.in.orig	2019-07-12 14:22:02.000000000 -0600
+++ makefile.in	2019-07-13 10:31:32.067349296 -0600
@@ -28,7 +28,7 @@ COMPILE=$(CXX) $(CXXFLAGS) -I$(DIR)
 
 #--------------------------------------------------------------------------#
 
-all: libcadical.a cadical mobical
+all: libcadical.so cadical mobical
 
 #--------------------------------------------------------------------------#
 
@@ -42,12 +42,18 @@ all: libcadical.a cadical mobical
 # Application binaries (the stand alone solver 'cadical' and the model based
 # tester 'mobical') and the library are the main build targets.
 
-cadical: cadical.o libcadical.a makefile
+cadical: cadical.o libcadical.so makefile
 	$(COMPILE) -o $@ $< -L. -lcadical
 
-mobical: mobical.o libcadical.a makefile
+mobical: mobical.o libcadical.so makefile
 	$(COMPILE) -o $@ $< -L. -lcadical
 
+libcadical.so: $(OBJ) makefile
+	rm -f $@
+	$(COMPILE) -shared -Wl,-h,libcadical.so.0 -o libcadical.so.0.0.0 $(OBJ)
+	ln -s libcadical.so.0.0.0 libcadical.so.0
+	ln -s libcadical.so.0 $@
+
 libcadical.a: $(OBJ) makefile
 	ar rc $@ $(OBJ)
 
--- test/api/run.sh.orig	2019-07-12 14:22:02.000000000 -0600
+++ test/api/run.sh	2019-07-13 10:31:32.074349289 -0600
@@ -28,8 +28,8 @@ die "needs to be called from a top-level
 [ -f "$CADICALBUILD/makefile" ] || \
   die "can not find '$CADICALBUILD/makefile' (run 'configure' first)"
 
-[ -f "$CADICALBUILD/libcadical.a" ] || \
-  die "can not find '$CADICALBUILD/libcadical.a' (run 'make' first)"
+[ -f "$CADICALBUILD/libcadical.so" ] || \
+  die "can not find '$CADICALBUILD/libcadical.so' (run 'make' first)"
 
 echo -n "$HILITE"
 echo "---------------------------------------------------------"