Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 288447 Details for
Bug 385201
sys-devel/auto{conf,make}-wrapper: fails when called from Eclipse with autotools support
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for ac-wrapper.sh
ac-wrapper_scriptname.patch (text/plain), 2.27 KB, created by
Florian Philipp
on 2011-10-01 15:16:57 UTC
(
hide
)
Description:
Patch for ac-wrapper.sh
Filename:
MIME Type:
Creator:
Florian Philipp
Created:
2011-10-01 15:16:57 UTC
Size:
2.27 KB
patch
obsolete
>--- ac-wrapper-11.sh 2011-10-01 16:26:16.000000000 +0200 >+++ ac-wrapper.sh 2011-10-01 16:48:14.000000000 +0200 >@@ -29,6 +29,16 @@ > " that would use autom4te." > fi > >+ >+# Sanitize $0 in order to protect against stupid ways of calling this script >+# such as `sh autoconf` which prevent $0 from being set to a valid path. >+# Since we cannot manipulate $0, use $script instead. >+if [ -x "$0" ]; then >+ script="$0" >+else >+ script=$(which "$0") >+fi >+ > if ! seq 0 0 2>/dev/null 1>&2 ; then #338518 > seq() { > local f l i >@@ -55,14 +65,14 @@ > binary="" > for v in ${vers} ; do > auto_ver=${v%:*} >- if [ -z "${binary}" ] && [ -x "${0}-${auto_ver}" ] ; then >- binary="${0}-${auto_ver}" >+ if [ -z "${binary}" ] && [ -x "${script}-${auto_ver}" ] ; then >+ binary="${script}-${auto_ver}" > fi > done > if [ -z "${binary}" ] ; then > err "Unable to locate any usuable version of autoconf.\n" \ > "\tI tried these versions: ${vers}\n" \ >- "\tWith a base name of '${0}'." >+ "\tWith a base name of '${script}'." > fi > > # >@@ -80,8 +90,8 @@ > auto_ver=${v%:*} > want_ver=${v#*:} > for wx in ${WANT_AUTOCONF} ; do >- if [ "${wx}" = "${want_ver}" ] && [ -x "${0}-${auto_ver}" ] ; then >- binary="${0}-${auto_ver}" >+ if [ "${wx}" = "${want_ver}" ] && [ -x "${script}-${auto_ver}" ] ; then >+ binary="${script}-${auto_ver}" > v="x" > fi > done >@@ -94,8 +104,8 @@ > # > acprereq_version() { > gawk \ >- '($0 !~ /^[[:space:]]*(#|dnl)/) { >- if (match($0, "AC_PREREQ\\(\\[?([0-9]\\.[0-9])", res)) >+ '($script !~ /^[[:space:]]*(#|dnl)/) { >+ if (match($script, "AC_PREREQ\\(\\[?([0-9]\\.[0-9])", res)) > VERSIONS[COUNT++] = res[1] > } > >@@ -108,7 +118,7 @@ > generated_version() { > gawk \ > '{ >- if (match($0, >+ if (match($script, > "^# Generated (by (GNU )?Autoconf|automatically using autoconf version) ([0-9].[0-9])", > res)) { > print res[3] >@@ -140,7 +150,7 @@ > && confversion=$(generated_version configure) > > if [ "${confversion}" = "2.1" ] && [ ! -f "configure.ac" ] ; then >- binary="${0}-2.13" >+ binary="${script}-2.13" > fi > esac > fi >@@ -158,7 +168,7 @@ > for v in ${vers} ; do > auto_ver=${v%:*} > want_ver=${v#*:} >- if [ "${binary}" = "${0}-${auto_ver}" ] ; then >+ if [ "${binary}" = "${script}-${auto_ver}" ] ; then > export WANT_AUTOCONF="${want_ver}" > fi > done
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 385201
: 288447