From: Naohiro Aota Date: Thu, 12 Oct 2017 02:22:24 +0000 (+0900) Subject: btrfs-progs: build: set include path relatively X-Git-Tag: upstream/4.16.1~357 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0792c170282f4b94bb2ffce483a5294d56eb8036;p=platform%2Fupstream%2Fbtrfs-progs.git btrfs-progs: build: set include path relatively Currently, gcc is passed the include directory with full path. As a result, dependency files (*.o.d) also record the full path at the build time. Such full path dependency is annoying for sharing the source between multiple machines, containers, or anything the path differ. And this is the same way what other program using autotools e.g. e2fsprogs is doing: $ grep top_builddir Makefile top_builddir = . CPPFLAGS = -I. -I$(top_builddir)/lib -I$(top_srcdir)/lib BUILD_CFLAGS = -g -O2 -I. -I$(top_builddir)/lib -I$(top_srcdir)/lib -DHAVE_CONFIG_H Signed-off-by: Naohiro Aota [ set TOPDIR=. instead of -I as discussed, does not harm linker ] Signed-off-by: David Sterba --- diff --git a/Makefile b/Makefile index 5450df3..d0657aa 100644 --- a/Makefile +++ b/Makefile @@ -60,7 +60,7 @@ DEBUG_LDFLAGS_INTERNAL = DEBUG_LDFLAGS := ABSTOPDIR = $(shell pwd) -TOPDIR := $(shell pwd) +TOPDIR := . # Common build flags CSTD = -std=gnu90