Opened 4 years ago

Closed 3 years ago

#62571 closed defect (duplicate)

libiodbc @3.52.14_2: drvconn.c:501:7: error: use of undeclared identifier 'liburl'

Reported by: kencu (Ken) Owned by: nerdling (Jeremy Lavergne)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: cooljeanius (Eric Gallager), DaveStrickland (Dave Strickland)
Port: libiodbc

Description

Catalina build fails, at least, with a number of errors in drvconn.c:

In file included from drvconn.c:78:
In file included from ./gui.h:75:
../include/iodbc.h:151:11: warning: 'SYS_ODBC_INI' macro redefined [-Wmacro-redefined]
#       define SYS_ODBC_INI "/etc/odbc.ini"
               ^
../include/config.h:152:9: note: previous definition is here
#define SYS_ODBC_INI "/opt/local/etc/odbc.ini"
        ^
In file included from drvconn.c:78:
In file included from ./gui.h:75:
../include/iodbc.h:163:13: warning: 'SYS_ODBCINST_INI' macro redefined [-Wmacro-redefined]
#    define SYS_ODBCINST_INI    "/etc/odbcinst.ini"
            ^
../include/config.h:149:9: note: previous definition is here
#define SYS_ODBCINST_INI "/opt/local/etc/odbcinst.ini"
        ^
drvconn.c:501:7: error: use of undeclared identifier 'liburl'
    { CALL_DRVCONN_DIALBOXW (_szdriver_u8, 'A'); }
      ^
drvconn.c:102:10: note: expanded from macro 'CALL_DRVCONN_DIALBOXW'
         liburl = CFURLCreateFromFileSystemRepresentation (NULL, (UInt8*)_path_u8, strlen(_path_u8), FALSE); \
         ^
drvconn.c:501:7: error: implicit declaration of function 'CFURLCreateFromFileSystemRepresentation' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
drvconn.c:102:19: note: expanded from macro 'CALL_DRVCONN_DIALBOXW'
         liburl = CFURLCreateFromFileSystemRepresentation (NULL, (UInt8*)_path_u8, strlen(_path_u8), FALSE); \

... and more

Attachments (1)

main.log (542.9 KB) - added by kencu (Ken) 4 years ago.

Download all attachments as: .zip

Change History (9)

Changed 4 years ago by kencu (Ken)

Attachment: main.log added

comment:1 Changed 4 years ago by kencu (Ken)

I thought maybe it was the error: implicit declaration of function issue, but that is not all of it. Disabling that error (by using clang-11 to build it) still gives the liburl error:

/opt/local/include/glib-2.0/glib/gversionmacros.h:899:49: note: expanded from macro 'GLIB_DEPRECATED_TYPE_IN_2_62_FOR'
# define GLIB_DEPRECATED_TYPE_IN_2_62_FOR(f)    GLIB_DEPRECATED_TYPE_FOR(f)
                                                ^
/opt/local/include/glib-2.0/glib/gmacros.h:1014:37: note: expanded from macro 'GLIB_DEPRECATED_TYPE_FOR'
#define GLIB_DEPRECATED_TYPE_FOR(f) G_DEPRECATED_FOR(f)
                                    ^
/opt/local/include/glib-2.0/glib/gmacros.h:950:44: note: expanded from macro 'G_DEPRECATED_FOR'
#define G_DEPRECATED_FOR(f) __attribute__((__deprecated__("Use '" #f "' instead")))
                                           ^
drvconn.c:501:7: error: use of undeclared identifier 'liburl'
    { CALL_DRVCONN_DIALBOXW (_szdriver_u8, 'A'); }
      ^

comment:2 Changed 4 years ago by kencu (Ken)

I have tried both with glib2 and glib2-devel, and get similar errors. WIth glib2-devel you get the deprecated warnings in the above box, with glib2 you don't get those deprecated warnings, but it still fails:

