summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorfile <file@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2007-07-18 16:27:04 +0000
committerfile <file@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2007-07-18 16:27:04 +0000
commit7aedb1abb4eeb7b9b0f9891ce31073249b5a892c (patch)
treeb9f81256a9a8a2a30e6e8d72080ac60edd66d552 /Makefile
parent077c316c9b4b8ef1b279056b1d3b5da9a84c7138 (diff)
A distribution may have multiple directories for firmware and without knowing the proper one we have to copy the firmware into each. We can't just copy it into the first one found.
git-svn-id: http://svn.digium.com/svn/zaptel/branches/1.2@2750 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 7 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index 8c9d3d0..edd01e1 100644
--- a/Makefile
+++ b/Makefile
@@ -133,10 +133,6 @@ endif
# sample makefile "trace print"
#tracedummy=$(shell echo ====== GOT HERE ===== >&2; echo >&2)
-ifeq ($(HOTPLUG_FIRMWARE),yes)
-FIRMWARE_DIR := $(firstword $(wildcard /usr/lib/hotplug/firmware /lib/firmware ))
-endif
-
CHKCONFIG := $(wildcard /sbin/chkconfig)
UPDATE_RCD := $(wildcard /usr/sbin/update-rc.d)
ifneq (,$(DESTDIR))
@@ -476,9 +472,13 @@ install-udev: devices
# FIRMWARE_DIR also implies HOTPLUG_FIRMWARE, unless set manually.
firmware:
-ifneq (,$(FIRMWARE_DIR))
- install -d $(DESTDIR)$(FIRMWARE_DIR)
- install -m 644 wct4xxp/*.ima wctc4xxp/*.bin $(DESTDIR)$(FIRMWARE_DIR)
+ifeq ($(HOTPLUG_FIRMWARE),yes)
+ if [ -d $(DESTDIR)/usr/lib/hotplug/firmware ]; then \
+ install -m 644 wct4xxp/*.ima wctc4xxp/*.bin $(DESTDIR)/usr/lib/hotplug/firmware; \
+ fi
+ if [ -d $(DESTDIR)/lib/firmware ]; then \
+ install -m 644 wct4xxp/*.ima wctc4xxp/*.bin $(DESTDIR)/lib/firmware; \
+ fi
@echo "Installed firmware"
else
@echo "Not installing firmware because we are not using hotplug firmware"