From: Justin Seyster Date: Wed, 7 Jul 2010 23:31:37 +0000 (-0400) Subject: Added a workspace directory with plug-in Makefile. X-Git-Tag: release-v1.0~74^2~5 X-Git-Url: https://git.fsl.cs.stonybrook.edu/?a=commitdiff_plain;h=87e62cf568df7c862d1c188978db17fcb3c8621f;p=interaspect.git Added a workspace directory with plug-in Makefile. --- diff --git a/workspace/.gitignore b/workspace/.gitignore new file mode 100644 index 0000000..385fbbf --- /dev/null +++ b/workspace/.gitignore @@ -0,0 +1,3 @@ +# The Makefile in this directory is hand-written, not generated by +# Automake +!Makefile diff --git a/workspace/Makefile b/workspace/Makefile new file mode 100644 index 0000000..8a8839d --- /dev/null +++ b/workspace/Makefile @@ -0,0 +1,30 @@ +# See README in this directory for more information about this +# Makefile. + +CC=gcc +CFLAGS=-Wall -Werror -O2 + +INCLUDE=-I../src +LIB_INTERASPECT=../src/.libs/libinteraspect.a + +all : + @echo Use \"make libhello.so\" to compile a plug-in named hello.c. + @echo See README in this directory for more information. + +clean : + -rm *.o lib*.so.1.0.0 lib*.so 2> /dev/null + +$(LIB_INTERASPECT) : + @echo Cannot find libinteraspect.a. + @echo Make sure InterAspect is compiled. + @echo You may need to check the README file to see how to pass the + @echo location of libinteraspect.a to this Makefile. + @false + +%.o : %.c + gcc $(CFLAGS) $(INCLUDE) -fPIC -c -o $@ $< + +lib%.so : %.o $(LIB_INTERASPECT) + gcc -shared -Wl,-soname,lib$*.so.1 -o lib$*.so $*.o $(LIB_INTERASPECT) + +.PHONY : all clean