graph-depends: add option to pass arbitrary dot options
authorYann E. MORIN <yann.morin.1998@free.fr>
Sun, 8 Jun 2014 14:03:52 +0000 (16:03 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 8 Jun 2014 14:43:32 +0000 (16:43 +0200)
Kids nowaday seem to prefer a left-to-right drawing rather than the
more conventional and historical top-down drawing.

Rather than multiply the number of environment variables, just add
a single one where the user can pass arbitrary dot options, such as:

    make BR2_GRAPH_DOT_OPTS=-Grankdir=LR graph-depends

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
Cc: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Makefile
package/pkg-generic.mk

index 0b4264a5d5a09741b074c821891b7e0c918c3f5f..08696f757c0d4d901b1bf9677835b40d3297447d 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -675,7 +675,7 @@ graph-depends:
        @cd "$(CONFIG_DIR)"; \
        $(TOPDIR)/support/scripts/graph-depends $(BR2_GRAPH_DEPS_OPTS) \
        |tee $(O)/graphs/$(@).dot \
-       |dot -T$(BR_GRAPH_OUT) -o $(O)/graphs/$(@).$(BR_GRAPH_OUT)
+       |dot $(BR2_GRAPH_DOT_OPTS) -T$(BR_GRAPH_OUT) -o $(O)/graphs/$(@).$(BR_GRAPH_OUT)
 
 else # ifeq ($(BR2_HAVE_DOT_CONFIG),y)
 
index 5116ed9fea30dc2153b67a49bbc795474c803d30..c6c367c042f8dfc08465c8a5323aa5a833dcb86b 100644 (file)
@@ -533,7 +533,7 @@ $(1)-graph-depends:
                        @cd "$(CONFIG_DIR)"; \
                        $(TOPDIR)/support/scripts/graph-depends -p $(1) $(BR2_GRAPH_DEPS_OPTS) \
                        |tee $(O)/graphs/$$(@).dot \
-                       |dot -T$(BR_GRAPH_OUT) -o $(O)/graphs/$$(@).$(BR_GRAPH_OUT)
+                       |dot $(BR2_GRAPH_DOT_OPTS) -T$(BR_GRAPH_OUT) -o $(O)/graphs/$$(@).$(BR_GRAPH_OUT)
 
 $(1)-dirclean:         $$($(2)_TARGET_DIRCLEAN)