Bug 258361 - print/cups-filters fails to build with net/openldap25-client
Summary: print/cups-filters fails to build with net/openldap25-client
Status: Closed Works As Intended
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Tijl Coosemans
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-09-08 05:37 UTC by rkoberman
Modified: 2021-10-28 16:26 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (tijl)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description rkoberman 2021-09-08 05:37:45 UTC
After the update from openldap24-cient to openldp25-client, the build fails with the error:
cc -DHAVE_CONFIG_H -I.   -DLIBICONV_PLUG -isystem /usr/local/include -I/usr/local/include -I/usr/local/include -D_PPD_DEPRECATED="" -D_REENTRANT -D_THREAD_SAFE -pthread -I/usr/local/include  -D_REENTRANT -D_THREAD_SAFE -pthread -I/usr/local/include -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include  -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/include  -I/usr/local/include -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -pthread  -I/usr/local/include/gio-unix-2.0 -I/usr/local/include -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -pthread  -I./cupsfilters/ -O2 -pipe  -DLIBICONV_PLUG -fstack-protector-strong -DLDAP_DEPRECATED -isystem /usr/local/include -fno-strict-aliasing  -Wall -std=gnu11 -D_GNU_SOURCE -MT utils/cups_browsed-cups-browsed.o -MD -MP -MF utils/.deps/cups_browsed-cups-browsed.Tpo -c -o utils/cups_browsed-cups-browsed.o `test -f 'utils/cups-browsed.c' || echo './'`utils/cups-browsed.c
utils/cups-browsed.c:94:14: error: static declaration of 'ldap_connect' follows non-static declaration
static LDAP *ldap_connect(void);
             ^
/usr/local/include/ldap.h:1555:1: note: previous declaration is here
ldap_connect( LDAP *ld );
^
utils/cups-browsed.c:4356:1: error: static declaration of 'ldap_connect' follows non-static declaration
ldap_connect(void)
^
/usr/local/include/ldap.h:1555:1: note: previous declaration is here
ldap_connect( LDAP *ld );
^
utils/cups-browsed.c:4605:39: error: too few arguments to function call, single argument 'ld' was not specified
  TempBrowseLDAPHandle = ldap_connect();
                         ~~~~~~~~~~~~ ^
