Opened 3 years ago

Closed 2 years ago

#62625 closed defect (fixed)

lighttpd @1.4.59 does not build on PPC Leopard because #pragma GCC diagnostic not allowed inside functions

Reported by: ballapete (Peter "Pete" Dyballa) Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: leopard Cc:
Port: lighttpd

Description

/usr/bin/gcc-4.2 -std=gnu99 -DHAVE_CONFIG_H -DHAVE_VERSIONSTAMP_H -DLIBRARY_DIR="\"/opt/local/lib\"" -DSBIN_DIR="\"/opt/local/sbin\"" -I. -I..    -I/opt/local/include -I/opt/local/include/LegacySupport -D_REENTRANT -I/opt/local/include -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES   -pipe -Os -I/opt/local/include/LegacySupport -arch ppc -Wall -W -Wshadow -pedantic -MT ls-hpack/lighttpd-lshpack.o -MD -MP -MF ls-hpack/.deps/lighttpd-lshpack.Tpo -c -o ls-hpack/lighttpd-lshpack.o `test -f 'ls-hpack/lshpack.c' || echo './'`ls-hpack/lshpack.c
In file included from ls-hpack/lshpack.h:34,
                 from ls-hpack/lshpack.c:40:
ls-hpack/lsxpack_header.h:59: warning: type of bit-field ‘flags’ is a GCC extension
ls-hpack/lshpack.c: In function ‘lshpack_enc_huff_encode’:
ls-hpack/lshpack.c:703: error: #pragma GCC diagnostic not allowed inside functions
ls-hpack/lshpack.c:704: error: #pragma GCC diagnostic not allowed inside functions
ls-hpack/lshpack.c:705: error: #pragma GCC diagnostic not allowed inside functions
ls-hpack/lshpack.c:820: error: #pragma GCC diagnostic not allowed inside functions
ls-hpack/lshpack.c: In function ‘hdec_get_table_entry’:
ls-hpack/lshpack.c:1502: warning: declaration of ‘index’ shadows a global declaration
/usr/include/string.h:125: warning: shadowed declaration is here
ls-hpack/lshpack.c: In function ‘lshpack_dec_decode’:
ls-hpack/lshpack.c:1610: warning: declaration of ‘index’ shadows a global declaration
/usr/include/string.h:125: warning: shadowed declaration is here
ls-hpack/lshpack.c: At top level:
ls-hpack/lshpack.c:2059: warning: expected [error|warning|ignored] after ‘#pragma GCC diagnostic’
make[3]: *** [ls-hpack/lighttpd-lshpack.o] Error 1
make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_www_lighttpd/lighttpd/work/lighttpd-1.4.59/src'
make[2]: *** [all] Error 2

The blocks of code are:

  702	#if __GNUC__ && !defined(__COVERITY__)
  703	#pragma GCC diagnostic push
  704	#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
  705	#pragma GCC diagnostic ignored "-Wuninitialized"
  706	#else
  707	    bits = 0;
  708	#endif

  819	#if __GNUC__
  820	#pragma GCC diagnostic pop
  821	#endif

Presumingly a more up-to-date GCC will compile…

Attachments (1)

main.log (75.3 KB) - added by ballapete (Peter "Pete" Dyballa) 3 years ago.
Main.log from PPC Leopard with GCC 4.2

Download all attachments as: .zip

Change History (6)

Changed 3 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

Main.log from PPC Leopard with GCC 4.2

comment:1 Changed 3 years ago by ballapete (Peter "Pete" Dyballa)

It built with GCC7.

comment:2 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… removed
Owner: set to ryandesign
Status: newassigned

comment:3 Changed 2 years ago by evanmiller (Evan Miller)

In 6e1535e8a3b440bb90d693de81dbcdba151757d5/macports-ports (master):

lighttpd: blacklist GCC <5

See: #62625

comment:4 Changed 2 years ago by gstrauss (Glenn Strauss)

In ab3d120c565ddad0c407026548f9a69c4b5bd01c/macports-ports (master):

lighttpd: update to 1.4.64

  • update to 1.4.64
  • remove files/implicit.patch; incorporated upstream
  • remove compiler.blacklist gcc 3.* 4.* provide patch to move #pragma GCC diagnostic outside funcs #62625
  • remove patch to doc/config/conf.d/mysql_vhost.conf (removed in lighttpd 1.4.64)

comment:5 Changed 2 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.