summaryrefslogtreecommitdiffstats
path: root/lib/libalpm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libalpm')
-rw-r--r--lib/libalpm/Makefile40
-rw-r--r--lib/libalpm/Makefile.am31
-rw-r--r--lib/libalpm/alpm.h2
3 files changed, 32 insertions, 41 deletions
diff --git a/lib/libalpm/Makefile b/lib/libalpm/Makefile
deleted file mode 100644
index 1f021776..00000000
--- a/lib/libalpm/Makefile
+++ /dev/null
@@ -1,40 +0,0 @@
-
-CXX=gcc
-CFLAGS=-g -Wall -pedantic -D_GNU_SOURCE -I. -I../..
-AR=ar rc
-RAN=ranlib
-
-OBJS=md5driver.o \
- md5.o \
- util.o \
- list.o \
- log.o \
- error.o \
- package.o \
- group.o \
- db.o \
- cache.o \
- conflict.o \
- deps.o \
- provide.o \
- rpmvercmp.o \
- backup.o \
- trans.o \
- add.o \
- remove.o \
- sync.o \
- handle.o \
- alpm.o
-
-all: libalpm.a
-
-%.o: %.c %.h
- $(CXX) -c $(CFLAGS) -o $@ $<
-
-libalpm.a: $(OBJS) alpm.h
- $(AR) $@ $(OBJS)
- $(RAN) $@
-
-clean:
- rm -f *.o *~ core
- rm -f libalpm.a
diff --git a/lib/libalpm/Makefile.am b/lib/libalpm/Makefile.am
new file mode 100644
index 00000000..57a8356b
--- /dev/null
+++ b/lib/libalpm/Makefile.am
@@ -0,0 +1,31 @@
+AUTOMAKE_OPTIONS = gnu
+DEFINES = -pedantic -D_GNU_SOURCE
+AM_CFLAGS = $(DEFINES)
+
+TARGETS = md5driver.c \
+ md5.c \
+ util.c \
+ list.c \
+ log.c \
+ error.c \
+ package.c \
+ group.c \
+ db.c \
+ cache.c \
+ conflict.c \
+ deps.c \
+ provide.c \
+ rpmvercmp.c \
+ backup.c \
+ trans.c \
+ add.c \
+ remove.c \
+ sync.c \
+ handle.c \
+ alpm.c
+
+lib_LTLIBRARIES = libalpm.la
+
+libalpm_la_SOURCES = $(TARGETS)
+
+libalpm_la_LDFLAGS = -no-undefined -version-info $(PM_VERSION_INFO)
diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h
index b12defee..5ba0e1d7 100644
--- a/lib/libalpm/alpm.h
+++ b/lib/libalpm/alpm.h
@@ -25,7 +25,7 @@
* Arch Linux Package Management library
*/
-#define PM_VERSION "0.1.0"
+/* #define PM_VERSION "0.1.0" */ /* Comes from autoconf's config.h */
#define PM_ROOT "/"
#define PM_DBPATH "var/lib/pacman"