/bin/sh ../libtool  --tag=CC   --mode=compile ccache /opt/local/bin/clang-mp-11 -DHAVE_CONFIG_H -I. -I../include  -I../include -I../iodbc -I../iodbcinst -D_REENTRANT -I/opt/local/include/gtk-2.0 -I/opt/local/lib/gtk-2.0/include -I/opt/local/include/pango-1.0 -I/opt/local/include/gio-unix-2.0/ -I/opt/local/include/cairo -I/opt/local/include/atk-1.0 -I/opt/local/include/cairo -I/opt/local/include/pixman-1 -I/opt/local/include/gdk-pixbuf-2.0 -I/opt/local/include/pango-1.0 -I/opt/local/include/harfbuzz -I/opt/local/include/pango-1.0 -I/opt/local/include/fribidi -I/opt/local/include/glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include/ossp -I/opt/local/include/freetype2 -I/opt/local/include/libpng16 -D__GTK__ -I/opt/local/include -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -DWITH_PTHREADS -D_REENTRANT  -pipe -Os -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -arch x86_64 -DODBCVER=0x0350 -DIODBC_BUILD=14210217 -DNO_FRAMEWORKS -MT drvconn.lo -MD -MP -MF .deps/drvconn.Tpo -c -o drvconn.lo drvconn.c
libtool: compile:  ccache /opt/local/bin/clang-mp-11 -DHAVE_CONFIG_H -I. -I../include -I../include -I../iodbc -I../iodbcinst -D_REENTRANT -I/opt/local/include/gtk-2.0 -I/opt/local/lib/gtk-2.0/include -I/opt/local/include/pango-1.0 -I/opt/local/include/gio-unix-2.0/ -I/opt/local/include/cairo -I/opt/local/include/atk-1.0 -I/opt/local/include/cairo -I/opt/local/include/pixman-1 -I/opt/local/include/gdk-pixbuf-2.0 -I/opt/local/include/pango-1.0 -I/opt/local/include/harfbuzz -I/opt/local/include/pango-1.0 -I/opt/local/include/fribidi -I/opt/local/include/glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include/ossp -I/opt/local/include/freetype2 -I/opt/local/include/libpng16 -D__GTK__ -I/opt/local/include -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -DWITH_PTHREADS -D_REENTRANT -pipe -Os -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -arch x86_64 -DODBCVER=0x0350 -DIODBC_BUILD=14210217 -DNO_FRAMEWORKS -MT drvconn.lo -MD -MP -MF .deps/drvconn.Tpo -c drvconn.c  -fno-common -DPIC -o .libs/drvconn.o
In file included from drvconn.c:78:
In file included from ./gui.h:75:
../include/iodbc.h:151:11: warning: 'SYS_ODBC_INI' macro redefined [-Wmacro-redefined]
#       define SYS_ODBC_INI "/etc/odbc.ini"
               ^
../include/config.h:157:9: note: previous definition is here
#define SYS_ODBC_INI "/opt/local/etc/odbc.ini"
        ^
In file included from drvconn.c:78:
In file included from ./gui.h:75:
../include/iodbc.h:163:13: warning: 'SYS_ODBCINST_INI' macro redefined [-Wmacro-redefined]
#    define SYS_ODBCINST_INI    "/etc/odbcinst.ini"
            ^
../include/config.h:154:9: note: previous definition is here
#define SYS_ODBCINST_INI "/opt/local/etc/odbcinst.ini"
        ^
drvconn.c:501:7: error: use of undeclared identifier 'liburl'
    { CALL_DRVCONN_DIALBOXW (_szdriver_u8, 'A'); }
      ^

comment:3 Changed 4 years ago by cooljeanius (Eric Gallager)

Cc: cooljeanius added

comment:4 Changed 4 years ago by DaveStrickland (Dave Strickland)

Cc: DaveStrickland added

comment:5 Changed 4 years ago by DaveStrickland (Dave Strickland)

FYI this port was still broken for me with the same error after a port selfupdate today, but then I tried the following work-around from #51921, and that successfully built and installed for me.

sudo port clean libiodbc
sudo port install -t libiodbc

comment:6 in reply to:  5 Changed 4 years ago by cooljeanius (Eric Gallager)

Replying to DaveStrickland:

FYI this port was still broken for me with the same error after a port selfupdate today, but then I tried the following work-around from #51921, and that successfully built and installed for me.

sudo port clean libiodbc
sudo port install -t libiodbc

Hm, if trace mode makes it succeed, can you try building it again in steps with debug mode on to see what trace mode reports hiding? i.e.:

sudo port -dt configure libiodbc
sudo port -dt build libiodbc
sudo port -dt destroot libiodbc

comment:7 Changed 4 years ago by DaveStrickland (Dave Strickland)

From the configure stage, the following are reported as being hidden:

Warning: The following existing files were hidden from the build system by trace mode:
  /opt/local/bin/ar
  /opt/local/bin/lipo
  /opt/local/bin/nm
  /opt/local/bin/nmedit
  /opt/local/bin/otool
  /opt/local/bin/pkg-config
  /opt/local/bin/ranlib
  /opt/local/bin/strip
  /private/var/select/sh

I'm not included the huge number of files that would have been hidden had they been present.

From the build stage:

Warning: The following existing files were hidden from the build system by trace mode:
  /opt/local/bin/ar
  /opt/local/bin/lipo
  /opt/local/bin/ranlib
  /opt/local/bin/strip
  /private/var/select/sh

From the destroot stage:

Warning: The following existing files were hidden from the build system by trace mode:
  /opt/local/bin/ranlib
  /private/var/select/sh
  /var/root/.CFUserTextEncoding

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

Resolution: duplicate
Status: assignedclosed

Duplicate of #51921.

Note: See TracTickets for help on using tickets.