Gentoo Archives: gentoo-commits

From: "Matthias Schwarzott (zzam)" <zzam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-fs/udev: ChangeLog udev-9999.ebuild udev-136.ebuild
Date: Tue, 20 Jan 2009 13:05:44
Message-Id: E1LPGD3-0007VT-P2@stork.gentoo.org
1 zzam 09/01/20 13:00:01
2
3 Modified: ChangeLog udev-9999.ebuild
4 Added: udev-136.ebuild
5 Log:
6 Version bumped. This raises kernel version for reliable udev usage to 2.6.20. Backported one patch. The upstream rule changes still need to be reviewed. For now keep using group uucp instead of dialout as suggested by upstream. Move init-script stuff into a subdir for FILESDIR. Small changes to shell-compat logic.
7 (Portage version: 2.1.6.6/cvs/Linux 2.6.27-gentoo-r1 i686)
8
9 Revision Changes Path
10 1.438 sys-fs/udev/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/ChangeLog?rev=1.438&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/ChangeLog?rev=1.438&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/ChangeLog?r1=1.437&r2=1.438
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v
19 retrieving revision 1.437
20 retrieving revision 1.438
21 diff -u -r1.437 -r1.438
22 --- ChangeLog 20 Jan 2009 11:20:22 -0000 1.437
23 +++ ChangeLog 20 Jan 2009 13:00:01 -0000 1.438
24 @@ -1,6 +1,21 @@
25 # ChangeLog for sys-fs/udev
26 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.437 2009/01/20 11:20:22 zzam Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.438 2009/01/20 13:00:01 zzam Exp $
29 +
30 +*udev-136 (20 Jan 2009)
31 +
32 + 20 Jan 2009; Matthias Schwarzott <zzam@g.o>
33 + +files/136/shell-compat-addon.sh, +files/136/udev.confd,
34 + +files/udev-136-fix-ide-cd-rule.diff, +files/136/udev.initd,
35 + +files/136/udev-dev-tarball.initd, +files/136/udev-mount.initd,
36 + +files/136/shell-compat-KV.sh, +files/136/udev-postmount.initd,
37 + +files/136/udev-start.sh, +files/136/udev-stop.sh, +udev-136.ebuild,
38 + udev-9999.ebuild:
39 + Version bumped. This raises kernel version for reliable udev usage to
40 + 2.6.20. Backported one patch. The upstream rule changes still need to be
41 + reviewed. For now keep using group uucp instead of dialout as suggested by
42 + upstream. Move init-script stuff into a subdir for FILESDIR. Small changes
43 + to shell-compat logic.
44
45 20 Jan 2009; Matthias Schwarzott <zzam@g.o>
46 files/shell-compat-118-r3.sh:
47
48
49
50 1.3 sys-fs/udev/udev-9999.ebuild
51
52 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/udev-9999.ebuild?rev=1.3&view=markup
53 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/udev-9999.ebuild?rev=1.3&content-type=text/plain
54 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/udev-9999.ebuild?r1=1.2&r2=1.3
55
56 Index: udev-9999.ebuild
57 ===================================================================
58 RCS file: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-9999.ebuild,v
59 retrieving revision 1.2
60 retrieving revision 1.3
61 diff -u -r1.2 -r1.3
62 --- udev-9999.ebuild 6 Jan 2009 18:42:15 -0000 1.2
63 +++ udev-9999.ebuild 20 Jan 2009 13:00:01 -0000 1.3
64 @@ -1,6 +1,6 @@
65 # Copyright 1999-2009 Gentoo Foundation
66 # Distributed under the terms of the GNU General Public License v2
67 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-9999.ebuild,v 1.2 2009/01/06 18:42:15 mr_bones_ Exp $
68 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-9999.ebuild,v 1.3 2009/01/20 13:00:01 zzam Exp $
69
70 inherit eutils flag-o-matic multilib toolchain-funcs versionator
71
72 @@ -38,14 +38,16 @@
73 local KV_MINOR=$(get_version_component_range 2 ${KV})
74 local KV_MICRO=$(get_version_component_range 3 ${KV})
75
76 - local min_micro=15 min_micro_reliable=20
77 + local KV_min_micro=15 KV_min_micro_reliable=20
78 + KV_min=2.6.${KV_min_micro}
79 + KV_min_reliable=2.6.${KV_min_micro_reliable}
80
81 local ok=0
82 if [[ ${KV_MAJOR} == 2 && ${KV_MINOR} == 6 ]]
83 then
84 - if [[ ${KV_MICRO} -ge ${min_micro_reliable} ]]; then
85 + if [[ ${KV_MICRO} -ge ${KV_min_micro_reliable} ]]; then
86 ok=2
87 - elif [[ ${KV_MICRO} -ge ${min_micro} ]]; then
88 + elif [[ ${KV_MICRO} -ge ${KV_min_micro} ]]; then
89 ok=1
90 fi
91 fi
92 @@ -53,11 +55,11 @@
93 if [[ ${ok} -lt 1 ]]
94 then
95 ewarn
96 - ewarn "${P} does not support Linux kernel before version 2.6.${min_micro}!"
97 + ewarn "${P} does not support Linux kernel before version ${KV_min}!"
98 fi
99 if [[ ${ok} -lt 2 ]]; then
100 ewarn "If you want to use udev reliable you should update"
101 - ewarn "to at least kernel version 2.6.${min_micro_reliable}!"
102 + ewarn "to at least kernel version ${KV_min_reliable}!"
103 ewarn
104 ebeep
105 fi
106 @@ -78,15 +80,20 @@
107
108 # patches go here...
109
110 + # change rules back to group uucp instead of dialout for now
111 + sed -e 's/GROUP="dialout"/GROUP="uucp"/' \
112 + -i rules/{rules.d,packages}/*.rules
113 +
114 if [[ ${PV} != 9999 ]]; then
115 # Make sure there is no sudden changes to upstream rules file
116 # (more for my own needs than anything else ...)
117 MD5=$(md5sum < "${S}/rules/rules.d/50-udev-default.rules")
118 MD5=${MD5/ -/}
119 - if [[ ${MD5} != c233e7da2eaebbda659d7121957aea72 ]]
120 + if [[ ${MD5} != 7c7de0a29a2cf218dc43dd099cd3bfec ]]
121 then
122 echo
123 eerror "50-udev-default.rules has been updated, please validate!"
124 + eerror "md5sum=${MD5}"
125 die "50-udev-default.rules has been updated, please validate!"
126 fi
127 fi
128 @@ -118,6 +125,8 @@
129 }
130
131 src_install() {
132 + local scriptdir="${FILESDIR}/136"
133 +
134 into /
135 emake DESTDIR="${D}" install || die "make install failed"
136 if [[ "$(get_libdir)" != "lib" ]]; then
137 @@ -134,7 +143,10 @@
138 || die "move_tmp_persistent_rules.sh not installed properly"
139 newexe "${FILESDIR}"/write_root_link_rule-125 write_root_link_rule \
140 || die "write_root_link_rule not installed properly"
141 - newexe "${FILESDIR}"/shell-compat-118-r3.sh shell-compat.sh \
142 +
143 + doexe "${scriptdir}"/shell-compat-KV.sh \
144 + || die "shell-compat.sh not installed properly"
145 + doexe "${scriptdir}"/shell-compat-addon.sh \
146 || die "shell-compat.sh not installed properly"
147
148 keepdir "${udev_helper_dir}"/state
149 @@ -170,19 +182,27 @@
150
151 # our udev hooks into the rc system
152 insinto /$(get_libdir)/rcscripts/addons
153 - newins "${FILESDIR}"/udev-start-135-r3.sh udev-start.sh
154 - newins "${FILESDIR}"/udev-stop-135-r2.sh udev-stop.sh
155 -
156 - # The udev-post init-script
157 - newinitd "${FILESDIR}"/udev-postmount-135-r2.initd udev-postmount
158 + doins "${scriptdir}"/udev-start.sh \
159 + || die "udev-start.sh not installed properly"
160 + doins "${scriptdir}"/udev-stop.sh \
161 + || die "udev-stop.sh not installed properly"
162 +
163 + local init
164 + # udev-postmount and init-scripts for >=openrc-0.3.1, Bug #240984
165 + for init in udev udev-mount udev-dev-tarball udev-postmount; do
166 + newinitd "${scriptdir}/${init}.initd" "${init}" \
167 + || die "initscript ${init} not installed properly"
168 + done
169 +
170 + # insert minimum kernel versions
171 + sed -e "s/%KV_MIN%/${KV_min}/" \
172 + -e "s/%KV_MIN_RELIABLE%/${KV_min_reliable}/" \
173 + -i "${D}"/etc/init.d/udev-mount
174
175 - # init-scripts for >=openrc-0.3.1, Bug #240984
176 - newinitd "${FILESDIR}/udev-135-r2.initd" udev
177 - newinitd "${FILESDIR}/udev-mount-135-r3.initd" udev-mount
178 - newinitd "${FILESDIR}/udev-dev-tarball-135-r2.initd" udev-dev-tarball
179
180 # config file for init-script and start-addon
181 - newconfd "${FILESDIR}/udev-135-r3.confd" udev
182 + newconfd "${scriptdir}/udev.confd" udev \
183 + || die "config file not installed properly"
184
185 insinto /etc/modprobe.d
186 newins "${FILESDIR}"/blacklist-110 blacklist
187
188
189
190 1.1 sys-fs/udev/udev-136.ebuild
191
192 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/udev-136.ebuild?rev=1.1&view=markup
193 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-fs/udev/udev-136.ebuild?rev=1.1&content-type=text/plain
194
195 Index: udev-136.ebuild
196 ===================================================================
197 # Copyright 1999-2009 Gentoo Foundation
198 # Distributed under the terms of the GNU General Public License v2
199 # $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-136.ebuild,v 1.1 2009/01/20 13:00:01 zzam Exp $
200
201 inherit eutils flag-o-matic multilib toolchain-funcs versionator
202
203 HOMEPAGE="http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html"
204 if [[ ${PV} == "9999" ]]; then
205 EGIT_REPO_URI="git://git.kernel.org/pub/scm/linux/hotplug/udev.git"
206 EGIT_BRANCH="master"
207 inherit git autotools
208 else
209 SRC_URI="mirror://kernel/linux/utils/kernel/hotplug/${P}.tar.bz2"
210 fi
211 DESCRIPTION="Linux dynamic and persistent device naming support (aka userspace devfs)"
212
213 LICENSE="GPL-2"
214 SLOT="0"
215 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
216 IUSE="selinux"
217
218 DEPEND="selinux? ( sys-libs/libselinux )"
219 RDEPEND="!sys-apps/coldplug
220 !<sys-fs/device-mapper-1.02.19-r1"
221 RDEPEND="${DEPEND} ${RDEPEND}
222 >=sys-apps/baselayout-1.12.5"
223 # We need the lib/rcscripts/addon support
224 PROVIDE="virtual/dev-manager"
225
226 pkg_setup() {
227 udev_helper_dir="/$(get_libdir)/udev"
228
229 # comparing kernel version without linux-info.eclass to not pull
230 # virtual/linux-sources
231
232 local KV=$(uname -r)
233 local KV_MAJOR=$(get_major_version ${KV})
234 local KV_MINOR=$(get_version_component_range 2 ${KV})
235 local KV_MICRO=$(get_version_component_range 3 ${KV})
236
237 local KV_min_micro=15 KV_min_micro_reliable=20
238 KV_min=2.6.${KV_min_micro}
239 KV_min_reliable=2.6.${KV_min_micro_reliable}
240
241 local ok=0
242 if [[ ${KV_MAJOR} == 2 && ${KV_MINOR} == 6 ]]
243 then
244 if [[ ${KV_MICRO} -ge ${KV_min_micro_reliable} ]]; then
245 ok=2
246 elif [[ ${KV_MICRO} -ge ${KV_min_micro} ]]; then
247 ok=1
248 fi
249 fi
250
251 if [[ ${ok} -lt 1 ]]
252 then
253 ewarn
254 ewarn "${P} does not support Linux kernel before version ${KV_min}!"
255 fi
256 if [[ ${ok} -lt 2 ]]; then
257 ewarn "If you want to use udev reliable you should update"
258 ewarn "to at least kernel version ${KV_min_reliable}!"
259 ewarn
260 ebeep
261 fi
262 }
263
264 sed_helper_dir() {
265 sed -e "s#/lib/udev#${udev_helper_dir}#" -i "$@"
266 }
267
268 src_unpack() {
269 if [[ ${PV} == "9999" ]] ; then
270 git_src_unpack
271 else
272 unpack ${A}
273 fi
274
275 cd "${S}"
276
277 # patches go here...
278 epatch "${FILESDIR}/${P}-fix-ide-cd-rule.diff"
279
280 # change rules back to group uucp instead of dialout for now
281 sed -e 's/GROUP="dialout"/GROUP="uucp"/' \
282 -i rules/{rules.d,packages}/*.rules
283
284 if [[ ${PV} != 9999 ]]; then
285 # Make sure there is no sudden changes to upstream rules file
286 # (more for my own needs than anything else ...)
287 MD5=$(md5sum < "${S}/rules/rules.d/50-udev-default.rules")
288 MD5=${MD5/ -/}
289 if [[ ${MD5} != 7c7de0a29a2cf218dc43dd099cd3bfec ]]
290 then
291 echo
292 eerror "50-udev-default.rules has been updated, please validate!"
293 eerror "md5sum=${MD5}"
294 die "50-udev-default.rules has been updated, please validate!"
295 fi
296 fi
297
298 sed_helper_dir \
299 rules/rules.d/50-udev-default.rules \
300 extras/rule_generator/write_*_rules \
301 udev/udev-util.c \
302 udev/udev-rules.c \
303 udev/udevd.c || die "sed failed"
304
305 if [[ ${PV} == 9999 ]]; then
306 eautoreconf
307 fi
308 }
309
310 src_compile() {
311 filter-flags -fprefetch-loop-arrays
312
313 econf \
314 --prefix=/usr \
315 --sysconfdir=/etc \
316 --exec-prefix= \
317 --with-libdir-name=$(get_libdir) \
318 --enable-logging \
319 $(use_with selinux)
320
321 emake || die "compiling udev failed"
322 }
323
324 src_install() {
325 local scriptdir="${FILESDIR}/136"
326
327 into /
328 emake DESTDIR="${D}" install || die "make install failed"
329 if [[ "$(get_libdir)" != "lib" ]]; then
330 # we can not just rename /lib to /lib64, because
331 # make install creates /lib64 and /lib
332 mkdir -p "${D}/$(get_libdir)"
333 mv "${D}"/lib/* "${D}/$(get_libdir)/"
334 rmdir "${D}"/lib
335 fi
336
337 exeinto "${udev_helper_dir}"
338 newexe "${FILESDIR}"/net-130-r1.sh net.sh || die "net.sh not installed properly"
339 newexe "${FILESDIR}"/move_tmp_persistent_rules-112-r1.sh move_tmp_persistent_rules.sh \
340 || die "move_tmp_persistent_rules.sh not installed properly"
341 newexe "${FILESDIR}"/write_root_link_rule-125 write_root_link_rule \
342 || die "write_root_link_rule not installed properly"
343
344 doexe "${scriptdir}"/shell-compat-KV.sh \
345 || die "shell-compat.sh not installed properly"
346 doexe "${scriptdir}"/shell-compat-addon.sh \
347 || die "shell-compat.sh not installed properly"
348
349 keepdir "${udev_helper_dir}"/state
350 keepdir "${udev_helper_dir}"/devices
351
352 # create symlinks for these utilities to /sbin
353 # where multipath-tools expect them to be (Bug #168588)
354 dosym "..${udev_helper_dir}/vol_id" /sbin/vol_id
355 dosym "..${udev_helper_dir}/scsi_id" /sbin/scsi_id
356
357 # Add gentoo stuff to udev.conf
358 echo "# If you need to change mount-options, do it in /etc/fstab" \
359 >> "${D}"/etc/udev/udev.conf
360
361 # let the dir exist at least
362 keepdir /etc/udev/rules.d
363
364 # Now installing rules
365 cd "${S}"/rules
366 insinto "${udev_helper_dir}"/rules.d/
367
368 # Our rules files
369 doins gentoo/??-*.rules
370 doins packages/40-alsa.rules
371 doins packages/40-isdn.rules
372
373 # Adding arch specific rules
374 if [[ -f packages/40-${ARCH}.rules ]]
375 then
376 doins "packages/40-${ARCH}.rules"
377 fi
378 cd "${S}"
379
380 # our udev hooks into the rc system
381 insinto /$(get_libdir)/rcscripts/addons
382 doins "${scriptdir}"/udev-start.sh \
383 || die "udev-start.sh not installed properly"
384 doins "${scriptdir}"/udev-stop.sh \
385 || die "udev-stop.sh not installed properly"
386
387 local init
388 # udev-postmount and init-scripts for >=openrc-0.3.1, Bug #240984
389 for init in udev udev-mount udev-dev-tarball udev-postmount; do
390 newinitd "${scriptdir}/${init}.initd" "${init}" \
391 || die "initscript ${init} not installed properly"
392 done
393
394 # insert minimum kernel versions
395 sed -e "s/%KV_MIN%/${KV_min}/" \
396 -e "s/%KV_MIN_RELIABLE%/${KV_min_reliable}/" \
397 -i "${D}"/etc/init.d/udev-mount
398
399
400 # config file for init-script and start-addon
401 newconfd "${scriptdir}/udev.confd" udev \
402 || die "config file not installed properly"
403
404 insinto /etc/modprobe.d
405 newins "${FILESDIR}"/blacklist-110 blacklist
406 doins "${FILESDIR}"/pnp-aliases
407
408 # convert /lib/udev to real used dir
409 sed_helper_dir \
410 "${D}/$(get_libdir)"/rcscripts/addons/*.sh \
411 "${D}"/etc/init.d/udev* \
412 "${D}"/etc/modprobe.d/*
413
414 # documentation
415 dodoc ChangeLog README TODO || die "failed installing docs"
416
417 cd docs/writing_udev_rules
418 mv index.html writing_udev_rules.html
419 dohtml *.html
420
421 cd "${S}"
422
423 newdoc extras/volume_id/README README_volume_id
424
425 echo "CONFIG_PROTECT_MASK=\"/etc/udev/rules.d\"" > 20udev
426 doenvd 20udev
427 }
428
429 pkg_preinst() {
430 if [[ -d ${ROOT}/lib/udev-state ]]
431 then
432 mv -f "${ROOT}"/lib/udev-state/* "${D}"/lib/udev/state/
433 rm -r "${ROOT}"/lib/udev-state
434 fi
435
436 if [[ -f ${ROOT}/etc/udev/udev.config &&
437 ! -f ${ROOT}/etc/udev/udev.rules ]]
438 then
439 mv -f "${ROOT}"/etc/udev/udev.config "${ROOT}"/etc/udev/udev.rules
440 fi
441
442 # delete the old udev.hotplug symlink if it is present
443 if [[ -h ${ROOT}/etc/hotplug.d/default/udev.hotplug ]]
444 then
445 rm -f "${ROOT}"/etc/hotplug.d/default/udev.hotplug
446 fi
447
448 # delete the old wait_for_sysfs.hotplug symlink if it is present
449 if [[ -h ${ROOT}/etc/hotplug.d/default/05-wait_for_sysfs.hotplug ]]
450 then
451 rm -f "${ROOT}"/etc/hotplug.d/default/05-wait_for_sysfs.hotplug
452 fi
453
454 # delete the old wait_for_sysfs.hotplug symlink if it is present
455 if [[ -h ${ROOT}/etc/hotplug.d/default/10-udev.hotplug ]]
456 then
457 rm -f "${ROOT}"/etc/hotplug.d/default/10-udev.hotplug
458 fi
459
460 # is there a stale coldplug initscript? (CONFIG_PROTECT leaves it behind)
461 coldplug_stale=""
462 if [[ -f ${ROOT}/etc/init.d/coldplug ]]
463 then
464 coldplug_stale="1"
465 fi
466
467 has_version "=${CATEGORY}/${PN}-103-r3"
468 previous_equal_to_103_r3=$?
469
470 has_version "<${CATEGORY}/${PN}-104-r5"
471 previous_less_than_104_r5=$?
472
473 has_version "<${CATEGORY}/${PN}-106-r5"
474 previous_less_than_106_r5=$?
475
476 has_version "<${CATEGORY}/${PN}-113"
477 previous_less_than_113=$?
478 }
479
480 fix_old_persistent_net_rules() {
481 local rules=${ROOT}/etc/udev/rules.d/70-persistent-net.rules
482 [[ -f ${rules} ]] || return
483
484 elog
485 elog "Updating persistent-net rules file"
486
487 # Change ATTRS to ATTR matches, Bug #246927
488 sed -i -e 's/ATTRS{/ATTR{/g' "${rules}"
489
490 # Add KERNEL matches if missing, Bug #246849
491 sed -ri \
492 -e '/KERNEL/ ! { s/NAME="(eth|wlan|ath)([0-9]+)"/KERNEL=="\1*", NAME="\1\2"/}' \
493 "${rules}"
494 }
495
496 # See Bug #129204 for a discussion about restarting udevd
497 restart_udevd() {
498 # need to merge to our system
499 [[ ${ROOT} = / ]] || return
500
501 # check if root of init-process is identical to ours (not in chroot)
502 [[ -r /proc/1/root && /proc/1/root/ -ef /proc/self/root/ ]] || return
503
504 # abort if there is no udevd running
505 [[ -n $(pidof udevd) ]] || return
506
507 # abort if no /dev/.udev exists
508 [[ -e /dev/.udev ]] || return
509
510 elog
511 elog "restarting udevd now."
512
513 killall -15 udevd &>/dev/null
514 sleep 1
515 killall -9 udevd &>/dev/null
516
517 /sbin/udevd --daemon
518 }
519
520 pkg_postinst() {
521 fix_old_persistent_net_rules
522
523 restart_udevd
524
525 if [[ -e "${ROOT}"/etc/runlevels/sysinit && ! -e "${ROOT}"/etc/runlevels/sysinit/udev ]]
526 then
527 ewarn
528 ewarn "You need to add the udev init script to the runlevel sysinit,"
529 ewarn "else your system will not be able to boot"
530 ewarn "after updating to >=openrc-0.4.0"
531 ewarn "Run this to enable udev for >=openrc-0.4.0:"
532 ewarn "\trc-update add udev sysinit"
533 ewarn
534 fi
535
536 # people want reminders, I'll give them reminders. Odds are they will
537 # just ignore them anyway...
538
539 if [[ ${coldplug_stale} == 1 ]]
540 then
541 ewarn "A stale coldplug init script found. You should run:"
542 ewarn
543 ewarn " rc-update del coldplug"
544 ewarn " rm -f /etc/init.d/coldplug"
545 ewarn
546 ewarn "udev now provides its own coldplug functionality."
547 fi
548
549 # delete 40-scsi-hotplug.rules - all integrated in 50-udev.rules
550 if [[ $previous_equal_to_103_r3 = 0 ]] &&
551 [[ -e ${ROOT}/etc/udev/rules.d/40-scsi-hotplug.rules ]]
552 then
553 ewarn "Deleting stray 40-scsi-hotplug.rules"
554 ewarn "installed by sys-fs/udev-103-r3"
555 rm -f "${ROOT}"/etc/udev/rules.d/40-scsi-hotplug.rules
556 fi
557
558 # Removing some device-nodes we thought we need some time ago
559 if [[ -d ${ROOT}/lib/udev/devices ]]
560 then
561 rm -f "${ROOT}"/lib/udev/devices/{null,zero,console,urandom}
562 fi
563
564 # Removing some old file
565 if [[ $previous_less_than_104_r5 = 0 ]]
566 then
567 rm -f "${ROOT}"/etc/dev.d/net/hotplug.dev
568 rmdir --ignore-fail-on-non-empty "${ROOT}"/etc/dev.d/net 2>/dev/null
569 fi
570
571 if [[ $previous_less_than_106_r5 = 0 ]] &&
572 [[ -e ${ROOT}/etc/udev/rules.d/95-net.rules ]]
573 then
574 rm -f "${ROOT}"/etc/udev/rules.d/95-net.rules
575 fi
576
577 # Try to remove /etc/dev.d as that is obsolete
578 if [[ -d ${ROOT}/etc/dev.d ]]
579 then
580 rmdir --ignore-fail-on-non-empty "${ROOT}"/etc/dev.d/default "${ROOT}"/etc/dev.d 2>/dev/null
581 if [[ -d ${ROOT}/etc/dev.d ]]
582 then
583 ewarn "You still have the directory /etc/dev.d on your system."
584 ewarn "This is no longer used by udev and can be removed."
585 fi
586 fi
587
588 # 64-device-mapper.rules now gets installed by sys-fs/device-mapper
589 # remove it if user don't has sys-fs/device-mapper installed
590 if [[ $previous_less_than_113 = 0 ]] &&
591 [[ -f ${ROOT}/etc/udev/rules.d/64-device-mapper.rules ]] &&
592 ! has_version sys-fs/device-mapper
593 then
594 rm -f "${ROOT}"/etc/udev/rules.d/64-device-mapper.rules
595 einfo "Removed unneeded file 64-device-mapper.rules"
596 fi
597
598 # requested in Bug #225033:
599 elog
600 elog "persistent-net does assigning fixed names to network devices."
601 elog "If you have problems with the persistent-net rules,"
602 elog "just delete the rules file"
603 elog "\trm ${ROOT}etc/udev/rules.d/70-persistent-net.rules"
604 elog "and then reboot."
605 elog
606 elog "This may however number your devices in a different way than they are now."
607
608 ewarn
609 ewarn "If you build an initramfs including udev, then please"
610 ewarn "make sure that the /sbin/udevadm binary gets included,"
611 ewarn "and your scripts changed to use it,as it replaces the"
612 ewarn "old helper apps udevinfo, udevtrigger, ..."
613
614 ewarn
615 ewarn "mount options for directory /dev are no longer"
616 ewarn "set in /etc/udev/udev.conf, but in /etc/fstab"
617 ewarn "as for other directories."
618
619 elog
620 elog "For more information on udev on Gentoo, writing udev rules, and"
621 elog " fixing known issues visit:"
622 elog " http://www.gentoo.org/doc/en/udev-guide.xml"
623 }