diff --git a/Makefile.in b/Makefile.in
index 4aa166bb2d48d0cbd3800d18f62bf27c4d067221..84ab4190040aa3da34ce0041741c212415f9c77d 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,5 +1,4 @@
-subdir-m += libcfs
-subdir-m += lnet
+subdir-m += @LIBCFS_SUBDIR@ lnet
 subdir-m += lustre
 subdir-m += lustre-iokit
 
diff --git a/build/autoconf/lustre-build.m4 b/build/autoconf/lustre-build.m4
index efd894c96ef7dbbd4ab0fea0a8f1b77558318440..dd9fc53c9a21e0d0d8a009f2572b6007435e9174 100644
--- a/build/autoconf/lustre-build.m4
+++ b/build/autoconf/lustre-build.m4
@@ -696,7 +696,7 @@ LC_CONFIG_CLIENT_SERVER
 # three macros for cmd3 
 LC_CONFIG_SPLIT
 LC_CONFIG_LDISKFS
-LIBCFS_CONFIG_CDEBUG
+LN_CONFIG_CDEBUG
 
 LB_CONFIG_MODULES
 
diff --git a/libcfs/autoconf/lustre-libcfs.m4 b/libcfs/autoconf/lustre-libcfs.m4
index 86fe0e63ec02dce4ff8b6b191069764db007b389..f78c781c6a7403bdf29a49510c73a3d6df0df177 100644
--- a/libcfs/autoconf/lustre-libcfs.m4
+++ b/libcfs/autoconf/lustre-libcfs.m4
@@ -1,9 +1,9 @@
 #
-# LIBCFS_CONFIG_CDEBUG
+# LN_CONFIG_CDEBUG
 #
 # whether to enable various libcfs debugs (CDEBUG, ENTRY/EXIT, LASSERT, etc.)
 #
-AC_DEFUN([LIBCFS_CONFIG_CDEBUG],
+AC_DEFUN([LN_CONFIG_CDEBUG],
 [
 AC_MSG_CHECKING([whether to enable CDEBUG, CWARN])
 AC_ARG_ENABLE([libcfs_cdebug],