summaryrefslogtreecommitdiff
path: root/make.tmpl.in
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2021-03-19 14:47:21 +0100
committerZdenek Kabelac <zkabelac@redhat.com>2021-03-19 23:21:18 +0100
commit48d04afaa2015fe285b2ae499b7f06d0b25ae00d (patch)
tree0d29f2c3421af060b0aa11793ff83bef26d97b6a /make.tmpl.in
parentc6a76c1ffe8321a4f2ed988fe5884541489e120f (diff)
downloadlvm2-48d04afaa2015fe285b2ae499b7f06d0b25ae00d.tar.gz
make: restore buildir != srcdir support
Our new faster deps generation missed support for buildirs != srcdir - as it can be usable to have several builds from unchanged directory with sources.
Diffstat (limited to 'make.tmpl.in')
-rw-r--r--make.tmpl.in5
1 files changed, 4 insertions, 1 deletions
diff --git a/make.tmpl.in b/make.tmpl.in
index 2611dcd90..6f3f81915 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -443,14 +443,17 @@ DEFS+=-D_FILE_OFFSET_BITS=64
%.o: %.c $(DEPS)
@echo " [CC] $(<F)"
+ @mkdir -p $(@D)
$(Q) $(CC) $(DEPFLAGS) -c $(INCLUDES) $(VALGRIND_CFLAGS) $(PROGS_CFLAGS) $(DEFS) $(DEFS_$@) $(WFLAGS) $(WCFLAGS) $(CFLAGS) $(CFLAGS_$@) $< -o $@
%.o: %.cpp $(DEPS)
@echo " [CXX] $(<F)"
+ @mkdir -p $(@D)
$(Q) $(CXX) -c $(INCLUDES) $(VALGRIND_CFLAGS) $(DEFS) $(DEFS_$@) $(WFLAGS) $(CXXFLAGS) $(CXXFLAGS_$@) $< -o $@
-%.pot: %.c Makefile
+%.pot: %.c $(DEPS)
@echo " [CC] $(<F)"
+ @mkdir -p $(@D)
$(Q) $(CC) -E $(INCLUDES) $(VALGRIND_CFLAGS) $(PROGS_CFLAGS) -include $(top_builddir)/po/pogen.h $(DEFS) $(WFLAGS) $(CFLAGS) $< >$@
%.so: %.o