diff mbox

[2/3] make_device_config.sh: Emit dependency file to directory where included

Message ID 1361460407-8493-3-git-send-email-afaerber@suse.de
State New
Headers show

Commit Message

Andreas Färber Feb. 21, 2013, 3:26 p.m. UTC
Placing the config-devices.mak.d file alongside the config-devices.mak
file in *-softmmu/ lead to it getting included into through
*-softmmu/Makefile in addition to ./Makefile, leading to confusion.

Instead, emit it to ./%-config-devices.mak.d, where it is included.

Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 Makefile                      |    2 +-
 scripts/make_device_config.sh |    2 +-
 2 Dateien geändert, 2 Zeilen hinzugefügt(+), 2 Zeilen entfernt(-)

Comments

Andreas Färber Feb. 21, 2013, 3:35 p.m. UTC | #1
Am 21.02.2013 16:26, schrieb Andreas Färber:
> Placing the config-devices.mak.d file alongside the config-devices.mak
> file in *-softmmu/ lead to it getting included into through

s/into//

> *-softmmu/Makefile in addition to ./Makefile, leading to confusion.
> 
> Instead, emit it to ./%-config-devices.mak.d, where it is included.
> 
> Signed-off-by: Andreas Färber <afaerber@suse.de>
> ---
>  Makefile                      |    2 +-
>  scripts/make_device_config.sh |    2 +-
>  2 Dateien geändert, 2 Zeilen hinzugefügt(+), 2 Zeilen entfernt(-)
> 
> diff --git a/Makefile b/Makefile
> index 0d9099a..0ece051 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -66,7 +66,7 @@ endif
>  
>  SUBDIR_MAKEFLAGS=$(if $(V),,--no-print-directory) BUILD_DIR=$(BUILD_DIR)
>  SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak, $(TARGET_DIRS))
> -SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %/config-devices.mak.d, $(TARGET_DIRS))
> +SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %-config-devices.mak.d, $(TARGET_DIRS))
>  
>  ifeq ($(SUBDIR_DEVICES_MAK),)
>  config-all-devices.mak:
> diff --git a/scripts/make_device_config.sh b/scripts/make_device_config.sh
> index 5d14885..26e9077 100644
> --- a/scripts/make_device_config.sh
> +++ b/scripts/make_device_config.sh
> @@ -3,7 +3,7 @@
>  # files from include directives.
>  
>  dest=$1.tmp
> -dep=$1.d
> +dep=`dirname $1`-`basename $1`.d
>  src=$2
>  src_dir=`dirname $src`
>  all_includes=
>
diff mbox

Patch

diff --git a/Makefile b/Makefile
index 0d9099a..0ece051 100644
--- a/Makefile
+++ b/Makefile
@@ -66,7 +66,7 @@  endif
 
 SUBDIR_MAKEFLAGS=$(if $(V),,--no-print-directory) BUILD_DIR=$(BUILD_DIR)
 SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak, $(TARGET_DIRS))
-SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %/config-devices.mak.d, $(TARGET_DIRS))
+SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %-config-devices.mak.d, $(TARGET_DIRS))
 
 ifeq ($(SUBDIR_DEVICES_MAK),)
 config-all-devices.mak:
diff --git a/scripts/make_device_config.sh b/scripts/make_device_config.sh
index 5d14885..26e9077 100644
--- a/scripts/make_device_config.sh
+++ b/scripts/make_device_config.sh
@@ -3,7 +3,7 @@ 
 # files from include directives.
 
 dest=$1.tmp
-dep=$1.d
+dep=`dirname $1`-`basename $1`.d
 src=$2
 src_dir=`dirname $src`
 all_includes=