Opened 13 years ago

Closed 11 years ago

#28262 closed defect (worksforme)

hs-digest: configure fails to find zlib

Reported by: easye Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: Cc: singingwolfboy@…, ryandesign (Ryan Carsten Schmidt), neverpanic (Clemens Lang)
Port: hs-digest

Description (last modified by easye)

Attempting to install pandoc is blocked by a failing configure phase for the hs-digest dependency.

The relevant lines in the log seem to be:

:info:configure Configuring digest-0.0.0.8...
:info:configure Setup: Missing dependency on a foreign library:
:info:configure * Missing header file: zlib.h
:info:configure * Missing C library: z
:info:configure This problem can usually be solved by installing the system package that
:info:configure provides this library (you may need the "-dev" version). If the library is
:info:configure already installed but in a non-standard location then you can use the flags
:info:configure --extra-include-dirs= and --extra-lib-dirs= to specify where it is.

I have both 'zlib' and 'hs-zlib' installed. I forcibly uninstalled and reinstalled these ports, but unfortunately duplicated this failure.

Unfortunately, hs-digest is marked nomaintainer, so I am adding `singingwolfboy' who is the maintainer of 'pandoc' so he knows that fresh installs of pandoc are failing.

Attachments (1)

main.log (2.8 KB) - added by easye 13 years ago.
Output of failing configure for hs-digest

Download all attachments as: .zip

Change History (10)

Changed 13 years ago by easye

Attachment: main.log added

Output of failing configure for hs-digest

comment:1 Changed 13 years ago by easye

Description: modified (diff)

comment:2 Changed 13 years ago by singingwolfboy@…

Building hs-digest worked for me. It looks like the hs-digest port was slightly out of date: I've updated it to version 0.0.0.9 and noted the dependency on zlib. Can you do a selfupdate and try again? If it still doesn't work, I'm going to need more information about your computer's configuration to have any hope of tracking down what's going wrong.

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

Cc: ryandesign@… added
Keywords: hs-digest pandoc removed
Summary: hs-digest fails to configure (blocks pandoc install)hs-digest: configure fails to find zlib

It still doesn't work, for me either (same error as reported above). Snow Leopard x86_64.

Note: your addition of the zlib dependency in r75793 should have been written "port:zlib" to ensure MacPorts zlib is installed; we would not want /usr/lib/libz.dylib to be able to satisfy the dependency.

comment:4 in reply to:  2 Changed 13 years ago by easye

Replying to singingwolfboy@…:

Building hs-digest worked for me. It looks like the hs-digest port was slightly out of date: I've updated it to version 0.0.0.9 and noted the dependency on zlib. Can you do a selfupdate and try again?

Still fails for me with the same error. Oddly enough, I have a second Snow Leopard x86_64 computer where hs-digest installed without a problem, so this seems to have some sort of weird, non-obvious cause.

Please let me know what additional information I can get to you to help diagnose here.

comment:5 Changed 13 years ago by easye

I ran into this problem again when upgrading to Lion.

By explicitly including ${prefix}/bin in the path as follows, the port

Index: Portfile
===================================================================
--- Portfile	(revision 81314)
+++ Portfile	(working copy)
@@ -16,4 +16,6 @@
                     sha1    602813001559a7003ec9a1baa2c2e20f89a4badc \
                     rmd160  b7f3c380835d6ea6abac444075320c03c0bd3f72
 
-depends_lib-append  lib:libz:zlib
+depends_lib-append  port:zlib
+
+configure.env-append   PATH=${prefix}/bin:/usr/bin

For various historical reasons, the user I use for installing doesn't have ${prefix}/bin defined in the system path, but instead adds it in '~/.profile' which is sourced by '~/.bashrc'. In debugging this, I found that if I entered the failing "runhaskell Setup configure …" command interactively it succeeds but under control of the "port" command it doesn't succeed. Then I guessed that somehow the right PATH isn't getting set to come up with the patch.

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

Are you saying you've removed ${prefix}/bin from binpath in macports.conf? Because that's the only reason why modifying PATH in that way in the portfile should have any effect. And modifying binpath in macports.conf is not recommended.

comment:7 in reply to:  6 Changed 13 years ago by easye

Replying to ryandesign@…:

Are you saying you've removed ${prefix}/bin from binpath in macports.conf? Because that's the only reason why modifying PATH in that way in the portfile should have any effect. And modifying binpath in macports.conf is not recommended.

No, I did not modify 'macports.conf'. Yes, I understand that modifying 'binpath' is not recommended, but this is what worked in my case. As this is a bug that only seems to affect a minority of users, I'm more reporting an equally odd success that should be reproducible by modifying the Portfile than suggesting that we patch the hs-digest Portfile in this manner.

comment:8 Changed 12 years ago by jmroot (Joshua Root)

Does the configure script generate a config.log or similar that we could look at?

comment:9 Changed 11 years ago by neverpanic (Clemens Lang)

Cc: cal@… added
Resolution: worksforme
Status: newclosed

I think this ticket is obsolete. I haven't had any issues installing hs-digest after r106868.

Note: See TracTickets for help on using tickets.