Opened 12 years ago

Closed 12 years ago

#36491 closed defect (fixed)

bob opportunistically links with opencv and qt4-mac

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: andre.anjos@…
Priority: Normal Milestone:
Component: ports Version: 2.1.2
Keywords: haspatch maintainer Cc: laurent.el-shafey@…, neverpanic (Clemens Lang)
Port: bob

Description

If you have opencv or qt4-mac installed, and you install bob with the opencv or qt4 variants deselected, bob still build with opencv or qt support enabled:

$ port installed opencv qt4-mac
The following ports are currently installed:
  opencv @2.4.2_1+universal (active)
  qt4-mac @4.8.3_1+quartz+universal (active)
$ sudo port install bob -opencv -qt4
--->  Computing dependencies for bob
--->  Fetching distfiles for bob
--->  Verifying checksum(s) for bob
--->  Extracting bob
--->  Configuring bob
--->  Building bob
--->  Staging bob into destroot
--->  Installing bob @1.1.0_0+python27
--->  Activating bob @1.1.0_0+python27
--->  Cleaning bob
$ port -q contents bob|xargs /usr/bin/otool -L|sort -u|/usr/bin/grep -i -E 'lib.*(cv|qt)'
	/opt/local/Library/Frameworks/QtCore.framework/Versions/4/QtCore (compatibility version 4.8.0, current version 4.8.3)
	/opt/local/Library/Frameworks/QtGui.framework/Versions/4/QtGui (compatibility version 4.8.0, current version 4.8.3)
	/opt/local/lib/libopencv_core.2.4.dylib (compatibility version 2.4.0, current version 2.4.2)
	/opt/local/lib/libopencv_objdetect.2.4.dylib (compatibility version 2.4.0, current version 2.4.2)
$ 

This is because the opencv and qt4 variants do nothing more than add a dependency. They need to do more—such as add a configure argument, set an environment variable, or maybe even apply a patchfile—to ensure that opencv and qt support are only enabled if the corresponding variant is selected.

Attachments (1)

less-opportunistic.diff (858 bytes) - added by andre.dos.anjos@… 12 years ago.
Patch to Portfile to make bob less opportunistic

Download all attachments as: .zip

Change History (5)

Changed 12 years ago by andre.dos.anjos@…

Attachment: less-opportunistic.diff added

Patch to Portfile to make bob less opportunistic

comment:1 Changed 12 years ago by andre.dos.anjos@…

Here is a patch that disables the "variants" for the time being.

The bug has been entered on our own bug tracking system: https://github.com/idiap/bob/issues/88, with a back track to this one.

As soon as we fix it, we may re-introduce variants in MacPorts.

Side question: Is there a reason to disable the parallel builds on this port? Would it be possible to have it re-enabled or would it break something?

comment:2 Changed 12 years ago by neverpanic (Clemens Lang)

Cc: cal@… added
Keywords: haspatch maintainer added

Commited the patch in r98731. It seems use_parallel_build no did sneak in accidentally when the port was discussed and tested in #36130. Do you want me to remove it?

Should I leave this open so you can track this, or should I close this and you'll just open a new bug as soon as you fixed the problem upstream?

comment:3 in reply to:  2 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to cal@…:

It seems use_parallel_build no did sneak in accidentally when the port was discussed and tested in #36130. Do you want me to remove it?

It built fine for me in parallel before, and still now. I removed this line in r98738.

comment:4 Changed 12 years ago by raimue (Rainer Müller)

Resolution: fixed
Status: newclosed

Closing as the original issue was resolved per comment:2; the reason for keeping this ticket open was resolved as well per comment:3.

Note: See TracTickets for help on using tickets.