Opened 13 years ago

Closed 12 years ago

#32415 closed defect (wontfix)

flex configure fails when an existing broken flex is installed

Reported by: mparchet@… Owned by: mww@…
Priority: Normal Milestone:
Component: ports Version: 2.0.3
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port: flex

Description

Hi

I wold like to install wine to run windows application on mac os lion.

When I try to install it, I get this message

Error: Target org.macports.configure returned: configure failure: shell command failed (see log for details)
Log for flex is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_flex/flex/main.log
Error: Unable to upgrade port: 1
Error: Unable to execute port: upgrade flex failed
To report a bug, see <http://guide.macports.org/#project.tickets>

flex main log

version:1
:msg:main --->  Computing dependencies for flex:info:main .:debug:main Searching for dependency: gettext
:debug:main Found Dependency: receipt exists for gettext
:msg:main
:debug:main Executing org.macports.main (flex)
:debug:main changing euid/egid - current euid: 0 - current egid: 0
:debug:main egid changed to: 501
:debug:main euid changed to: 503
:debug:main Skipping completed org.macports.archivefetch (flex)
:debug:main Privilege de-escalation not attempted as not running as root.
:debug:main Skipping completed org.macports.fetch (flex)
:debug:main Privilege de-escalation not attempted as not running as root.
:debug:main Skipping completed org.macports.checksum (flex)
:debug:main Privilege de-escalation not attempted as not running as root.
:debug:main Skipping completed org.macports.extract (flex)
:debug:main Privilege de-escalation not attempted as not running as root.
:debug:main Skipping completed org.macports.patch (flex)
:debug:main Privilege de-escalation not attempted as not running as root.
:debug:configure configure phase started at Mon Dec  5 20:56:53 CET 2011
:notice:configure --->  Configuring flex
:debug:configure Using compiler 'Mac OS X llvm-gcc 4.2'
:debug:configure Executing org.macports.configure (flex)
<ync.macports.org_release_ports_devel_flex/flex/main.log" [readonly] 73L, 6021C

Tanks for your help

Best regards

Battant

Attachments (2)

main log flex.rtf (11.3 KB) - added by mparchet@… 13 years ago.
main log flex contenent
config.log (16.9 KB) - added by mparchet@… 13 years ago.

Download all attachments as: .zip

Change History (8)

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

Cc: ryandesign@… rmstonecipher@… added
Keywords: wine removed
Owner: changed from macports-tickets@… to mww@…
Port: flex added; wine removed
Summary: can't install wine on mac os 10.7.2flex configure fails

Please clean flex and try again and if it fails again attach its entire main.log.

sudo port clean flex
sudo port install flex

Changed 13 years ago by mparchet@…

Attachment: main log flex.rtf added

main log flex contenent

comment:2 Changed 13 years ago by mparchet@…

Hi,

I'm sorry it's don't work so I attatch the main log flex file get with the cat command.

Best regards

Battant

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

Cc: rmstonecipher@… removed

The interesting error from the log is:

checking lex output file root... configure: error: cannot find output from flex; giving up

Could you also attach the config.log file? It's in the directory printed by the command port work flex

Changed 13 years ago by mparchet@…

Attachment: config.log added

comment:4 Changed 13 years ago by mparchet@…

Hi,

Here's the flex config.log file (see attachment).

Best regards

Battant

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

Summary: flex configure failsflex configure fails when an existing broken flex is installed

Thanks. That config.log doesn't seem to have been created by a MacPorts-initiated installation attempt. I see on line 7 that it was created by just running "./configure"; MacPorts would have run "./configure --prefix=/opt/local --infodir=/opt/local/share/info --mandir=/opt/local/share/man". Perhaps after the MacPorts build failed, you tried running ./configure again manually?

Further down, on line 39, it shows the parts of your PATH. Since this config.log was not made in the context of MacPorts, it shows your shell environment's PATH, not the PATH MacPorts would set. It shows you have the MacPorts paths /opt/local/bin and /opt/local/sbin in your PATH four times each, which is not a problem but is redundant. It also shows you have /sw/bin and /sw/sbin in your PATH, which is a problem if those directories contain anything. Those directories are part of Fink (another package manager) and it's not supported to have more than one package manager installed at a time; doing this can lead to conflicts and unexpected behavior. Please decide whether you would like to use Fink or MacPorts (or Homebrew, even), and uninstall the other(s).

It also shows that your PATH contains /usr/local/bin. This is part of the default PATH on OS X, and it's not a problem if there's nothing in there. But /usr/local could contain software you installed manually, or using Homebrew; either would again be a problem for MacPorts and a potential source of conflicts and problems. Ports built using MacPorts might look in /usr/local for headers or libraries and find them and use them. And this is exactly what happened in your case, according to the log. On line 334 it says:

configure:4877: checking lex output file root
configure:4888: flex conftest.l
dyld: Library not loaded: /usr/local/lib/libintl.3.dylib
  Referenced from: /opt/local/bin/flex
  Reason: image not found
./configure: line 4889:  1002 Trace/BPT trap: 5       flex conftest.l

This shows that you already have flex installed with MacPorts, and that at the time it was installed, it found a copy of the gettext internationalization library, libintl, in /usr/local/lib, and used it instead of the MacPorts version it was supposed to use. Since then, perhaps at our direction, you removed that libintl from /usr/local/lib, so now MacPorts flex can't find it and so it can't run.

The solution is to deactivate this broken flex, then clean the flex port and try to build it again.

sudo port -f deactivate flex
sudo port clean flex
sudo port install flex

It is possible you have other programs or libraries installed by MacPorts that are also inadvertently linked with libraries in /usr/local/lib (or /sw/lib). You could use otool -L to examine all of your programs and libraries, and if you find any, ensure those non-MacPorts libraries are gone, then rebuild the affected port(s). For example to rebuild port foo you could:

sudo port -n upgrade --force foo

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

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