diff options
author | Kay Sievers <kay.sievers@vrfy.org> | 2008-07-30 01:45:23 +0200 |
---|---|---|
committer | Kay Sievers <kay.sievers@vrfy.org> | 2008-07-30 01:45:23 +0200 |
commit | 01618658fd82dbc5e6315b639f00e87c6fee3c54 (patch) | |
tree | df8e628d04a81186d6d431fd3b1fa50a3d34987a /udev/udev_rules_parse.c | |
parent | 726687ad48bdececed1e7e44387c50e009e28208 (diff) |
use autotools
Diffstat (limited to 'udev/udev_rules_parse.c')
-rw-r--r-- | udev/udev_rules_parse.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/udev/udev_rules_parse.c b/udev/udev_rules_parse.c index 3ada8b1c7d..273f92f486 100644 --- a/udev/udev_rules_parse.c +++ b/udev/udev_rules_parse.c @@ -451,7 +451,7 @@ static int add_to_rules(struct udev_rules *rules, char *line, const char *filena /* allow programs in /lib/udev called without the path */ if (strchr(file, '/') == NULL) { - strlcpy(file, "/lib/udev/", sizeof(file)); + strlcpy(file, UDEV_PREFIX "/lib/udev/", sizeof(file)); strlcat(file, value, sizeof(file)); pos = strchr(file, ' '); if (pos) @@ -739,24 +739,24 @@ int udev_rules_init(struct udev_rules *rules, int resolve_names) if (udev_rules_dir[0] != '\0') { /* custom rules location for testing */ - add_matching_files(&name_list, udev_rules_dir, RULESFILE_SUFFIX); + add_matching_files(&name_list, udev_rules_dir, ".rules"); } else { /* read default rules */ - add_matching_files(&name_list, RULES_LIB_DIR, RULESFILE_SUFFIX); + add_matching_files(&name_list, UDEV_PREFIX "/lib/udev/rules.d", ".rules"); /* read user/custom rules */ - add_matching_files(&sort_list, RULES_ETC_DIR, RULESFILE_SUFFIX); + add_matching_files(&sort_list, SYSCONFDIR "/udev/rules.d", ".rules"); /* read dynamic/temporary rules */ strlcpy(filename, udev_root, sizeof(filename)); - strlcat(filename, "/"RULES_DYN_DIR, sizeof(filename)); + strlcat(filename, "/.udev/rules.d", sizeof(filename)); if (stat(filename, &statbuf) != 0) { create_path(filename); selinux_setfscreatecon(filename, NULL, S_IFDIR|0755); mkdir(filename, 0755); selinux_resetfscreatecon(); } - add_matching_files(&sort_list, filename, RULESFILE_SUFFIX); + add_matching_files(&sort_list, filename, ".rules"); /* sort all rules files by basename into list of files */ list_for_each_entry_safe(sort_loop, sort_tmp, &sort_list, node) { |