On Monday 18 July 2005 15:53, Gerald Pfeifer wrote: > revision 1.3 > date: 2005/07/15 10:09:43; author: julliard; state: Exp; lines: +1 -3 > Hans Leidekker <[EMAIL PROTECTED]> > Link directly to liblcms. > Fix typo in test. > > This is on FreeBSD 4.10, but I expect it may be more related to the > system still running XFree86 4.3? > > Is some configure check missing somewhere?
You have the lcms headers but somehow linking against lcms fails on your system. Can you find out why? Jacek had traced this problem to a 64-bit version of lcms on his system. Patch below should fix your compile problems but you should realize that afterwards you will not have a functional mscms dll unless you also fix the linking problem. -Hans Changelog Make lcms support depend on headers _and_ libraries, not just the headers.
Index: dlls/mscms/handle.c =================================================================== RCS file: /home/wine/wine/dlls/mscms/handle.c,v retrieving revision 1.5 diff -u -p -r1.5 handle.c --- dlls/mscms/handle.c 21 Feb 2005 18:38:15 -0000 1.5 +++ dlls/mscms/handle.c 18 Jul 2005 14:29:54 -0000 @@ -29,7 +29,7 @@ #include "mscms_priv.h" -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS static CRITICAL_SECTION MSCMS_handle_cs; static CRITICAL_SECTION_DEBUG MSCMS_handle_cs_debug = @@ -284,4 +284,4 @@ void MSCMS_destroy_htransform_handle( HT } } -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ Index: dlls/mscms/icc.c =================================================================== RCS file: /home/wine/wine/dlls/mscms/icc.c,v retrieving revision 1.4 diff -u -p -r1.4 icc.c --- dlls/mscms/icc.c 15 Jul 2005 10:09:43 -0000 1.4 +++ dlls/mscms/icc.c 18 Jul 2005 14:29:54 -0000 @@ -36,7 +36,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mscms); -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS static inline void MSCMS_adjust_endianess32( ULONG *ptr ) { @@ -107,4 +107,4 @@ DWORD MSCMS_get_profile_size( icProfile return size; } -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ Index: dlls/mscms/mscms_priv.h =================================================================== RCS file: /home/wine/wine/dlls/mscms/mscms_priv.h,v retrieving revision 1.7 diff -u -p -r1.7 mscms_priv.h --- dlls/mscms/mscms_priv.h 21 Feb 2005 18:38:15 -0000 1.7 +++ dlls/mscms/mscms_priv.h 18 Jul 2005 14:29:54 -0000 @@ -18,11 +18,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifdef HAVE_LCMS_LCMS_H -#define HAVE_LCMS_H 1 -#endif - -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS /* These basic Windows types are defined in lcms.h when compiling on * a non-Windows platform (why?), so they would normally not conflict @@ -92,4 +88,4 @@ extern void MSCMS_get_profile_header( ic extern void MSCMS_set_profile_header( icProfile *iccprofile, PROFILEHEADER *header ); extern DWORD MSCMS_get_profile_size( icProfile *iccprofile ); -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ Index: dlls/mscms/profile.c =================================================================== RCS file: /home/wine/wine/dlls/mscms/profile.c,v retrieving revision 1.18 diff -u -p -r1.18 profile.c --- dlls/mscms/profile.c 15 Jul 2005 10:09:43 -0000 1.18 +++ dlls/mscms/profile.c 18 Jul 2005 14:29:54 -0000 @@ -148,7 +148,7 @@ BOOL WINAPI GetColorProfileElement( HPRO PVOID buffer, PBOOL ref ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); DWORD i, count; icTag tag; @@ -177,7 +177,7 @@ BOOL WINAPI GetColorProfileElement( HPRO } } -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -202,7 +202,7 @@ BOOL WINAPI GetColorProfileElement( HPRO BOOL WINAPI GetColorProfileElementTag( HPROFILE profile, DWORD index, PTAGTYPE type ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); DWORD count; icTag tag; @@ -219,7 +219,7 @@ BOOL WINAPI GetColorProfileElementTag( H ret = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -244,7 +244,7 @@ BOOL WINAPI GetColorProfileElementTag( H BOOL WINAPI GetColorProfileFromHandle( HPROFILE profile, PBYTE buffer, PDWORD size ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); PROFILEHEADER header; @@ -265,7 +265,7 @@ BOOL WINAPI GetColorProfileFromHandle( H *size = header.phSize; ret = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -288,7 +288,7 @@ BOOL WINAPI GetColorProfileFromHandle( H BOOL WINAPI GetColorProfileHeader( HPROFILE profile, PPROFILEHEADER header ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); TRACE( "( %p, %p )\n", profile, header ); @@ -298,7 +298,7 @@ BOOL WINAPI GetColorProfileHeader( HPROF MSCMS_get_profile_header( iccprofile, header ); return TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -319,7 +319,7 @@ BOOL WINAPI GetColorProfileHeader( HPROF BOOL WINAPI GetCountColorProfileElements( HPROFILE profile, PDWORD count ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); TRACE( "( %p, %p )\n", profile, count ); @@ -328,7 +328,7 @@ BOOL WINAPI GetCountColorProfileElements *count = MSCMS_get_tag_count( iccprofile ); ret = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -508,7 +508,7 @@ BOOL WINAPI InstallColorProfileW( PCWSTR BOOL WINAPI IsColorProfileTagPresent( HPROFILE profile, TAGTYPE type, PBOOL present ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); DWORD i, count; icTag tag; @@ -530,7 +530,7 @@ BOOL WINAPI IsColorProfileTagPresent( HP } } -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -551,7 +551,7 @@ BOOL WINAPI IsColorProfileTagPresent( HP BOOL WINAPI IsColorProfileValid( HPROFILE profile, PBOOL valid ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); TRACE( "( %p, %p )\n", profile, valid ); @@ -559,7 +559,7 @@ BOOL WINAPI IsColorProfileValid( HPROFIL if (!valid) return FALSE; if (iccprofile) return *valid = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -584,7 +584,7 @@ BOOL WINAPI SetColorProfileElement( HPRO PVOID buffer ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); DWORD i, count, access = MSCMS_hprofile2access( profile ); icTag tag; @@ -609,7 +609,7 @@ BOOL WINAPI SetColorProfileElement( HPRO } } -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -629,7 +629,7 @@ BOOL WINAPI SetColorProfileElement( HPRO BOOL WINAPI SetColorProfileHeader( HPROFILE profile, PPROFILEHEADER header ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); DWORD access = MSCMS_hprofile2access( profile ); @@ -641,7 +641,7 @@ BOOL WINAPI SetColorProfileHeader( HPROF MSCMS_set_profile_header( iccprofile, header ); return TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -763,7 +763,7 @@ HPROFILE WINAPI OpenColorProfileA( PPROF */ HPROFILE WINAPI OpenColorProfileW( PPROFILE profile, DWORD access, DWORD sharing, DWORD creation ) { -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS cmsHPROFILE cmsprofile = NULL; icProfile *iccprofile = NULL; HANDLE handle = NULL; @@ -831,7 +831,7 @@ HPROFILE WINAPI OpenColorProfileW( PPROF if (cmsprofile) return MSCMS_create_hprofile_handle( handle, iccprofile, cmsprofile, access ); -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return NULL; } @@ -850,7 +850,7 @@ HPROFILE WINAPI OpenColorProfileW( PPROF BOOL WINAPI CloseColorProfile( HPROFILE profile ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS icProfile *iccprofile = MSCMS_hprofile2iccprofile( profile ); HANDLE file = MSCMS_hprofile2handle( profile ); DWORD access = MSCMS_hprofile2access( profile ); @@ -872,6 +872,6 @@ BOOL WINAPI CloseColorProfile( HPROFILE CloseHandle( MSCMS_hprofile2handle( profile ) ); MSCMS_destroy_hprofile_handle( profile ); -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } Index: dlls/mscms/transform.c =================================================================== RCS file: /home/wine/wine/dlls/mscms/transform.c,v retrieving revision 1.3 diff -u -p -r1.3 transform.c --- dlls/mscms/transform.c 15 Jul 2005 10:09:43 -0000 1.3 +++ dlls/mscms/transform.c 18 Jul 2005 14:29:54 -0000 @@ -57,7 +57,7 @@ HTRANSFORM WINAPI CreateColorTransformW( HPROFILE target, DWORD flags ) { HTRANSFORM ret = NULL; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS cmsHTRANSFORM cmstransform; cmsHPROFILE cmsprofiles[3]; int intent; @@ -84,7 +84,7 @@ HTRANSFORM WINAPI CreateColorTransformW( } ret = MSCMS_create_htransform_handle( cmstransform ); -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -92,7 +92,7 @@ HTRANSFORM WINAPI CreateMultiProfileTran PDWORD intents, DWORD nintents, DWORD flags, DWORD cmm ) { HTRANSFORM ret = NULL; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS cmsHPROFILE *cmsprofiles; cmsHTRANSFORM cmstransform; DWORD i; @@ -115,14 +115,14 @@ HTRANSFORM WINAPI CreateMultiProfileTran HeapFree( GetProcessHeap(), 0, cmsprofiles ); ret = MSCMS_create_htransform_handle( cmstransform ); -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } BOOL WINAPI DeleteColorTransform( HTRANSFORM transform ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS cmsHTRANSFORM cmstransform; TRACE( "( %p )\n", transform ); @@ -133,7 +133,7 @@ BOOL WINAPI DeleteColorTransform( HTRANS MSCMS_destroy_htransform_handle( transform ); ret = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; } @@ -142,7 +142,7 @@ BOOL WINAPI TranslateBitmapBits( HTRANSF DWORD outputstride, PBMCALLBACKFN callback, ULONG data ) { BOOL ret = FALSE; -#ifdef HAVE_LCMS_H +#ifdef HAVE_LCMS cmsHTRANSFORM cmstransform; TRACE( "( %p, %p, 0x%08x, 0x%08lx, 0x%08lx, 0x%08lx, %p, 0x%08x, 0x%08lx, %p, 0x%08lx )\n", @@ -154,6 +154,6 @@ BOOL WINAPI TranslateBitmapBits( HTRANSF cmsDoTransform( cmstransform, srcbits, destbits, width * height ); ret = TRUE; -#endif /* HAVE_LCMS_H */ +#endif /* HAVE_LCMS */ return ret; }