Opened 5 years ago

Closed 5 years ago

#48015 closed defect (fixed)

tmux-devel @20150604-83a7017_0: missing build dependency on pkgconfig

Reported by: larryv (Lawrence Velázquez) Owned by: tessus (Helmut K. C. Tessarek)
Priority: Normal Milestone:
Component: ports Version: 2.3.3
Keywords: haspatch Cc:
Port: tmux-devel

Description

The configure phase fails if pkgconfig is not installed or visible. This affects our Buildbot buildslaves, and you can observe it for yourself with trace mode:

% sudo port -dt configure tmux-devel
[...]
DEBUG: Executing command line:  cd "/opt/local/var/macports/build/_Users_larryv_Projects_MacPorts_git-svn_trunk_dports_sysutils_tmux/tmux-devel/work/tmux-83a70172a4a12ee9fa069b381172ddbf75c92ad1" && ./autogen.sh 
configure.ac:17: installing 'etc/compile'
configure.ac:9: installing 'etc/config.guess'
configure.ac:9: installing 'etc/config.sub'
configure.ac:7: installing 'etc/install-sh'
configure.ac:7: installing 'etc/missing'
Makefile.am: installing 'etc/depcomp'
configure.ac:112: error: possibly undefined macro: AC_SEARCH_LIBS
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
autoreconf: /opt/local/bin/autoconf failed with exit status: 1
autoreconf failed
Command failed:  cd "/opt/local/var/macports/build/_Users_larryv_Projects_MacPorts_git-svn_trunk_dports_sysutils_tmux/tmux-devel/work/tmux-83a70172a4a12ee9fa069b381172ddbf75c92ad1" && ./autogen.sh 
Exit code: 1

The error message is misleading; the problem is actually at line 115, where configure.ac tries to use PKG_CHECK_MODULES, which is defined in pkgconfig’s pkg.m4 file.

I’ve attached two patches. One makes the build use autogen.sh, as upstream recommends. It also patches autogen.sh to invoke Autotools verbosely, to aid debugging. The other actually adds the dependency on pkgconfig.

Attachments (2)

0001-tmux-devel-Use-autogen.sh.patch (1.9 KB) - added by larryv (Lawrence Velázquez) 5 years ago.
Use autogen.sh
0002-tmux-devel-Require-pkgconfig-for-configure.patch (864 bytes) - added by larryv (Lawrence Velázquez) 5 years ago.
depend on pkgconfig

Download all attachments as: .zip

Change History (6)

Changed 5 years ago by larryv (Lawrence Velázquez)

Use autogen.sh

Changed 5 years ago by larryv (Lawrence Velázquez)

depend on pkgconfig

comment:1 Changed 5 years ago by tessus (Helmut K. C. Tessarek)

Hi Larry,

Thanks for the patches. Look good to me. I missed this since I do have pkgconfig installed. Also, I would not have thought it were needed in the first place.

Do we really need the verbose output? No more debugging needed anyway at the moment. It might help in the future, although I don't think that this should be done in userland.

comment:2 in reply to:  1 Changed 5 years ago by larryv (Lawrence Velázquez)

Replying to tessarek@…:

Do we really need the verbose output?

Not really, if you don’t want it. Admittedly, aclocal --verbose is incredibly talkative.

comment:3 Changed 5 years ago by tessus (Helmut K. C. Tessarek)

I love debugging output, but I'd rather use it locally when needed.

comment:4 in reply to:  3 Changed 5 years ago by larryv (Lawrence Velázquez)

Resolution: fixed
Status: newclosed

We prefer verbose output in general because it makes user-submitted logs more useful. But Autotools are generally pretty well-behaved (at least, when we use them), so it’s less necessary there.

Anyway, r137408 and r137409.

Note: See TracTickets for help on using tickets.