delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2013/10/31/09:26:18

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:content-type:content-transfer-encoding; q=dns; s=default; b=God
rMPr6z6+zs2uLlOhMEZOumfbJtSBflEIn4HaBZWxqz08ZK9MzIEmNSOHaSzUNf29
ItgrFjYEbrLR/lfPlRqDZWMKciGgx69bHR12b4z6ynFH2Drzuf4n0JJwpmfALzTr
5Uirf5z+A2WfDqWDmeKzkNCZq4gb5iMmBQkUqn2E=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:content-type:content-transfer-encoding; s=default; bh=Mgj6BQ9vu
LYyCxZzPyfKENfINXI=; b=OGnOJfGs6DHebxzkuKmYlmBuz9EiLpsuPPcY+YTGV
aZifoloS2ZrU9RSisf648ZRAlPBkXpZ9vcu/5PV4bTH89NudD0NPRej3WEZRYrZx
P2aTVuFNnWtxTnhsDQUz2diuw2SmjVPSuSFCf80hJB6afAx92DL7cQTJXICYcSgn
a8=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2
X-HELO: mail-ea0-f175.google.com
X-Received: by 10.15.101.3 with SMTP id bo3mr3187150eeb.77.1383225939827; Thu, 31 Oct 2013 06:25:39 -0700 (PDT)
Message-ID: <52725A4F.7010201@gmail.com>
Date: Thu, 31 Oct 2013 14:25:35 +0100
From: marco atzeri <marco DOT atzeri AT gmail DOT com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0
MIME-Version: 1.0
To: "cygwin AT cygwin DOT com" <cygwin AT cygwin DOT com>
Subject: bash command line limit
X-IsSubscribed: yes

There is any expected specific limit to command line length in
bash scripts on cygwin ?

Testing octave, I am noticing that line longer than ~ 5000 characters
are aborted with no message.

The line is :
--------------------------------------------------------------------
OCTAVE_BINDIR="$builddir/src" \
OCTAVE_SITE_INITFILE="$top_srcdir/scripts/startup/main-rcfile" \
OCTAVE_DEFAULT_QT_SETTINGS="$builddir/libgui/default-qt-settings" \
OCTAVE_LOCALE_DIR="$builddir/libgui/languages" \
OCTAVE_JAVA_DIR="$builddir/scripts/java" \
   exec $builddir/libtool -v --mode=execute $driver \
     "$octave_executable" --no-init-path --path="$LOADPATH" \
     --image-path="$IMAGEPATH" --doc-cache-file="$DOCFILE" \
     --built-in-docstrings-file="$BUILT_IN_DOCSTRINGS_FILE" \
     --texi-macros-file="$TEXIMACROSFILE" --info-file="$INFOFILE" "$@"
---------------------------------------------------------------------
end its full lenght when expended is over 5000 characters.

Just removing the last "\" before exec and dropping the length ~ 4950
and the script works again


In theory , the limit should be much more:

$ getconf ARG_MAX
32000

Regards
Marco



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019