Opened 12 years ago

Closed 3 years ago

#23675 closed defect (duplicate)

ufraw @0.17 fails to build against gtk2+quartz

Reported by: vincent.lucarelli@… Owned by: dbevans (David B. Evans)
Priority: Normal Milestone:
Component: ports Version: 1.8.2
Keywords: Cc: ryandesign (Ryan Schmidt), cavinsays@…, cooljeanius (Eric Gallager), MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Port: ufraw

Description

While trying to build gimp on Snow Leopard, the ufraw port fails to build with the following error:

/usr/bin/g++-4.2 -DHAVE_CONFIG_H -I.  -I/opt/port/include   -I/opt/port/include -I/opt/port/include/gtk-2.0 -I/opt/port/lib/gtk-2.0/include \
-I/opt/port/include/atk-1.0 -I/opt/port/include/cairo -I/opt/port/include/pango-1.0 -I/opt/port/include/glib-2.0 -I/opt/port/lib/glib-2.0/include \
-I/opt/port/include/pixman-1 -I/opt/port/include/freetype2 -I/opt/port/include/libpng12   \
-I/opt/port/include/glib-2.0 -I/opt/port/lib/glib-2.0/include -I/opt/port/include   \
-I/opt/port/include    -I/opt/port/include/libpng12   -I/opt/port/include   \
-DDCRAW_NOMAIN -DUFRAW_LOCALEDIR=\"/opt/port/share/locale\" -I/opt/port/include  \
-O2 -arch x86_64 -fopenmp -MT uf_gtk.o -MD -MP -MF .deps/uf_gtk.Tpo -c -o uf_gtk.o uf_gtk.cc

uf_gtk.cc: In function 'void uf_get_display_profile(GtkWidget*, guint8**, gint*)':
uf_gtk.cc:297: error: 'CMFlattenProfile' was not declared in this scope
make[2]: *** [uf_gtk.o] Error 1
make[2]: *** Waiting for unfinished jobs....

From the header file CMApplication.h

#if !__LP64__ && !TARGET_OS_WIN32
/* This function is deprecated in Mac OS X 10.5. Use CMCopyProfile instead.*/
CSEXTERN CMError 
CMFlattenProfile(
  CMProfileRef   prof,
  UInt32         flags,
  CMFlattenUPP   proc,
  void *         refCon,
  Boolean *      preferredCMMnotfound)                        AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
#endif // !__LP64__ && !TARGET_OS_WIN32

So I tried to build it as a 32-bit port so LP64 wasn't defined.

 > sudo port -d build ufraw configure.build_arch=i386 

But this fails on the link step because all of ufraw's dependencies were built as 64-bit libraries.

One option is to build everything at 32-bit libraries/applications but is there a way to replace the CMFlattenProfile with CMCopyProfile as the header suggests?

Attachments (2)

ufraw-debug-fail-snow-leopard.txt (22.2 KB) - added by vincent.lucarelli@… 12 years ago.
Debug Output showing ufraw failed build on Snow Leopard +quartz +no_x11
ufrawnovariantsdebug.txt (171.4 KB) - added by cavinsays@… 12 years ago.

Download all attachments as: .zip

Change History (19)

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

Keywords: ufraw Mac OS X 10.6 Snow Leopard CMFlattenProfile removed
Owner: changed from macports-tickets@… to frank.mcpherson@…

Please remember to cc the maintainer.

comment:2 Changed 12 years ago by sylgar@…

Cc: sylgar@… added

Cc Me!

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

Cc: ryandesign@… added

ufraw builds fine for me on Snow Leopard. Please attach complete debug output so we can compare your output with that of a machine where it works.

Changed 12 years ago by vincent.lucarelli@…

Debug Output showing ufraw failed build on Snow Leopard +quartz +no_x11

comment:4 Changed 12 years ago by cavinsays@…

Same thing happens here when building +quartz +no_x11

comment:5 in reply to:  4 Changed 12 years ago by ryandesign (Ryan Schmidt)

Replying to cavinsays@…:

Same thing happens here when building +quartz +no_x11

Ah, ok. I don't use +quartz +no_x11, so I guess the workaround for now is to not use those variants.

Replying to vincent.lucarelli@…:

is there a way to replace the CMFlattenProfile with CMCopyProfile as the header suggests?

That's something you should ask the developer of ufraw.

Changed 12 years ago by cavinsays@…

Attachment: ufrawnovariantsdebug.txt added

comment:6 Changed 12 years ago by cavinsays@…

Same thing happened again except using no variants.

comment:7 Changed 12 years ago by ryandesign (Ryan Schmidt)

The log shows that you have used the +quartz and +no_x11 variants when installing gimp2, cairo and pango-devel. That's probably where the problem is. (ufraw itself doesn't have +quartz or +no_x11 (or any other) variants.)

comment:8 Changed 12 years ago by cavinsays@…

Cc: cavinsays@… added

Cc Me!

comment:9 Changed 11 years ago by dbevans (David B. Evans)

Cc: devans@… added
Summary: ufraw-0.16 Build fails on deprecated CMFlattenProfileufraw-0.17 Build fails on deprecated CMFlattenProfile

Although ufraw doesn't have a +quartz variant, the code itself checks to see if gtk2 is built using Quartz support via GDK_WINDOWING_QUARTZ and enables the offending code if that is the case.

This continues to be the case in the current port version ufraw-0.17.

Until this is resolved by the upstream developer, I have committed a change to port gimp in r71290 that removes the dependency on ufraw if +quartz is set and the build_arch is 64-bit.

comment:10 Changed 11 years ago by jmroot (Joshua Root)

Summary: ufraw-0.17 Build fails on deprecated CMFlattenProfileufraw @0.17 fails to build against gtk2+quartz

comment:11 Changed 10 years ago by jmroot (Joshua Root)

Cc: devans@… removed
Owner: changed from frank.mcpherson@… to devans@…

comment:12 Changed 10 years ago by sylgar@…

Cc: sylgar@… removed

Cc Me!

comment:13 Changed 10 years ago by pb.mosca@…

version 0.18 does also not compile. It fails with the same error.

I managed to make it compile by porting a patch from The Gimp, that replace CMFlattenProfile.

I filed it to the UFRaw sourceforge: https://sourceforge.net/tracker/?func=detail&aid=3541393&group_id=127649&atid=709086

comment:14 Changed 9 years ago by cooljeanius (Eric Gallager)

Cc: egall@… added

Cc Me!

comment:15 Changed 9 years ago by halsteaw@…

Might be time to test for this bug again as the sourceforge link in comment 13 says the change was committed.

If fixed, it would remove from the gimp port:

if +quartz is set, remove ufraw which uses CMFlattenProfile if gtk2 is

# built with Quartz support and is also not available in a 64-bit version ticket #23675

comment:16 Changed 3 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Cc: MarcusCalhoun-Lopez added

comment:17 Changed 3 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Resolution: duplicate
Status: newclosed

This issue seems to have been fixed (see #49584).

Note: See TracTickets for help on using tickets.