/usr/local/include/ldap.h:1555:1: note: 'ldap_connect' declared here
ldap_connect( LDAP *ld );
^
utils/cups-browsed.c:5608:25: warning: 'ppdOpenFile' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
      } else if ((ppd = ppdOpenFile(ppdname)) == NULL) {
                        ^
/usr/local/include/cups/ppd.h:389:54: note: 'ppdOpenFile' has been explicitly marked deprecated here
extern ppd_file_t       *ppdOpenFile(const char *filename) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                           ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:5615:2: warning: 'ppdMarkDefaults' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        ppdMarkDefaults(ppd);
        ^
/usr/local/include/cups/ppd.h:384:47: note: 'ppdMarkDefaults' has been explicitly marked deprecated here
extern void             ppdMarkDefaults(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                         ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:5616:17: warning: 'ppdFirstOption' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        for (ppd_opt = ppdFirstOption(ppd); ppd_opt;
                       ^
/usr/local/include/cups/ppd.h:431:54: note: 'ppdFirstOption' has been explicitly marked deprecated here
extern ppd_option_t     *ppdFirstOption(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                         ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:5617:17: warning: 'ppdNextOption' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
             ppd_opt = ppdNextOption(ppd))
                       ^
/usr/local/include/cups/ppd.h:433:53: note: 'ppdNextOption' has been explicitly marked deprecated here
extern ppd_option_t     *ppdNextOption(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                        ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:5625:2: warning: 'ppdClose' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        ppdClose(ppd);
        ^
/usr/local/include/cups/ppd.h:364:40: note: 'ppdClose' has been explicitly marked deprecated here
extern void             ppdClose(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                  ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8639:13: warning: 'ppdOpenFile' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        if ((ppd = ppdOpenFile(loadedppd)) == NULL) {
                   ^
/usr/local/include/cups/ppd.h:389:54: note: 'ppdOpenFile' has been explicitly marked deprecated here
extern ppd_file_t       *ppdOpenFile(const char *filename) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                           ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8641:26: warning: 'ppdLastError' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
          ppd_status_t status = ppdLastError(&linenum);
                                ^
/usr/local/include/cups/ppd.h:403:45: note: 'ppdLastError' has been explicitly marked deprecated here
extern ppd_status_t     ppdLastError(int *line) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8643:21: warning: 'ppdErrorString' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
                       loadedppd, ppdErrorString(status), linenum);
                                  ^
/usr/local/include/cups/ppd.h:398:56: note: 'ppdErrorString' has been explicitly marked deprecated here
extern const char       *ppdErrorString(ppd_status_t status) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                             ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8650:2: warning: 'ppdMarkDefaults' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        ppdMarkDefaults(ppd);
        ^
/usr/local/include/cups/ppd.h:384:47: note: 'ppdMarkDefaults' has been explicitly marked deprecated here
extern void             ppdMarkDefaults(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                         ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8651:2: warning: 'cupsMarkOptions' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        cupsMarkOptions(ppd, p->num_options, p->options);
        ^
/usr/local/include/cups/ppd.h:362:87: note: 'cupsMarkOptions' has been explicitly marked deprecated here
extern int              cupsMarkOptions(ppd_file_t *ppd, int num_options, cups_option_t *options) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                                                                  ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8657:4: warning: 'ppdClose' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
          ppdClose(ppd);
          ^
/usr/local/include/cups/ppd.h:364:40: note: 'ppdClose' has been explicitly marked deprecated here
extern void             ppdClose(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                  ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8668:4: warning: 'ppdClose' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
          ppdClose(ppd);
          ^
/usr/local/include/cups/ppd.h:364:40: note: 'ppdClose' has been explicitly marked deprecated here
extern void             ppdClose(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                  ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8693:22: warning: 'ppdFindMarkedChoice' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
              if ((choice = ppdFindMarkedChoice(ppd, "PageSize")) == NULL)
                            ^
/usr/local/include/cups/ppd.h:379:25: note: 'ppdFindMarkedChoice' has been explicitly marked deprecated here
                                             _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                             ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8694:12: warning: 'ppdFindMarkedChoice' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
                choice = ppdFindMarkedChoice(ppd, "PageRegion");
                         ^
/usr/local/include/cups/ppd.h:379:25: note: 'ppdFindMarkedChoice' has been explicitly marked deprecated here
                                             _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                             ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8696:17: warning: 'ppdFindMarkedChoice' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
              choice = ppdFindMarkedChoice(ppd, keyword);
                       ^
/usr/local/include/cups/ppd.h:379:25: note: 'ppdFindMarkedChoice' has been explicitly marked deprecated here
                                             _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                             ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:8774:2: warning: 'ppdClose' is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
        ppdClose(ppd);
        ^
/usr/local/include/cups/ppd.h:364:40: note: 'ppdClose' has been explicitly marked deprecated here
extern void             ppdClose(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
                                                  ^
/usr/local/include/cups/versioning.h:202:59: note: expanded from macro '_CUPS_DEPRECATED_1_6_MSG'
#      define _CUPS_DEPRECATED_1_6_MSG(m) __attribute__ ((deprecated(m))) _CUPS_PUBLIC
                                                          ^
utils/cups-browsed.c:11393:39: error: too few arguments to function call, single argument 'ld' was not specified
      BrowseLDAPHandle = ldap_connect();
                         ~~~~~~~~~~~~ ^
/usr/local/include/ldap.h:1555:1: note: 'ldap_connect' declared here
ldap_connect( LDAP *ld );
^
16 warnings and 4 errors generated.
gmake[4]: *** [Makefile:3595: utils/cups_browsed-cups-browsed.o] Error 1
gmake[4]: Leaving directory '/usr/ports/print/cups-filters/work/cups-filters-1.28.6'
gmake[3]: *** [Makefile:4913: all-recursive] Error 1
gmake[3]: Leaving directory '/usr/ports/print/cups-filters/work/cups-filters-1.28.6'
gmake[2]: *** [Makefile:2090: all] Error 2
gmake[2]: Leaving directory '/usr/ports/print/cups-filters/work/cups-filters-1.28.6'
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/print/cups-filters
*** Error code 1

Stop.
make: stopped in /usr/ports/print/cups-filters

===>>> make build failed for print/cups-filters
===>>> Aborting update
Comment 1 rkoberman 2021-09-08 21:32:25 UTC
Yesterday pkg version reported net/openldap24-client as orphaned. Indeed, I looked for the port and and could only find openldap25-client, so I installed openldap25-client to replace the orphaned version using '-o' option. All seemed well until I tried updating print/cups-filters. That failed with the ldap issues shown in this ticket.

Today I started looking at the issue more closely and opened the repo to look at log messages only to find net/opnldap24-client was present with no indication that anything had ever happened. The latest log entry was the removal of the $FreeBSD line from the Makefile.

I updated my ports tree (git pull --ff-only) and net/openldap24-client reappeared. I replaced openldap25-client with it, again using -o, and was then able to update print/cups-filters with no issues.

I'm baffled as to how this could have happened. This bug really looks like a requirement that cups-filters/Makefile should be updated to require openldap24 rather than the current version.

I am updating the subject accordingly. I'll generate a patch (on line change) later as I am out of time for now.
Comment 2 rkoberman 2021-09-08 21:32:52 UTC
Yesterday pkg version reported net/openldap24-client as orphaned. Indeed, I looked for the port and and could only find openldap25-client, so I installed openldap25-client to replace the orphaned version using '-o' option. All seemed well until I tried updating print/cups-filters. That failed with the ldap issues shown in this ticket.

Today I started looking at the issue more closely and opened the repo to look at log messages only to find net/opnldap24-client was present with no indication that anything had ever happened. The latest log entry was the removal of the $FreeBSD line from the Makefile.

I updated my ports tree (git pull --ff-only) and net/openldap24-client reappeared. I replaced openldap25-client with it, again using -o, and was then able to update print/cups-filters with no issues.

I'm baffled as to how this could have happened. This bug really looks like a requirement that cups-filters/Makefile should be updated to require openldap24 rather than the current version.

I am updating the subject accordingly. I'll generate a patch (on line change) later as I am out of time for now.