[linux-mm-cc] [PATCH] fix to enable to build with O option
IKEDA Munehiro
m-ikeda at ds.jp.nec.com
Wed May 9 01:02:11 EDT 2007
Hi all,
I found a problem to make lib/* with "O" option like
make O=../build bzImage
This probelem was caused by that "lib-y" can't properly handle a file
in sub-directory.
So this patch modifies and creates makefiles to fix it.
By this patch, minilzo.o, WKdm.o, and WK4x4.o will not be archived in
lib/lib.a. As far as I know it has no problem ... doesn't it?
This patch is for patch-ccache-alpha-008-2.6.21 applied kernel.
Note (1) ---
Now all of 3 algos are always compiled because they are listed in "obj-y".
Yes, I know the best way is defining CONFIG_* for each compression algo
and then modifing the makefiles as the ToDo 3) a) ii) says. So this
patch is just a "patch" literally, and has to be fixed again when the
ToDo is done.
Note (2) ---
minilzo is currently beeing pushed in mainline. If you don't know,
please see
http://www.ussg.iu.edu/hypermail/linux/kernel/0705.0/1963.html
IMHO, we should collabotare with the action.
Best regards,
IKEDA, Munehiro
>From 107981bb01a10cc3cc262c8d1a8423dafd9eae32 Mon Sep 17 00:00:00 2001
From: IKEDA, Munehiro <m-ikeda at ds.jp.nec.com>
Date: Mon, 7 May 2007 20:25:39 +0900
Subject: [PATCH] fix to enable to build with O option
When making with "O" option, lib/WK4x4, lib/WKdm, and
lib/LZO failed to be compiled.
This patch modified lib/Makefile and added new Makefiles
in these directories to fix it.
---
lib/LZO/Makefile | 5 +++++
lib/Makefile | 6 ++++--
lib/WK4x4/Makefile | 5 +++++
lib/WKdm/Makefile | 5 +++++
4 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/lib/LZO/Makefile b/lib/LZO/Makefile
new file mode 100644
index 0000000..2877952
--- /dev/null
+++ b/lib/LZO/Makefile
@@ -0,0 +1,5 @@
+#
+# Makefile for LZO
+#
+
+obj-y := minilzo.o
diff --git a/lib/Makefile b/lib/Makefile
index e64987b..350f394 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -5,8 +5,7 @@ #
lib-y := ctype.o string.o vsprintf.o cmdline.o \
rbtree.o radix-tree.o dump_stack.o \
idr.o div64.o int_sqrt.o bitmap.o extable.o prio_tree.o \
- sha1.o irq_regs.o reciprocal_div.o \
- WKdm/WKdm.o WK4x4/WK4x4.o LZO/minilzo.o
+ sha1.o irq_regs.o reciprocal_div.o
lib-$(CONFIG_MMU) += ioremap.o
lib-$(CONFIG_SMP) += cpumask.o
@@ -14,6 +13,9 @@ lib-$(CONFIG_SMP) += cpumask.o
lib-y += kobject.o kref.o kobject_uevent.o klist.o
obj-y += sort.o parser.o halfmd4.o debug_locks.o random32.o bust_spinlocks.o
+obj-y += WKdm/
+obj-y += WK4x4/
+obj-y += LZO/
ifeq ($(CONFIG_DEBUG_KOBJECT),y)
CFLAGS_kobject.o += -DDEBUG
diff --git a/lib/WK4x4/Makefile b/lib/WK4x4/Makefile
new file mode 100644
index 0000000..50d136b
--- /dev/null
+++ b/lib/WK4x4/Makefile
@@ -0,0 +1,5 @@
+#
+# Makefile for WK4x4
+#
+
+obj-y := WK4x4.o
diff --git a/lib/WKdm/Makefile b/lib/WKdm/Makefile
new file mode 100644
index 0000000..a447b29
--- /dev/null
+++ b/lib/WKdm/Makefile
@@ -0,0 +1,5 @@
+#
+# Makefile for WKdm
+#
+
+obj-y := WKdm.o
-- 1.4.0
More information about the linux-mm-cc
mailing list