summaryrefslogtreecommitdiff
path: root/extras/multipath/libdevmapper/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'extras/multipath/libdevmapper/Makefile')
-rw-r--r--extras/multipath/libdevmapper/Makefile9
1 files changed, 8 insertions, 1 deletions
diff --git a/extras/multipath/libdevmapper/Makefile b/extras/multipath/libdevmapper/Makefile
index 72b39cedf5..b160075416 100644
--- a/extras/multipath/libdevmapper/Makefile
+++ b/extras/multipath/libdevmapper/Makefile
@@ -3,7 +3,14 @@
# Copyright (C) 2003 Christophe Varoqui, <christophe.varoqui@free.fr>
CC = gcc
-CFLAGS = -pipe -g -O2 -Wall -Wunused -Wstrict-prototypes -nostdinc -I../../../klibc/klibc/include -I../../../klibc/klibc/include/bits32 -I/usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.3.1/include -I../../../klibc/linux/include -I. -Iioctl
+udevdir = ../../..
+klibcdir = $(udevdir)/klibc
+
+CC = gcc
+GCCINCDIR := ${shell $(CC) -print-search-dirs | sed -ne "s/install: \(.*\)/\1include/gp"}
+CFLAGS = -pipe -g -O2 -Wall -Wunused -Wstrict-prototypes -nostdinc \
+ -I$(klibcdir)/klibc/include -I$(klibcdir)/klibc/include/bits32 \
+ -I$(GCCINCDIR) -I$(klibcdir)/linux/include -I. -Iioctl
OBJS = ioctl/libdevmapper.o libdm-common.o