Blob Blame History Raw
diff -up libaio-0.3.109/src/Makefile.orig libaio-0.3.109/src/Makefile
--- libaio-0.3.109/src/Makefile.orig	2009-10-09 14:17:02.000000000 -0400
+++ libaio-0.3.109/src/Makefile	2014-03-10 17:12:39.167190155 -0400
@@ -1,6 +1,7 @@
 prefix=/usr
-includedir=$(prefix)/include
-libdir=$(prefix)/lib
+includedir=/usr/include
+libdir=/usr/lib
+usrlibdir=/usr/lib
 
 ARCH := $(shell uname -m | sed -e s/i.86/i386/)
 CFLAGS := -nostdlib -nostartfiles -Wall -I. -g -fomit-frame-pointer -O2 -fPIC
@@ -51,11 +52,11 @@ $(libname): $(libaio_sobjs) libaio.map
 	$(CC) $(SO_CFLAGS) -Wl,--version-script=libaio.map -Wl,-soname=$(soname) -o $@ $(libaio_sobjs) $(LINK_FLAGS)
 
 install: $(all_targets)
-	install -D -m 644 libaio.h $(includedir)/libaio.h
-	install -D -m 644 libaio.a $(libdir)/libaio.a
-	install -D -m 755 $(libname) $(libdir)/$(libname)
-	ln -sf $(libname) $(libdir)/$(soname)
-	ln -sf $(libname) $(libdir)/libaio.so
+	install -D -m 644 libaio.h $(destdir)$(includedir)/libaio.h
+	install -D -m 644 libaio.a $(destdir)$(usrlibdir)/libaio.a
+	install -D -m 755 $(libname) $(destdir)$(libdir)/$(libname)
+	ln -sf $(libdir)/$(libname) $(destdir)$(libdir)/$(soname)
+	ln -sf $(libdir)/$(libname) $(destdir)$(usrlibdir)/libaio.so
 
 $(libaio_objs): libaio.h