X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com Date: Tue, 14 Jul 2015 16:32:46 +0200 (CEST) X-X-Sender: igor2 AT igor2priv To: "Vladimir Zhbanov (vzhbanov AT gmail DOT com) [via geda-user AT delorie DOT com]" X-Debug: to=geda-user AT delorie DOT com from="gedau AT igor2 DOT repo DOT hu" From: gedau AT igor2 DOT repo DOT hu cc: geda-developers AT lists DOT launchpad DOT net Subject: Re: [geda-user] Re: geda-gaf on FreeBSD and probably other architectures In-Reply-To: <20150714140911.GA18818@localhost.localdomain> Message-ID: References: <20150714103959 DOT GA17565 AT localhost DOT localdomain> <20150714140911 DOT GA18818 AT localhost DOT localdomain> User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Tue, 14 Jul 2015, Vladimir Zhbanov (vzhbanov AT gmail DOT com) [via geda-user AT delorie DOT com] wrote: > > OK, the line in question was > d=`LANG=C date -d $(DATE_VERSION) "+%B %-d, %Y"` ; \ > > I've written two scripts, one is combination of sed and awk: > > echo DATE_VERSION | sed 's/\(....\)\(..\)\(..\)/\1 \2 \3 00 00 00/' | > LANG=C awk '{print (strftime ("%B %-d, %Y", mktime ($0)))}' strftime() in awk is not portable - gawk supports it, mawk and the old/traditional awk implementations don't. I really suggest using C, as the project already depends on C and strftime() is C89 so won't introduce new dependencies portability-wise. Regards, Igor2