]> git.rm.cloudns.org Git - xonotic/d0_blind_id.git/commitdiff
initial autoconf stuff
authorRudolf Polzer <divverent@alientrap.org>
Sat, 24 Apr 2010 18:29:43 +0000 (20:29 +0200)
committerRudolf Polzer <divverent@alientrap.org>
Sat, 24 Apr 2010 19:03:28 +0000 (21:03 +0200)
Makefile [deleted file]
Makefile.am [new file with mode: 0644]
autogen.sh [new file with mode: 0644]
configure.ac [new file with mode: 0644]

diff --git a/Makefile b/Makefile
deleted file mode 100644 (file)
index 8534658..0000000
--- a/Makefile
+++ /dev/null
@@ -1,12 +0,0 @@
-all: blind_id
-
-OBJECTS = d0.o d0_blind_id.o d0_iobuf.o d0_bignum-gmp.o sha1.o main.o
-
-blind_id: $(OBJECTS)
-       $(CC) $(LDFLAGS) -o $@ $^
-clean:
-       $(RM) blind_id $(OBJECTS)
-
-CFLAGS += -Wall -Wextra
-CPPFLAGS += -I/opt/gmp/include
-LDFLAGS += -L/opt/gmp/lib -Wl,-rpath,/opt/gmp/lib -lgmp -lm -lrt -s -O3
diff --git a/Makefile.am b/Makefile.am
new file mode 100644 (file)
index 0000000..803afe3
--- /dev/null
@@ -0,0 +1,14 @@
+bin_PROGRAMS = blind_id
+blind_id_SOURCES = main.c
+blind_id_LDADD = libblind_id.la
+
+lib_LTLIBRARIES = libblind_id.la
+libblind_id_la_SOURCES = d0_bignum-gmp.c d0_blind_id.c d0.c d0_iobuf.c sha1.c
+libblind_id_la_LDFLAGS = -versioninfo 0:0:0
+# versioninfo:
+#   - compatible interface change: c:r:a -> c+1:0:a+1
+#   - incompatible interface change: c:r:a -> c+1:0:0
+#   - internal change: c:r:a -> c:r+1:a
+
+library_includedir = $(includedir)
+library_include_HEADERS = d0_blind_id.h
diff --git a/autogen.sh b/autogen.sh
new file mode 100644 (file)
index 0000000..ba97cb9
--- /dev/null
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+set -ex
+
+aclocal
+automake
+autoconf
diff --git a/configure.ac b/configure.ac
new file mode 100644 (file)
index 0000000..65b2ea8
--- /dev/null
@@ -0,0 +1,11 @@
+AC_INIT([d0_blind_id], [0.1], [divVerent@alientrap.org])
+AM_INIT_AUTOMAKE([-Wall foreign])
+AC_PROG_CC
+AM_PROG_LIBTOOL
+
+AC_SEARCH_LIBS(clock_gettime, rt, , [AC_MSG_ERROR([GNU MP not found, see http://gmplib.org/])])
+AC_SEARCH_LIBS(__gmpz_init, gmp, , [AC_MSG_ERROR([GNU MP not found, see http://gmplib.org/])])
+
+AC_CONFIG_HEADERS([config.h])
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT