diff options
Diffstat (limited to 'meta/recipes-devtools/i2c-tools/files/0001-tools-Module.mk-Add-missing-dependencies.patch')
| -rw-r--r-- | meta/recipes-devtools/i2c-tools/files/0001-tools-Module.mk-Add-missing-dependencies.patch | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/meta/recipes-devtools/i2c-tools/files/0001-tools-Module.mk-Add-missing-dependencies.patch b/meta/recipes-devtools/i2c-tools/files/0001-tools-Module.mk-Add-missing-dependencies.patch new file mode 100644 index 0000000000..e47c02ab7f --- /dev/null +++ b/meta/recipes-devtools/i2c-tools/files/0001-tools-Module.mk-Add-missing-dependencies.patch | |||
| @@ -0,0 +1,69 @@ | |||
| 1 | From 08b0d67ba7eceb862cb17f52eb1911e9579726ea Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Jean Delvare <jdelvare@suse.de> | ||
| 3 | Date: Thu, 14 Dec 2017 08:52:26 +0100 | ||
| 4 | Subject: [PATCH] tools/Module.mk: Add missing dependencies | ||
| 5 | |||
| 6 | Better build the library before building the tools which link against | ||
| 7 | it, otherwise parallel builds could run into a race and break. | ||
| 8 | |||
| 9 | Upstream-Status: Backport | ||
| 10 | |||
| 11 | Signed-off-by: Jean Delvare <jdelvare@suse.de> | ||
| 12 | Tested-by: Angelo Compagnucci <angelo@amarulasolutions.com> | ||
| 13 | Acked-by: Angelo Compagnucci <angelo@amarulasolutions.com> | ||
| 14 | Signed-off-by: Maxin B. John <maxin.john@intel.com> | ||
| 15 | --- | ||
| 16 | lib/Module.mk | 7 +++++++ | ||
| 17 | tools/Module.mk | 10 +++++----- | ||
| 18 | 2 files changed, 12 insertions(+), 5 deletions(-) | ||
| 19 | |||
| 20 | diff --git a/lib/Module.mk b/lib/Module.mk | ||
| 21 | index 8a58f5b..67afe91 100644 | ||
| 22 | --- a/lib/Module.mk | ||
| 23 | +++ b/lib/Module.mk | ||
| 24 | @@ -37,6 +37,13 @@ ifeq ($(BUILD_STATIC_LIB),1) | ||
| 25 | LIB_TARGETS += $(LIB_STLIBNAME) | ||
| 26 | endif | ||
| 27 | |||
| 28 | +# Library file to link against (static or dynamic) | ||
| 29 | +ifeq ($(USE_STATIC_LIB),1) | ||
| 30 | +LIB_DEPS := $(LIB_DIR)/$(LIB_STLIBNAME) | ||
| 31 | +else | ||
| 32 | +LIB_DEPS := $(LIB_DIR)/$(LIB_SHBASENAME) | ||
| 33 | +endif | ||
| 34 | + | ||
| 35 | # | ||
| 36 | # Libraries | ||
| 37 | # | ||
| 38 | diff --git a/tools/Module.mk b/tools/Module.mk | ||
| 39 | index 6421a23..609de7a 100644 | ||
| 40 | --- a/tools/Module.mk | ||
| 41 | +++ b/tools/Module.mk | ||
| 42 | @@ -24,19 +24,19 @@ TOOLS_TARGETS := i2cdetect i2cdump i2cset i2cget i2ctransfer | ||
| 43 | # Programs | ||
| 44 | # | ||
| 45 | |||
| 46 | -$(TOOLS_DIR)/i2cdetect: $(TOOLS_DIR)/i2cdetect.o $(TOOLS_DIR)/i2cbusses.o | ||
| 47 | +$(TOOLS_DIR)/i2cdetect: $(TOOLS_DIR)/i2cdetect.o $(TOOLS_DIR)/i2cbusses.o $(LIB_DEPS) | ||
| 48 | $(CC) $(LDFLAGS) -o $@ $^ $(TOOLS_LDFLAGS) | ||
| 49 | |||
| 50 | -$(TOOLS_DIR)/i2cdump: $(TOOLS_DIR)/i2cdump.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o | ||
| 51 | +$(TOOLS_DIR)/i2cdump: $(TOOLS_DIR)/i2cdump.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o $(LIB_DEPS) | ||
| 52 | $(CC) $(LDFLAGS) -o $@ $^ $(TOOLS_LDFLAGS) | ||
| 53 | |||
| 54 | -$(TOOLS_DIR)/i2cset: $(TOOLS_DIR)/i2cset.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o | ||
| 55 | +$(TOOLS_DIR)/i2cset: $(TOOLS_DIR)/i2cset.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o $(LIB_DEPS) | ||
| 56 | $(CC) $(LDFLAGS) -o $@ $^ $(TOOLS_LDFLAGS) | ||
| 57 | |||
| 58 | -$(TOOLS_DIR)/i2cget: $(TOOLS_DIR)/i2cget.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o | ||
| 59 | +$(TOOLS_DIR)/i2cget: $(TOOLS_DIR)/i2cget.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o $(LIB_DEPS) | ||
| 60 | $(CC) $(LDFLAGS) -o $@ $^ $(TOOLS_LDFLAGS) | ||
| 61 | |||
| 62 | -$(TOOLS_DIR)/i2ctransfer: $(TOOLS_DIR)/i2ctransfer.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o | ||
| 63 | +$(TOOLS_DIR)/i2ctransfer: $(TOOLS_DIR)/i2ctransfer.o $(TOOLS_DIR)/i2cbusses.o $(TOOLS_DIR)/util.o $(LIB_DEPS) | ||
| 64 | $(CC) $(LDFLAGS) -o $@ $^ $(TOOLS_LDFLAGS) | ||
| 65 | |||
| 66 | # | ||
| 67 | -- | ||
| 68 | 2.4.0 | ||
| 69 | |||
