Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:96250 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 63602 invoked from network); 5 Oct 2016 14:59:37 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Oct 2016 14:59:37 -0000 Authentication-Results: pb1.pair.com smtp.mail=dclarke@blastwave.org; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=dclarke@blastwave.org; sender-id=unknown Received-SPF: error (pb1.pair.com: domain blastwave.org from 209.17.115.110 cause and error) X-PHP-List-Original-Sender: dclarke@blastwave.org X-Host-Fingerprint: 209.17.115.110 atl4mhob17.myregisteredsite.com Received: from [209.17.115.110] ([209.17.115.110:34562] helo=atl4mhob17.myregisteredsite.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 5A/54-23443-75515F75 for ; Wed, 05 Oct 2016 10:59:37 -0400 Received: from mailpod.hostingplatform.com ([10.30.77.36]) by atl4mhob17.myregisteredsite.com (8.14.4/8.14.4) with ESMTP id u95ExXmv010031 for ; Wed, 5 Oct 2016 10:59:33 -0400 Received: (qmail 11601 invoked by uid 0); 5 Oct 2016 14:59:32 -0000 X-TCPREMOTEIP: 99.247.223.96 X-Authenticated-UID: dclarke@blastwave.org Received: from unknown (HELO ?172.16.35.41?) (dclarke@blastwave.org@99.247.223.96) by 0 with ESMTPA; 5 Oct 2016 14:59:32 -0000 To: internals@lists.php.net Message-ID: <090bbd8e-ebe9-0806-ca69-4ec28a56ce05@blastwave.org> Date: Wed, 5 Oct 2016 10:59:32 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: ext/fileinfo/libmagic/apprentice.c", line 2195: error: syntax error From: dclarke@blastwave.org (Dennis Clarke) I tried the php-install mail list but saw no reply thus I will try here. While attempting a build of 7.0.11 I was presented with : "/usr/local/build/php-7.0.11_SunOS5.10_sparcv9.001/ext/fileinfo/libmagic/apprentice.c", line 2195: error: syntax error before or at: struct "/usr/local/build/php-7.0.11_SunOS5.10_sparcv9.001/ext/fileinfo/libmagic/apprentice.c", line 2209: error: syntax error before or at: struct cc: acomp failed for /usr/local/build/php-7.0.11_SunOS5.10_sparcv9.001/ext/fileinfo/libmagic/apprentice.c gmake: *** [ext/fileinfo/libmagic/apprentice.lo] Error 1 The problem appears to be in a strange placement of the keyword "struct" : 2189 private int 2190 parse_apple(struct magic_set *ms, struct magic_entry *me, const char *line) 2191 { 2192 struct magic *m = &me->mp[0]; 2193 2194 return parse_extra(ms, me, line, 2195 CAST(off_t, offsetof(struct magic, apple)), 2196 sizeof(m->apple), "APPLE", "!+-./", 0); 2197 } 2198 also 2203 private int 2204 parse_mime(struct magic_set *ms, struct magic_entry *me, const char *line) 2205 { 2206 struct magic *m = &me->mp[0]; 2207 2208 return parse_extra(ms, me, line, 2209 CAST(zend_off_t, offsetof(struct magic, mimetype)), 2210 sizeof(m->mimetype), "MIME", "+-/.", 1); 2211 } 2212 Not sure where the definition of "offsetof()" is located but something seems clearly not C compliant here. So this is using the Oracle Studio 12.5 compiler tools on a big old SPARC box running Solaris 10. Any input would be appreciated. The cflags were permissive and allowed for transition type elements as I note that C99 with strict compliance will fail horribly. The configure stage was reasonably clean also. In any case .. any input would be greatly appreciated. Dennis