[asterisk-dev] Zaptel udev checking svn 1064
Jeffrey C. Ollie
jeff at ocjtech.us
Thu May 18 06:40:42 MST 2006
On Wed, 2006-05-17 at 13:26 -0500, Kevin P. Fleming wrote:
> Jeffrey C. Ollie wrote:
>
> > We shouldn't need to comment out any rules if we name the file that we
> > install "/etc/udev/rules.d/10-zaptel.rules".
>
> The only way we could guarantee that would be to name it
> 00-zaptel.rules, or something like that... and even that would not be
> perfect.
>
> I think the only other reasonable action might be to scan
> /etc/udev/rules.d/* for any other files that appear to contain Zaptel
> rules and warn the admin that the new rules might not get used... thoughts?
Naming the file "10-zaptel.rules" should be sufficent. The udev
documentation recommends that admins put locally created rules in
10-local.rules. What might be even better would be to allow the admin
to specify his/her own name:
Index: Makefile
===================================================================
--- Makefile (revision 1072)
+++ Makefile (working copy)
@@ -83,8 +83,10 @@
# because they'll be wiped at next reboot.
DYNFS:=$(shell ps ax | grep -v grep | grep -qw 'devfsd\|udevd' && echo "yes")
+UDEVRULESFILE?=10-zaptel.rules
+UDEVRULESDIR?=/etc/udev/rules.d
# Check for udev rules directories
-ifneq (,$(wildcard $(ROOT_PREFIX)/etc/udev/rules.d))
+ifneq (,$(wildcard $(ROOT_PREFIX)$(UDEVRULESDIR)))
UDEVRULES=yes
endif
@@ -310,7 +312,7 @@
done
else # DYNFS
ifdef UDEVRULES
- build_tools/genudevrules > $(INSTALL_PREFIX)/etc/udev/rules.d/zaptel.rules
+ build_tools/genudevrules > $(INSTALL_PREFIX)$(UDEVRULESDIR)/$(UDEVRULESFILE)
else # !UDEVRULES
@echo "**** Dynamic filesystem detected -- not creating device nodes"
endif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20060518/7c101626/attachment.pgp
More information about the asterisk-dev
mailing list