[PATCH] Makefile patch to create KBUILD_OUPUT if it doesn't exist

From: Brian Jackson
Date: Wed Mar 31 2004 - 17:48:40 EST


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

It was probably intentional to not have the Makefile automagically create
KBUILD_OUPUT if it doesn't exist, but just in case, here's a patch which
makes it do just that. I'd appreciate feedback either way just so I know if
it's actually getting looked at or if it got lost somewhere along the way.

- --Brian Jackson

- --- Makefile.orig 2004-03-31 16:21:48.254691909 -0600
+++ Makefile 2004-03-31 16:34:27.507098249 -0600
@@ -88,10 +88,10 @@
ifneq ($(KBUILD_OUTPUT),)
# Invoke a second make in the output directory, passing relevant variables
# check that the output directory actually exists
+$(if $(wildcard $(KBUILD_OUTPUT)),, \
+ $(shell mkdir -p ${KBUILD_OUTPUT}))
saved-output := $(KBUILD_OUTPUT)
KBUILD_OUTPUT := $(shell cd $(KBUILD_OUTPUT) && /bin/pwd)
- -$(if $(wildcard $(KBUILD_OUTPUT)),, \
- - $(error output directory "$(saved-output)" does not exist))

.PHONY: $(MAKECMDGOALS)


- --
http://www.brianandsara.net
For Sale : http://www.brianandsara.net/temp/forsale.php
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAa0qH+cPN+Z7qK9cRAiB9AJ0dtkq92cgYTailSvEPBS2Z/iez9wCg0CA2
GBdCdX7RPUhe9EXdXn7Y6Yg=
=+vf2
-----END PGP SIGNATURE-----
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/