X-Account-Key: account1
X-UIDL: 2d7090fb6c269afa6b28ec50938d68bf
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:                                                                                 
Received: from lists.maptools.org (localhost [127.0.0.1])
	by mail.howardsilvan.com (Postfix) with ESMTPS id D55FAC4215F
	for <faxguy@howardsilvan.com>; Thu, 13 Aug 2015 12:00:34 -0700 (PDT)
Received: from lists.maptools.org ([94.23.4.142] helo=lists.maptools.org)
	by fangorn.howardsilvan.com with SMTP (2.3.3); 13 Aug 2015 12:00:33 -0800
Received: from [10.1.0.241] (localhost.localdomain [127.0.0.1])
	by lists.maptools.org (Postfix) with ESMTP id D22C835C027;
	Thu, 13 Aug 2015 13:58:42 -0500 (EST)
Received: from b.painless.aa.net.uk (b.painless.aa.net.uk [81.187.30.52])
	by lists.maptools.org (Postfix) with ESMTPS id 7B1C335C024
	for <tiff@lists.maptools.org>; Thu, 13 Aug 2015 13:58:30 -0500 (EST)
Received: from	d.1.8.9.4.c.9.3.c.6.9.b.2.0.1.c.d.b.d.d.0.6.8.0.0.b.8.0.1.0.0.2.ip6.arpa	([2001:8b0:860:ddbd:c102:b96c:39c4:981d])
	by b.painless.aa.net.uk
	with esmtpsa (TLSv1:AES128-SHA:128)	(Exim 4.77) (envelope-from <rleigh@codelibre.net>)
	id 1ZPxiC-0007H8-MX	for tiff@lists.maptools.org;
	Thu, 13 Aug 2015 19:58:48 +0100
To: tiff@lists.maptools.org
From: Roger Leigh <rleigh@codelibre.net>
Message-ID: <55CCE8E5.7060405@codelibre.net>
Date: Thu, 13 Aug 2015 18:58:45 +0000
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:38.0) Gecko/20100101
	Thunderbird/38.1.0
MIME-Version: 1.0
Subject: [Tiff] [patch] Additional CMake fixes (2)
X-BeenThere: tiff@lists.maptools.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: TIFF and libtiff discussion <tiff.lists.maptools.org>
List-Unsubscribe: <http://lists.maptools.org/mailman/listinfo/tiff>,
	<mailto:tiff-request@lists.maptools.org?subject=unsubscribe>
List-Archive: <http://lists.maptools.org/mailman/private/tiff>
List-Post: <mailto:tiff@lists.maptools.org>
List-Help: <mailto:tiff-request@lists.maptools.org?subject=help>
List-Subscribe: <http://lists.maptools.org/mailman/listinfo/tiff>,
	<mailto:tiff-request@lists.maptools.org?subject=subscribe>
Sender: tiff-bounces@lists.maptools.org
Errors-To: tiff-bounces@lists.maptools.org
X-Assp-ID: fangorn.howardsilvan.com m1-92434-10769
X-Assp-Session: 7F06B6D5E0E8 (mail 1)
X-Assp-Detected-RIP: 2001:8b0:860:ddbd:c102:b96c:39c4:981d, 81.187.30.52
X-Assp-Source-IP: 2001:8b0:860:ddbd:c102:b96c:39c4:981d
X-Assp-Envelope-From: tiff-bounces@lists.maptools.org
X-Assp-Intended-For: faxguy@howardsilvan.com
X-Assp-Version: 2.3.3(14029) on fangorn.howardsilvan.com
X-Assp-Server-TLS: yes
X-Assp-Delay: not delayed (whitelisted); 13 Aug 2015 12:00:34 -0800
X-Assp-Whitelisted: Yes (whitelistdb)
Return-Path: tiff-bounces@lists.maptools.org
Content-Type: multipart/mixed; boundary=------------040504070300060107080301

This is a multi-part message in MIME format.
--------------040504070300060107080301
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit

Hi,

I found that there's a copy-paste error in libtiff/CMakeLists.txt.  The 
libtiffxx logic was actually applying properties to the libtiff target, 
which includes its linker map file and this meant that the libtiff 
symbols were not versioned correctly and the libtiffxx symbol versioning 
was absent entirely.

The attached patch sets the properties on the targets correctly, and so 
the symbol versioning should match the autotools logic now.

I have been using the cmake build logic against 4.0.4 for a few months 
now on Linux, MacOS X, FreeBSD and Windows with several Visual Studio 
versions, and it seems to be working well.  On Windows, I now have daily 
integration testing against VS 2012 and 2013, with 2010/2015 to come.

We have a reasonably large set of build slaves in the 
ci.openmicroscopy.org Jenkins CI setup; I could likely set up a libtiff 
build/test job to build the current CVS against all the Visual Studio 
versions if that would be of any benefit to you.  Likewise for 
Linux/MacOSX/BSD, though I suspect these already have much better test 
coverage!  If you wanted to drop the set of project files for each 
Visual Studio version in favour of CMake, this would give you test 
coverage of the complete set.

I've also (this week) submitted some improvements to the FindTIFF CMake 
module so it can detect Debug and Release versions of the library 
properly (previously was Release only, so it's now possible to link with 
a Debug libtiff for your own debug builds when using CMake).


Regards,
Roger

--------------040504070300060107080301
Content-Type: text/x-patch;
 name="tiff-symbol-map.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="tiff-symbol-map.patch"

diff -urN tiff-4.0.4/libtiff/CMakeLists.txt tiff-4.0.4-fixed/libtiff/CMakeLists.txt
--- tiff-4.0.4/libtiff/CMakeLists.txt	2015-06-25 09:54:08.537710322 -0700
+++ tiff-4.0.4-fixed/libtiff/CMakeLists.txt	2015-08-13 11:45:08.946509390 -0700
@@ -149,16 +149,16 @@
 if(cxx)
   add_library(tiffxx SHARED ${tiffxx_SOURCES} ${tiffxx_HEADERS})
   target_link_libraries(tiffxx tiff)
-  set_target_properties(tiff PROPERTIES SOVERSION ${SO_COMPATVERSION})
+  set_target_properties(tiffxx PROPERTIES SOVERSION ${SO_COMPATVERSION})
   if(NOT CYGWIN)
     # This property causes shared libraries on Linux to have the full version
     # encoded into their final filename.  We disable this on Cygwin because
     # it causes cygz-${TIFF_FULL_VERSION}.dll to be created when cygz.dll
     # seems to be the default.
-    set_target_properties(tiff PROPERTIES VERSION ${SO_VERSION})
+    set_target_properties(tiffxx PROPERTIES VERSION ${SO_VERSION})
   endif()
   if(HAVE_LD_VERSION_SCRIPT)
-    set_target_properties(tiff PROPERTIES LINK_FLAGS
+    set_target_properties(tiffxx PROPERTIES LINK_FLAGS
                           "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/libtiffxx.map")
   endif()
 

--------------040504070300060107080301
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Tiff mailing list: Tiff@lists.maptools.org
http://lists.maptools.org/mailman/listinfo/tiff
http://www.remotesensing.org/libtiff/
--------------040504070300060107080301--


