public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] eselect r747 - in trunk: . modules
@ 2009-12-29 19:15 Ulrich Mueller (ulm)
  0 siblings, 0 replies; only message in thread
From: Ulrich Mueller (ulm) @ 2009-12-29 19:15 UTC (permalink / raw
  To: gentoo-commits

Author: ulm
Date: 2009-12-29 19:15:30 +0000 (Tue, 29 Dec 2009)
New Revision: 747

Modified:
   trunk/ChangeLog
   trunk/modules/env.eselect
Log:
Remove the "makelinks" option in env module, bug 298742.

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2009-12-29 14:17:08 UTC (rev 746)
+++ trunk/ChangeLog	2009-12-29 19:15:30 UTC (rev 747)
@@ -1,5 +1,11 @@
 2009-12-29  Ulrich Mueller  <ulm@gentoo.org>
 
+	* modules/env.eselect (do_update): Remove the "makelinks" option.
+	The logic of this was always wrong, and mtime caching breaks with
+	recent glibc versions. Bug 298742.
+	(need_links, LDMTIMEDB): Function and variable removed.
+	(describe_update_parameters, describe_update_options): Update.
+
 	* modules/env.eselect (PATH_CLASS): Fix a typo, ADA_OBJECT_PATH
 	should be ADA_OBJECTS_PATH.
 

Modified: trunk/modules/env.eselect
===================================================================
--- trunk/modules/env.eselect	2009-12-29 14:17:08 UTC (rev 746)
+++ trunk/modules/env.eselect	2009-12-29 19:15:30 UTC (rev 747)
@@ -35,7 +35,6 @@
 ENVPROFILE="${EROOT}/etc/profile.env"
 LDCONFIG="${EROOT}/etc/ld.so.conf"
 PRELINK="${EROOT}/etc/prelink.conf"
-LDMTIMEDB="${EROOT}/var/lib/eselect/env/ld-mtimedb"
 
 # Keep all stored LDPATHS
 ESELECT_LDPATH=( )
@@ -215,25 +214,6 @@
 	echo -n -e "${str}" >"$(canonicalise "${PRELINK}")"
 }
 
-# need_links()
-# Returns true if any item of ${LDPATH} has been modified.
-need_links() {
-	local ret=1
-	for x in "${ESELECT_LDPATH[@]}"; do
-		y=${x//\//_}
-		y=${y//-/_}
-		y=${y//./_}
-		y=${y//+/_}
-		oldmtime=$(load_config "${LDMTIMEDB}" "mtime${y}")
-		newmtime=$(stat -c %Y ${x} 2> /dev/null)
-		if [[ ${oldmtime} != ${newmtime} ]]; then
-			ret=0
-			store_config "${LDMTIMEDB}" "mtime${y}" ${newmtime}
-		fi
-	done
-	return ${ret}
-}
-
 # update_ldcache()
 # Update ld.so.cache using ldconfig
 update_ldcache() {
@@ -263,22 +243,21 @@
 }
 
 describe_update_parameters() {
-	echo "<makelinks> <noldconfig>"
+	echo "<noldconfig>"
 }
 
 describe_update_options() {
-	echo "makelinks : Specify \"makelinks\" to force updating of links"
 	echo "noldconfig : Do not alter the ld.so cache or configuration."
 }
 
 do_update() {
-	local makelinks ldconfig=1
+	local ldconfig=1
 	while [[ $# -gt 0 ]]; do
-		case ${1} in
+		case ${1##--} in
 			makelinks)
-				makelinks="-X"
+				# option is ignored, only for backwards compatibility
 				;;
-			noldconfig)
+			noldconfig|no-ldconfig)
 				ldconfig=0
 				;;
 			*)
@@ -296,11 +275,10 @@
 
 	# Create configuration files
 	create_profile_env
-	if [[ ${ldconfig} == 1 ]]; then
+	if [[ ${ldconfig} -ne 0 ]]; then
 		create_ld_so_conf
 		[[ -e ${EROOT}/usr/sbin/prelink ]] && create_prelink_conf
-		need_links && makelinks="-X"
-		update_ldcache ${makelinks}
+		update_ldcache
 	fi
 
 	# fix up ${ENVPROFILE}




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-12-29 19:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-29 19:15 [gentoo-commits] eselect r747 - in trunk: . modules Ulrich Mueller (ulm)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox