Opened 4 years ago

Closed 4 years ago

#61889 closed defect (fixed)

gnome-vfs: error: implicit declaration of function 'g_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]

Reported by: vrurg (Vadim Belman) Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: xcode12 bigsur catalina Cc:
Port: gnome-vfs

Description

Build fails with "implicit declaration of function 'g_printf'" error.

Attachments (3)

main.log (884.3 KB) - added by vrurg (Vadim Belman) 4 years ago.
patch-test-async-directory.diff (335 bytes) - added by dsteck 4 years ago.
patch of test-async-directory.c
Portfile (2.8 KB) - added by dsteck 4 years ago.
new Portfile

Download all attachments as: .zip

Change History (11)

Changed 4 years ago by vrurg (Vadim Belman)

Attachment: main.log added

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

Keywords: x86_64 removed

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

Summary: gnome-vfs build failsgnome-vfs: error: implicit declaration of function 'g_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]

Error is:

:info:build /usr/bin/clang -DHAVE_CONFIG_H -I. -I.. -I.. -I.. -I../libgnomevfs -DORBIT2=1 -D_REENTRANT -I/opt/local/include/gconf/2 -I/opt/local/include/orbit-2.0 -I/opt/local/include/glib-2.0 -I/opt/local/lib/glib-2.0/include  -DMODULES_PATH=\"/opt/local/lib/vfs/modules\"  -I/opt/local/include -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.1.sdk  -pipe -Os -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.1.sdk -arch x86_64 -MT test-mime-info-cache.o -MD -MP -MF .deps/test-mime-info-cache.Tpo -c -o test-mime-info-cache.o test-mime-info-cache.c
:info:build test-async-directory.c:236:2: error: implicit declaration of function 'g_printf' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
:info:build         g_printf("Initializing gnome-libs...");
:info:build         ^
:info:build test-async-directory.c:236:2: note: did you mean 'g_print'?
:info:build /opt/local/include/glib-2.0/glib/gmessages.h:465:17: note: 'g_print' declared here
:info:build void            g_print                 (const gchar    *format,
:info:build                 ^
:info:build 1 error generated.

comment:3 Changed 4 years ago by mf2k (Frank Schima)

Keywords: xcode12 added; bigsur removed

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

Keywords: bigsur catalina added

Problem does affect Catalina and Big Sur because they respectively support or require Xcode 12, so we should use the OS version specific keywords so users searching for OS version specific problems by keyword can find this problem.

Changed 4 years ago by dsteck

patch of test-async-directory.c

Changed 4 years ago by dsteck

Attachment: Portfile added

new Portfile

comment:5 Changed 4 years ago by dsteck

I've attached a patch and a Portfile that makes this port compile. The fix is the same one mentioned here: https://mail.gnome.org/archives/commits-list/2013-January/msg00008.html

comment:7 Changed 4 years ago by Daniel Steck <35888116+dsteck@…>

In 77870440134f4a65aad08361e8e1276de4f5a94f/macports-ports (master):

gnome-vfs: new Portfile and patch to fix ticket https://github.com/macports/macports-ports/pull/61889

  • simple change, one include statement added to fix build failure
  • Portfile references new patch
  • new checksums added to Portfile to pass port lint
  • fixes issue in ticket: #61889

comment:8 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

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