Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 348154 Details for
Bug 468952
libtool.eclass depends on GNU chown - not available on all platforms
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed implementation of estat
estat.patch (text/plain), 1.28 KB, created by
Alexis Ballier
on 2013-05-13 11:02:11 UTC
(
hide
)
Description:
proposed implementation of estat
Filename:
MIME Type:
Creator:
Alexis Ballier
Created:
2013-05-13 11:02:11 UTC
Size:
1.28 KB
patch
obsolete
>Index: portability.eclass >=================================================================== >RCS file: /var/cvsroot/gentoo-x86/eclass/portability.eclass,v >retrieving revision 1.24 >diff -u -B -r1.24 portability.eclass >--- portability.eclass 4 Jan 2012 05:57:19 -0000 1.24 >+++ portability.eclass 13 May 2013 11:00:33 -0000 >@@ -132,6 +132,34 @@ > done > } > >+# @FUNCTION: estat >+# @USAGE: <'%a'> <file> >+# @DESCRIPTION: >+# Portable version of GNU stat -c. See GNU stat(1) manpage. >+# Its usage is limited to format specifiers that are actually implemented in a >+# portable way. >+# It supports only one format specifier, meaning "$(estat '%a%b' file)" is not >+# allowed but "$(estat '%a' file)$(estat '%b' file)" should be used instead. >+# estat currently implements the following specifiers from GNU stat: %a. >+estat() { >+ local stat_version="unknown" >+ if $(stat --help 2>&1 | grep -q GNU) ; then >+ stat_version="GNU" >+ fi >+ >+ local fmt=$1; shift >+ >+ case ${fmt} in >+ %a) >+ if [ "${stat_version}" = "GNU" ] ; then >+ stat -c "${fmt}" "$@" >+ else >+ find "$@" -maxdepth 0 -printf '%m' >+ fi;; >+ *) die "unhandled form";; >+ esac >+} >+ > _dead_portability_user_funcs() { die "if you really need this, please file a bug for base-system@gentoo.org"; } > is-login-disabled() { _dead_portability_user_funcs; } >
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 468952
: 348154