[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Cluster-devel] [PATCH] for a header-file-cannot-found building error



the -idirafter used as a backend including path for header files, but the original style
didn't work, pick a specific gcc command from the making process:

gcc -Wall  -g -I. -O2 -idirafter /usr/src/linux-2.6.21.7/include/linux -I//usr/include \
        -I../config -I../../cman/lib -I../include/ -I../lib/ -c -o plock.o plock.c
plock.c:37:34: linux/lock_dlm_plock.h: No such file or directory

just because plock.c needs a header file <linux/lock_dlm_plock.h>, this could work:

gcc -Wall  -g -I. -O2 -idirafter /usr/src/linux-2.6.21.7/include -I//usr/include \
        -I../config -I../../cman/lib -I../include/ -I../lib/ -c -o plock.o plock.c

--- ./cluster-2.00.00/group/dlm_controld/Makefile.orig	2006-08-11 23:18:15.000000000 +0800
+++ ./cluster-2.00.00/group/dlm_controld/Makefile	2007-08-15 11:02:47.000000000 +0800
@@ -17,7 +17,7 @@
 
 CFLAGS+= -g -I${incdir} -I${top_srcdir}/config
 
-CFLAGS+= -idirafter ${KERNEL_SRC}/include/linux \
+CFLAGS+= -idirafter ${KERNEL_SRC}/include \
 	-I../../group/lib/ \
 	-I../../ccs/lib/ \
 	-I../../cman/lib/ \

--- ./cluster-2.00.00/group/gfs_controld/Makefile.orig	2006-08-11 23:18:15.000000000 +0800
+++ ./cluster-2.00.00/group/gfs_controld/Makefile	2007-08-15 11:02:38.000000000 +0800
@@ -16,7 +16,7 @@
 include ${top_srcdir}/make/defines.mk
 
 CFLAGS+= -g -I. -O2 \
-	-idirafter ${KERNEL_SRC}/include/linux \
+	-idirafter ${KERNEL_SRC}/include \
 	-I${incdir} \
 	-I${top_srcdir}/config \
 	-I../../cman/lib \


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]