Opened 7 years ago

Closed 7 years ago

#55716 closed defect (fixed)

netpbm@10.81.01+universal+x11 build fails on Snow Leopard

Reported by: rlhamil Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.4.2
Keywords: snowleopard Cc:
Port: netpbm

Description (last modified by mf2k (Frank Schima))

The problem (or at any rate, the first problem) seems to be that strnlen() is missing...

:info:build sldtoppm.c:218:17: warning: implicit declaration of function 'strnlen' is invalid in C99 [-Wimplicit-function-declaration]
:info:build             if (strnlen(slideName, 32) == 32)
:info:build                 ^
:info:build 1 warning generated.
:info:build sldtoppm.c:218:17: warning: implicit declaration of function 'strnlen' is invalid in C99 [-Wimplicit-function-declaration]
:info:build             if (strnlen(slideName, 32) == 32)
:info:build                 ^
[...]
:info:build /opt/local/bin/clang-mp-3.9 -o sldtoppm sldtoppm.o     -L/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_netpbm/netpbm/work/advanced/lib -lnetpbm -L/opt/local/lib -Wl,-headerpad_max_install_names -arch x86_64 -arch i386   -lm  
:info:build Undefined symbols for architecture x86_64:
:info:build   "_strnlen", referenced from:
:info:build       _main in sldtoppm.o
:info:build ld: symbol(s) not found for architecture x86_64
:info:build clang: error: linker command failed with exit code 1 (use -v to see invocation)

Attachments (1)

main.log-netpbm.txt.gz (36.3 KB) - added by rlhamil 7 years ago.

Download all attachments as: .zip

Change History (6)

Changed 7 years ago by rlhamil

Attachment: main.log-netpbm.txt.gz added

comment:1 Changed 7 years ago by mf2k (Frank Schima)

Keywords: snowleopard added; snow leopard removed
Owner: set to ryandesign
Status: newassigned

In the future, please use WikiFormatting and Cc the port maintainers (port info --maintainers netpbm), if any.

comment:2 Changed 7 years ago by mf2k (Frank Schima)

Description: modified (diff)

comment:3 Changed 7 years ago by josephsacco

strnlen is a GNU extension that was not available before OSX10.7. Here is a workaround

https://stackoverflow.com/questions/32468480/strnlen-does-not-exist-in-gcc-4-2-1-on-mac-os-x-10-6-8-how-to-define-it#32468556

-Joseph

comment:4 in reply to:  3 Changed 7 years ago by Schamschula (Marius Schamschula)

Replying to josephsacco:

strnlen is a GNU extension that was not available before OSX10.7. Here is a workaround

https://stackoverflow.com/questions/32468480/strnlen-does-not-exist-in-gcc-4-2-1-on-mac-os-x-10-6-8-how-to-define-it#32468556

-Joseph

The snowleopard_fixes-1.0 PortGroup provides this (and other similarly missing methods)

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

Resolution: fixed
Status: assignedclosed

In f0e129b4ce5b1c39b09064f3d66869be64aaf922/macports-ports:

netpbm: Update to 10.81.02

Closes: #55716

Note: See TracTickets for help on using tickets.