From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail-wi0-x22c.google.com ([2a00:1450:400c:c05::22c]) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1YPJD4-0002ao-SS for ptxdist@pengutronix.de; Sun, 22 Feb 2015 00:11:43 +0100 Received: by mail-wi0-f172.google.com with SMTP id l15so9823226wiw.5 for ; Sat, 21 Feb 2015 15:11:37 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <1E9AED858BEB204B9DE4F807C7ED0EF617CDD326@EMSRVWIN2934.apps.edc.thyssenkrupp.com> References: <1E9AED858BEB204B9DE4F807C7ED0EF617CDD326@EMSRVWIN2934.apps.edc.thyssenkrupp.com> Date: Sat, 21 Feb 2015 18:11:37 -0500 Message-ID: From: Jon Ringle Subject: Re: [ptxdist] (no subject) Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============0515724251==" Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: "ptxdist@pengutronix.de" --===============0515724251== Content-Type: multipart/alternative; boundary=e89a8f8391b1789278050fa14a81 --e89a8f8391b1789278050fa14a81 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Sat, Feb 21, 2015 at 6:07 PM, R=C3=BCdiger, Christoph < Christoph.Ruediger@thyssenkrupp.com> wrote: > Hello, > > I'm trying to use ptxdist on a Mac OS X system to get rid of the Linux VM > just for compiling things. Here is the thing I stumbled upon because I > don't get the intention and therefore struggle to find a patch. > > The git commit 0dc57566bc5a25d2b086de333844a3c00addf0e4 from 2012-12-13 > changed the body of the ptxd_make_log() function in scripts/libptxdist.sh > from this implementation > > -ptxd_make_log() { > - # > - # fd3 =3D=3D stdout to logfile > - # fd4 =3D=3D stderr to logfile > - # fd5 =3D=3D clean stdout > - # fd6 =3D=3D clean stderr > - # > - { > - export PTXDIST_FD_STDOUT=3D5 > - export PTXDIST_FD_STDERR=3D6 > - export PTXDIST_FD_LOGFILE=3D7 > - { > - if [ -z "${PTXDIST_QUIET}" ]; then > - ptxd_make "${@}" 4>&- | > - # make's stdout on fd0 > - tee -a "${PTX_LOGFILE}" 2>&4 4>&- 5>&- 6>= &- > - check_pipe_status || return > - else > - exec 4>&- > - ptxd_make "${@}" 1>> "${PTX_LOGFILE}" > - fi > - } 2>&1 1>&3 3>&- 7>> "${PTX_LOGFILE}" | > - # make's stderr on fd0 > - tee -a "${PTX_LOGFILE}" 1>&2 3>&- 4>&- 5>&- 6>&- > - check_pipe_status || return > - } 3>&1 4>&2 5>&1 6>&2 > -} > > to this implementation > > +ptxd_make_log() {( > + # stdout only > + exec {PTXDIST_FD_STDOUT}>&1 > + # stderr only > + exec {PTXDIST_FD_STDERR}>&2 > missing $ try: exec ${PTXDIST_FD_STDOUT}>&1 exec ${PTXDIST_FD_STDERR}>&2 --e89a8f8391b1789278050fa14a81 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Sat, Feb 21, 2015 at 6:07 PM, R=C3=BCdiger, Christoph <Christoph.Ruediger@thyssenkrupp.com> wrote:
Hello,

I'm trying to use ptxdist on a Mac OS X system to get rid of the Linux = VM just for compiling things. Here is the thing I stumbled upon because I d= on't get the intention and therefore struggle to find a patch.

The git commit 0dc57566bc5a25d2b086de333844a3c00addf0e4 from 2012-12-13 cha= nged the body of the ptxd_make_log() function in scripts/libptxdist.sh from= this implementation

-ptxd_make_log() {
-=C2=A0 =C2=A0 =C2=A0 =C2=A0#
-=C2=A0 =C2=A0 =C2=A0 =C2=A0# fd3 =3D=3D stdout to logfile
-=C2=A0 =C2=A0 =C2=A0 =C2=A0# fd4 =3D=3D stderr to logfile
-=C2=A0 =C2=A0 =C2=A0 =C2=A0# fd5 =3D=3D clean stdout
-=C2=A0 =C2=A0 =C2=A0 =C2=A0# fd6 =3D=3D clean stderr
-=C2=A0 =C2=A0 =C2=A0 =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0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0else
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0exec 4>&-
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0ptxd_make "${@}" 1>> = "${PTX_LOGFILE}"
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0fi
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0} 2>&1 1>= &3 3>&- 7>> "${PTX_LOGFILE}" |
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0# make's stderr= on fd0
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0tee -a "${PTX_= LOGFILE}" 1>&2 3>&- 4>&- 5>&- 6>&-<= br> -=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0check_pipe_status |= | return
-=C2=A0 =C2=A0 =C2=A0 =C2=A0} 3>&1 4>&2 5>&1 6>&= ;2
-}

to this implementation

+ptxd_make_log() {(
+=C2=A0 =C2=A0 =C2=A0 =C2=A0# stdout only
+=C2=A0 =C2=A0 =C2=A0 =C2=A0exec {PTXDIST_FD_STDOUT}>&1
+=C2=A0 =C2=A0 =C2=A0 =C2=A0# stderr only
+=C2=A0 =C2=A0 =C2=A0 =C2=A0exec {PTXDIST_FD_STDERR}>&2

missing $
try:
exec ${PTXDIST_F= D_STDOUT}>&1
exec ${PTXDIST_FD_STDERR}>&2
=C2=A0
--e89a8f8391b1789278050fa14a81-- --===============0515724251== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline -- ptxdist mailing list ptxdist@pengutronix.de --===============0515724251==--