gpio: Only descend into gpio directory when CONFIG_GPIOLIB is set
authorAndrew F. Davis <afd@ti.com>
Mon, 13 Jun 2016 20:02:00 +0000 (15:02 -0500)
committerLinus Walleij <linus.walleij@linaro.org>
Tue, 14 Jun 2016 06:58:06 +0000 (08:58 +0200)
When CONFIG_GPIOLIB is not set make will still descend into the gpio
directory but nothing will be built. This produces unneeded build
artifacts and messages in addition to slowing the build. Fix this here.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/Makefile

index 0b6f3d60193dcc2f2cdfaabe2f37e23a0b8f48a9..50f6131430e82ada36147797ab43c7f357a97b5a 100644 (file)
@@ -12,7 +12,7 @@ obj-$(CONFIG_GENERIC_PHY)     += phy/
 
 # GPIO must come after pinctrl as gpios may need to mux pins etc
 obj-$(CONFIG_PINCTRL)          += pinctrl/
-obj-y                          += gpio/
+obj-$(CONFIG_GPIOLIB)          += gpio/
 obj-y                          += pwm/
 obj-$(CONFIG_PCI)              += pci/
 obj-$(CONFIG_PARISC)           += parisc/