Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 257707 Details for
Bug 348788
mysql_fx.eclass is not prefix-aware
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
cumulative patch relative to in-tree mysql_fx.eclass
a.patch (text/plain), 2.92 KB, created by
Francesco Riosa
on 2010-12-21 21:02:36 UTC
(
hide
)
Description:
cumulative patch relative to in-tree mysql_fx.eclass
Filename:
MIME Type:
Creator:
Francesco Riosa
Created:
2010-12-21 21:02:36 UTC
Size:
2.92 KB
patch
obsolete
>--- /g/portage/eclass/mysql_fx.eclass 2009-02-12 06:06:32.000000000 +0100 >+++ mysql_fx.eclass 2010-12-21 21:56:27.429050625 +0100 >@@ -3,7 +3,8 @@ > # $Header: /var/cvsroot/gentoo-x86/eclass/mysql_fx.eclass,v 1.22 2009/02/12 05:05:14 robbat2 Exp $ > > # Author: Francesco Riosa (Retired) <vivo@gentoo.org> >-# Maintainer: Luca Longinotti <chtekk@gentoo.org> >+# Maintainer: MySQL Team <mysql-bugs@gentoo.org> >+# Luca Longinotti <chtekk@gentoo.org> > > inherit multilib > >@@ -177,13 +178,20 @@ > [[ ${want_s} -le ${have_s} ]] && return 0 || return 1 > } > >+__rm_and_ln() { >+ rm -f "${2}" >+ ln -s "${1}" "${2}" >+} >+ > # > # To be called on the live filesystem, reassigning symlinks of each MySQL > # library to the best version available. > # > mysql_lib_symlinks() { >- einfo "Updating MySQL .so symlinks" >- local d dirlist maxdots soname sonameln reldir >+ local d dirlist maxdots libname libnameln libsuffix reldir t >+ libsuffix=$(get_libname) >+ [[ -z ${libsuffix} ]] && return >+ einfo "Updating MySQL ${libsuffix} symlinks" > reldir="${1}" > pushd "${reldir}/usr/$(get_libdir)" &> /dev/null > # dirlist must contain the less significative directory left >@@ -191,20 +199,41 @@ > > # waste some time in removing and recreating symlinks > for d in $dirlist ; do >- for soname in $( find "${d}" -name "*.so*" -and -not -type "l" 2>/dev/null ) ; do >+ for libname in $( find "${d}" -name "*.${libsuffix}*" -and -not -type "l" 2>/dev/null ) ; do > # maxdot is a limit versus infinite loop > maxdots=0 >- sonameln=${soname##*/} >+ libnameln=${libname##*/} >+ t=${libnameln//./} # t will be used to count number of dots > # loop in version of the library to link it, similar to how > # libtool works >- while [[ ${sonameln:0-3} != '.so' ]] && [[ ${maxdots} -lt 6 ]] ; do >- rm -f "${sonameln}" >- ln -s "${soname}" "${sonameln}" >- (( ++maxdots )) >- sonameln="${sonameln%.*}" >- done >- rm -f "${sonameln}" >- ln -s "${soname}" "${sonameln}" >+ # - [[ $((${#libnameln} - ${#t})) > 1 ]] check is redundant >+ # because libmysqlclient.dylib libmysqlclient.so behave the same >+ # - idem for maxdots check >+ if [[ ${libnameln:0-${#libsuffix}} == "${libsuffix}" ]] \ >+ && [[ $((${#libnameln} - ${#t})) > 1 ]] >+ then >+ # .dylib like naming scheme >+ libnameln=${libnameln%.${libsuffix}} >+ t=${libnameln%%.*} >+ while [[ ${t} != ${libnameln} ]] \ >+ && [[ ${maxdots} -lt 6 ]] >+ do >+ __rm_and_ln "${libname}" "${libnameln}.${libsuffix}" >+ (( ++maxdots )) >+ libnameln="${libnameln%.*}" >+ done >+ __rm_and_ln "${libname}" "${libnameln}.${libsuffix}" >+ else >+ # .so like naming scheme >+ while [[ ${libnameln:0-${#libsuffix}} != "${libsuffix}" ]] \ >+ && [[ ${maxdots} -lt 6 ]] >+ do >+ __rm_and_ln "${libname}" "${libnameln}" >+ (( ++maxdots )) >+ libnameln="${libnameln%.*}" >+ done >+ __rm_and_ln "${libname}" "${libnameln}" >+ fi > done > done > popd &> /dev/null
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 348788
: 257707