Annotation of /branches/R11-unstable/include/hal.sminc
Parent Directory | Revision Log
Revision 19668 -
(hide annotations)
(download)
Wed Oct 9 13:09:29 2013 UTC (10 years, 11 months ago) by niro
Original Path: trunk/include/hal.sminc
File size: 1687 byte(s)
Wed Oct 9 13:09:29 2013 UTC (10 years, 11 months ago) by niro
Original Path: trunk/include/hal.sminc
File size: 1687 byte(s)
-split udev, hal, systemd and sysvinit functions into seperate includes and use pkgconfig if possible
1 | niro | 19668 | # hal specific functions |
2 | |||
3 | DEPEND="${DEPEND} | ||
4 | >= sys-apps/hal-0.5.7" | ||
5 | |||
6 | sminclude mtools | ||
7 | |||
8 | minstallhalinformation() | ||
9 | { | ||
10 | local halrule | ||
11 | local file | ||
12 | |||
13 | [[ -z "$1" ]] && die "No hal rule given" | ||
14 | |||
15 | # if no fullpath given use file from sourcedir | ||
16 | if [[ -z $(dirname $1) ]] || [[ $(dirname $1) = . ]] | ||
17 | then | ||
18 | file="${SOURCEDIR}/$(mpname)/$1" | ||
19 | else | ||
20 | file="$1" | ||
21 | fi | ||
22 | |||
23 | if [[ -n "$2" ]] | ||
24 | then | ||
25 | halrule="$2" | ||
26 | else | ||
27 | halrule="$(basename ${file})" | ||
28 | fi | ||
29 | |||
30 | # needed directory | ||
31 | minstalldir /usr/share/hal/fdi/information/20thirdparty || die | ||
32 | |||
33 | # install our udev rule | ||
34 | minstallfile ${file} /usr/share/hal/fdi/information/20thirdparty/${halrule} || die | ||
35 | } | ||
36 | |||
37 | minstallhalpolicy() | ||
38 | { | ||
39 | local halrule | ||
40 | local file | ||
41 | |||
42 | [[ -z "$1" ]] && die "No hal rule given" | ||
43 | |||
44 | # if no fullpath given use file from sourcedir | ||
45 | if [[ -z $(dirname $1) ]] || [[ $(dirname $1) = . ]] | ||
46 | then | ||
47 | file="${SOURCEDIR}/$(mpname)/$1" | ||
48 | else | ||
49 | file="$1" | ||
50 | fi | ||
51 | |||
52 | if [[ -n "$2" ]] | ||
53 | then | ||
54 | halrule="$2" | ||
55 | else | ||
56 | halrule="$(basename ${file})" | ||
57 | fi | ||
58 | |||
59 | # needed directory | ||
60 | minstalldir /usr/share/hal/fdi/policy/20thirdparty || die | ||
61 | |||
62 | # install our udev rule | ||
63 | minstallfile ${file} /usr/share/hal/fdi/policy/20thirdparty/${halrule} || die | ||
64 | } | ||
65 | |||
66 | minstallhalpreprobe() | ||
67 | { | ||
68 | local halrule | ||
69 | local file | ||
70 | |||
71 | [[ -z "$1" ]] && die "No hal rule given" | ||
72 | |||
73 | # if no fullpath given use file from sourcedir | ||
74 | if [[ -z $(dirname $1) ]] || [[ $(dirname $1) = . ]] | ||
75 | then | ||
76 | file="${SOURCEDIR}/$(mpname)/$1" | ||
77 | else | ||
78 | file="$1" | ||
79 | fi | ||
80 | |||
81 | if [[ -n "$2" ]] | ||
82 | then | ||
83 | halrule="$2" | ||
84 | else | ||
85 | halrule="$(basename ${file})" | ||
86 | fi | ||
87 | |||
88 | # needed directory | ||
89 | minstalldir /usr/share/hal/fdi/preprobe/10osvendor || die | ||
90 | |||
91 | # install our udev rule | ||
92 | minstallfile ${file} /usr/share/hal/fdi/preprobe/10osvendor/${halrule} || die | ||
93 | } |