mirror of
https://github.com/rtlsdrblog/rtl-sdr-blog.git
synced 2025-01-11 18:57:19 +01:00
don't install udev rules by default, as it may pollute the system
For cmake call with -DINSTALL_UDEV_RULES=ON for the rules to be installed during the default install/uninstall stages. For autotools call "make install-udev-rules" or "make uninstall-udev- The rules file will be installed to "/etc/udev/rules.d".
This commit is contained in:
parent
5a26bd51e7
commit
0c7ba8e03e
@ -90,7 +90,7 @@ add_custom_target(uninstall
|
|||||||
########################################################################
|
########################################################################
|
||||||
# Install udev rules
|
# Install udev rules
|
||||||
########################################################################
|
########################################################################
|
||||||
option(INSTALL_UDEV_RULES "Install udev rules for RTL-SDR" ON)
|
option(INSTALL_UDEV_RULES "Install udev rules for RTL-SDR" OFF)
|
||||||
if (INSTALL_UDEV_RULES)
|
if (INSTALL_UDEV_RULES)
|
||||||
install (
|
install (
|
||||||
FILES rtl-sdr.rules
|
FILES rtl-sdr.rules
|
||||||
|
11
Makefile.am
11
Makefile.am
@ -7,16 +7,19 @@ SUBDIRS = include src
|
|||||||
pkgconfigdir = $(libdir)/pkgconfig
|
pkgconfigdir = $(libdir)/pkgconfig
|
||||||
pkgconfig_DATA = librtlsdr.pc
|
pkgconfig_DATA = librtlsdr.pc
|
||||||
|
|
||||||
udevrulesdir=/etc/udev/rules.d
|
|
||||||
udevrules_DATA = rtl-sdr.rules
|
|
||||||
|
|
||||||
BUILT_SOURCES = $(top_srcdir)/.version
|
BUILT_SOURCES = $(top_srcdir)/.version
|
||||||
$(top_srcdir)/.version:
|
$(top_srcdir)/.version:
|
||||||
echo $(VERSION) > $@-t && mv $@-t $@
|
echo $(VERSION) > $@-t && mv $@-t $@
|
||||||
dist-hook:
|
dist-hook:
|
||||||
echo $(VERSION) > $(distdir)/.tarball-version
|
echo $(VERSION) > $(distdir)/.tarball-version
|
||||||
|
|
||||||
EXTRA_DIST = git-version-gen $(udevrules_DATA)
|
install-udev-rules:
|
||||||
|
$(INSTALL_DATA) rtl-sdr.rules /etc/udev/rules.d
|
||||||
|
|
||||||
|
uninstall-udev-rules:
|
||||||
|
rm -rf /etc/udev/rules.d/rtl-sdr.rules
|
||||||
|
|
||||||
|
EXTRA_DIST = git-version-gen
|
||||||
|
|
||||||
if HAVE_DOXYGEN
|
if HAVE_DOXYGEN
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user