Do not litter the source directory with build artifacts
Before, building locally left a file named "vboot_host.pc" in the
top directory.
With this change, it's put into the $BUILD directory where it
belongs.
It still gets installed into the same place, of course.
BUG=chromium:459338
BRANCH=none
TEST=make runtests, and
Run:
make test_setup MINIMAL=
make test_setup MINIMAL=1
find . -name vboot_host.pc
Before this CL:
./build/install_for_test/usr/lib/pkgconfig/vboot_host.pc
./build/install_for_test/lib/pkgconfig/vboot_host.pc
./vboot_host.pc
After this CL:
./build/install_for_test/usr/lib/pkgconfig/vboot_host.pc
./build/install_for_test/lib/pkgconfig/vboot_host.pc
./build/vboot_host.pc
Change-Id: I3a888f72a5753228eec5187178d0da22de782171
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/254712
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Nam Nguyen <namnguyen@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
diff --git a/Makefile b/Makefile
index 438ab06..5b72f47 100644
--- a/Makefile
+++ b/Makefile
@@ -1419,7 +1419,7 @@
${Q}$(call run_if_prog,etags,${cmd_etags})
${Q}$(call run_if_prog,ctags,${cmd_ctags})
-PC_FILES = ${PC_IN_FILES:%.pc.in=%.pc}
+PC_FILES = ${PC_IN_FILES:%.pc.in=${BUILD}/%.pc}
${PC_FILES}: ${PC_IN_FILES}
${Q}sed \
-e 's:@LDLIBS@:${LDLIBS}:' \
@@ -1429,4 +1429,4 @@
.PHONY: pc_files_install
pc_files_install: ${PC_FILES}
${Q}mkdir -p ${ULP_DIR}
- ${Q}${INSTALL} -D -m 0644 $< ${ULP_DIR}/$<
+ ${Q}${INSTALL} -D -m 0644 $< ${ULP_DIR}/$(notdir $<)