diff --git a/.gitignore b/.gitignore index e7c2d04..6c46149 100644 --- a/.gitignore +++ b/.gitignore @@ -137,6 +137,4 @@ m4/lt~obsolete.m4 # Generated Makefile # (meta build system like autotools, # can automatically generate from config.status script -# (which is called by configure script)) -Makefile - +# (which is called by configure script) diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..868ccb0 --- /dev/null +++ b/Makefile @@ -0,0 +1,33 @@ +LUAINC?=/usr/include +CC?=gcc + + +OBJS = limap.o + +.PHONY: limap clean uwimap all +#$(OBJS) + +CFLAGS = +LDFLAGS = -lcrypt -lssl -lcrypto + +all: uwimap limap + @echo "DONE" + +uwimap: + cd imap && make slx EXTRACFLAGS="-fPIC -I/usr/include/openssl" + +%.o: %.c + @echo "building obj files" + $(CC) -I$(LUAINC) -I./imap/c-client/ -fPIC $(CFLAGS) -c $< -o $@ + +limap: $(OBJS) + @echo "building shared library" + $(CC) -shared \ + $(OBJS) \ + imap/c-client/c-client.a \ + $(LDFLAGS) -o limap.so + +clean: + @echo "Clean all" + cd imap && make clean + - rm -rf *.o *.so *.a