From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 104283 invoked by alias); 19 Aug 2017 20:53:57 -0000 Mailing-List: contact newlib-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: newlib-owner@sourceware.org Received: (qmail 104269 invoked by uid 89); 19 Aug 2017 20:53:56 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy=H*i:sk:09a4309, H*f:sk:09a4309, Attached, personal X-HELO: smtp-out-so.shaw.ca Received: from smtp-out-so.shaw.ca (HELO smtp-out-so.shaw.ca) (64.59.136.139) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 19 Aug 2017 20:53:52 +0000 Received: from [192.168.1.100] ([24.64.240.204]) by shaw.ca with SMTP id jAkfdNIqp8LPZjAkgdRg1F; Sat, 19 Aug 2017 14:53:51 -0600 X-Authority-Analysis: v=2.2 cv=e552ceh/ c=1 sm=1 tr=0 a=MVEHjbUiAHxQW0jfcDq5EA==:117 a=MVEHjbUiAHxQW0jfcDq5EA==:17 a=IkcTkHD0fZMA:10 a=KwXFQT2fuueLHZ9S1Y4A:9 a=QEXdDO2ut3YA:10 Reply-To: Brian.Inglis@SystematicSw.ab.ca Subject: Re: Cygwin strptime() is missing "%s" which strftime() has To: newlib@sourceware.org References: <851e9a02-f7c2-25c4-f37d-64d17d5c6d54@SystematicSw.ab.ca> <20170725091613.GB14419@calimero.vinschen.de> <20170725185206.GE14419@calimero.vinschen.de> <9c38bcee-fbb0-9a30-0c28-58629f54aa0e@SystematicSw.ab.ca> <20170726104918.GF14419@calimero.vinschen.de> <6ae417fd-e109-4549-f005-5cfa7b6fdb62@SystematicSw.ab.ca> <20170726193443.GD30367@calimero.vinschen.de> <20170731095532.GK24013@calimero.vinschen.de> <09a4309f-a47c-5056-16bf-fe81e9ad483a@SystematicSw.ab.ca> From: Brian Inglis Message-ID: Date: Mon, 21 Aug 2017 03:09:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <09a4309f-a47c-5056-16bf-fe81e9ad483a@SystematicSw.ab.ca> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-CMAE-Envelope: MS4wfC3mG4vNr/NpU70sAYoyrrmXEHd/BRmdP7Mscm10DAzmMr5Fzx5/1ZpKdkRp6ffhu3AnNeaAhO8QR0N+8lmiArYlKvc7SNq/Jc0e1Mx2sdDzFUJC7Sf2 f1Bg6Ud2HLCCU25KY3F1G3DOBpvuleyxRSqOPEj9IUF/Fvph5mpXLz+PIItbXnK2XTWyiWJ+WcdLNw== X-IsSubscribed: yes X-SW-Source: 2017/txt/msg00845.txt.bz2 On 2017-08-18 14:00, Brian Inglis wrote: > On 2017-07-31 03:55, Corinna Vinschen wrote: >> On Jul 28 14:50, Brian Inglis wrote: >>> On 2017-07-26 13:34, Corinna Vinschen wrote: >>>> On Jul 26 11:27, Brian Inglis wrote: >>>>> On 2017-07-26 04:49, Corinna Vinschen wrote: >>>>>> On Jul 25 14:13, Brian Inglis wrote: >>>>>>> On 2017-07-25 12:52, Corinna Vinschen wrote: >>>>>>>> Well... on *third* thought, targets may redefine time_t via redefining >>>>>>>> _TIME_T_. Targets not doing that will get long, so yeah, you're right. >>>>>>>> Maybe it is safer to use always strtoll_l and just break this down to >>>>>>>> time_t on the way. >>>>>>> >>>>>>> My concern has always been do all newlib RTEMS targets support long >>>>>>> long, even if same as long, and stroll_l? >>>>>> >>>>>> Yes. The long long functions are not excluded like we do with long >>>>>> double stuff. >>>>>> >>>>>>> Trying to build standalone or combined STC for this with changed strptime.c >>>>>>> ld/collect2 fails to resolve ...global_locale. >>>>>> >>>>>> Yeah, it's an internal function to newlib. You need to include >>>>>> libc/locale/setlocale.h somehow to accomplish that. STC from Cygwin >>>>>> userspace will do. >>>>> >>>>> Not doing it for me: that's why I asked if there were undistributed locale >>>>> changes in the tree, and maybe in a dev snapshot? >>>> >>>> No, it's an *internal* function, it doesn't get exported. There's no >>>> (easy) way to build strptime.c outside the newlib tree as part of the >>>> lib. That's why I said a userspace STC is enough. Don't try to build >>>> strptime.c as standalone. Just build it as part of newlib/Cygwin and >>>> test it from userspace by calling it. >>> >>> Finally got all the prereqs installed and a clean build. >>> My configure uses the default prefix /usr/local, which is at the head of my >>> personal path. >>> Is that enough for a test build, and how do I do that, or do I have to replace >>> the current release, with configure --prefix=/, make install into /bin/? >> >> The configured paths don't matter for the Cygwin DLL itself, and your >> patch doesn't change any headers or entry points of the lib. So just exit >> from Cygwin, replace the DLL in Explorer, start a shell and go ahead. > > Test still won't run as expected after DLL replacement, nor coreutils strptime. > Aren't there lib import files or maps or anything I also have to move? > Attached slightly redacted build config and make logs. > > Resending without attachments to see if this makes it to the list. Doh! Cygwin has its own strptime.cc whereas it uses strftime.c from newlib. Guess I should also patch Cygwin strptime.cc in a similar manner. -- Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada