Lists: | pgsql-committerspgsql-hackers |
---|
From: | momjian(at)postgresql(dot)org (Bruce Momjian) |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-10 16:15:24 |
Message-ID: | 20071110161524.033F77540F0@cvs.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Log Message:
-----------
Use strip -x on OS/X-darwin because non-"-x" causes link problems:
http://archives.postgresql.org/pgsql-hackers/2007-10/msg01470.php
Modified Files:
--------------
pgsql/config:
install-sh (r1.4 -> r1.5)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/config/install-sh?r1=1.4&r2=1.5)
From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-13 10:39:34 |
Message-ID: | 200711131139.34813.peter_e@gmx.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Am Samstag, 10. November 2007 schrieb Bruce Momjian:
> Log Message:
> -----------
> Use strip -x on OS/X-darwin because non-"-x" causes link problems:
>
> http://archives.postgresql.org/pgsql-hackers/2007-10/msg01470.php
>
> Modified Files:
> --------------
> pgsql/config:
> install-sh (r1.4 -> r1.5)
>
> (http://developer.postgresql.org/cvsweb.cgi/pgsql/config/install-sh?r1=1.4&
>r2=1.5)
How will this work, considering that $template isn't set anywhere?
--
Peter Eisentraut
http://developer.postgresql.org/~petere/
From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | pgsql-committers(at)postgresql(dot)org, Bruce Momjian <bruce(at)momjian(dot)us> |
Subject: | Re: [HACKERS] pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-13 17:15:56 |
Message-ID: | 18190.1194974156@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Am Samstag, 10. November 2007 schrieb Bruce Momjian:
>> Use strip -x on OS/X-darwin because non-"-x" causes link problems:
> How will this work, considering that $template isn't set anywhere?
It won't, of course. Perhaps something like
if test `uname -s` = Darwin
instead.
regards, tom lane
From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-committers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-13 18:15:53 |
Message-ID: | 200711131815.lADIFrD29372@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Tom Lane wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > Am Samstag, 10. November 2007 schrieb Bruce Momjian:
> >> Use strip -x on OS/X-darwin because non-"-x" causes link problems:
>
> > How will this work, considering that $template isn't set anywhere?
>
> It won't, of course. Perhaps something like
>
> if test `uname -s` = Darwin
>
> instead.
I am afraid some unames don't have -s, so I did uname -a and tested for
it starting with Darwin. Patch attached and applied.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://postgres.enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
Attachment | Content-Type | Size |
---|---|---|
/rtmp/diff | text/x-diff | 976 bytes |
From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-committers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-13 18:37:56 |
Message-ID: | 20071113183756.GD19014@alvh.no-ip.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Bruce Momjian wrote:
> Tom Lane wrote:
> > Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > > Am Samstag, 10. November 2007 schrieb Bruce Momjian:
> > >> Use strip -x on OS/X-darwin because non-"-x" causes link problems:
> >
> > > How will this work, considering that $template isn't set anywhere?
> >
> > It won't, of course. Perhaps something like
> >
> > if test `uname -s` = Darwin
> >
> > instead.
>
> I am afraid some unames don't have -s, so I did uname -a and tested for
> it starting with Darwin. Patch attached and applied.
Hmm, this doesn't seem to work for me:
$ if test expr "`uname -a`" : 'Darwin' -ne 0
> then stripprog="${STRIPPROG-strip -x}"
> else stripprog="${STRIPPROG-strip}"
> fi
-bash: test: too many arguments
--
Alvaro Herrera http://www.amazon.com/gp/registry/5ZYLFMCVHXC
"La naturaleza, tan frágil, tan expuesta a la muerte... y tan viva"
From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-committers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] pgsql: Use strip -x on OS/X-darwin because non-"-x" causes link |
Date: | 2007-11-13 18:50:55 |
Message-ID: | 200711131850.lADIotV25841@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Alvaro Herrera wrote:
> Bruce Momjian wrote:
> > Tom Lane wrote:
> > > Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > > > Am Samstag, 10. November 2007 schrieb Bruce Momjian:
> > > >> Use strip -x on OS/X-darwin because non-"-x" causes link problems:
> > >
> > > > How will this work, considering that $template isn't set anywhere?
> > >
> > > It won't, of course. Perhaps something like
> > >
> > > if test `uname -s` = Darwin
> > >
> > > instead.
> >
> > I am afraid some unames don't have -s, so I did uname -a and tested for
> > it starting with Darwin. Patch attached and applied.
>
> Hmm, this doesn't seem to work for me:
>
> $ if test expr "`uname -a`" : 'Darwin' -ne 0
> > then stripprog="${STRIPPROG-strip -x}"
> > else stripprog="${STRIPPROG-strip}"
> > fi
> -bash: test: too many arguments
Sorry, corrected patch attached, tested, and applied.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://postgres.enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
Attachment | Content-Type | Size |
---|---|---|
/rtmp/diff | text/x-diff | 992 bytes |
From: | Gregory Stark <stark(at)enterprisedb(dot)com> |
---|---|
To: | "Alvaro Herrera" <alvherre(at)alvh(dot)no-ip(dot)org> |
Cc: | "Bruce Momjian" <bruce(at)momjian(dot)us>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Peter Eisentraut" <peter_e(at)gmx(dot)net>, <pgsql-committers(at)postgresql(dot)org> |
Subject: | Re: [HACKERS] pgsql: Use strip -x on OS/X-darwinbecause non-"-x" causes link |
Date: | 2007-11-13 18:57:49 |
Message-ID: | 87oddy3rde.fsf@oxford.xeocode.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
"Alvaro Herrera" <alvherre(at)alvh(dot)no-ip(dot)org> writes:
> Hmm, this doesn't seem to work for me:
>
> $ if test expr "`uname -a`" : 'Darwin' -ne 0
>> then stripprog="${STRIPPROG-strip -x}"
>> else stripprog="${STRIPPROG-strip}"
>> fi
> -bash: test: too many arguments
No, "test" and "expr" are separate programs.
The above would be
if test "$(expr "$(uname -a)" : Darwin)" -ne 0 ; then
...
Except the "test" invocation is entirely redundant, expr is already intended
to be used as the program for an if condition. You can just do:
if expr "`uname -a`" : Darwin >/dev/null ; then
...
--
Gregory Stark
EnterpriseDB http://www.enterprisedb.com
Ask me about EnterpriseDB's On-Demand Production Tuning