You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(33) |
Jun
|
Jul
(30) |
Aug
(2) |
Sep
|
Oct
(30) |
Nov
(136) |
Dec
(59) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(255) |
Feb
(169) |
Mar
(322) |
Apr
(185) |
May
(33) |
Jun
(89) |
Jul
(47) |
Aug
(59) |
Sep
(40) |
Oct
(31) |
Nov
(74) |
Dec
(84) |
2002 |
Jan
(163) |
Feb
(78) |
Mar
(23) |
Apr
(5) |
May
(22) |
Jun
(75) |
Jul
(143) |
Aug
(48) |
Sep
(111) |
Oct
(58) |
Nov
(124) |
Dec
(278) |
2003 |
Jan
(106) |
Feb
(276) |
Mar
(354) |
Apr
(97) |
May
(14) |
Jun
(3) |
Jul
(7) |
Aug
(21) |
Sep
(83) |
Oct
(110) |
Nov
(3) |
Dec
(119) |
2004 |
Jan
(318) |
Feb
(409) |
Mar
(68) |
Apr
(23) |
May
(105) |
Jun
(147) |
Jul
(69) |
Aug
(53) |
Sep
(23) |
Oct
(14) |
Nov
(15) |
Dec
(63) |
2005 |
Jan
(146) |
Feb
(69) |
Mar
(157) |
Apr
(127) |
May
(166) |
Jun
(8) |
Jul
(5) |
Aug
(3) |
Sep
(8) |
Oct
(17) |
Nov
(29) |
Dec
(34) |
2006 |
Jan
(3) |
Feb
(4) |
Mar
(1) |
Apr
(70) |
May
(241) |
Jun
(82) |
Jul
(344) |
Aug
(196) |
Sep
(87) |
Oct
(57) |
Nov
(121) |
Dec
(86) |
2007 |
Jan
(60) |
Feb
(67) |
Mar
(102) |
Apr
(28) |
May
(13) |
Jun
(29) |
Jul
(38) |
Aug
(56) |
Sep
(91) |
Oct
(89) |
Nov
(50) |
Dec
(68) |
2008 |
Jan
(87) |
Feb
(47) |
Mar
(100) |
Apr
(34) |
May
(65) |
Jun
(54) |
Jul
(98) |
Aug
(128) |
Sep
(109) |
Oct
(141) |
Nov
(40) |
Dec
(206) |
2009 |
Jan
(176) |
Feb
(226) |
Mar
(134) |
Apr
(84) |
May
(152) |
Jun
(85) |
Jul
(91) |
Aug
(153) |
Sep
(141) |
Oct
(59) |
Nov
(87) |
Dec
(75) |
2010 |
Jan
(58) |
Feb
(41) |
Mar
(51) |
Apr
(74) |
May
(81) |
Jun
(39) |
Jul
(30) |
Aug
(43) |
Sep
(76) |
Oct
(59) |
Nov
(62) |
Dec
(52) |
2011 |
Jan
(125) |
Feb
(41) |
Mar
(96) |
Apr
(53) |
May
(21) |
Jun
(23) |
Jul
(48) |
Aug
(71) |
Sep
(37) |
Oct
(81) |
Nov
(60) |
Dec
(32) |
2012 |
Jan
(51) |
Feb
(23) |
Mar
|
Apr
(8) |
May
(2) |
Jun
|
Jul
(8) |
Aug
(25) |
Sep
(4) |
Oct
(32) |
Nov
(17) |
Dec
(2) |
2013 |
Jan
(8) |
Feb
(2) |
Mar
(9) |
Apr
(9) |
May
(37) |
Jun
(48) |
Jul
(63) |
Aug
(42) |
Sep
(59) |
Oct
(83) |
Nov
(141) |
Dec
(133) |
2014 |
Jan
(57) |
Feb
(58) |
Mar
(58) |
Apr
(25) |
May
(14) |
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
From: <hez...@us...> - 2013-10-29 00:18:50
|
Revision: 12639 http://sourceforge.net/p/plplot/code/12639 Author: hezekiahcarty Date: 2013-10-29 00:18:45 +0000 (Tue, 29 Oct 2013) Log Message: ----------- Update OCaml example 16, small type fix for OCaml's plshades This version should have no visual difference between the C and OCaml example 16. There is still a postscript output difference due to some color setting and restoration which is performed in the OCaml version. That difference will be addressed in a later commit. Modified Paths: -------------- trunk/bindings/ocaml/plplot_impl.c trunk/examples/ocaml/x16.ml Modified: trunk/bindings/ocaml/plplot_impl.c =================================================================== --- trunk/bindings/ocaml/plplot_impl.c 2013-10-28 22:05:41 UTC (rev 12638) +++ trunk/bindings/ocaml/plplot_impl.c 2013-10-29 00:18:45 UTC (rev 12639) @@ -450,7 +450,7 @@ void ml_plshades( const PLFLT **a, PLINT nx, PLINT ny, PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLFLT *clevel, PLINT nlevel, PLFLT fill_width, - PLINT cont_color, PLINT cont_width, + PLINT cont_color, PLFLT cont_width, PLBOOL rectangular ) { c_plshades( a, nx, ny, Modified: trunk/examples/ocaml/x16.ml =================================================================== --- trunk/examples/ocaml/x16.ml 2013-10-28 22:05:41 UTC (rev 12638) +++ trunk/examples/ocaml/x16.ml 2013-10-29 00:18:45 UTC (rev 12639) @@ -9,6 +9,33 @@ open Plplot +let colorbar ?color ?contour values = + (* Smaller text *) + plschr 0.0 0.75; + (* Small ticks on the vertical axis *) + plsmaj 0.0 0.5; + plsmin 0.0 0.5; + + let axis = + [ + `frame0; + `frame1; + `vertical_label; + `unconventional_label; + `major_ticks; + ] + in + let shade = Plot.shade_colorbar ~custom:true ~axis values in + let pos = Plot.viewport_pos ~inside:false 0.005 0.0 in + Plot.plot [ + Plot.colorbar ?color ?contour ~orient:(`top (0.0375, 0.875)) ~label:[`bottom "Magnitude"] ~pos shade; + ]; + + (* Reset text and tick sizes *) + plschr 0.0 1.0; + plsmaj 0.0 1.0; + plsmin 0.0 1.0 + let pi = atan 1.0 *. 4.0 (* Fundamental settings. See notes[] for more info. *) @@ -133,6 +160,8 @@ plshades z (-1.0) 1.0 (-1.0) 1.0 shedge fill_width cont_color cont_width true; + colorbar shedge; + plcol0 1; plbox "bcnst" 0.0 0 "bcnstv" 0.0 0; plcol0 2; @@ -153,6 +182,8 @@ plset_pltr (pltr1 xg1 yg1); plshades z (-1.0) 1.0 (-1.0) 1.0 shedge fill_width cont_color cont_width true; + colorbar shedge; + plcol0 1; plbox "bcnst" 0.0 0 "bcnstv" 0.0 0; plcol0 2; @@ -174,6 +205,8 @@ plshades z (-1.0) 1.0 (-1.0) 1.0 shedge fill_width cont_color cont_width false; + colorbar shedge; + plcol0 1; plbox "bcnst" 0.0 0 "bcnstv" 0.0 0; plcol0 2; @@ -195,6 +228,8 @@ plshades z (-1.0) 1.0 (-1.) 1.0 shedge fill_width 2 3.0 false; + colorbar ~color:(`index 2) ~contour:(`index 2, 3.0) shedge; + plcol0 1; plbox "bcnst" 0.0 0 "bcnstv" 0.0 0; plcol0 2; @@ -214,6 +249,8 @@ plset_defined zdefined; plshades z (-1.0) 1.0 (-1.0) 1.0 shedge fill_width cont_color cont_width false; + + colorbar shedge; plunset_defined (); plcol0 1; @@ -257,6 +294,8 @@ plshades z (-1.0) 1.0 (-1.0) 1.0 shedge fill_width cont_color cont_width false; + colorbar shedge; + (* Now we can draw the perimeter. (If do before, shade stuff may overlap.) *) let px = Array.make perimeterpts 0.0 in let py = Array.make perimeterpts 0.0 in This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-28 22:05:44
|
Revision: 12638 http://sourceforge.net/p/plplot/code/12638 Author: airwin Date: 2013-10-28 22:05:41 +0000 (Mon, 28 Oct 2013) Log Message: ----------- Warn if Tcl/Tk library locations are different. Add 4.0.0 to the list of possible itk versions. Modified Paths: -------------- trunk/cmake/modules/tcl-related.cmake Modified: trunk/cmake/modules/tcl-related.cmake =================================================================== --- trunk/cmake/modules/tcl-related.cmake 2013-10-26 21:18:55 UTC (rev 12637) +++ trunk/cmake/modules/tcl-related.cmake 2013-10-28 22:05:41 UTC (rev 12638) @@ -85,15 +85,15 @@ OUTPUT_VARIABLE AVAILABLE_ITCL) if(AVAILABLE_ITCL) execute_process( - COMMAND ${TCL_TCLSH} GetITCL_Version.tcl - WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/cmake/modules - OUTPUT_VARIABLE itcl_library_versions) + COMMAND ${TCL_TCLSH} GetITCL_Version.tcl + WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/cmake/modules + OUTPUT_VARIABLE itcl_library_versions) message(STATUS "Looking for itcl.h") find_path(ITCL_INCLUDE_PATH itcl.h ${TCL_INCLUDE_PATH}) if(ITCL_INCLUDE_PATH) message(STATUS "Looking for itcl.h - found") message(STATUS "Looking for itcl library") - get_filename_component(TCL_LIBRARY_PATH ${TCL_LIBRARY} PATH) + get_filename_component(TCL_LIBRARY_PATH ${TCL_LIBRARY} PATH) set(itcl_library_versions 4.0.0 3.4 3.3 3.2 3.1 3.0 2.1 2.0) foreach(version ${itcl_library_versions}) find_library(ITCL_LIBRARY itcl${version} PATHS ${TCL_LIBRARY_PATH} @@ -132,13 +132,21 @@ else(ENABLE_itcl) set(MKTCLINDEX_ARGS "-tcl") endif(ENABLE_itcl) + if(ENABLE_tk AND NOT X11_FOUND) message(STATUS "WARNING: X11 not found, disabling Tk interface code") set(ENABLE_tk OFF CACHE BOOL "Enable Tk interface code" FORCE) endif(ENABLE_tk AND NOT X11_FOUND) if(ENABLE_tk) + get_filename_component(TK_LIBRARY_PATH ${TK_LIBRARY} PATH) + if(NOT ${TK_LIBRARY_PATH} STREQUAL ${TCL_LIBRARY_PATH}) + message(STATUS "TCL_LIBRARY_PATH = ${TCL_LIBRARY_PATH}") + message(STATUS "TK_LIBRARY_PATH = ${TK_LIBRARY_PATH}") + message(STATUS "WARNING: the Tcl and Tk library locations are inconsistent so those libraries are likely not compatible") + endif(NOT ${TK_LIBRARY_PATH} STREQUAL ${TCL_LIBRARY_PATH}) + endif(ENABLE_tk) + if(ENABLE_tk) set(TK_INCLUDE_PATH ${TK_INCLUDE_PATH} ${X11_INCLUDE_DIR}) - set(TK_LIBRARY ${TK_LIBRARY}) message(STATUS "TK_INCLUDE_PATH = ${TK_INCLUDE_PATH}") message(STATUS "TK_LIBRARY = ${TK_LIBRARY}") else(ENABLE_tk) @@ -153,9 +161,9 @@ if(ITK_INCLUDE_PATH) message(STATUS "Looking for itk.h - found") message(STATUS "Looking for itk library") - set(itk_library_versions 3.4 3.3 3.2 3.1 3.0 2.1 2.0) + set(itk_library_versions 4.0.0 3.4 3.3 3.2 3.1 3.0 2.1 2.0) foreach(version ${itk_library_versions}) - find_library(ITK_LIBRARY itk${version} + find_library(ITK_LIBRARY itk${version} PATHS ${TCL_LIBRARY_PATH} PATH_SUFFIXES itk${version}) endforeach(version ${itk_library_versions}) if(ITK_LIBRARY) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 21:18:58
|
Revision: 12637 http://sourceforge.net/p/plplot/code/12637 Author: airwin Date: 2013-10-26 21:18:55 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Fix build issue for Tcl/Tk 8.6 which no longer #defines Tcl_Import_TCL_DECLARED. Instead, we now assume that all Tcl/Tk versions we use declare Tcl_Import (true for at least Tcl/Tk 8.5.x and probably for much earlier Tcl/Tk versions as well) so we no longer declare Tcl_Import ourselves. Modified Paths: -------------- trunk/bindings/tk/tkMain.c Modified: trunk/bindings/tk/tkMain.c =================================================================== --- trunk/bindings/tk/tkMain.c 2013-10-26 20:47:49 UTC (rev 12636) +++ trunk/bindings/tk/tkMain.c 2013-10-26 21:18:55 UTC (rev 12637) @@ -85,7 +85,8 @@ // From tclIntDecls.h -#ifndef Tcl_Import_TCL_DECLARED +//#ifndef Tcl_Import_TCL_DECLARED +#if 0 EXTERN int Tcl_Import _ANSI_ARGS_( ( Tcl_Interp * interp, Tcl_Namespace * nsPtr, char * pattern, int allowOverwrite ) ); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 20:47:51
|
Revision: 12636 http://sourceforge.net/p/plplot/code/12636 Author: airwin Date: 2013-10-26 20:47:49 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Quiet -O1 -Wuninitialized warnings that all proved to be false alarms. Tested by Alan W. Irwin <ai...@us...> using the install target. No uninitialized warnings occurred other than for the remaining such warnings from the swig-generated bindings code for Python, Lua, and Octave (but not for Java which may give a clue for what to do for those other languages). Modified Paths: -------------- trunk/src/plbuf.c trunk/src/pllegend.c trunk/src/plvect.c Modified: trunk/src/plbuf.c =================================================================== --- trunk/src/plbuf.c 2013-10-26 18:59:10 UTC (rev 12635) +++ trunk/src/plbuf.c 2013-10-26 20:47:49 UTC (rev 12636) @@ -771,8 +771,14 @@ static void rdbuf_image( PLStream *pls ) { + // Unnecessarily initialize dev_iy and dev_z to quiet -O1 + // -Wuninitialized warnings which are false alarms. (If something + // goes wrong with the dev_ix malloc below any further use of + // dev_iy and dev_z does not occur. Similarly, if something goes + // wrong with the dev_iy malloc below any further use of dev_z + // does not occur.) short *dev_ix, *dev_iy = NULL; - unsigned short *dev_z, dev_zmin, dev_zmax; + unsigned short *dev_z = NULL, dev_zmin, dev_zmax; PLINT nptsX, nptsY, npts; PLFLT xmin, ymin, dx, dy; Modified: trunk/src/pllegend.c =================================================================== --- trunk/src/pllegend.c 2013-10-26 18:59:10 UTC (rev 12635) +++ trunk/src/pllegend.c 2013-10-26 20:47:49 UTC (rev 12636) @@ -1531,7 +1531,11 @@ // Min and max values // Assumes that the values array is sorted from smallest to largest // OR from largest to smallest. - PLFLT min_value, max_value, max_abs; + // Unnecessarily initialize min_value, max_value, and max_abs + // to quiet -O1 -Wuninitialized warnings that are false alarms. + // (n_axes is guaranteed to be 1 or greater so that the loops that + // define these values must be executed at least once.) + PLFLT min_value = 0., max_value = 0., max_abs = 0.; // Length of cap in orientation direction in normalized subpage // coordinates and mm. PLFLT cap_extent, cap_extent_mm; Modified: trunk/src/plvect.c =================================================================== --- trunk/src/plvect.c 2013-10-26 18:59:10 UTC (rev 12635) +++ trunk/src/plvect.c 2013-10-26 20:47:49 UTC (rev 12636) @@ -68,7 +68,10 @@ plP_plotvect( PLFLT x, PLFLT y, PLFLT u, PLFLT v, PLFLT scale ) { PLFLT uu, vv, px0, py0, dpx, dpy; - PLINT *a_x, *a_y; + // Unnecessarily initialize a_y to quiet a -O1 -Wuninitialized warning + // which is a false alarm. (If something goes wrong with the + // a_x malloc below any further use of a_y does not occur.) + PLINT *a_x, *a_y = NULL; int j; uu = scale * u; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 18:59:13
|
Revision: 12635 http://sourceforge.net/p/plplot/code/12635 Author: airwin Date: 2013-10-26 18:59:10 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Initial implementation of a build_projects configuration for itk. This is needed because (unlike the case of itcl which is now an integrated part of tcl) itk is not integrated into tk. Tested by: Alan W. Irwin <ai...@us...> on Linux using the build_itk target of build_projects using the -DBUILD_THE_BUILDTOOLS=ON cmake option. There were no build issues for either itk or its dependencies, tk and tcl. Modified Paths: -------------- trunk/cmake/build_projects/CMakeLists.txt Added Paths: ----------- trunk/cmake/build_projects/itk/ trunk/cmake/build_projects/itk/bp.cmake Modified: trunk/cmake/build_projects/CMakeLists.txt =================================================================== --- trunk/cmake/build_projects/CMakeLists.txt 2013-10-26 18:44:58 UTC (rev 12634) +++ trunk/cmake/build_projects/CMakeLists.txt 2013-10-26 18:59:10 UTC (rev 12635) @@ -287,8 +287,11 @@ pkg-config #subversion swig + # itcl is integrated into tcl tcl tk + # itk is not integrated into tk (or tcl). + itk ) else(BUILD_THE_BUILDTOOLS) # List of all configurations. Order doesn't matter because multiple Added: trunk/cmake/build_projects/itk/bp.cmake =================================================================== --- trunk/cmake/build_projects/itk/bp.cmake (rev 0) +++ trunk/cmake/build_projects/itk/bp.cmake 2013-10-26 18:59:10 UTC (rev 12635) @@ -0,0 +1,115 @@ +# itk/bp.cmake +# CMakeLists.txt file to configure the build of itk. + +# Copyright (C) 2013 Alan W. Irwin + +# This file is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License, or (at your option) any later version. + +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this file; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + +# The top-level CMakeLists.txt file that includes this file should +# have run "include(ExternalProject)" and set EP_BASE variable (and +# corresponding directory property) as well as various BP variables +# used below that configure how the External_Project functions +# operate. + +# These build configuration details for itk adapted from +# the fink build +# <http://www.mail-archive.com/fin...@li.../msg113511.html> +# Protect against configuring a build twice in one CMake call +if(itk_configured) + return() +endif(itk_configured) +set(itk_configured ON) + +# List of dependencies (most of which are build tools) which should be +# ignored. +set(BP_ignored_dependencies_LIST ${extra_ignored_dependencies_list}) + +set(itk_dependencies_LIST tk tcl) +# Remove dependencies that should be ignored. +if(itk_dependencies_LIST) + list(REMOVE_ITEM itk_dependencies_LIST ${BP_ignored_dependencies_LIST}) +endif(itk_dependencies_LIST) + +set(itk_dependencies_targets) +foreach(build_configuration ${itk_dependencies_LIST}) + if(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + include(${build_configuration}/bp.cmake) + list(APPEND itk_dependencies_targets build_${build_configuration}) + else(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + message(STATUS "Warning: A build_configuration for ${build_configuration} does not exist so it is assumed this dependency of itk has been installed another way.") + endif(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) +endforeach(build_configuration ${itk_dependences_LIST}) + +# This can be safely done only after above includes. +set(BP_PACKAGE itk) + +# Data that is related to downloads. +set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/project/incrtcl/%5bincr%20Tcl_Tk%5d-4-source/Itcl%20${ITCL_ITK_VERSION}/itk${ITCL_ITK_VERSION}.tar.gz) +set(${BP_PACKAGE}_DOWNLOAD_HASH_TYPE MD5) +set(${BP_PACKAGE}_DOWNLOAD_HASH e3600a9ad0fcdcbbc4138af5a4893b7e) + +# Data that is related to the PATH that must be used. +if(MSYS_PLATFORM) + #set(BP_PATH_NODLL "${BP_PATH}") + #set(BP_PATH "${EP_BASE}/Build/build_${BP_PACKAGE}/dll;${BP_PATH_NODLL}") + determine_msys_path(BP_PATH "${BP_PATH}") + # Must have all elements of env command in MSYS platform form + determine_msys_path(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +else(MSYS_PLATFORM) + set(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +endif(MSYS_PLATFORM) +#message(STATUS "modified BP_PATH for ${BP_PACKAGE} = ${BP_PATH}") + +if(BP_HAVE_64_BIT_OS) + set(ITK_ENABLE_64_BIT --enable-64bit) +endif(BP_HAVE_64_BIT_OS) + +ExternalProject_Add( + build_${BP_PACKAGE} + DEPENDS ${${BP_PACKAGE}_dependencies_targets} + URL ${${BP_PACKAGE}_URL} + URL_HASH ${${BP_PACKAGE}_DOWNLOAD_HASH_TYPE}=${${BP_PACKAGE}_DOWNLOAD_HASH} + CONFIGURE_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${${BP_PACKAGE}_SET_CFLAGS} CPPFLAGS=-I${BP_CMAKE_INSTALL_PREFIX}/include ${source_PATH}/${BP_CONFIGURE_COMMAND} --mandir=${BP_CMAKE_INSTALL_PREFIX}/share/man ${ITK_ENABLE_64_BIT} --with-itcl=${BP_CMAKE_INSTALL_PREFIX}/lib/itcl${ITCL_ITK_LIBVERSION} + BUILD_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} + INSTALL_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-build + COMMAND echo "Replace build-tree locations by install-tree locations" + COMMAND ${SED_EXECUTABLE} + -e "s@^\\(ITK_SRC_DIR='\\).*@\\1${BP_CMAKE_INSTALL_PREFIX}/include'@" + # Comment out the next since itk build system does not configure any + # of these variables so they are left in symbolic "@" form. + #-e "/ITK_B/s@='\\(-L\\)\\?.*build_itk@='\\1${BP_CMAKE_INSTALL_PREFIX}/lib@" + -i itkConfig.sh + APPEND + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-install + COMMAND echo "Install-tree fixups" + COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/itk${ITCL_ITK_LIBVERSION}/libitk${ITCL_ITK_LIBVERSION}.so + APPEND + ) + +list(APPEND build_target_LIST build_${BP_PACKAGE}) +# Restore BP_PATH to original state. +set(BP_PATH "${BP_ORIGINAL_NATIVE_PATH}") +#message(STATUS "${BP_PACKAGE} restored original BP_PATH = ${BP_PATH}") This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 18:45:02
|
Revision: 12634 http://sourceforge.net/p/plplot/code/12634 Author: airwin Date: 2013-10-26 18:44:58 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Use some useful convenience variables defined by the tcl build configuration to keep track of and enforce consistent version numbers for Tcl/Tk and iTcl/iTk. Modified Paths: -------------- trunk/cmake/build_projects/tk/bp.cmake Modified: trunk/cmake/build_projects/tk/bp.cmake =================================================================== --- trunk/cmake/build_projects/tk/bp.cmake 2013-10-26 18:41:13 UTC (rev 12633) +++ trunk/cmake/build_projects/tk/bp.cmake 2013-10-26 18:44:58 UTC (rev 12634) @@ -56,7 +56,7 @@ set(BP_PACKAGE tk) # Data that is related to downloads. -set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/tcl/tk8.6.1-src.tar.gz) +set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/project/tcl/Tcl/${TCL_TK_VERSION}/tk${TCL_TK_VERSION}-src.tar.gz) set(${BP_PACKAGE}_DOWNLOAD_HASH_TYPE MD5) set(${BP_PACKAGE}_DOWNLOAD_HASH 63f21c3a0e0cefbd854b4eb29b129ac6) @@ -110,8 +110,8 @@ ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-install COMMAND echo "Install-tree fixups" COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install-private-headers - COMMAND ${LN_EXECUTABLE} -v -sf wish8.6 ${BP_CMAKE_INSTALL_PREFIX}/bin/wish - COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtk8.6.so + COMMAND ${LN_EXECUTABLE} -v -sf wish${TCL_TK_LIBVERSION} ${BP_CMAKE_INSTALL_PREFIX}/bin/wish + COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtk${TCL_TK_LIBVERSION}.so APPEND ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 18:41:15
|
Revision: 12633 http://sourceforge.net/p/plplot/code/12633 Author: airwin Date: 2013-10-26 18:41:13 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Implement and use some useful convenience variables to keep track of and enforce consistent version numbers for Tcl/Tk and iTcl/iTk. Modified Paths: -------------- trunk/cmake/build_projects/tcl/bp.cmake Modified: trunk/cmake/build_projects/tcl/bp.cmake =================================================================== --- trunk/cmake/build_projects/tcl/bp.cmake 2013-10-26 06:41:06 UTC (rev 12632) +++ trunk/cmake/build_projects/tcl/bp.cmake 2013-10-26 18:41:13 UTC (rev 12633) @@ -55,8 +55,15 @@ # This can be safely done only after above includes. set(BP_PACKAGE tcl) +# These variables are also used by tk and itk (and accessible to those +# build configurations because they both depend on this one in any case). +set(TCL_TK_VERSION 8.6.1) +string(REGEX REPLACE "\\.[0-9]$" "" TCL_TK_LIBVERSION ${TCL_TK_VERSION}) +set(ITCL_ITK_VERSION 4.0.0) +set(ITCL_ITK_LIBVERSION ${ITCL_ITK_VERSION}) + # Data that is related to downloads. -set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/tcl/tcl8.6.1-src.tar.gz) +set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/project/tcl/Tcl/${TCL_TK_VERSION}/tcl${TCL_TK_VERSION}-src.tar.gz) set(${BP_PACKAGE}_DOWNLOAD_HASH_TYPE MD5) set(${BP_PACKAGE}_DOWNLOAD_HASH aae4b701ee527c6e4e1a6f9c7399882e) @@ -110,8 +117,8 @@ ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-install COMMAND echo "Install-tree fixups" COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install-private-headers - COMMAND ${LN_EXECUTABLE} -v -sf tclsh8.6 ${BP_CMAKE_INSTALL_PREFIX}/bin/tclsh - COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtcl8.6.so + COMMAND ${LN_EXECUTABLE} -v -sf tclsh${TCL_TK_LIBVERSION} ${BP_CMAKE_INSTALL_PREFIX}/bin/tclsh + COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtcl${TCL_TK_LIBVERSION}.so APPEND ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 06:41:11
|
Revision: 12632 http://sourceforge.net/p/plplot/code/12632 Author: airwin Date: 2013-10-26 06:41:06 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Fix endif label inconsistency that crept into last commit. Modified Paths: -------------- trunk/cmake/modules/qt.cmake Modified: trunk/cmake/modules/qt.cmake =================================================================== --- trunk/cmake/modules/qt.cmake 2013-10-26 02:45:20 UTC (rev 12631) +++ trunk/cmake/modules/qt.cmake 2013-10-26 06:41:06 UTC (rev 12632) @@ -130,7 +130,7 @@ "setting all qt devices to OFF." ) set(ANY_QT_DEVICE OFF) -endif(ENABLE_qt AND NOT PLD_extqt) +endif(NOT ENABLE_qt) if(NOT ANY_QT_DEVICE) set(PLD_bmpqt OFF CACHE BOOL "Enable Qt Windows bmp device" FORCE) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 02:45:26
|
Revision: 12631 http://sourceforge.net/p/plplot/code/12631 Author: airwin Date: 2013-10-26 02:45:20 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Fix minor memory leak in example. Modified Paths: -------------- trunk/examples/c/x33c.c Modified: trunk/examples/c/x33c.c =================================================================== --- trunk/examples/c/x33c.c 2013-10-26 01:00:43 UTC (rev 12630) +++ trunk/examples/c/x33c.c 2013-10-26 02:45:20 UTC (rev 12631) @@ -275,6 +275,7 @@ plvpor( 0.0, 1.0, 0.0, 1.0 ); plwind( 0.0, 1.0, 0.0, 1.0 ); plptex( 0.5, 0.5, 0.0, 0.0, 0.5, title ); + free( label ); } void This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-26 01:00:50
|
Revision: 12630 http://sourceforge.net/p/plplot/code/12630 Author: airwin Date: 2013-10-26 01:00:43 +0000 (Sat, 26 Oct 2013) Log Message: ----------- Drop qt devices if ENABLE_qt (which activates the build of the plplotqtd library which the qt devices depend on) is false. Modified Paths: -------------- trunk/cmake/modules/qt.cmake Modified: trunk/cmake/modules/qt.cmake =================================================================== --- trunk/cmake/modules/qt.cmake 2013-10-25 18:51:21 UTC (rev 12629) +++ trunk/cmake/modules/qt.cmake 2013-10-26 01:00:43 UTC (rev 12630) @@ -102,20 +102,6 @@ endif(QT4_FOUND) endif(ANY_QT_DEVICE) -if(NOT ANY_QT_DEVICE) - set(PLD_bmpqt OFF CACHE BOOL "Enable Qt Windows bmp device" FORCE) - set(PLD_jpgqt OFF CACHE BOOL "Enable Qt jpg device" FORCE) - set(PLD_pngqt OFF CACHE BOOL "Enable Qt png device" FORCE) - set(PLD_ppmqt OFF CACHE BOOL "Enable Qt ppm device" FORCE) - set(PLD_tiffqt OFF CACHE BOOL "Enable Qt tiff device" FORCE) - set(PLD_epsqt OFF CACHE BOOL "Enable Qt EPS device" FORCE) - set(PLD_pdfqt OFF CACHE BOOL "Enable Qt PDF device" FORCE) - set(PLD_qtwidget OFF CACHE BOOL "Enable Qt interactive device" FORCE) - set(PLD_svgqt OFF CACHE BOOL "Enable Qt SVG device" FORCE) - set(PLD_extqt OFF CACHE BOOL "Enable Qt ext device" FORCE) - set(PLD_memqt OFF CACHE BOOL "Enable Qt mem device" FORCE) -endif(NOT ANY_QT_DEVICE) - if(DEFAULT_NO_BINDINGS) option(ENABLE_qt "Enable Qt bindings" OFF) option(ENABLE_pyqt4 "Enable pyqt4 Python extension module" OFF) @@ -124,6 +110,11 @@ option(ENABLE_pyqt4 "Enable pyqt4 Python extension module" ON) endif(DEFAULT_NO_BINDINGS) +# ENABLE_qt depends on PLD_extqt +if(NOT ANY_QT_DEVICE) + set(PLD_extqt OFF CACHE BOOL "Enable Qt ext device" FORCE) +endif(NOT ANY_QT_DEVICE) + if(ENABLE_qt AND NOT PLD_extqt) message(STATUS "WARNING: PLD_extqt is OFF so " @@ -132,6 +123,29 @@ set(ENABLE_qt OFF CACHE BOOL "Enable Qt bindings" FORCE) endif(ENABLE_qt AND NOT PLD_extqt) +# All qt devices depend on ENABLE_qt +if(NOT ENABLE_qt) + message(STATUS + "WARNING: ENABLE_qt is OFF so " + "setting all qt devices to OFF." + ) + set(ANY_QT_DEVICE OFF) +endif(ENABLE_qt AND NOT PLD_extqt) + +if(NOT ANY_QT_DEVICE) + set(PLD_bmpqt OFF CACHE BOOL "Enable Qt Windows bmp device" FORCE) + set(PLD_jpgqt OFF CACHE BOOL "Enable Qt jpg device" FORCE) + set(PLD_pngqt OFF CACHE BOOL "Enable Qt png device" FORCE) + set(PLD_ppmqt OFF CACHE BOOL "Enable Qt ppm device" FORCE) + set(PLD_tiffqt OFF CACHE BOOL "Enable Qt tiff device" FORCE) + set(PLD_epsqt OFF CACHE BOOL "Enable Qt EPS device" FORCE) + set(PLD_pdfqt OFF CACHE BOOL "Enable Qt PDF device" FORCE) + set(PLD_qtwidget OFF CACHE BOOL "Enable Qt interactive device" FORCE) + set(PLD_svgqt OFF CACHE BOOL "Enable Qt SVG device" FORCE) + set(PLD_extqt OFF CACHE BOOL "Enable Qt ext device" FORCE) + set(PLD_memqt OFF CACHE BOOL "Enable Qt mem device" FORCE) +endif(NOT ANY_QT_DEVICE) + if(ENABLE_pyqt4 AND NOT ENABLE_python) message(STATUS "WARNING: ENABLE_python is OFF so " This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-25 18:51:24
|
Revision: 12629 http://sourceforge.net/p/plplot/code/12629 Author: airwin Date: 2013-10-25 18:51:21 +0000 (Fri, 25 Oct 2013) Log Message: ----------- Initial commit of build configuration for tk. Tested by Alan W. Irwin <ai...@us...> on Linux using the build_tk target for build_projects configured with -DBUILD_THE_BUILDTOOLS=ON. N.B. Tk-8.6.1 does not include itk so a separate build_projects configuration will have to be made for itk before Tk and iTk can be tested together for a PLplot build. Modified Paths: -------------- trunk/cmake/build_projects/CMakeLists.txt Added Paths: ----------- trunk/cmake/build_projects/tk/ trunk/cmake/build_projects/tk/bp.cmake Modified: trunk/cmake/build_projects/CMakeLists.txt =================================================================== --- trunk/cmake/build_projects/CMakeLists.txt 2013-10-25 06:36:35 UTC (rev 12628) +++ trunk/cmake/build_projects/CMakeLists.txt 2013-10-25 18:51:21 UTC (rev 12629) @@ -288,6 +288,7 @@ #subversion swig tcl + tk ) else(BUILD_THE_BUILDTOOLS) # List of all configurations. Order doesn't matter because multiple Added: trunk/cmake/build_projects/tk/bp.cmake =================================================================== --- trunk/cmake/build_projects/tk/bp.cmake (rev 0) +++ trunk/cmake/build_projects/tk/bp.cmake 2013-10-25 18:51:21 UTC (rev 12629) @@ -0,0 +1,121 @@ +# tk/bp.cmake +# CMakeLists.txt file to configure the build of tk. + +# Copyright (C) 2013 Alan W. Irwin + +# This file is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License, or (at your option) any later version. + +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this file; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + +# The top-level CMakeLists.txt file that includes this file should +# have run "include(ExternalProject)" and set EP_BASE variable (and +# corresponding directory property) as well as various BP variables +# used below that configure how the External_Project functions +# operate. + +# These build configuration details for Tk adapted from information in +# <http://www.linuxfromscratch.org/blfs/view/svn/general/tk.html>. + +# Protect against configuring a build twice in one CMake call +if(tk_configured) + return() +endif(tk_configured) +set(tk_configured ON) + +# List of dependencies (most of which are build tools) which should be +# ignored. +set(BP_ignored_dependencies_LIST ${extra_ignored_dependencies_list}) + +set(tk_dependencies_LIST tcl) +# Remove dependencies that should be ignored. +if(tk_dependencies_LIST) + list(REMOVE_ITEM tk_dependencies_LIST ${BP_ignored_dependencies_LIST}) +endif(tk_dependencies_LIST) + +set(tk_dependencies_targets) +foreach(build_configuration ${tk_dependencies_LIST}) + if(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + include(${build_configuration}/bp.cmake) + list(APPEND tk_dependencies_targets build_${build_configuration}) + else(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + message(STATUS "Warning: A build_configuration for ${build_configuration} does not exist so it is assumed this dependency of tk has been installed another way.") + endif(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) +endforeach(build_configuration ${tk_dependences_LIST}) + +# This can be safely done only after above includes. +set(BP_PACKAGE tk) + +# Data that is related to downloads. +set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/tcl/tk8.6.1-src.tar.gz) +set(${BP_PACKAGE}_DOWNLOAD_HASH_TYPE MD5) +set(${BP_PACKAGE}_DOWNLOAD_HASH 63f21c3a0e0cefbd854b4eb29b129ac6) + +# Data that is related to the PATH that must be used. +# N.B. note below that we always use the unix subdirectory of the +# source tree to find the configure script. Note, there is a macosx +# and win subdirectory there as well that contain configure scripts +# with additional options for those platforms, but for now the unix +# version of configure may be good enough for our needs for all +# platforms. +if(MSYS_PLATFORM) + #set(BP_PATH_NODLL "${BP_PATH}") + #set(BP_PATH "${EP_BASE}/Build/build_${BP_PACKAGE}/dll;${BP_PATH_NODLL}") + determine_msys_path(BP_PATH "${BP_PATH}") + # Must have all elements of env command in MSYS platform form + determine_msys_path(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}/unix") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +else(MSYS_PLATFORM) + set(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}/unix") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +endif(MSYS_PLATFORM) +#message(STATUS "modified BP_PATH for ${BP_PACKAGE} = ${BP_PATH}") + +if(BP_HAVE_64_BIT_OS) + set(TK_ENABLE_64_BIT --enable-64bit) +endif(BP_HAVE_64_BIT_OS) + +ExternalProject_Add( + build_${BP_PACKAGE} + DEPENDS ${${BP_PACKAGE}_dependencies_targets} + URL ${${BP_PACKAGE}_URL} + URL_HASH ${${BP_PACKAGE}_DOWNLOAD_HASH_TYPE}=${${BP_PACKAGE}_DOWNLOAD_HASH} + CONFIGURE_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${${BP_PACKAGE}_SET_CFLAGS} CPPFLAGS=-I${BP_CMAKE_INSTALL_PREFIX}/include ${source_PATH}/${BP_CONFIGURE_COMMAND} --mandir=${BP_CMAKE_INSTALL_PREFIX}/share/man ${TK_ENABLE_64_BIT} + BUILD_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} + INSTALL_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-build + COMMAND echo "Replace build-tree locations by install-tree locations" + COMMAND ${SED_EXECUTABLE} + -e "s@^\\(TK_SRC_DIR='\\).*@\\1${BP_CMAKE_INSTALL_PREFIX}/include'@" + -e "/TK_B/s@='\\(-L\\)\\?.*build_tk@='\\1${BP_CMAKE_INSTALL_PREFIX}/lib@" + -i tkConfig.sh + APPEND + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-install + COMMAND echo "Install-tree fixups" + COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install-private-headers + COMMAND ${LN_EXECUTABLE} -v -sf wish8.6 ${BP_CMAKE_INSTALL_PREFIX}/bin/wish + COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtk8.6.so + APPEND + ) + +list(APPEND build_target_LIST build_${BP_PACKAGE}) +# Restore BP_PATH to original state. +set(BP_PATH "${BP_ORIGINAL_NATIVE_PATH}") +#message(STATUS "${BP_PACKAGE} restored original BP_PATH = ${BP_PATH}") This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-25 06:36:38
|
Revision: 12628 http://sourceforge.net/p/plplot/code/12628 Author: airwin Date: 2013-10-25 06:36:35 +0000 (Fri, 25 Oct 2013) Log Message: ----------- Initial commit of build configuration for Tcl. Tested by Alan W. Irwin <ai...@us...> on Linux using a build_projects build with -DBUILD_THE_BUILDTOOLS=ON and the build_tcl target. Tcl-8.61 (and itcl-4.0.0 and several other components) built and installed without issues. Afterward, an ordinary build_projects build with the build_plplot_lite target found that installation of Tcl-8.6.1 and iTcl-4.0.0 and used it to determine Tcl-8.6 results for all our standard examples which agreed with the corresponding C results. Modified Paths: -------------- trunk/cmake/build_projects/CMakeLists.txt Added Paths: ----------- trunk/cmake/build_projects/tcl/ trunk/cmake/build_projects/tcl/bp.cmake Modified: trunk/cmake/build_projects/CMakeLists.txt =================================================================== --- trunk/cmake/build_projects/CMakeLists.txt 2013-10-25 06:22:19 UTC (rev 12627) +++ trunk/cmake/build_projects/CMakeLists.txt 2013-10-25 06:36:35 UTC (rev 12628) @@ -83,6 +83,10 @@ bash make python + uname + sed + ln + chmod ) foreach(executable ${executables_LIST}) @@ -105,6 +109,31 @@ ) message(STATUS "PYTHON_VERSION = ${PYTHON_VERSION}") +# Determine whether OS is 64-bits from uname -m "machine name" field. + +execute_process( + COMMAND + ${UNAME_EXECUTABLE} -m + OUTPUT_VARIABLE UNAME_MACHINE + OUTPUT_STRIP_TRAILING_WHITESPACE + ) + +# Determine desired install permissions on shared objects. +if(CMAKE_INSTALL_SO_NO_EXE) + set(SO_NUMERICAL_PERMISSIONS 644) +else(CMAKE_INSTALL_SO_NO_EXE) + set(SO_NUMERICAL_PERMISSIONS 755) +endif(CMAKE_INSTALL_SO_NO_EXE) + +# This will need refinement as more platforms tested, but it works on +# Intel/AMD Linux hardware and also MinGW/MSYS on 32-bit Windows for +# now. +if(UNAME_MACHINE STREQUAL x86_64) + set(BP_HAVE_64_BIT_OS ON) +else(UNAME_MACHINE STREQUAL x86_64) + set(BP_HAVE_64_BIT_OS OFF) +endif(UNAME_MACHINE STREQUAL x86_64) + # Use modified version of the CMake 2.8.12 ExternalProject module # where the tar.xz processing has been fixed. set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}) @@ -258,6 +287,7 @@ pkg-config #subversion swig + tcl ) else(BUILD_THE_BUILDTOOLS) # List of all configurations. Order doesn't matter because multiple Added: trunk/cmake/build_projects/tcl/bp.cmake =================================================================== --- trunk/cmake/build_projects/tcl/bp.cmake (rev 0) +++ trunk/cmake/build_projects/tcl/bp.cmake 2013-10-25 06:36:35 UTC (rev 12628) @@ -0,0 +1,121 @@ +# tcl/bp.cmake +# CMakeLists.txt file to configure the build of tcl. + +# Copyright (C) 2013 Alan W. Irwin + +# This file is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License, or (at your option) any later version. + +# This file is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this file; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + +# The top-level CMakeLists.txt file that includes this file should +# have run "include(ExternalProject)" and set EP_BASE variable (and +# corresponding directory property) as well as various BP variables +# used below that configure how the External_Project functions +# operate. + +# These build configuration details for Tcl adapted from information in +# <http://www.linuxfromscratch.org/blfs/view/svn/general/tcl.html>. + +# Protect against configuring a build twice in one CMake call +if(tcl_configured) + return() +endif(tcl_configured) +set(tcl_configured ON) + +# List of dependencies (most of which are build tools) which should be +# ignored. +set(BP_ignored_dependencies_LIST ${extra_ignored_dependencies_list}) + +set(tcl_dependencies_LIST) +# Remove dependencies that should be ignored. +if(tcl_dependencies_LIST) + list(REMOVE_ITEM tcl_dependencies_LIST ${BP_ignored_dependencies_LIST}) +endif(tcl_dependencies_LIST) + +set(tcl_dependencies_targets) +foreach(build_configuration ${tcl_dependencies_LIST}) + if(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + include(${build_configuration}/bp.cmake) + list(APPEND tcl_dependencies_targets build_${build_configuration}) + else(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) + message(STATUS "Warning: A build_configuration for ${build_configuration} does not exist so it is assumed this dependency of tcl has been installed another way.") + endif(EXISTS ${CMAKE_SOURCE_DIR}/${build_configuration}/bp.cmake) +endforeach(build_configuration ${tcl_dependences_LIST}) + +# This can be safely done only after above includes. +set(BP_PACKAGE tcl) + +# Data that is related to downloads. +set(${BP_PACKAGE}_URL http://downloads.sourceforge.net/tcl/tcl8.6.1-src.tar.gz) +set(${BP_PACKAGE}_DOWNLOAD_HASH_TYPE MD5) +set(${BP_PACKAGE}_DOWNLOAD_HASH aae4b701ee527c6e4e1a6f9c7399882e) + +# Data that is related to the PATH that must be used. +# N.B. note below that we always use the unix subdirectory of the +# source tree to find the configure script. Note, there is a macosx +# and win subdirectory there as well that contain configure scripts +# with additional options for those platforms, but for now the unix +# version of configure may be good enough for our needs for all +# platforms. +if(MSYS_PLATFORM) + #set(BP_PATH_NODLL "${BP_PATH}") + #set(BP_PATH "${EP_BASE}/Build/build_${BP_PACKAGE}/dll;${BP_PATH_NODLL}") + determine_msys_path(BP_PATH "${BP_PATH}") + # Must have all elements of env command in MSYS platform form + determine_msys_path(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}/unix") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +else(MSYS_PLATFORM) + set(source_PATH "${EP_BASE}/Source/build_${BP_PACKAGE}/unix") + set(${BP_PACKAGE}_SET_CFLAGS "CFLAGS=$ENV{CFLAGS}") +endif(MSYS_PLATFORM) +#message(STATUS "modified BP_PATH for ${BP_PACKAGE} = ${BP_PATH}") + +if(BP_HAVE_64_BIT_OS) + set(TCL_ENABLE_64_BIT --enable-64bit) +endif(BP_HAVE_64_BIT_OS) + +ExternalProject_Add( + build_${BP_PACKAGE} + DEPENDS ${${BP_PACKAGE}_dependencies_targets} + URL ${${BP_PACKAGE}_URL} + URL_HASH ${${BP_PACKAGE}_DOWNLOAD_HASH_TYPE}=${${BP_PACKAGE}_DOWNLOAD_HASH} + CONFIGURE_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${${BP_PACKAGE}_SET_CFLAGS} ${source_PATH}/${BP_CONFIGURE_COMMAND} --mandir=${BP_CMAKE_INSTALL_PREFIX}/share/man ${TCL_ENABLE_64_BIT} + BUILD_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} + INSTALL_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-build + COMMAND echo "Replace build-tree locations by install-tree locations" + COMMAND ${SED_EXECUTABLE} + -e "s@^\\(TCL_SRC_DIR='\\).*@\\1${BP_CMAKE_INSTALL_PREFIX}/include'@" + -e "/TCL_B/s@='\\(-L\\)\\?.*build_tcl@='\\1${BP_CMAKE_INSTALL_PREFIX}/lib@" + -i tclConfig.sh + APPEND + ) + +add_custom_command( + OUTPUT + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-install + COMMAND echo "Install-tree fixups" + COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_MAKE_COMMAND} install-private-headers + COMMAND ${LN_EXECUTABLE} -v -sf tclsh8.6 ${BP_CMAKE_INSTALL_PREFIX}/bin/tclsh + COMMAND ${CHMOD_EXECUTABLE} -v ${SO_NUMERICAL_PERMISSIONS} ${BP_CMAKE_INSTALL_PREFIX}/lib/libtcl8.6.so + APPEND + ) + +list(APPEND build_target_LIST build_${BP_PACKAGE}) +# Restore BP_PATH to original state. +set(BP_PATH "${BP_ORIGINAL_NATIVE_PATH}") +#message(STATUS "${BP_PACKAGE} restored original BP_PATH = ${BP_PATH}") This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-25 06:22:21
|
Revision: 12627 http://sourceforge.net/p/plplot/code/12627 Author: airwin Date: 2013-10-25 06:22:19 +0000 (Fri, 25 Oct 2013) Log Message: ----------- Bump the maximum version searched for to 4.0.0 for iTcl. (Note that version is an integral part of the Tcl-8.6.1 source code and automatically builds when Tcl-8.6.1 is built.) Modified Paths: -------------- trunk/cmake/modules/tcl-related.cmake Modified: trunk/cmake/modules/tcl-related.cmake =================================================================== --- trunk/cmake/modules/tcl-related.cmake 2013-10-24 23:01:26 UTC (rev 12626) +++ trunk/cmake/modules/tcl-related.cmake 2013-10-25 06:22:19 UTC (rev 12627) @@ -94,7 +94,7 @@ message(STATUS "Looking for itcl.h - found") message(STATUS "Looking for itcl library") get_filename_component(TCL_LIBRARY_PATH ${TCL_LIBRARY} PATH) - set(itcl_library_versions 3.4 3.3 3.2 3.1 3.0 2.1 2.0) + set(itcl_library_versions 4.0.0 3.4 3.3 3.2 3.1 3.0 2.1 2.0) foreach(version ${itcl_library_versions}) find_library(ITCL_LIBRARY itcl${version} PATHS ${TCL_LIBRARY_PATH} PATH_SUFFIXES itcl${version}) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <and...@us...> - 2013-10-24 23:01:37
|
Revision: 12626 http://sourceforge.net/p/plplot/code/12626 Author: andrewross Date: 2013-10-24 23:01:26 +0000 (Thu, 24 Oct 2013) Log Message: ----------- Fix up various compiler warnings, mostly related to casting and uninitialized variables. Modified Paths: -------------- trunk/bindings/f95/plstubs.h trunk/bindings/f95/scstubs.c trunk/bindings/java/plplotjavac.i trunk/bindings/python/plplot_widgetmodule.c trunk/bindings/python/plplotcmodule.i trunk/drivers/xfig.c trunk/examples/c/x33c.c trunk/examples/c++/x16.cc trunk/examples/f95/x00f.f90 trunk/examples/f95/x09f.f90 trunk/examples/f95/x27f.f90 trunk/examples/f95/x33f.f90 trunk/src/plfreetype.c trunk/src/plmap.c Modified: trunk/bindings/f95/plstubs.h =================================================================== --- trunk/bindings/f95/plstubs.h 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/bindings/f95/plstubs.h 2013-10-24 23:01:26 UTC (rev 12626) @@ -208,7 +208,7 @@ #define PLFONT FNAME( PLFONT, plfont ) #define PLFONTLD FNAME( PLFONTLD, plfontld ) #define PLGCHR FNAME( PLGCHR, plgchr ) -#define PLGCMAP1_RANGE FNAME( PLFCMAP1_RANGE, plgcmap1_range ) +#define PLGCMAP1_RANGE FNAME( PLGCMAP1_RANGE, plgcmap1_range ) #define PLGCOL0 FNAME( PLGCOL0, plgcol0 ) #define PLGCOL0A FNAME( PLGCOL0A, plgcol0a ) #define PLGCOLBG FNAME( PLGCOLBG, plgcolbg ) Modified: trunk/bindings/f95/scstubs.c =================================================================== --- trunk/bindings/f95/scstubs.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/bindings/f95/scstubs.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -106,6 +106,7 @@ void PLGCOLBG( PLINT *r, PLINT *g, PLINT *b ); void PLGCOLBGA( PLINT *r, PLINT *g, PLINT *b, PLFLT *a ); void PLGCOMPRESSION( PLINT *compression ); +void PLGCMAP1_RANGE( PLFLT *min_color, PLFLT *max_color ); void PLGDEV7( char *dev, int length ); void PLGDIDEV( PLFLT *p_mar, PLFLT *p_aspect, PLFLT *p_jx, PLFLT *p_jy ); void PLGDIORI( PLFLT *p_rot ); @@ -198,6 +199,7 @@ void PLSCMAP1LA2( PLBOOL *itype, PLINT *npts, PLFLT *intensity, PLFLT *coord1, PLFLT *coord2, PLFLT *coord3, PLFLT *a ); void PLSCMAP1N( PLINT *n ); +void PLSCMAP1_RANGE( PLFLT *min_color, PLFLT *max_color ); void PLSCOL0( PLINT *icol0, PLINT *r, PLINT *g, PLINT *b ); void PLSCOL0A( PLINT *icol0, PLINT *r, PLINT *g, PLINT *b, PLFLT *a ); void PLSCOLBG( PLINT *r, PLINT *g, PLINT *b ); @@ -412,10 +414,10 @@ PLFLT **a; int i, j; - a = (PLFLT **) malloc( sizeof ( PLFLT * ) * ( *n_axes ) ); + a = (PLFLT **) malloc( sizeof ( PLFLT * ) * ( size_t ) ( *n_axes ) ); for ( i = 0; i < *n_axes; i++ ) { - a[i] = (PLFLT *) malloc( sizeof ( PLFLT ) * n_values[i] ); + a[i] = (PLFLT *) malloc( sizeof ( PLFLT ) * ( size_t ) n_values[i] ); for ( j = 0; j < n_values[i]; j++ ) { a[i][j] = values[i + j * ( *n_axes )]; Modified: trunk/bindings/java/plplotjavac.i =================================================================== --- trunk/bindings/java/plplotjavac.i 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/bindings/java/plplotjavac.i 2013-10-24 23:01:26 UTC (rev 12626) @@ -197,7 +197,7 @@ setup_array_1d_b( PLBOOL **pa, jboolean *adat, int n ) { int i; - *pa = (PLBOOL *) malloc( n * sizeof ( PLBOOL ) ); + *pa = (PLBOOL *) malloc( ( size_t ) n * sizeof ( PLBOOL ) ); for ( i = 0; i < n; i++ ) { ( *pa )[i] = adat[i] ? 1 : 0; @@ -210,7 +210,7 @@ setup_array_1d_i( PLINT **pa, jint *adat, int n ) { int i; - *pa = (PLINT *) malloc( n * sizeof ( PLINT ) ); + *pa = (PLINT *) malloc( ( size_t ) n * sizeof ( PLINT ) ); for ( i = 0; i < n; i++ ) { ( *pa )[i] = adat[i]; @@ -223,7 +223,7 @@ setup_array_1d_f( PLFLT **pa, jfloat *adat, int n ) { int i; - *pa = (PLFLT *) malloc( n * sizeof ( PLFLT ) ); + *pa = (PLFLT *) malloc( ( size_t ) n * sizeof ( PLFLT ) ); for ( i = 0; i < n; i++ ) { ( *pa )[i] = adat[i]; @@ -236,7 +236,7 @@ setup_array_1d_d( PLFLT **pa, jdouble *adat, int n ) { int i; - *pa = (PLFLT *) malloc( n * sizeof ( PLFLT ) ); + *pa = (PLFLT *) malloc( ( size_t ) n * sizeof ( PLFLT ) ); for ( i = 0; i < n; i++ ) { ( *pa )[i] = adat[i]; @@ -251,8 +251,8 @@ { int i, j; - *pa = (PLFLT **) malloc( nx * sizeof ( PLFLT * ) ); - ( *pa )[0] = (PLFLT *) malloc( nx * ny * sizeof ( PLFLT ) ); + *pa = (PLFLT **) malloc( ( size_t ) nx * sizeof ( PLFLT * ) ); + ( *pa )[0] = (PLFLT *) malloc( ( size_t ) ( nx * ny ) * sizeof ( PLFLT ) ); for ( i = 0; i < nx; i++ ) { @@ -270,8 +270,8 @@ { int i, j; - *pa = (PLFLT **) malloc( nx * sizeof ( PLFLT * ) ); - ( *pa )[0] = (PLFLT *) malloc( nx * ny * sizeof ( PLFLT ) ); + *pa = (PLFLT **) malloc( ( size_t ) nx * sizeof ( PLFLT * ) ); + ( *pa )[0] = (PLFLT *) malloc( ( size_t ) ( nx * ny ) * sizeof ( PLFLT ) ); for ( i = 0; i < nx; i++ ) { @@ -292,7 +292,7 @@ #ifdef PL_DOUBLE x = (double *) dat; #else - x = (double *) malloc( n * sizeof ( double ) ); + x = (double *) malloc( ( size_t ) n * sizeof ( double ) ); for ( i = 0; i < n; i++ ) { x[i] = (double) dat[i]; @@ -915,8 +915,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -982,8 +982,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1040,8 +1040,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1094,8 +1094,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1178,8 +1178,8 @@ return; } - ptr = (PLFLT **) malloc( nx * sizeof ( PLFLT * ) ); - ptr[0] = (PLFLT *) malloc( nx * ny * sizeof ( PLFLT ) ); + ptr = (PLFLT **) malloc( ( size_t ) nx * sizeof ( PLFLT * ) ); + ptr[0] = (PLFLT *) malloc( ( size_t ) nx * ny * sizeof ( PLFLT ) ); for ( i = 0; i < nx; i++ ) { ptr[i] = ptr[0] + i * ny; @@ -1197,8 +1197,8 @@ ptr = $1; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); for ( i = 0; i < nx; i++ ) { @@ -1254,8 +1254,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1318,6 +1318,8 @@ jmethodID mapformID; JNIEnv *cbenvMapform; + void mapform_java( PLINT n, PLFLT *x, PLFLT *y ); + // C mapform callback function which calls the java // mapform function in a PLCallbackMapform object. void mapform_java( PLINT n, PLFLT *x, PLFLT *y ) @@ -1567,8 +1569,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1643,8 +1645,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1711,8 +1713,8 @@ int nx = ( *jenv )->GetArrayLength( jenv, $input ); int ny = -1; int i, j; - ai = (jobject *) malloc( nx * sizeof ( jobject ) ); - adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) ); + ai = (jobject *) malloc( ( size_t ) nx * sizeof ( jobject ) ); + adat = (jPLFLT **) malloc( ( size_t ) nx * sizeof ( jPLFLT * ) ); ( *jenv )->EnsureLocalCapacity( jenv, nx ); @@ -1805,7 +1807,7 @@ // Take a copy of the C string as the typemap is for a non const C string jmethodID capacityID = ( *jenv )->GetMethodID( jenv, sbufClass, "capacity", "()I" ); jint capacity = ( *jenv )->CallIntMethod( jenv, $input, capacityID ); - $1 = (char *) malloc( capacity + 1 ); + $1 = (char *) malloc( ( size_t ) ( capacity + 1 ) ); // Zero the original StringBuffer, so we can replace it with the result setLengthID = ( *jenv )->GetMethodID( jenv, sbufClass, "setLength", "(I)V" ); @@ -1850,7 +1852,7 @@ int i = 0; size = (int) ( ( *jenv )->GetArrayLength( jenv, $input ) ); $1 = &size; - $2 = (char **) malloc( ( size + 1 ) * sizeof ( char * ) ); + $2 = (char **) malloc( ( size_t ) ( size + 1 ) * sizeof ( char * ) ); // make a copy of each string for ( i = 0; i < size; i++ ) { @@ -1929,7 +1931,7 @@ printf( "Arrays must be the same length\n" ); return; } - $1 = (char **) malloc( Alen * sizeof ( char * ) ); + $1 = (char **) malloc( ( size_t ) Alen * sizeof ( char * ) ); // make a copy of each string for ( i = 0; i < Alen; i++ ) { @@ -1975,7 +1977,7 @@ int size = ( *jenv )->GetArrayLength( jenv, $input ); Alen = size; $1 = size; - $2 = (char **) malloc( Alen * sizeof ( char * ) ); + $2 = (char **) malloc( ( size_t ) Alen * sizeof ( char * ) ); // make a copy of each string for ( i = 0; i < Alen; i++ ) { Modified: trunk/bindings/python/plplot_widgetmodule.c =================================================================== --- trunk/bindings/python/plplot_widgetmodule.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/bindings/python/plplot_widgetmodule.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -8,8 +8,11 @@ #ifdef ENABLE_tk #include <tcl.h> +#include "pltk.h" #endif +void initplplot_widget( void ); + #define TRY( E ) if ( !( E ) ) return NULL #ifdef ENABLE_tk @@ -66,13 +69,13 @@ PLDLLIMPEXP_PLPLOT_WIDGETMODULE void initplplot_widget( void ) { PyObject *m; - PyObject *d; + //PyObject *d; import_array(); // Create the module and add the functions m = Py_InitModule( "plplot_widget", plplot_widget_methods ); - d = PyModule_GetDict( m ); + PyModule_GetDict( m ); // Check for errors if ( PyErr_Occurred() ) Modified: trunk/bindings/python/plplotcmodule.i =================================================================== --- trunk/bindings/python/plplotcmodule.i 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/bindings/python/plplotcmodule.i 2013-10-24 23:01:26 UTC (rev 12626) @@ -113,8 +113,11 @@ #if SIZEOF_LONG != 4 %wrapper %{ + + PyArrayObject* myIntArray_ContiguousFromObject( PyObject* in, int type, int mindims, int maxdims ); + // some really twisted stuff to allow calling a single precision library from python - PyArrayObject* myIntArray_ContiguousFromObject( PyObject* in, int type, int mindims, int maxdims ) + PyArrayObject* myIntArray_ContiguousFromObject( PyObject* in, int PL_UNUSED( type ), int mindims, int maxdims ) { PyArrayObject* tmp = (PyArrayObject *) PyArray_ContiguousFromObject( in, NPY_PLINT, mindims, maxdims ); @@ -478,7 +481,7 @@ $2 = PyArray_DIMS( tmp )[0]; $3 = PyArray_DIMS( tmp )[1]; size = $3; - $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * $2 ); + $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) $2 ); for ( i = 0; i < $2; i++ ) $1[i] = ( (PLFLT *) PyArray_DATA( tmp ) + i * size ); } @@ -498,7 +501,7 @@ Xlen = $2 = PyArray_DIMS( tmp )[0]; Ylen = $3 = PyArray_DIMS( tmp )[1]; size = $3; - $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * $2 ); + $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) $2 ); for ( i = 0; i < $2; i++ ) $1[i] = ( (PLFLT *) PyArray_DATA( tmp ) + i * size ); } @@ -518,7 +521,7 @@ Xlen = PyArray_DIMS( tmp )[0]; Ylen = PyArray_DIMS( tmp )[1]; size = Ylen; - $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * Xlen ); + $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) Xlen ); for ( i = 0; i < Xlen; i++ ) $1[i] = ( (PLFLT *) PyArray_DATA( tmp ) + i * size ); } @@ -555,7 +558,7 @@ return NULL; } size = Ylen; - $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * Xlen ); + $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) Xlen ); for ( i = 0; i < Xlen; i++ ) $1[i] = ( (PLFLT *) PyArray_DATA( tmp ) + i * size ); } @@ -578,7 +581,7 @@ return NULL; } size = Ylen; - $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * Xlen ); + $1 = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) Xlen ); for ( i = 0; i < Xlen; i++ ) $1[i] = ( (PLFLT *) PyArray_DATA( tmp ) + i * size ); } @@ -608,7 +611,7 @@ if ( !array ) return NULL; size = Ylen; - $3 = (double **) malloc( sizeof ( double * ) * Xlen ); + $3 = (double **) malloc( sizeof ( double * ) * ( size_t ) Xlen ); for ( i = 0; i < Xlen; i++ ) $3[i] = ( (double *) PyArray_DATA( (PyArrayObject *) array ) + i * size ); } @@ -637,7 +640,7 @@ PyErr_SetString( PyExc_ValueError, "Vectors must be same length." ); return NULL; } - $1 = (char **) malloc( sizeof ( char* ) * Alen ); + $1 = (char **) malloc( sizeof ( char* ) * ( size_t ) Alen ); for ( i = 0; i < Alen; i++ ) { $1[i] = (char *) PyArray_DATA( tmp ) + i * PyArray_STRIDES( tmp )[0]; @@ -659,7 +662,7 @@ return NULL; Alen = PyArray_DIMS( tmp )[0]; $1 = Alen; - $2 = (char **) malloc( sizeof ( char* ) * Alen ); + $2 = (char **) malloc( sizeof ( char* ) * ( size_t ) Alen ); for ( i = 0; i < Alen; i++ ) { $2[i] = (char *) PyArray_DATA( tmp ) + i * PyArray_STRIDES( tmp )[0]; @@ -719,6 +722,11 @@ static PLcGrid tmpGrid1; static PLcGrid2 tmpGrid2; + PLcGrid* marshal_PLcGrid1( PyObject* input, int isimg ); + void cleanup_PLcGrid1( void ); + PLcGrid2* marshal_PLcGrid2( PyObject* input, int isimg ); + void cleanup_PLcGrid2( void ); + PLcGrid* marshal_PLcGrid1( PyObject* input, int isimg ) { // fprintf(stderr, "marshal PLcGrid1\n"); @@ -736,8 +744,8 @@ PyErr_SetString( PyExc_ValueError, "Expected a sequence to two 1D arrays." ); return NULL; } - tmpGrid1.nx = PyArray_DIMS( pltr_xg )[0]; - tmpGrid1.ny = PyArray_DIMS( pltr_yg )[0]; + tmpGrid1.nx = ( PLINT ) PyArray_DIMS( pltr_xg )[0]; + tmpGrid1.ny = ( PLINT ) PyArray_DIMS( pltr_yg )[0]; if ( isimg == 0 ) { if ( Xlen != tmpGrid1.nx || Ylen != tmpGrid1.ny ) @@ -790,8 +798,8 @@ PyErr_SetString( PyExc_ValueError, "Arrays must be same size." ); return NULL; } - tmpGrid2.nx = PyArray_DIMS( pltr_xg )[0]; - tmpGrid2.ny = PyArray_DIMS( pltr_xg )[1]; + tmpGrid2.nx = ( PLINT ) PyArray_DIMS( pltr_xg )[0]; + tmpGrid2.ny = ( PLINT ) PyArray_DIMS( pltr_xg )[1]; if ( isimg == 0 ) { if ( Xlen != tmpGrid2.nx || Ylen != tmpGrid2.ny ) @@ -809,10 +817,10 @@ } } size = tmpGrid2.ny; - tmpGrid2.xg = (PLFLT **) malloc( sizeof ( PLFLT* ) * tmpGrid2.nx ); + tmpGrid2.xg = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) tmpGrid2.nx ); for ( i = 0; i < tmpGrid2.nx; i++ ) tmpGrid2.xg[i] = ( (PLFLT *) PyArray_DATA( pltr_xg ) + i * size ); - tmpGrid2.yg = (PLFLT **) malloc( sizeof ( PLFLT* ) * tmpGrid2.nx ); + tmpGrid2.yg = (PLFLT **) malloc( sizeof ( PLFLT* ) * ( size_t ) tmpGrid2.nx ); for ( i = 0; i < tmpGrid2.nx; i++ ) tmpGrid2.yg[i] = ( (PLFLT *) PyArray_DATA( pltr_yg ) + i * size ); return &tmpGrid2; @@ -920,6 +928,22 @@ #define MY_UNBLOCK_THREADS #endif +// Function prototypes + void do_pltr_callback( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer data ); + PLFLT do_f2eval_callback( PLINT x, PLINT y, PLPointer data ); + void do_label_callback( PLINT axis, PLFLT value, char *string, PLINT len, PLPointer data ); + void do_ct_callback( PLFLT x, PLFLT y, PLFLT *xt, PLFLT *yt, PLPointer data ); + void do_mapform_callback( PLINT n, PLFLT *x, PLFLT *y ); + pltr_func marshal_pltr( PyObject* input ); + void cleanup_pltr( void ); + ct_func marshal_ct( PyObject* input ); + void cleanup_ct( void ); + mapform_func marshal_mapform( PyObject* input ); + void cleanup_mapform( void ); + PLPointer marshal_PLPointer( PyObject* input, int isimg ); + void cleanup_PLPointer( void ); + + // This is the callback that gets handed to the C code. It, in turn, calls the Python callback void do_pltr_callback( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer data ) @@ -1026,7 +1050,6 @@ { PyObject *pdata, *arglist, *result; char *pystring; - PLFLT fresult = 0.0; // the data argument is acutally a pointer to a python object if ( data ) @@ -1500,7 +1523,7 @@ } tmp = PyList_Size( $input ); $1 = &tmp; - $2 = (char **) malloc( ( tmp + 1 ) * sizeof ( char * ) ); + $2 = (char **) malloc( ( size_t ) ( tmp + 1 ) * sizeof ( char * ) ); for ( i = 0; i < tmp; i++ ) { PyObject *s = PyList_GetItem( $input, i ); Modified: trunk/drivers/xfig.c =================================================================== --- trunk/drivers/xfig.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/drivers/xfig.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -123,7 +123,7 @@ dev = (xfig_Dev *) pls->dev; - dev->curwid = pls->width < 1 ? 1 : pls->width; + dev->curwid = pls->width < 1 ? 1 : (int) pls->width; dev->firstline = 1; dev->xold = PL_UNDEFINED; @@ -390,7 +390,7 @@ case PLSTATE_WIDTH: flushbuffer( pls ); dev->firstline = 1; - dev->curwid = pls->width < 1 ? 1 : pls->width; + dev->curwid = pls->width < 1 ? 1 : (int) pls->width; break; case PLSTATE_COLOR0: Modified: trunk/examples/c/x33c.c =================================================================== --- trunk/examples/c/x33c.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/c/x33c.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -257,7 +257,7 @@ 15, 1, 1, low_cap_color, high_cap_color, cont_color, cont_width, - n_labels, label_opts, (const char **) &label, + n_labels, label_opts, (const char * const *) &label, n_axes, axis_opts, ticks, sub_ticks, n_values_array, (const PLFLT * const *) values_array ); Modified: trunk/examples/c++/x16.cc =================================================================== --- trunk/examples/c++/x16.cc 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/c++/x16.cc 2013-10-24 23:01:26 UTC (rev 12626) @@ -168,7 +168,6 @@ PLINT axis_subticks[NUM_AXES] = { 0, }; - PLFLT filler_values[2] = { 0.0, 1.0 }; #define NUM_LABELS 1 PLINT n_labels = NUM_LABELS; PLINT label_opts[] = { Modified: trunk/examples/f95/x00f.f90 =================================================================== --- trunk/examples/f95/x00f.f90 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/f95/x00f.f90 2013-10-24 23:01:26 UTC (rev 12626) @@ -28,7 +28,7 @@ real(kind=plflt), dimension(NSIZE) :: x, y real(kind=plflt) :: xmin = 0._plflt, xmax = 1._plflt, ymin = 0._plflt, ymax = 100._plflt - integer :: i + ! integer :: i ! Prepare data to be plotted. x = arange(0, NSIZE) / real(NSIZE-1,plflt) Modified: trunk/examples/f95/x09f.f90 =================================================================== --- trunk/examples/f95/x09f.f90 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/f95/x09f.f90 2013-10-24 23:01:26 UTC (rev 12626) @@ -149,7 +149,7 @@ integer :: i,j real(kind=plflt) :: xg(xdim, ydim), yg(xdim, ydim), & z(xdim, ydim), px(PERIMETERPTS), py(PERIMETERPTS), & - lev(NLEVEL), t, r, theta, delta + lev(NLEVEL), r, theta, delta call plenv(-1._plflt, 1._plflt, -1._plflt, 1._plflt, 0, -2) call plcol0(1) Modified: trunk/examples/f95/x27f.f90 =================================================================== --- trunk/examples/f95/x27f.f90 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/f95/x27f.f90 2013-10-24 23:01:26 UTC (rev 12626) @@ -173,6 +173,12 @@ n = windings*steps+1 + ! Initialize variables to prevent compiler warnings + xmin = 0.0 + xmax = 0.0 + ymin = 0.0 + ymax = 0.0 + do i = 1,n phi = dble(i-1) * dphi phiw = (params(1)-params(2))/params(2)*phi Modified: trunk/examples/f95/x33f.f90 =================================================================== --- trunk/examples/f95/x33f.f90 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/examples/f95/x33f.f90 2013-10-24 23:01:26 UTC (rev 12626) @@ -748,9 +748,7 @@ integer :: sub_ticks(1) real(kind=plflt) :: low_cap_color, high_cap_color logical :: vertical, ifn - integer, parameter :: n_axes = 1 character(len=20) :: axis_opts(1) - integer, parameter :: n_labels = 1 integer :: label_opts(1) character(len=200) :: labels(1) character(len=200) :: title Modified: trunk/src/plfreetype.c =================================================================== --- trunk/src/plfreetype.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/src/plfreetype.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -225,7 +225,7 @@ { // FCI in text stream; change font accordingly. FT_SetFace( pls, text[i] ); - *yy = FT->face->size->metrics.height > -*yy ? -FT->face->size->metrics.height : *yy; + *yy = (int) (FT->face->size->metrics.height > -*yy ? -FT->face->size->metrics.height : *yy); } else { Modified: trunk/src/plmap.c =================================================================== --- trunk/src/plmap.c 2013-10-24 18:54:19 UTC (rev 12625) +++ trunk/src/plmap.c 2013-10-24 23:01:26 UTC (rev 12626) @@ -169,8 +169,8 @@ } #endif - bufx = malloc( ncopies * sizeof ( PLFLT* ) ); - bufy = malloc( ncopies * sizeof ( PLFLT* ) ); + bufx = malloc( ( size_t ) ncopies * sizeof ( PLFLT* ) ); + bufy = malloc( ( size_t ) ncopies * sizeof ( PLFLT* ) ); for ( i = 0; i < ncopies; i++ ) { bufx[i] = NULL; @@ -206,8 +206,8 @@ free( bufx[i] ); if ( bufy[i] ) free( bufy[i] ); - bufx[i] = malloc( bufsize * sizeof ( double ) ); - bufy[i] = malloc( bufsize * sizeof ( double ) ); + bufx[i] = malloc( ( size_t ) bufsize * sizeof ( double ) ); + bufy[i] = malloc( ( size_t ) bufsize * sizeof ( double ) ); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-24 18:54:22
|
Revision: 12625 http://sourceforge.net/p/plplot/code/12625 Author: airwin Date: 2013-10-24 18:54:19 +0000 (Thu, 24 Oct 2013) Log Message: ----------- Set some variables to quiet false-alarm warnings from -O3 -Wuninitialized. Modified Paths: -------------- trunk/src/plbox.c trunk/src/pldtik.c trunk/src/plmap.c Modified: trunk/src/plbox.c =================================================================== --- trunk/src/plbox.c 2013-10-24 18:22:29 UTC (rev 12624) +++ trunk/src/plbox.c 2013-10-24 18:54:19 UTC (rev 12625) @@ -1394,7 +1394,7 @@ PLBOOL ldy, lfy, liy, lly, lmy, lny, lty, lvy, loy, lxy; PLFLT vpwxmi, vpwxma, vpwymi, vpwyma; PLFLT vpwxmin, vpwxmax, vpwymin, vpwymax; - PLFLT pos, tn, tp, offset, height, just; + PLFLT tn, tp, offset; PLFLT factor, tstart; const char *timefmt = NULL; PLFLT default_mm, char_height_mm, height_mm; @@ -1404,6 +1404,12 @@ // label function is provided. PLBOOL custom_exponent_placement = !plsc->label_func && plsc->label_data; + // pos, height, and just are unnecessarily set to quiet + // -O3 -Wuninitialized warnings that are obvious false alarms from + // the clarity of the code associated with the true or false + // result for custom_exponent_placement. + PLFLT pos = 0.0, height = 0.0, just = 0.0; + plgchr( &default_mm, &char_height_mm ); // Set plot options from input @@ -1880,7 +1886,7 @@ PLBOOL ldy, lfy, liy, lly, lmy, lny, lty, lvy, loy, lxy; PLFLT vpwxmi, vpwxma, vpwymi, vpwyma; PLFLT vpwxmin, vpwxmax, vpwymin, vpwymax; - PLFLT pos, tn, offset, height, just; + PLFLT tn, offset; const char *timefmt; PLINT i; PLINT xdigmax, xdigits, xdigmax_old, xdigits_old; @@ -1894,6 +1900,12 @@ // label function is provided. PLBOOL custom_exponent_placement = !plsc->label_func && plsc->label_data; + // pos, height, and just are unnecessarily set to quiet + // -O3 -Wuninitialized warnings that are obvious false alarms from + // the clarity of the code associated with the true or false + // result for custom_exponent_placement. + PLFLT pos = 0.0, height = 0.0, just = 0.0; + plgchr( &default_mm, &char_height_mm ); // Save some parameters Modified: trunk/src/pldtik.c =================================================================== --- trunk/src/pldtik.c 2013-10-24 18:22:29 UTC (rev 12624) +++ trunk/src/pldtik.c 2013-10-24 18:54:19 UTC (rev 12625) @@ -39,7 +39,8 @@ { PLFLT t1, t2, tick_reasonable; PLINT np, ns; - PLFLT factor; + // Unnecessarily set factor to quiet -O3 -Wuninitialized warnings. + PLFLT factor = 0.0; if ( ld ) Modified: trunk/src/plmap.c =================================================================== --- trunk/src/plmap.c 2013-10-24 18:22:29 UTC (rev 12624) +++ trunk/src/plmap.c 2013-10-24 18:54:19 UTC (rev 12625) @@ -125,7 +125,8 @@ #ifdef HAVE_SHAPELIB SHPHandle in; int nentries; - int nparts; + // Unnecessarily set nparts to quiet -O3 -Wuninitialized warnings. + int nparts = 0; int entrynumber = 0; int partnumber = 0; int shapetype; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-24 18:22:33
|
Revision: 12624 http://sourceforge.net/p/plplot/code/12624 Author: airwin Date: 2013-10-24 18:22:29 +0000 (Thu, 24 Oct 2013) Log Message: ----------- Fix bug in logic which allowed uninitialized values (for height, pos, and just) for the fairly common case when label_func and label_data were non-NULL. Improve code clarity so it is obvious these values must be initialized by the code logic. N.B. the gcc options -O3 -Wunintialized found this bug, but the above fix does not quiet the warning message, i.e., this bug fix turns this warning about uninitialized variables into a false alarm. Modified Paths: -------------- trunk/src/plbox.c Modified: trunk/src/plbox.c =================================================================== --- trunk/src/plbox.c 2013-10-24 17:38:37 UTC (rev 12623) +++ trunk/src/plbox.c 2013-10-24 18:22:29 UTC (rev 12624) @@ -1400,6 +1400,10 @@ PLFLT default_mm, char_height_mm, height_mm; PLFLT string_length_mm = 0.0, pos_mm = 0.0; + // Assume label data is for placement of exponents if no custom + // label function is provided. + PLBOOL custom_exponent_placement = !plsc->label_func && plsc->label_data; + plgchr( &default_mm, &char_height_mm ); // Set plot options from input @@ -1526,9 +1530,7 @@ if ( !llx && !ldx && !lox && xmode ) { - // Assume label data is for placement of exponents if no custom - // label function is provided. - if ( !plsc->label_func && plsc->label_data ) + if ( custom_exponent_placement ) { height = ( (PLLabelDefaults *) plsc->label_data )->exp_label_disp; pos = ( (PLLabelDefaults *) plsc->label_data )->exp_label_pos; @@ -1770,7 +1772,7 @@ if ( !lly && !ldy && !loy && ymode ) { snprintf( string, STRING_LEN, "(x10#u%d#d)", (int) yscale ); - if ( !plsc->label_func && plsc->label_data ) + if ( custom_exponent_placement ) { height = ( (PLLabelDefaults *) plsc->label_data )->exp_label_disp; pos = ( (PLLabelDefaults *) plsc->label_data )->exp_label_pos; @@ -1787,7 +1789,7 @@ // Left axis exponent if ( lny ) { - if ( !plsc->label_data ) + if ( !custom_exponent_placement ) { height = 3.2; pos = 1.0 + offset; @@ -1825,7 +1827,7 @@ // Right axis exponent. if ( lmy ) { - if ( !plsc->label_data ) + if ( !custom_exponent_placement ) { height = 3.4; // Extra space for superscript pos = 1.0 + offset; @@ -1888,6 +1890,10 @@ PLFLT default_mm, char_height_mm, height_mm; PLFLT string_length_mm = 0.0, pos_mm = 0.0; + // Assume label data is for placement of exponents if no custom + // label function is provided. + PLBOOL custom_exponent_placement = !plsc->label_func && plsc->label_data; + plgchr( &default_mm, &char_height_mm ); // Save some parameters @@ -2068,9 +2074,7 @@ if ( !llx && !ldx && !lox && xmode ) { - // Assume label data is for placement of exponents if no custom - // label function is provided. - if ( !plsc->label_func && plsc->label_data ) + if ( custom_exponent_placement ) { height = ( (PLLabelDefaults *) plsc->label_data )->exp_label_disp; pos = ( (PLLabelDefaults *) plsc->label_data )->exp_label_pos; @@ -2326,7 +2330,7 @@ if ( !lly && !ldy && !loy && ymode ) { snprintf( string, STRING_LEN, "(x10#u%d#d)", (int) yscale ); - if ( !plsc->label_func && plsc->label_data ) + if ( custom_exponent_placement ) { height = ( (PLLabelDefaults *) plsc->label_data )->exp_label_disp; pos = ( (PLLabelDefaults *) plsc->label_data )->exp_label_pos; @@ -2343,7 +2347,7 @@ // Left axis exponent. if ( lny ) { - if ( !plsc->label_data ) + if ( !custom_exponent_placement ) { height = 3.2; pos = 1.0 + offset; @@ -2381,7 +2385,7 @@ // Right axis exponent. if ( lmy ) { - if ( !plsc->label_data ) + if ( !custom_exponent_placement ) { height = 3.4; // Extra space for superscript pos = 1.0 + offset; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-24 17:38:41
|
Revision: 12623 http://sourceforge.net/p/plplot/code/12623 Author: airwin Date: 2013-10-24 17:38:37 +0000 (Thu, 24 Oct 2013) Log Message: ----------- Style previous commit. Modified Paths: -------------- trunk/bindings/python/plplotcmodule.i Modified: trunk/bindings/python/plplotcmodule.i =================================================================== --- trunk/bindings/python/plplotcmodule.i 2013-10-23 19:27:05 UTC (rev 12622) +++ trunk/bindings/python/plplotcmodule.i 2013-10-24 17:38:37 UTC (rev 12623) @@ -1470,7 +1470,8 @@ return NULL; } tmp = (char **) malloc( sizeof ( char* ) * 4 ); - if ( tmp == NULL ) return NULL; + if ( tmp == NULL ) + return NULL; $1 = tmp; for ( i = 0; i < 4; i++ ) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-23 19:27:09
|
Revision: 12622 http://sourceforge.net/p/plplot/code/12622 Author: airwin Date: 2013-10-23 19:27:05 +0000 (Wed, 23 Oct 2013) Log Message: ----------- NUMERIC_INCLUDE_PATH ==> NUMPY_INCLUDE_PATH We have dropped support for the Numeric Python module and are now exclusively using the numpy Python modules instead. Therefore, have changed the CMake variable name used in our build system that holds the location of the numpy headers from the confusing misnomer, NUMERIC_INCLUDE_PATH, to NUMPY_INCLUDE_PATH. I have also taken this opportunity to simplify our numpy-related build system logic, e.g., by dropping CMake variables that were not being used anywhere. This change only impacts PLplot users who in the past have used the cmake option -DNUMERIC_INCLUDE_PATH to set the CMake variable NUMERIC_INCLUDE_PATH to the location of the numpy header directory. Note we discourage that method since without that user intervention, the build system uses python and numpy to find the location which should normally be foolproof and not subject to the inconsistencies or errors possible with setting the variable. But if some users still insist on setting the variable, that variable's name should now be NUMPY_INCLUDE_PATH. Modified Paths: -------------- trunk/README.release trunk/bindings/gnome2/python/CMakeLists.txt trunk/bindings/python/CMakeLists.txt trunk/cmake/modules/python.cmake trunk/cmake/modules/summary.cmake trunk/config.h.in trunk/plplot_test/CMakeLists.txt trunk/plplot_test/test_python.sh.in Modified: trunk/README.release =================================================================== --- trunk/README.release 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/README.release 2013-10-23 19:27:05 UTC (rev 12622) @@ -23,6 +23,8 @@ 3. Changes relative to PLplot 5.9.10 (the previous development release) +3.1 NUMERIC_INCLUDE_PATH ==> NUMPY_INCLUDE_PATH + 4. OFFICIAL NOTICES FOR USERS SINCE 5.8.0 (the previous stable release) 5. Changes relative to PLplot 5.8.0 (the previous stable release) @@ -99,6 +101,7 @@ all non-windows systems 5.65 Update f95 examples to take larger advantage of Fortran 95 capabilities 5.66 Substantial additions to the doxygen documentation +5.67 NUMERIC_INCLUDE_PATH ==> NUMPY_INCLUDE_PATH 1. OFFICIAL NOTICES FOR USERS SINCE 5.9.10 (the previous development release) @@ -110,8 +113,22 @@ 3. Changes relative to PLplot 5.9.10 (the previous development release) -None at this time. +3.1 NUMERIC_INCLUDE_PATH ==> NUMPY_INCLUDE_PATH +We have long since dropped support for the Numeric Python module and +are now exclusively using the numpy Python modules instead. +Therefore, we have changed the CMake variable name used in our build +system that holds the location of the numpy headers from the confusing +misnomer, NUMERIC_INCLUDE_PATH, to NUMPY_INCLUDE_PATH. This change +only impacts PLplot users who in the past have used the cmake option +-DNUMERIC_INCLUDE_PATH to set the CMake variable NUMERIC_INCLUDE_PATH +to the location of the numpy header directory. Note we discourage +that method since without that user intervention, the build system +uses python and numpy to find the location which should normally be +foolproof and not subject to the inconsistencies or errors possible +with setting the variable. But if some users still insist on setting +the variable, that variable's name should now be NUMPY_INCLUDE_PATH. + 4. OFFICIAL NOTICES FOR USERS SINCE 5.8.0 (the previous stable release) (5.9.10) The minimum version of CMake has been bumped to 5.8.9. This @@ -1443,3 +1460,20 @@ documentation of every single argument of the public API for PLplot. A substantial increase in such documentation has been implemented in this release cycle. + +5.67 NUMERIC_INCLUDE_PATH ==> NUMPY_INCLUDE_PATH + +We have long since dropped support for the Numeric Python module and +are now exclusively using the numpy Python modules instead. +Therefore, we have changed the CMake variable name used in our build +system that holds the location of the numpy headers from the confusing +misnomer, NUMERIC_INCLUDE_PATH, to NUMPY_INCLUDE_PATH. This change +only impacts PLplot users who in the past have used the cmake option +-DNUMERIC_INCLUDE_PATH to set the CMake variable NUMERIC_INCLUDE_PATH +to the location of the numpy header directory. Note we discourage +that method since without that user intervention, the build system +uses python and numpy to find the location which should normally be +foolproof and not subject to the inconsistencies or errors possible +with setting the variable. But if some users still insist on setting +the variable, that variable's name should now be NUMPY_INCLUDE_PATH. + Modified: trunk/bindings/gnome2/python/CMakeLists.txt =================================================================== --- trunk/bindings/gnome2/python/CMakeLists.txt 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/bindings/gnome2/python/CMakeLists.txt 2013-10-23 19:27:05 UTC (rev 12622) @@ -115,7 +115,7 @@ ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ${PYTHON_INCLUDE_PATH} - ${NUMERIC_INCLUDE_PATH} + ${NUMPY_INCLUDE_PATH} ) ### Build and install the gcw module Modified: trunk/bindings/python/CMakeLists.txt =================================================================== --- trunk/bindings/python/CMakeLists.txt 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/bindings/python/CMakeLists.txt 2013-10-23 19:27:05 UTC (rev 12622) @@ -33,7 +33,7 @@ ${CMAKE_CURRENT_BINARY_DIR} ${TCL_INCLUDE_PATH} ${PYTHON_INCLUDE_PATH} - ${NUMERIC_INCLUDE_PATH} + ${NUMPY_INCLUDE_PATH} ${CMAKE_SOURCE_DIR}/bindings/swig-support ) else(ENABLE_tk) @@ -44,7 +44,7 @@ ${CMAKE_BINARY_DIR}/include ${CMAKE_CURRENT_BINARY_DIR} ${PYTHON_INCLUDE_PATH} - ${NUMERIC_INCLUDE_PATH} + ${NUMPY_INCLUDE_PATH} ${CMAKE_SOURCE_DIR}/bindings/swig-support ) endif(ENABLE_tk) Modified: trunk/cmake/modules/python.cmake =================================================================== --- trunk/cmake/modules/python.cmake 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/cmake/modules/python.cmake 2013-10-23 19:27:05 UTC (rev 12622) @@ -60,55 +60,46 @@ endif(NOT PYTHON_LIBRARIES OR NOT PYTHON_INCLUDE_PATH) endif(ENABLE_python) -option(HAVE_NUMPY "Have the numpy package" ON) - if(ENABLE_python) - # NUMERIC_INCLUDE_PATH = path to arrayobject.h for numpy. - #message(STATUS "DEBUG: NUMERIC_INCLUDE_PATH = ${NUMERIC_INCLUDE_PATH}") - if(NOT NUMERIC_INCLUDE_PATH) - if(HAVE_NUMPY) - # First check for new version of numpy - execute_process( - COMMAND - ${PYTHON_EXECUTABLE} -c "import numpy; print numpy.get_include()" - OUTPUT_VARIABLE NUMPY_INCLUDE_PATH - RESULT_VARIABLE NUMPY_ERR - OUTPUT_STRIP_TRAILING_WHITESPACE - ) - if(NUMPY_ERR) - set(HAVE_NUMPY OFF CACHE BOOL "Have the numpy package" FORCE) - endif(NUMPY_ERR) - endif(HAVE_NUMPY) - - if(HAVE_NUMPY) + # NUMPY_INCLUDE_PATH = path to arrayobject.h for numpy. + #message(STATUS "DEBUG: NUMPY_INCLUDE_PATH = ${NUMPY_INCLUDE_PATH}") + if(NOT NUMPY_INCLUDE_PATH) + # Check for numpy installation. + execute_process( + COMMAND + ${PYTHON_EXECUTABLE} -c "import numpy; print numpy.get_include()" + OUTPUT_VARIABLE NUMPY_INCLUDE_PATH_PARENT + RESULT_VARIABLE NUMPY_ERR + OUTPUT_STRIP_TRAILING_WHITESPACE + ) + if(NUMPY_ERR) + set(NUMPY_INCLUDE_PATH) + else(NUMPY_ERR) # We use the full path name (including numpy on the end), but # Double-check that all is well with that choice. find_path( - NUMERIC_INCLUDE_PATH + NUMPY_INCLUDE_PATH arrayobject.h - ${NUMPY_INCLUDE_PATH}/numpy + ${NUMPY_INCLUDE_PATH_PARENT}/numpy ) - if(NUMERIC_INCLUDE_PATH) - set(PYTHON_NUMERIC_NAME numpy CACHE INTERNAL "") - endif(NUMERIC_INCLUDE_PATH) - endif(HAVE_NUMPY) + endif(NUMPY_ERR) - endif(NOT NUMERIC_INCLUDE_PATH) + endif(NOT NUMPY_INCLUDE_PATH) - if(NOT NUMERIC_INCLUDE_PATH) + if(NOT NUMPY_INCLUDE_PATH) message(STATUS "WARNING: " "NumPy header not found. Disabling Python bindings") set(ENABLE_python OFF CACHE BOOL "Enable Python bindings" FORCE) - endif(NOT NUMERIC_INCLUDE_PATH) + endif(NOT NUMPY_INCLUDE_PATH) endif(ENABLE_python) -if(ENABLE_python AND HAVE_NUMPY) +if(ENABLE_python) # This numpy installation bug found by Geoff. option(EXCLUDE_PYTHON_LIBRARIES "Linux temporary workaround for numpy installation bug for non-system Python install prefix" OFF) if(EXCLUDE_PYTHON_LIBRARIES) set(PYTHON_LIBRARIES) endif(EXCLUDE_PYTHON_LIBRARIES) -endif(ENABLE_python AND HAVE_NUMPY) +endif(ENABLE_python) if(ENABLE_python) # if CMAKE_INSTALL_EXEC_PREFIX is an empty string, must replace Modified: trunk/cmake/modules/summary.cmake =================================================================== --- trunk/cmake/modules/summary.cmake 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/cmake/modules/summary.cmake 2013-10-23 19:27:05 UTC (rev 12622) @@ -89,7 +89,7 @@ PYTHON_EXECUTABLE: ${PYTHON_EXECUTABLE} PYTHON_INCLUDE_PATH: ${PYTHON_INCLUDE_PATH} PYTHON_LIBRARIES: ${PYTHON_LIBRARIES} -NUMERIC_INCLUDE_PATH: ${NUMERIC_INCLUDE_PATH}") +NUMPY_INCLUDE_PATH: ${NUMPY_INCLUDE_PATH}") endif(ENABLE_python) set( Modified: trunk/config.h.in =================================================================== --- trunk/config.h.in 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/config.h.in 2013-10-23 19:27:05 UTC (rev 12622) @@ -112,9 +112,6 @@ // Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. #cmakedefine HAVE_NDIR_H 1 -// Define if python numpy is available -#cmakedefine HAVE_NUMPY - // Define if libpango is available #cmakedefine HAVE_PANGO Modified: trunk/plplot_test/CMakeLists.txt =================================================================== --- trunk/plplot_test/CMakeLists.txt 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/plplot_test/CMakeLists.txt 2013-10-23 19:27:05 UTC (rev 12622) @@ -170,12 +170,6 @@ endif(ENABLE_octave) if(ENABLE_python) - if(HAVE_NUMPY) - # The following examples only work with numpy - set(NUMPY_EXAMPLES "21") - else(HAVE_NUMPY) - set(NUMPY_EXAMPLES) - endif(HAVE_NUMPY) configure_file( test_python.sh.in ${CMAKE_CURRENT_BINARY_DIR}/test_python.sh Modified: trunk/plplot_test/test_python.sh.in =================================================================== --- trunk/plplot_test/test_python.sh.in 2013-10-23 08:46:57 UTC (rev 12621) +++ trunk/plplot_test/test_python.sh.in 2013-10-23 19:27:05 UTC (rev 12622) @@ -30,7 +30,7 @@ # For 24 you need special fonts installed to get good result. lang="p" for index in 00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 \ - 20 22 23 24 25 26 27 28 29 30 31 33 @NUMPY_EXAMPLES@ ; do + 20 21 22 23 24 25 26 27 28 29 30 31 33 ; do if [ "$verbose_test" ] ; then echo "x${index}" fi This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <and...@us...> - 2013-10-23 08:47:00
|
Revision: 12621 http://sourceforge.net/p/plplot/code/12621 Author: andrewross Date: 2013-10-23 08:46:57 +0000 (Wed, 23 Oct 2013) Log Message: ----------- If CMAKE_INSTALL_PREFIX is different to the prefix used to install octave, then make sure .oct files go in ${CMAKE_INSTALL_LIBDIR}/octave , i.e. in a library directory rather than a data directory. They are binary files so should not live under CMAKE_INSTALL_DATADIR. Modified Paths: -------------- trunk/cmake/modules/octave.cmake Modified: trunk/cmake/modules/octave.cmake =================================================================== --- trunk/cmake/modules/octave.cmake 2013-10-23 06:04:04 UTC (rev 12620) +++ trunk/cmake/modules/octave.cmake 2013-10-23 08:46:57 UTC (rev 12621) @@ -277,7 +277,7 @@ # Transform OCTAVE_OCT_DIR if prefixes not the same. if(NOT CMAKE_INSTALL_PREFIX STREQUAL "${OCTAVE_PREFIX}") - set(OCTAVE_OCT_DIR ${PLPLOT_OCTAVE_DIR}) + set(OCTAVE_OCT_DIR ${CMAKE_INSTALL_LIBDIR}/octave) endif(NOT CMAKE_INSTALL_PREFIX STREQUAL "${OCTAVE_PREFIX}") message(STATUS "OCTAVE_OCT_DIR = ${OCTAVE_OCT_DIR}") This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-23 06:04:10
|
Revision: 12620 http://sourceforge.net/p/plplot/code/12620 Author: airwin Date: 2013-10-23 06:04:04 +0000 (Wed, 23 Oct 2013) Log Message: ----------- Update documentation based on a new name (removed_configured.patch) and different purpose (remove a configured file) for one of the patch files that makes another patch file (missing_zlib_headers.patch) redundant and therefore removed. Modified Paths: -------------- trunk/cmake/build_projects/libharu/README.libharu Modified: trunk/cmake/build_projects/libharu/README.libharu =================================================================== --- trunk/cmake/build_projects/libharu/README.libharu 2013-10-23 05:54:35 UTC (rev 12619) +++ trunk/cmake/build_projects/libharu/README.libharu 2013-10-23 06:04:04 UTC (rev 12620) @@ -12,7 +12,7 @@ bp.cmake Improved build system (Werner's build system culled from the -git version of libharu with additional improvements by me): +git version of libharu in 2010 or so with additional improvements by me): cmake.patch @@ -24,9 +24,14 @@ visibility.patch -Bug fix for the case where zlib is not available. +This patch is to remove a configured file from the tarball that made a +build with a separate build tree impossible since it's name was the +same as the configured file include/hpdf_config.h in the build tree, +but its location in the source tree took precedence in the header +search path thus incorrectly imposing the configuration of the +computer that created the tarball. -missing_zlib_headers.patch +remove_configured.patch (1) Patch a pre-existing freshly unpacked version of libharu-2.2.1, with these patches, e.g., @@ -34,7 +39,7 @@ patch -d /home/software/libharu/libharu-2.2.1 -p1 < cmake.patch patch -d /home/software/libharu/libharu-2.2.1 -p1 < large_font.patch patch -d /home/software/libharu/libharu-2.2.1 -p1 < visibility.patch -patch -d /home/software/libharu/libharu-2.2.1 -p1 < missing_zlib_headers.patch +patch -d /home/software/libharu/libharu-2.2.1 -p1 < remove_configured.patch (2) configure, build, and install libharu starting with an empty build tree and empty install tree, e.g., This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-23 05:54:38
|
Revision: 12619 http://sourceforge.net/p/plplot/code/12619 Author: airwin Date: 2013-10-23 05:54:35 +0000 (Wed, 23 Oct 2013) Log Message: ----------- Get rid of another file that is no longer used with the new patch approach. Removed Paths: ------------- trunk/cmake/build_projects/libharu/CMakeLists.txt Deleted: trunk/cmake/build_projects/libharu/CMakeLists.txt =================================================================== --- trunk/cmake/build_projects/libharu/CMakeLists.txt 2013-10-23 02:42:08 UTC (rev 12618) +++ trunk/cmake/build_projects/libharu/CMakeLists.txt 2013-10-23 05:54:35 UTC (rev 12619) @@ -1,216 +0,0 @@ -# CMakeLists.txt -# -# Copyright (C) 2008 Werner Smekal -# Copyright (C) 2010 Alan W. Irwin -# -# This software is provided 'as-is', without any express or implied warranty. -# -# In no event will the authors be held liable for any damages arising from the -# use of this software. -# -# Permission is granted to anyone to use this software for any purpose,including -# commercial applications, and to alter it and redistribute it freely, subject -# to the following restrictions: -# -# 1. The origin of this software must not be misrepresented; you must not claim -# that you wrote the original software. If you use this software in a -# product, an acknowledgment in the product documentation would be -# appreciated but is not required. -# 2. Altered source versions must be plainly marked as such, and must not be -# misrepresented as being the original software. -# 3. This notice may not be removed or altered from any source distribution. -# -# Process this file with cmake to produce Makefiles or project files -# for your specific compiler tool set -# -# TODO: -# - shared and static library -# - packaging -# - devpackage -# ======================================================================= -# libharu project -# ======================================================================= -project(libharu C) - -# we want cmake version 2.4.8 at least -cmake_minimum_required(VERSION 2.4.8 FATAL_ERROR) - -# Location where the haru cmake build system first looks for cmake modules -set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules) - -# determine compiler name -set(COMPILER_LABEL "unknown") -if(CMAKE_COMPILER_IS_GNUCC) - set(COMPILER_LABEL "gcc") -endif(CMAKE_COMPILER_IS_GNUCC) -if(MSVC) - set(COMPILER_LABEL "vc") -endif(MSVC) - -### Version information for libharu software package. -### N.B. Needs review before each release! -set(LIBHARU_MAJOR 2) -set(LIBHARU_MINOR 2) -set(LIBHARU_PATCH 0) -set(LIBHARU_VERSION ${LIBHARU_MAJOR}.${LIBHARU_MINOR}.${LIBHARU_PATCH}) -# libhpdf library version information. -# N.B. Not to be confused with package version set above! - -# Rules: -# (1) If a backwards incompatible API change has been made in the library -# API (e.g., if old compiled and linked applications will no longer work) -# then increment SOVERSION and zero the corresponding minor and patch -# numbers just before release. -# (2) If the library changes are limited to additions to the API, then -# then leave SOVERSION alone, increment the minor number and zero the -# patch number just before release. -# (3) If the library changes are limited to implementation changes with -# no API changes at all, then leave SOVERSION and minor number alone, and -# increment the patch number just before the release. -# (4) If there are no library source code changes at all, then leave all -# library version numbers the same for the release. -# If library has not been properly versioned before start the numbering -# at 0.0.0. -set(hpdf_SOVERSION 0) -set(hpdf_VERSION ${hpdf_SOVERSION}.0.0) -### End of version information to be reviewed. - -# Use RPATH? -if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") - # No rpath on Darwin. Setting it will only cause trouble. -else(CMAKE_SYSTEM_NAME STREQUAL "Darwin") - option(USE_RPATH "Use -rpath when linking libraries, executables" ON) -endif(CMAKE_SYSTEM_NAME STREQUAL "Darwin") - -# Description of libharu for cpack. -set(LIBHARU_DESCRIPTION "libHaru is a free, cross platform, open source library for generating PDF files.") -set(LIBHARU_PACKAGE_NAME "libHaru-${LIBHARU_VERSION}-${COMPILER_LABEL}") - -# Comment out all this name stuff which I feel is probably unnecessary (since -# PLplot doesn't bother with this.) -# set library name, msvc does not prepend 'lib' automatically -#if(MSVC) -# set(LIBHARU_NAME lib) -#endif(MSVC) -#set(LIBHARU_NAME ${LIBHARU_NAME}hpdf) -#set(LIBHARU_NAME_STATIC ${LIBHARU_NAME}s) - -# ======================================================================= -# command line options -# ======================================================================= -option(LIBHARU_SHARED "Build shared lib" YES) -option(LIBHARU_STATIC "Build static lib" YES) -option(LIBHARU_EXAMPLES "Build libharu examples" NO) -option(DEVPAK "Create DevPackage" NO) - -if(DEVPAK AND NOT WIN32) - message( STATUS "DevPackage only available for Win32. Set DEVPAK to OFF." ) - set(DEVPAK OFF) -endif(DEVPAK AND NOT WIN32) -if(DEVPAK AND LIBHARU_EXAMPLES) - message( STATUS "Examples are not build for DevPackage. Set LIBHARU_EXAMPLES to OFF." ) - set(LIBHARU_EXAMPLES OFF) -endif(DEVPAK AND LIBHARU_EXAMPLES) - - - -if(BUILD_SHARED_LIBS) - set(LIBHARU_SHARED ON) -endif(BUILD_SHARED_LIBS) - -# ======================================================================= -# look for headers and libraries -# ======================================================================= -include(haru) -include(summary) - -set(ADDITIONAL_LIBRARIES ${MATH_LIB}) -# check zlib availibility -find_package(ZLIB) -if(ZLIB_FOUND) - set(HAVE_LIBZ ON) - include_directories(${ZLIB_INCLUDE_DIR}) - list(APPEND ADDITIONAL_LIBRARIES ${ZLIB_LIBRARIES}) -else(ZLIB_FOUND) - set(HPDF_NOZLIB ON) -endif(ZLIB_FOUND) - -# check png availibility -find_package(PNG) -if(PNG_FOUND) - set(HAVE_LIBPNG ON) - include_directories(${PNG_INCLUDE_DIR}) - add_definitions(${PNG_DEFINITIONS}) - list(APPEND ADDITIONAL_LIBRARIES ${PNG_LIBRARIES}) -else(PNG_FOUND) - set(HPDF_NOPNGLIB ON) -endif(PNG_FOUND) - -# ======================================================================= -# Add compiler flags -# ======================================================================= -# add definitions and directories to include -#if(CMAKE_COMPILER_IS_GNUCC) -# add_definitions("-Wall") -#endif(CMAKE_COMPILER_IS_GNUCC) -if(MSVC_VERSION GREATER 1399) - add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_DEPRECATE) -endif(MSVC_VERSION GREATER 1399) -include_directories(${CMAKE_SOURCE_DIR}/include) -include_directories(${CMAKE_BINARY_DIR}/include) - -# create DevPackage file -if(DEVPAK) - configure_file( - ${CMAKE_SOURCE_DIR}/libharu.DevPackage.cmake - ${CMAKE_BINARY_DIR}/libharu.DevPackage - ) -endif(DEVPAK) - -# ======================================================================= -# Configure and install header files. -# ======================================================================= -add_subdirectory(include) - -# ======================================================================= -# create library and demos -# ======================================================================= -add_subdirectory(src) -add_subdirectory(demo) - -# install various files -# These commented out to keep install tree as lean as possible. May want -# to add some documentation files later to the install tree. -#install(FILES README CHANGES INSTALL DESTINATION .) -#install(DIRECTORY doc DESTINATION .) -#if(NOT DEVPAK) -# install(DIRECTORY if DESTINATION .) -#endif(NOT DEVPAK) -#if(DEVPAK) -# install(FILES ${CMAKE_BINARY_DIR}/libharu.DevPackage DESTINATION .) -#endif(DEVPAK) -# ======================================================================= -# print out some information -# ======================================================================= -summary() - -# ======================================================================= -# packing stuff -# ======================================================================= -set(CPACK_PACKAGE_DESCRIPTION_SUMMARY ${LIBHARU_DESCRIPTION}) -set(CPACK_PACKAGE_VENDOR "Werner Smekal") -set(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_CURRENT_SOURCE_DIR}/README) -set(CPACK_PACKAGE_VERSION_MAJOR "${LIBHARU_MAJOR}") -set(CPACK_PACKAGE_VERSION_MINOR "${LIBHARU_MINOR}") -set(CPACK_PACKAGE_VERSION_PATCH "${LIBHARU_PATCH}") -set(CPACK_PACKAGE_FILE_NAME "libHaru-${LIBHARU_VERSION}-${COMPILER_LABEL}") - -set(CPACK_STRIP_FILES ON) - -if(WIN32) - set(CPACK_GENERATOR ZIP) -else(WIN32) - set(CPACK_GENERATOR TGZ) -endif(WIN32) - -INCLUDE( CPack ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-23 02:42:11
|
Revision: 12618 http://sourceforge.net/p/plplot/code/12618 Author: airwin Date: 2013-10-23 02:42:08 +0000 (Wed, 23 Oct 2013) Log Message: ----------- Update libharu-2.2.1 build configuration so that it works on both Linux and MinGW/MSYS. Tested by Alan W. Irwin <ai...@us...> using the build_plplot_lite target of the build_projects project on both Linux and MinGW/MSYS/Wine. The PDF files resulting from the test_noninteractive target run as part of that build, look reasonable on both platforms and there were no obvious run-time errors. Modified Paths: -------------- trunk/cmake/build_projects/libharu/bp.cmake trunk/cmake/build_projects/libharu/cmake.patch Added Paths: ----------- trunk/cmake/build_projects/libharu/remove_configured.patch Removed Paths: ------------- trunk/cmake/build_projects/libharu/missing_zlib_headers.patch Modified: trunk/cmake/build_projects/libharu/bp.cmake =================================================================== --- trunk/cmake/build_projects/libharu/bp.cmake 2013-10-22 17:47:13 UTC (rev 12617) +++ trunk/cmake/build_projects/libharu/bp.cmake 2013-10-23 02:42:08 UTC (rev 12618) @@ -62,12 +62,12 @@ COMMAND ${CMAKE_COMMAND} -E echo "Apply all patches" COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/cmake.patch COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/large_font.patch - COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/missing_zlib_headers.patch + COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/remove_configured.patch COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/visibility.patch DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/cmake.patch ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/large_font.patch - ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/missing_zlib_headers.patch + ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/remove_configured.patch ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/visibility.patch APPEND ) Modified: trunk/cmake/build_projects/libharu/cmake.patch =================================================================== --- trunk/cmake/build_projects/libharu/cmake.patch 2013-10-22 17:47:13 UTC (rev 12617) +++ trunk/cmake/build_projects/libharu/cmake.patch 2013-10-23 02:42:08 UTC (rev 12618) @@ -1,6 +1,6 @@ diff -Naur libharu-2.2.1_pristine/CMakeLists.txt libharu-2.2.1/CMakeLists.txt --- libharu-2.2.1_pristine/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/CMakeLists.txt 2013-10-21 10:51:25.543121062 -0700 ++++ libharu-2.2.1/CMakeLists.txt 2013-10-22 15:55:30.205030236 -0700 @@ -0,0 +1,216 @@ +# CMakeLists.txt +# @@ -136,7 +136,7 @@ + include_directories(${ZLIB_INCLUDE_DIR}) + list(APPEND ADDITIONAL_LIBRARIES ${ZLIB_LIBRARIES}) +else(ZLIB_FOUND) -+ set(HPDF_NOZLIB ON) ++ set(LIBHPDF_HAVE_NOZLIB ON) +endif(ZLIB_FOUND) + +# check png availibility @@ -147,7 +147,7 @@ + add_definitions(${PNG_DEFINITIONS}) + list(APPEND ADDITIONAL_LIBRARIES ${PNG_LIBRARIES}) +else(PNG_FOUND) -+ set(HPDF_NOPNGLIB ON) ++ set(LIBHPDF_HAVE_NOPNGLIB ON) +endif(PNG_FOUND) + +# ======================================================================= @@ -220,7 +220,7 @@ +INCLUDE( CPack ) diff -Naur libharu-2.2.1_pristine/cmake/modules/haru.cmake libharu-2.2.1/cmake/modules/haru.cmake --- libharu-2.2.1_pristine/cmake/modules/haru.cmake 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/cmake/modules/haru.cmake 2013-10-21 10:52:11.838244974 -0700 ++++ libharu-2.2.1/cmake/modules/haru.cmake 2013-10-22 15:55:30.205030236 -0700 @@ -0,0 +1,54 @@ +# cmake/modules/haru.cmake +# @@ -278,7 +278,7 @@ +endif(NOT WIN32) diff -Naur libharu-2.2.1_pristine/cmake/modules/summary.cmake libharu-2.2.1/cmake/modules/summary.cmake --- libharu-2.2.1_pristine/cmake/modules/summary.cmake 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/cmake/modules/summary.cmake 2013-10-21 10:52:36.297782032 -0700 ++++ libharu-2.2.1/cmake/modules/summary.cmake 2013-10-22 15:55:30.213030083 -0700 @@ -0,0 +1,66 @@ +# cmake/modules/summary.cmake +# @@ -348,7 +348,7 @@ +endmacro(summary) diff -Naur libharu-2.2.1_pristine/demo/CMakeLists.txt libharu-2.2.1/demo/CMakeLists.txt --- libharu-2.2.1_pristine/demo/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/demo/CMakeLists.txt 2013-10-21 10:54:41.939403569 -0700 ++++ libharu-2.2.1/demo/CMakeLists.txt 2013-10-22 15:55:30.213030083 -0700 @@ -0,0 +1,183 @@ +# demo/CMakeLists.txt +# @@ -535,7 +535,7 @@ +endif(LIBHARU_EXAMPLES) diff -Naur libharu-2.2.1_pristine/include/CMakeLists.txt libharu-2.2.1/include/CMakeLists.txt --- libharu-2.2.1_pristine/include/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/include/CMakeLists.txt 2013-10-21 10:53:43.508509852 -0700 ++++ libharu-2.2.1/include/CMakeLists.txt 2013-10-22 15:55:30.213030083 -0700 @@ -0,0 +1,63 @@ +# include/CMakeLists.txt for libharu. +### @@ -602,8 +602,8 @@ +install(FILES ${include_INSTALLED_HEADERS} DESTINATION include/hpdf) diff -Naur libharu-2.2.1_pristine/include/hpdf_config.h.cmake libharu-2.2.1/include/hpdf_config.h.cmake --- libharu-2.2.1_pristine/include/hpdf_config.h.cmake 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/include/hpdf_config.h.cmake 2013-10-21 10:55:06.162944881 -0700 -@@ -0,0 +1,97 @@ ++++ libharu-2.2.1/include/hpdf_config.h.cmake 2013-10-22 15:56:31.771881667 -0700 +@@ -0,0 +1,91 @@ +/* + * Copyright (C) 2008 Werner Smekal + * Copyright (C) 2010 Alan W. Irwin @@ -637,12 +637,6 @@ +/* Define to 1 if you have the <inttypes.h> header file. */ +#cmakedefine LIBHPDF_HAVE_INTTYPES_H + -+/* Define to 1 if you have the `png' library (-lpng). */ -+#cmakedefine HAVE_LIBPNG -+ -+/* Define to 1 if you have the `z' library (-lz). */ -+#cmakedefine HAVE_LIBZ -+ +/* Define to 1 if you have the <memory.h> header file. */ +#cmakedefine LIBHPDF_HAVE_MEMORY_H + @@ -674,10 +668,10 @@ +#cmakedefine LIBHPDF_DEBUG_TRACE + +/* libpng is not available */ -+#cmakedefine HPDF_NOPNGLIB ++#cmakedefine LIBHPDF_HAVE_NOPNGLIB + +/* zlib is not available */ -+#cmakedefine HPDF_NOZLIB ++#cmakedefine LIBHPDF_HAVE_NOZLIB + +/* Define to the address where bug reports for this package should be sent. */ +#cmakedefine LIBHPDF_PACKAGE_BUGREPORT @@ -703,7 +697,7 @@ +#endif /* _HPDF_CONFIG_H */ diff -Naur libharu-2.2.1_pristine/src/CMakeLists.txt libharu-2.2.1/src/CMakeLists.txt --- libharu-2.2.1_pristine/src/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 -+++ libharu-2.2.1/src/CMakeLists.txt 2013-10-21 10:53:23.164894950 -0700 ++++ libharu-2.2.1/src/CMakeLists.txt 2013-10-22 15:55:30.213030083 -0700 @@ -0,0 +1,150 @@ +# src/CMakeLists.txt +# Deleted: trunk/cmake/build_projects/libharu/missing_zlib_headers.patch =================================================================== --- trunk/cmake/build_projects/libharu/missing_zlib_headers.patch 2013-10-22 17:47:13 UTC (rev 12617) +++ trunk/cmake/build_projects/libharu/missing_zlib_headers.patch 2013-10-23 02:42:08 UTC (rev 12618) @@ -1,11 +0,0 @@ -diff -Naur libharu-2.2.1_pristine/src/hpdf_streams.c libharu-2.2.1/src/hpdf_streams.c ---- libharu-2.2.1_pristine/src/hpdf_streams.c 2010-02-08 01:49:57.000000000 -0800 -+++ libharu-2.2.1/src/hpdf_streams.c 2013-10-21 11:47:12.026846086 -0700 -@@ -23,6 +23,7 @@ - #include "hpdf_consts.h" - #include "hpdf_utils.h" - #include "hpdf_streams.h" -+#include "hpdf_config.h" - - #ifndef LIBHPDF_HAVE_NOZLIB - #include <zlib.h> Added: trunk/cmake/build_projects/libharu/remove_configured.patch =================================================================== --- trunk/cmake/build_projects/libharu/remove_configured.patch (rev 0) +++ trunk/cmake/build_projects/libharu/remove_configured.patch 2013-10-23 02:42:08 UTC (rev 12618) @@ -0,0 +1,131 @@ +diff -Naur libharu-2.2.1_pristine/include/hpdf_config.h libharu-2.2.1/include/hpdf_config.h +--- libharu-2.2.1_pristine/include/hpdf_config.h 2010-11-22 02:00:33.000000000 -0800 ++++ libharu-2.2.1/include/hpdf_config.h 1969-12-31 16:00:00.000000000 -0800 +@@ -1,127 +0,0 @@ +-#ifndef _INCLUDE_HPDF_CONFIG_H +-#define _INCLUDE_HPDF_CONFIG_H 1 +- +-/* include/hpdf_config.h. Generated automatically at end of configure. */ +-/* include/config.h. Generated from config.h.in by configure. */ +-/* include/config.h.in. Generated from configure.in by autoheader. */ +- +-/* debug build */ +-#ifndef LIBHPDF_DEBUG +-#define LIBHPDF_DEBUG /**/ +-#endif +- +-/* debug trace enabled */ +-/* #undef DEBUG_TRACE */ +- +-/* Define to 1 if you have the <dlfcn.h> header file. */ +-#ifndef LIBHPDF_HAVE_DLFCN_H +-#define LIBHPDF_HAVE_DLFCN_H 1 +-#endif +- +-/* Define to 1 if you have the <inttypes.h> header file. */ +-#ifndef LIBHPDF_HAVE_INTTYPES_H +-#define LIBHPDF_HAVE_INTTYPES_H 1 +-#endif +- +-/* Define to 1 if you have the `png' library (-lpng). */ +-#ifndef LIBHPDF_HAVE_LIBPNG +-#define LIBHPDF_HAVE_LIBPNG 1 +-#endif +- +-/* Define to 1 if you have the `z' library (-lz). */ +-#ifndef LIBHPDF_HAVE_LIBZ +-#define LIBHPDF_HAVE_LIBZ 1 +-#endif +- +-/* Define to 1 if you have the <memory.h> header file. */ +-#ifndef LIBHPDF_HAVE_MEMORY_H +-#define LIBHPDF_HAVE_MEMORY_H 1 +-#endif +- +-/* libpng is not available */ +-/* #undef HAVE_NOPNGLIB */ +- +-/* zlib is not available */ +-/* #undef HAVE_NOZLIB */ +- +-/* Define to 1 if you have the <stdint.h> header file. */ +-#ifndef LIBHPDF_HAVE_STDINT_H +-#define LIBHPDF_HAVE_STDINT_H 1 +-#endif +- +-/* Define to 1 if you have the <stdlib.h> header file. */ +-#ifndef LIBHPDF_HAVE_STDLIB_H +-#define LIBHPDF_HAVE_STDLIB_H 1 +-#endif +- +-/* Define to 1 if you have the <strings.h> header file. */ +-#ifndef LIBHPDF_HAVE_STRINGS_H +-#define LIBHPDF_HAVE_STRINGS_H 1 +-#endif +- +-/* Define to 1 if you have the <string.h> header file. */ +-#ifndef LIBHPDF_HAVE_STRING_H +-#define LIBHPDF_HAVE_STRING_H 1 +-#endif +- +-/* Define to 1 if you have the <sys/stat.h> header file. */ +-#ifndef LIBHPDF_HAVE_SYS_STAT_H +-#define LIBHPDF_HAVE_SYS_STAT_H 1 +-#endif +- +-/* Define to 1 if you have the <sys/types.h> header file. */ +-#ifndef LIBHPDF_HAVE_SYS_TYPES_H +-#define LIBHPDF_HAVE_SYS_TYPES_H 1 +-#endif +- +-/* Define to 1 if you have the <unistd.h> header file. */ +-#ifndef LIBHPDF_HAVE_UNISTD_H +-#define LIBHPDF_HAVE_UNISTD_H 1 +-#endif +- +-/* Define to the sub-directory in which libtool stores uninstalled libraries. +- */ +-#ifndef LIBHPDF_LT_OBJDIR +-#define LIBHPDF_LT_OBJDIR ".libs/" +-#endif +- +-/* Define to the address where bug reports for this package should be sent. */ +-#ifndef LIBHPDF_PACKAGE_BUGREPORT +-#define LIBHPDF_PACKAGE_BUGREPORT "" +-#endif +- +-/* Define to the full name of this package. */ +-#ifndef LIBHPDF_PACKAGE_NAME +-#define LIBHPDF_PACKAGE_NAME "libhpdf" +-#endif +- +-/* Define to the full name and version of this package. */ +-#ifndef LIBHPDF_PACKAGE_STRING +-#define LIBHPDF_PACKAGE_STRING "libhpdf 2.2.1" +-#endif +- +-/* Define to the one symbol short name of this package. */ +-#ifndef LIBHPDF_PACKAGE_TARNAME +-#define LIBHPDF_PACKAGE_TARNAME "libhpdf" +-#endif +- +-/* Define to the home page for this package. */ +-#ifndef LIBHPDF_PACKAGE_URL +-#define LIBHPDF_PACKAGE_URL "" +-#endif +- +-/* Define to the version of this package. */ +-#ifndef LIBHPDF_PACKAGE_VERSION +-#define LIBHPDF_PACKAGE_VERSION "2.2.1" +-#endif +- +-/* Define to 1 if you have the ANSI C header files. */ +-#ifndef LIBHPDF_STDC_HEADERS +-#define LIBHPDF_STDC_HEADERS 1 +-#endif +- +-/* Define to `unsigned int' if <sys/types.h> does not define. */ +-/* #undef size_t */ +- +-/* once: _INCLUDE_HPDF_CONFIG_H */ +-#endif This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-22 17:47:17
|
Revision: 12617 http://sourceforge.net/p/plplot/code/12617 Author: airwin Date: 2013-10-22 17:47:13 +0000 (Tue, 22 Oct 2013) Log Message: ----------- Create SO_PERMISSIONS variable that is designed to mimic the permissions of shared objects created by the add_library command. The result should be correct regardless of whether the Linux platform is Fedora-based or Debian-based. Use that permissions variable for the dll*_stubs.so shared objects built and installed by the OCaml bindings and the plplot_octave.oct shared object built and installed by the Octave bindings. Tested by Alan W. Irwin <ai...@us...> using the install target on a Debian system. All permissions of the relevant installed files mentioned above were (-rw-r--r--) as expected. On Fedora systems the results should be (-rwxr-xr-x), but that needs testing. Modified Paths: -------------- trunk/bindings/ocaml/CMakeLists.txt trunk/bindings/ocaml/plcairo/CMakeLists.txt trunk/bindings/octave/CMakeLists.txt trunk/cmake/modules/plplot.cmake Modified: trunk/bindings/ocaml/CMakeLists.txt =================================================================== --- trunk/bindings/ocaml/CMakeLists.txt 2013-10-22 01:33:19 UTC (rev 12616) +++ trunk/bindings/ocaml/CMakeLists.txt 2013-10-22 17:47:13 UTC (rev 12617) @@ -360,15 +360,13 @@ DESTINATION ${OCAML_INSTALL_DIR}/plplot ) - # Shared library stubs go in stublibs. - # Use default permissions (rw-r--r--) for FILES signature because - # those are the permissions used by install(TARGETS... (which - # we are trying to emulate here because that signature not - # available to us because this shared object was - # created by a custom command). + # Shared library stubs go in stublibs. Use SO_PERMISSIONS to + # be consistent with permissions used for shared objects created + # by the add_library command. install( FILES ${CMAKE_CURRENT_BINARY_DIR}/dllplplot_stubs.so DESTINATION ${OCAML_INSTALL_DIR}/stublibs + PERMISSIONS ${SO_PERMISSIONS} ) endif(ENABLE_ocaml) Modified: trunk/bindings/ocaml/plcairo/CMakeLists.txt =================================================================== --- trunk/bindings/ocaml/plcairo/CMakeLists.txt 2013-10-22 01:33:19 UTC (rev 12616) +++ trunk/bindings/ocaml/plcairo/CMakeLists.txt 2013-10-22 17:47:13 UTC (rev 12617) @@ -250,15 +250,13 @@ DESTINATION ${OCAML_INSTALL_DIR}/plcairo ) - # Shared library stubs go in stublibs - # Use default permissions (rw-r--r--) for FILES signature because - # those are the permissions used by install(TARGETS... (which - # we are trying to emulate here because that signature not - # available to us because this shared object was - # created by a custom command). + # Shared library stubs go in stublibs. Use SO_PERMISSIONS to + # be consistent with permissions used for shared objects created + # by the add_library command. install( FILES ${CMAKE_CURRENT_BINARY_DIR}/dllplcairo_stubs.so DESTINATION ${OCAML_INSTALL_DIR}/stublibs + PERMISSIONS ${SO_PERMISSIONS} ) endif(ENABLE_ocaml AND OCAML_HAS_CAIRO) Modified: trunk/bindings/octave/CMakeLists.txt =================================================================== --- trunk/bindings/octave/CMakeLists.txt 2013-10-22 01:33:19 UTC (rev 12616) +++ trunk/bindings/octave/CMakeLists.txt 2013-10-22 17:47:13 UTC (rev 12617) @@ -311,19 +311,15 @@ ) endif(USE_RPATH) - # Have to be specific about permissions for some reason (probably oct suffix). - set(PERM_MODULES - OWNER_READ - OWNER_WRITE - GROUP_READ - WORLD_READ - ) + # Have to be specific about permissions for some reason (probably + # oct suffix). Use SO_PERMISSIONS to be consistent with permissions + # used for other shared objects created by the add_library command. install(TARGETS plplot_octave EXPORT export_plplot LIBRARY DESTINATION ${OCTAVE_OCT_DIR} - PERMISSIONS ${PERM_MODULES} + PERMISSIONS ${SO_PERMISSIONS} ) endif(ENABLE_octave) Modified: trunk/cmake/modules/plplot.cmake =================================================================== --- trunk/cmake/modules/plplot.cmake 2013-10-22 01:33:19 UTC (rev 12616) +++ trunk/cmake/modules/plplot.cmake 2013-10-22 17:47:13 UTC (rev 12617) @@ -544,4 +544,34 @@ include(doxygen) include(summary) +# Calculate permissions that should be used for shared objects that +# are created by custom commands to be consistent with the permissions +# automatically used for shared objects created as targets. The +# result (whether execute permissions are set) depends on +# CMAKE_INSTALL_SO_NO_EXE that is set in +# $prefix/share/cmake-2.8/Modules/Platform/Linux.cmake, where $prefix +# is the installation prefix for cmake itself, and the value depends +# on Linux platform. +if(CMAKE_INSTALL_SO_NO_EXE) + # Permissions for shared objects are (rw-r--r--). + set(SO_PERMISSIONS + OWNER_READ + OWNER_WRITE + GROUP_READ + WORLD_READ + ) +else(CMAKE_INSTALL_SO_NO_EXE) + # Permissions for shared objects are (rwxr-xr-x). + set(SO_PERMISSIONS + OWNER_READ + OWNER_WRITE + OWNER_EXECUTE + GROUP_READ + GROUP_EXECUTE + WORLD_READ + WORLD_EXECUTE + ) +endif(CMAKE_INSTALL_SO_NO_EXE) + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-22 01:33:22
|
Revision: 12616 http://sourceforge.net/p/plplot/code/12616 Author: airwin Date: 2013-10-22 01:33:19 +0000 (Tue, 22 Oct 2013) Log Message: ----------- Implement a VALGRIND_ALL_TESTS option to use valgrind for all runs of plplot-test.sh. With this option, time make VERBOSE=1 -j4 test_c_psc >& test_c_psc.out takes 6 minutes to complete on a mediocre PC (5-yr old box with 2 real cpu's). Tested by Alan W. Irwin <ai...@us...> using the test_c_psc target on a 64-bit Linux system. The result was all examples were valgrind perfect, e.g., ==4688== HEAP SUMMARY: ==4688== in use at exit: 0 bytes in 0 blocks ==4688== total heap usage: 360 allocs, 360 frees, 122,385 bytes allocated ==4688== ==4688== All heap blocks were freed -- no leaks are possible ==4688== ==4688== For counts of detected and suppressed errors, rerun with: -v ==4688== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 4 from 4) except for x16c and x33c where valgrind showed plcolorbar memory management issues which I will now attempt to figure out. Modified Paths: -------------- trunk/examples/CMakeLists.txt Modified: trunk/examples/CMakeLists.txt =================================================================== --- trunk/examples/CMakeLists.txt 2013-10-21 22:14:00 UTC (rev 12615) +++ trunk/examples/CMakeLists.txt 2013-10-22 01:33:19 UTC (rev 12616) @@ -420,6 +420,18 @@ ${CMAKE_CURRENT_BINARY_DIR}/lena.pgm ) + find_program(VALGRIND_EXECUTABLE valgrind) + if(VALGRIND_EXECUTABLE) + option(VALGRIND_ALL_TESTS "Apply valgrind to all runs of plplot_test/plplot-test.sh" OFF) + if(VALGRIND_ALL_TESTS) + set(plplot_test_debug --debug) + else(VALGRIND_ALL_TESTS) + set(plplot_test_debug) + endif(VALGRIND_ALL_TESTS) + else(VALGRIND_EXECUTABLE) + set(plplot_test_debug) + endif(VALGRIND_EXECUTABLE) + if(CORE_BUILD) set(custom_test_script ${CMAKE_BINARY_DIR}/plplot_test/plplot-test.sh) set(custom_env EXAMPLES_DIR=${CMAKE_BINARY_DIR}/examples SRC_EXAMPLES_DIR=${CMAKE_SOURCE_DIR}/examples) @@ -492,7 +504,7 @@ add_custom_command( OUTPUT ${output_list} COMMAND ${CMAKE_COMMAND} -E echo "Generate ${language} results for psc device" - COMMAND env ${environment} ${custom_test_command} --verbose --front-end=${language} --device=psc + COMMAND env ${environment} ${custom_test_command} --verbose --front-end=${language} --device=psc ${plplot_test_debug} DEPENDS ${compare_file_depends_${language}} VERBATIM ) @@ -574,7 +586,7 @@ add_custom_command( OUTPUT ${output_list} COMMAND ${CMAKE_COMMAND} -E echo "Generate C results for ${device} file device" - COMMAND env ${custom_env} ${custom_test_command} --verbose --front-end=c --device=${device} + COMMAND env ${custom_env} ${custom_test_command} --verbose --front-end=c --device=${device} ${plplot_test_debug} DEPENDS ${file_device_depends_${device}} VERBATIM @@ -682,7 +694,7 @@ endif(ENABLE_DYNDRIVERS) add_custom_target(test_c_${device} COMMAND ${CMAKE_COMMAND} -E echo "Generate C results for ${device} interactive device" - COMMAND env ${custom_env} ${custom_test_command} --verbose --interactive --device=${device} + COMMAND env ${custom_env} ${custom_test_command} --verbose --interactive --device=${device} ${plplot_test_debug} DEPENDS ${interactive_device_depends_${device}} VERBATIM @@ -711,7 +723,7 @@ get_property(files_examples_octave GLOBAL PROPERTY FILES_examples_octave) add_custom_target(test_octave_${device} COMMAND ${CMAKE_COMMAND} -E echo "Generate interactive octave results for ${device} interactive device" - COMMAND env ${custom_env} ${custom_test_command} --verbose --interactive_octave --device=${device} + COMMAND env ${custom_env} ${custom_test_command} --verbose --interactive_octave --device=${device} ${plplot_test_debug} DEPENDS ${interactive_device_depends_${device}} ${files_examples_octave} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ai...@us...> - 2013-10-21 22:14:03
|
Revision: 12615 http://sourceforge.net/p/plplot/code/12615 Author: airwin Date: 2013-10-21 22:14:00 +0000 (Mon, 21 Oct 2013) Log Message: ----------- Convert from 2.1.0 release to 2.2.1 release. Convert to using patches to express changes to the 2.2.1 release rather than files which are difficult to adjust for any upstream libharu changes in future. Tested by Alan W. Irwin <airwin.users.sourceforge.net> following directions in README.libharu for a standalone build on Linux and also using the build_projects approach on Linux. ToDo: MinGW/MSYS/Wine currently fails (presumably due to 2.1.0 ==> 2.2.1 change). So will have to figure out the problem, and update the patches for that case. Modified Paths: -------------- trunk/cmake/build_projects/libharu/README.libharu trunk/cmake/build_projects/libharu/bp.cmake Added Paths: ----------- trunk/cmake/build_projects/libharu/cmake.patch trunk/cmake/build_projects/libharu/large_font.patch trunk/cmake/build_projects/libharu/missing_zlib_headers.patch trunk/cmake/build_projects/libharu/visibility.patch Removed Paths: ------------- trunk/cmake/build_projects/libharu/cmake/ trunk/cmake/build_projects/libharu/demo/ trunk/cmake/build_projects/libharu/include/ trunk/cmake/build_projects/libharu/include_hpdf_config.h.patch trunk/cmake/build_projects/libharu/src/ Modified: trunk/cmake/build_projects/libharu/README.libharu =================================================================== --- trunk/cmake/build_projects/libharu/README.libharu 2013-10-21 01:11:34 UTC (rev 12614) +++ trunk/cmake/build_projects/libharu/README.libharu 2013-10-21 22:14:00 UTC (rev 12615) @@ -6,64 +6,45 @@ CMake logic that automatically builds libharu as part of the "Build Projects" project (see CMakeLists.txt file in the parent directory) -that uses ExternalProject_Add to build projects that have a ep.cmake +that uses ExternalProject_Add to build projects that have a bp.cmake file: -ep.cmake +bp.cmake Improved build system (Werner's build system culled from the git version of libharu with additional improvements by me): -CMakeLists.txt -cmake/modules/haru.cmake -cmake/modules/summary.cmake -src/CMakeLists.txt -include/CMakeLists.txt -demo/CMakeLists.txt -include/hpdf_config.h.cmake +cmake.patch Support for larger font sizes (without this, example 24 does not work): -include/hpdf_consts.h -src/hpdf_page_operator.c +large_font.patch Support for gcc visibility: -include/hpdf.h +visibility.patch Bug fix for the case where zlib is not available. -include_hpdf_config.h.patch +missing_zlib_headers.patch -(1) copy selected files from here on top of a pre-existing freshly -unpacked version of libharu-2.1.0, e.g., +(1) Patch a pre-existing freshly unpacked version of libharu-2.2.1, +with these patches, e.g., -mkdir -p /home/software/libharu/libharu-2.1.0/cmake/modules -cp -f libharu/CMakeLists.txt /home/software/libharu/libharu-2.1.0 -cp -f libharu/demo/CMakeLists.txt /home/software/libharu/libharu-2.1.0/demo -cp -f libharu/src/hpdf_page_operator.c libharu/src/CMakeLists.txt \ -/home/software/libharu/libharu-2.1.0/src -cp -f libharu/cmake/modules/haru.cmake libharu/cmake/modules/summary.cmake \ -/home/software/libharu/libharu-2.1.0/cmake/modules -cp -f libharu/include/hpdf_consts.h libharu/include/hpdf_config.h.cmake \ -libharu/include/hpdf.h libharu/include/CMakeLists.txt \ -/home/software/libharu/libharu-2.1.0/include +patch -d /home/software/libharu/libharu-2.2.1 -p1 < cmake.patch +patch -d /home/software/libharu/libharu-2.2.1 -p1 < large_font.patch +patch -d /home/software/libharu/libharu-2.2.1 -p1 < visibility.patch +patch -d /home/software/libharu/libharu-2.2.1 -p1 < missing_zlib_headers.patch -N.B. libharu-2.1.0 has no cmake-based build-system at all (unlike the -git version) so this cp operation installs that as well as changes to -implement the larger font size support and gcc visibility. - -(2) Fix bug for case when zlib is not available. -patch -d /home/software/libharu/libharu-2.1.0 -p1 < libharu/include_hpdf_config.h.patch - -(3) configure, build, and install libharu starting with an empty build tree +(2) configure, build, and install libharu starting with an empty build tree and empty install tree, e.g., +cd /home/software/libharu +mkdir -p build_dir +cd build_dir rm -rf /home/software/libharu/build_dir/* /home/software/libharu/install -cd /home/software/libharu/build_dir cmake -DCMAKE_INSTALL_PREFIX=/home/software/libharu/install \ --DPOST_2.1.0=OFF -DLIBHARU_EXAMPLES=ON \ -../libharu-2.1.0 >& cmake.out +../libharu-2.2.1 >& cmake.out make -j4 install >& make_install.out The above step works fine on Linux with @@ -71,10 +52,9 @@ export CFLAGS='-g -fvisibility=hidden' set before the "cmake" invocation to test the new gcc visibility support -in hpdf.h. Note -DPOST_2.1.0=OFF is essential for the 2.1.0 -version, but you should drop this option for anything after 2.1.0. -Also note that -DLIBHARU_EXAMPLES=ON builds the demos, but does not -test them. +in hpdf.h. Note that the -DLIBHARU_EXAMPLES=ON cmake option would attempt +to build the demos (but not test them). However, avoid using this +option with 2.2.1 since no demos are included with that release. N.B. This improved CMake-based build system has been tested for both Linux and MinGW/MSYS now using the "Build Projects" project (see the Modified: trunk/cmake/build_projects/libharu/bp.cmake =================================================================== --- trunk/cmake/build_projects/libharu/bp.cmake 2013-10-21 01:11:34 UTC (rev 12614) +++ trunk/cmake/build_projects/libharu/bp.cmake 2013-10-21 22:14:00 UTC (rev 12615) @@ -33,8 +33,8 @@ set(${BP_PACKAGE}_configured ON) # Data that is related to downloads. -set(${BP_PACKAGE}_URL http://${BP_PACKAGE}.org/files/${BP_PACKAGE}-2.1.0.tar.gz) -set(${BP_PACKAGE}_URL_MD5 0623b8fb08ae1b28af08b2cdbd66b662) +set(${BP_PACKAGE}_URL http://${BP_PACKAGE}.org/files/${BP_PACKAGE}-2.2.1.tar.gz) +set(${BP_PACKAGE}_URL_MD5 63da8e087744f1d6cf16f9501b1cb766) # Data that is related to the PATH that must be used. if(MSYS_PLATFORM) @@ -48,63 +48,27 @@ build_${BP_PACKAGE} URL ${${BP_PACKAGE}_URL} URL_MD5 ${${BP_PACKAGE}_URL_MD5} - # Note -DPOST_2.1.0=OFF is essential for the 2.1.0 version, but you - # should drop this option for anything after 2.1.0. Also note that - # -DLIBHARU_EXAMPLES=ON builds the demos, but does not test them. - CONFIGURE_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_CMAKE_COMMAND} -DPOST_2.1.0=OFF -DLIBHARU_EXAMPLES=ON ${EP_BASE}/Source/build_${BP_PACKAGE} + PATCH_COMMAND "" + # Do not use -DLIBHARU_EXAMPLES=ON (which builds the demos, but does + # not test them) because latest release does not include demos. + CONFIGURE_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_CMAKE_COMMAND} ${EP_BASE}/Source/build_${BP_PACKAGE} BUILD_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_BUILD_COMMAND} INSTALL_COMMAND ${ENV_EXECUTABLE} PATH=${BP_PATH} ${BP_PARALLEL_BUILD_COMMAND} install ) -# Add custom commands to the current no-command update step. add_custom_command( OUTPUT - ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-update - COMMAND ${CMAKE_COMMAND} -E make_directory ${EP_BASE}/Source/build_${BP_PACKAGE}/cmake/modules - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/CMakeLists.txt - ${EP_BASE}/Source/build_${BP_PACKAGE}/CMakeLists.txt - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/demo/CMakeLists.txt - ${EP_BASE}/Source/build_${BP_PACKAGE}/demo/CMakeLists.txt - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/src/hpdf_page_operator.c - ${EP_BASE}/Source/build_${BP_PACKAGE}/src/hpdf_page_operator.c - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/src/CMakeLists.txt - ${EP_BASE}/Source/build_${BP_PACKAGE}/src/CMakeLists.txt - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/cmake/modules/haru.cmake - ${EP_BASE}/Source/build_${BP_PACKAGE}/cmake/modules/haru.cmake - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/cmake/modules/summary.cmake - ${EP_BASE}/Source/build_${BP_PACKAGE}/cmake/modules/summary.cmake - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf_consts.h - ${EP_BASE}/Source/build_${BP_PACKAGE}/include/hpdf_consts.h - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf_config.h.cmake - ${EP_BASE}/Source/build_${BP_PACKAGE}/include/hpdf_config.h.cmake - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf.h - ${EP_BASE}/Source/build_${BP_PACKAGE}/include/hpdf.h - COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/CMakeLists.txt - ${EP_BASE}/Source/build_${BP_PACKAGE}/include/CMakeLists.txt - COMMAND ${PATCH_EXECUTABLE} -d ${EP_BASE}/Source/build_${BP_PACKAGE} -p1 < ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include_hpdf_config.h.patch - COMMENT "Custom updating of ${BP_PACKAGE}" + ${EP_BASE}/Stamp/build_${BP_PACKAGE}/build_${BP_PACKAGE}-patch + COMMAND ${CMAKE_COMMAND} -E echo "Apply all patches" + COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/cmake.patch + COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/large_font.patch + COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/missing_zlib_headers.patch + COMMAND ${PATCH_EXECUTABLE} -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/visibility.patch DEPENDS - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/CMakeLists.txt - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/demo/CMakeLists.txt - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/src/hpdf_page_operator.c - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/src/CMakeLists.txt - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/cmake/modules/haru.cmake - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/cmake/modules/summary.cmake - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf_consts.h - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf_config.h.cmake - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/hpdf.h - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include/CMakeLists.txt - ${CMAKE_SOURCE_DIR}/${BP_PACKAGE}/include_hpdf_config.h.patch + ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/cmake.patch + ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/large_font.patch + ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/missing_zlib_headers.patch + ${CMAKE_CURRENT_SOURCE_DIR}/${BP_PACKAGE}/visibility.patch APPEND ) Added: trunk/cmake/build_projects/libharu/cmake.patch =================================================================== --- trunk/cmake/build_projects/libharu/cmake.patch (rev 0) +++ trunk/cmake/build_projects/libharu/cmake.patch 2013-10-21 22:14:00 UTC (rev 12615) @@ -0,0 +1,857 @@ +diff -Naur libharu-2.2.1_pristine/CMakeLists.txt libharu-2.2.1/CMakeLists.txt +--- libharu-2.2.1_pristine/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/CMakeLists.txt 2013-10-21 10:51:25.543121062 -0700 +@@ -0,0 +1,216 @@ ++# CMakeLists.txt ++# ++# Copyright (C) 2008 Werner Smekal ++# Copyright (C) 2010 Alan W. Irwin ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++# ++# Process this file with cmake to produce Makefiles or project files ++# for your specific compiler tool set ++# ++# TODO: ++# - shared and static library ++# - packaging ++# - devpackage ++# ======================================================================= ++# libharu project ++# ======================================================================= ++project(libharu C) ++ ++# we want cmake version 2.4.8 at least ++cmake_minimum_required(VERSION 2.4.8 FATAL_ERROR) ++ ++# Location where the haru cmake build system first looks for cmake modules ++set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules) ++ ++# determine compiler name ++set(COMPILER_LABEL "unknown") ++if(CMAKE_COMPILER_IS_GNUCC) ++ set(COMPILER_LABEL "gcc") ++endif(CMAKE_COMPILER_IS_GNUCC) ++if(MSVC) ++ set(COMPILER_LABEL "vc") ++endif(MSVC) ++ ++### Version information for libharu software package. ++### N.B. Needs review before each release! ++set(LIBHARU_MAJOR 2) ++set(LIBHARU_MINOR 2) ++set(LIBHARU_PATCH 0) ++set(LIBHARU_VERSION ${LIBHARU_MAJOR}.${LIBHARU_MINOR}.${LIBHARU_PATCH}) ++# libhpdf library version information. ++# N.B. Not to be confused with package version set above! ++ ++# Rules: ++# (1) If a backwards incompatible API change has been made in the library ++# API (e.g., if old compiled and linked applications will no longer work) ++# then increment SOVERSION and zero the corresponding minor and patch ++# numbers just before release. ++# (2) If the library changes are limited to additions to the API, then ++# then leave SOVERSION alone, increment the minor number and zero the ++# patch number just before release. ++# (3) If the library changes are limited to implementation changes with ++# no API changes at all, then leave SOVERSION and minor number alone, and ++# increment the patch number just before the release. ++# (4) If there are no library source code changes at all, then leave all ++# library version numbers the same for the release. ++# If library has not been properly versioned before start the numbering ++# at 0.0.0. ++set(hpdf_SOVERSION 0) ++set(hpdf_VERSION ${hpdf_SOVERSION}.0.0) ++### End of version information to be reviewed. ++ ++# Use RPATH? ++if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") ++ # No rpath on Darwin. Setting it will only cause trouble. ++else(CMAKE_SYSTEM_NAME STREQUAL "Darwin") ++ option(USE_RPATH "Use -rpath when linking libraries, executables" ON) ++endif(CMAKE_SYSTEM_NAME STREQUAL "Darwin") ++ ++# Description of libharu for cpack. ++set(LIBHARU_DESCRIPTION "libHaru is a free, cross platform, open source library for generating PDF files.") ++set(LIBHARU_PACKAGE_NAME "libHaru-${LIBHARU_VERSION}-${COMPILER_LABEL}") ++ ++# Comment out all this name stuff which I feel is probably unnecessary (since ++# PLplot doesn't bother with this.) ++# set library name, msvc does not prepend 'lib' automatically ++#if(MSVC) ++# set(LIBHARU_NAME lib) ++#endif(MSVC) ++#set(LIBHARU_NAME ${LIBHARU_NAME}hpdf) ++#set(LIBHARU_NAME_STATIC ${LIBHARU_NAME}s) ++ ++# ======================================================================= ++# command line options ++# ======================================================================= ++option(LIBHARU_SHARED "Build shared lib" YES) ++option(LIBHARU_STATIC "Build static lib" YES) ++option(LIBHARU_EXAMPLES "Build libharu examples" NO) ++option(DEVPAK "Create DevPackage" NO) ++ ++if(DEVPAK AND NOT WIN32) ++ message( STATUS "DevPackage only available for Win32. Set DEVPAK to OFF." ) ++ set(DEVPAK OFF) ++endif(DEVPAK AND NOT WIN32) ++if(DEVPAK AND LIBHARU_EXAMPLES) ++ message( STATUS "Examples are not build for DevPackage. Set LIBHARU_EXAMPLES to OFF." ) ++ set(LIBHARU_EXAMPLES OFF) ++endif(DEVPAK AND LIBHARU_EXAMPLES) ++ ++ ++ ++if(BUILD_SHARED_LIBS) ++ set(LIBHARU_SHARED ON) ++endif(BUILD_SHARED_LIBS) ++ ++# ======================================================================= ++# look for headers and libraries ++# ======================================================================= ++include(haru) ++include(summary) ++ ++set(ADDITIONAL_LIBRARIES ${MATH_LIB}) ++# check zlib availibility ++find_package(ZLIB) ++if(ZLIB_FOUND) ++ set(HAVE_LIBZ ON) ++ include_directories(${ZLIB_INCLUDE_DIR}) ++ list(APPEND ADDITIONAL_LIBRARIES ${ZLIB_LIBRARIES}) ++else(ZLIB_FOUND) ++ set(HPDF_NOZLIB ON) ++endif(ZLIB_FOUND) ++ ++# check png availibility ++find_package(PNG) ++if(PNG_FOUND) ++ set(HAVE_LIBPNG ON) ++ include_directories(${PNG_INCLUDE_DIR}) ++ add_definitions(${PNG_DEFINITIONS}) ++ list(APPEND ADDITIONAL_LIBRARIES ${PNG_LIBRARIES}) ++else(PNG_FOUND) ++ set(HPDF_NOPNGLIB ON) ++endif(PNG_FOUND) ++ ++# ======================================================================= ++# Add compiler flags ++# ======================================================================= ++# add definitions and directories to include ++#if(CMAKE_COMPILER_IS_GNUCC) ++# add_definitions("-Wall") ++#endif(CMAKE_COMPILER_IS_GNUCC) ++if(MSVC_VERSION GREATER 1399) ++ add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_DEPRECATE) ++endif(MSVC_VERSION GREATER 1399) ++include_directories(${CMAKE_SOURCE_DIR}/include) ++include_directories(${CMAKE_BINARY_DIR}/include) ++ ++# create DevPackage file ++if(DEVPAK) ++ configure_file( ++ ${CMAKE_SOURCE_DIR}/libharu.DevPackage.cmake ++ ${CMAKE_BINARY_DIR}/libharu.DevPackage ++ ) ++endif(DEVPAK) ++ ++# ======================================================================= ++# Configure and install header files. ++# ======================================================================= ++add_subdirectory(include) ++ ++# ======================================================================= ++# create library and demos ++# ======================================================================= ++add_subdirectory(src) ++add_subdirectory(demo) ++ ++# install various files ++# These commented out to keep install tree as lean as possible. May want ++# to add some documentation files later to the install tree. ++#install(FILES README CHANGES INSTALL DESTINATION .) ++#install(DIRECTORY doc DESTINATION .) ++#if(NOT DEVPAK) ++# install(DIRECTORY if DESTINATION .) ++#endif(NOT DEVPAK) ++#if(DEVPAK) ++# install(FILES ${CMAKE_BINARY_DIR}/libharu.DevPackage DESTINATION .) ++#endif(DEVPAK) ++# ======================================================================= ++# print out some information ++# ======================================================================= ++summary() ++ ++# ======================================================================= ++# packing stuff ++# ======================================================================= ++set(CPACK_PACKAGE_DESCRIPTION_SUMMARY ${LIBHARU_DESCRIPTION}) ++set(CPACK_PACKAGE_VENDOR "Werner Smekal") ++set(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_CURRENT_SOURCE_DIR}/README) ++set(CPACK_PACKAGE_VERSION_MAJOR "${LIBHARU_MAJOR}") ++set(CPACK_PACKAGE_VERSION_MINOR "${LIBHARU_MINOR}") ++set(CPACK_PACKAGE_VERSION_PATCH "${LIBHARU_PATCH}") ++set(CPACK_PACKAGE_FILE_NAME "libHaru-${LIBHARU_VERSION}-${COMPILER_LABEL}") ++ ++set(CPACK_STRIP_FILES ON) ++ ++if(WIN32) ++ set(CPACK_GENERATOR ZIP) ++else(WIN32) ++ set(CPACK_GENERATOR TGZ) ++endif(WIN32) ++ ++INCLUDE( CPack ) +diff -Naur libharu-2.2.1_pristine/cmake/modules/haru.cmake libharu-2.2.1/cmake/modules/haru.cmake +--- libharu-2.2.1_pristine/cmake/modules/haru.cmake 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/cmake/modules/haru.cmake 2013-10-21 10:52:11.838244974 -0700 +@@ -0,0 +1,54 @@ ++# cmake/modules/haru.cmake ++# ++# Copyright (C) 2008 Werner Smekal ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++# ++# check if headers exist ++# Need these modules to do subsequent checks. ++include(CheckIncludeFiles) ++ ++# ======================================================================= ++# check header availability ++# ======================================================================= ++# check if header file exists ++check_include_files(dlfcn.h HAVE_DLFCN_H) ++check_include_files(inttypes.h HAVE_INTTYPES_H) ++check_include_files(memory.h HAVE_MEMORY_H) ++check_include_files(stdint.h HAVE_STDINT_H) ++check_include_files(stdlib.h HAVE_STDLIB_H) ++check_include_files(strings.h HAVE_STRINGS_H) ++check_include_files(string.h HAVE_STRING_H) ++check_include_files(sys/stat.h HAVE_SYS_STAT_H) ++check_include_files(sys/types.h HAVE_SYS_TYPES_H) ++check_include_files(unistd.h HAVE_UNISTD_H) ++ ++ ++# ======================================================================= ++# additional library support ++# ======================================================================= ++# On windows systems the math library is not separated so do not specify ++# it unless you are on a non-windows system. ++if(NOT WIN32) ++ find_library(MATH_LIB NAMES m PATHS /usr/local/lib /usr/lib) ++ if(NOT MATH_LIB) ++ message(FATAL_ERROR "Cannot find required math library") ++ endif(NOT MATH_LIB) ++else(NOT WIN32) ++ set(MATH_LIB) ++endif(NOT WIN32) +diff -Naur libharu-2.2.1_pristine/cmake/modules/summary.cmake libharu-2.2.1/cmake/modules/summary.cmake +--- libharu-2.2.1_pristine/cmake/modules/summary.cmake 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/cmake/modules/summary.cmake 2013-10-21 10:52:36.297782032 -0700 +@@ -0,0 +1,66 @@ ++# cmake/modules/summary.cmake ++# ++# Copyright (C) 2008 Werner Smekal ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++# ++# Macro for outputting all the most important CMake variables for haru ++ ++# ======================================================================= ++# print summary of configuration to screen ++# ======================================================================= ++ ++macro(summary) ++set(_output_results " ++Summary of CMake build system results for the haru library ++ ++Install location variables which can be set by the user: ++CMAKE_INSTALL_PREFIX: ${CMAKE_INSTALL_PREFIX} ++CMAKE_INSTALL_EXEC_PREFIX ${CMAKE_INSTALL_EXEC_PREFIX} ++CMAKE_INSTALL_BINDIR ${CMAKE_INSTALL_BINDIR} ++CMAKE_INSTALL_LIBDIR ${CMAKE_INSTALL_LIBDIR} ++CMAKE_INSTALL_INCLUDEDIR ${CMAKE_INSTALL_INCLUDEDIR} ++ ++Other important CMake variables: ++ ++CMAKE_SYSTEM_NAME: ${CMAKE_SYSTEM_NAME} ++UNIX: ${UNIX} ++WIN32: ${WIN32} ++APPLE: ${APPLE} ++MSVC: ${MSVC} (MSVC_VERSION: ${MSVC_VERSION}) ++MINGW: ${MINGW} ++MSYS: ${MSYS} ++CYGWIN: ${CYGWIN} ++BORLAND: ${BORLAND} ++WATCOM: ${WATCOM} ++ ++CMAKE_BUILD_TYPE: ${CMAKE_BUILD_TYPE} ++CMAKE_C_COMPILER CMAKE_C_FLAGS: ${CMAKE_C_COMPILER} ${CMAKE_C_FLAGS} ++ ++Library options: ++LIBHARU_SHARED: ${LIBHARU_SHARED} ++LIBHARU_STATIC: ${LIBHARU_STATIC} ++LIBHARU_EXAMPLES: ${LIBHARU_EXAMPLES} ++DEVPAK: ${DEVPAK} ++ ++Optional libraries: ++HAVE_LIBZ: ${HAVE_LIBZ} ++HAVE_LIBPNG: ${HAVE_LIBPNG} ++") ++message("${_output_results}") ++endmacro(summary) +diff -Naur libharu-2.2.1_pristine/demo/CMakeLists.txt libharu-2.2.1/demo/CMakeLists.txt +--- libharu-2.2.1_pristine/demo/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/demo/CMakeLists.txt 2013-10-21 10:54:41.939403569 -0700 +@@ -0,0 +1,183 @@ ++# demo/CMakeLists.txt ++# ++# Copyright (C) 2008 Werner Smekal ++# Copyright (C) 2010 Alan W. Irwin ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++## ++# create demo executables ++ ++if(LIBHARU_EXAMPLES) ++ # ======================================================================= ++ # source file names and c flags ++ # ======================================================================= ++ set( ++ demos_NAMES ++ character_map ++ encoding_list ++ encryption ++ ext_gstate_demo ++ font_demo ++ image_demo ++ jpeg_demo ++ jpfont_demo ++ line_demo ++ link_annotation ++ make_rawimage ++ outline_demo ++ #outline_demo_jp ++ permission ++ png_demo ++ slide_show_demo ++ text_annotation ++ ttfont_demo ++ ttfont_demo_jp ++ ) ++ ++ set( ++ demos_with_grid_NAMES ++ arc_demo ++ chfont_demo ++ raw_image_demo ++ text_demo ++ text_demo2 ++ ) ++ ++ # we need to add some definitions for win 32 ++ if(WIN32 AND NOT CYGWIN) ++ add_definitions(-D__WIN32__) ++ endif(WIN32 AND NOT CYGWIN) ++ ++ # link the examples to the shared library otherwise to the static ++ if(LIBHARU_SHARED) ++ set(_LIBHARU_LIB hpdf) ++ if(CYGWIN OR MINGW) ++ add_definitions(-DHPDF_DLL_CDECL) ++ elseif(WIN32) ++ add_definitions(-DHPDF_DLL) ++ endif(CYGWIN OR MINGW) ++ else(LIBHARU_SHARED) ++ set(_LIBHARU_LIB hpdf_static) ++ endif(LIBHARU_SHARED) ++ ++ # ======================================================================= ++ # create demos ++ # ======================================================================= ++ foreach(demo ${demos_NAMES}) ++ add_executable(${demo} ${demo}.c) ++ target_link_libraries(${demo} ${_LIBHARU_LIB}) ++ if(USE_RPATH) ++ set_target_properties( ++ ${demo} ++ PROPERTIES ++ INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib" ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ else(USE_RPATH) ++ set_target_properties( ++ ${demo} ++ PROPERTIES ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ endif(USE_RPATH) ++ endforeach(demo) ++ ++ # some demos need grid_sheet.c compiled in ++ foreach(demo ${demos_with_grid_NAMES}) ++ add_executable(${demo} ${demo}.c grid_sheet.c) ++ target_link_libraries(${demo} ${_LIBHARU_LIB}) ++ if(USE_RPATH) ++ set_target_properties( ++ ${demo} ++ PROPERTIES ++ INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib" ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ else(USE_RPATH) ++ set_target_properties( ++ ${demo} ++ PROPERTIES ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ endif(USE_RPATH) ++ endforeach(demo) ++ ++ if(MATH_LIB) ++ # These are a subset of the demos above which include math.h and which ++ # therefore require linking with ${MATH_LIB}. ++ set( ++ demos_requiring_MATH_LIB ++ text_demo2 ++ text_demo ++ raw_image_demo ++ image_demo ++ make_rawimage ++ ) ++ ++ foreach(demo ${demos_requiring_MATH_LIB}) ++ target_link_libraries(${demo} ${MATH_LIB}) ++ endforeach(demo ${demos_requiring_MATH_LIB}) ++ endif(MATH_LIB) ++ ++ add_executable(grid_sheet grid_sheet.c) ++ # the grid_sheet demo needs extra define, but cannot use add_definitions ++ # for that because that command affects all source files in the directory. ++ # So use set_target_properties instead. ++ set_target_properties(grid_sheet PROPERTIES COMPILE_FLAGS "-DSTAND_ALONE") ++ target_link_libraries(grid_sheet ${_LIBHARU_LIB}) ++ if(USE_RPATH) ++ set_target_properties( ++ grid_sheet ++ PROPERTIES ++ INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib" ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ else(USE_RPATH) ++ set_target_properties( ++ grid_sheet ++ PROPERTIES ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ endif(USE_RPATH) ++ ++ # ======================================================================= ++ # install demo source, demo executables and other files ++ # ======================================================================= ++ ++ # comment out the rest of this until have better install tree ++ # location for these files. For example, the current location makes ++ # a real mess on Unix. In any case, demo executables should not be ++ # installed. Instead, an independent demo build and test system ++ # (say, CMake-based as for PLplot) would be nice to implement for ++ # the installed demos. ++ ++ # install( ++ # TARGETS ${demos_NAMES} ${demos_with_grid_NAMES} grid_sheet ++ # DESTINATION demo ++ # ) ++ ++ # foreach(demo ${demos_NAMES} ${demos_with_grid_NAMES} grid_sheet) ++ # install(FILES ${demo}.c DESTINATION demo) ++ # endforeach(demo) ++ ++ # install demo files ++ # install( ++ # DIRECTORY images mbtext pngsuite rawimage ttfont type1 ++ # DESTINATION demo ++ # ) ++endif(LIBHARU_EXAMPLES) +diff -Naur libharu-2.2.1_pristine/include/CMakeLists.txt libharu-2.2.1/include/CMakeLists.txt +--- libharu-2.2.1_pristine/include/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/include/CMakeLists.txt 2013-10-21 10:53:43.508509852 -0700 +@@ -0,0 +1,63 @@ ++# include/CMakeLists.txt for libharu. ++### ++### Process this file with cmake to produce Makefile ++### ++# Copyright (C) 2008 Werner Smekal ++# Copyright (C) 2010 Alan W. Irwin ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++# ++ ++configure_file( ++ ${CMAKE_CURRENT_SOURCE_DIR}/hpdf_config.h.cmake ++ ${CMAKE_CURRENT_BINARY_DIR}/hpdf_config.h ++ ) ++ ++set(include_INSTALLED_HEADERS ++ hpdf.h ++ hpdf_annotation.h ++ hpdf_catalog.h ++ hpdf_conf.h ++ ${CMAKE_CURRENT_BINARY_DIR}/hpdf_config.h ++ hpdf_consts.h ++ hpdf_destination.h ++ hpdf_doc.h ++ hpdf_encoder.h ++ hpdf_encrypt.h ++ hpdf_encryptdict.h ++ hpdf_error.h ++ hpdf_ext_gstate.h ++ hpdf_font.h ++ hpdf_fontdef.h ++ hpdf_gstate.h ++ hpdf_image.h ++ hpdf_info.h ++ hpdf_list.h ++ hpdf_mmgr.h ++ hpdf_objects.h ++ hpdf_outline.h ++ hpdf_page_label.h ++ hpdf_pages.h ++ hpdf_streams.h ++ hpdf_types.h ++ hpdf_u3d.h ++ hpdf_utils.h ++ hpdf_version.h ++ ) ++ ++install(FILES ${include_INSTALLED_HEADERS} DESTINATION include/hpdf) +diff -Naur libharu-2.2.1_pristine/include/hpdf_config.h.cmake libharu-2.2.1/include/hpdf_config.h.cmake +--- libharu-2.2.1_pristine/include/hpdf_config.h.cmake 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/include/hpdf_config.h.cmake 2013-10-21 10:55:06.162944881 -0700 +@@ -0,0 +1,97 @@ ++/* ++ * Copyright (C) 2008 Werner Smekal ++ * Copyright (C) 2010 Alan W. Irwin ++ * ++ * This software is provided 'as-is', without any express or implied warranty. ++ * ++ * In no event will the authors be held liable for any damages arising from the ++ * use of this software. ++ * ++ * Permission is granted to anyone to use this software for any purpose,including ++ * commercial applications, and to alter it and redistribute it freely, subject ++ * to the following restrictions: ++ * ++ * 1. The origin of this software must not be misrepresented; you must not claim ++ * that you wrote the original software. If you use this software in a ++ * product, an acknowledgment in the product documentation would be ++ * appreciated but is not required. ++ * 2. Altered source versions must be plainly marked as such, and must not be ++ * misrepresented as being the original software. ++ * 3. This notice may not be removed or altered from any source distribution. ++ */ ++ ++/* include/hpdf_config.h.in. Generated from configure.in by autoheader. */ ++ ++#ifndef _HPDF_CONFIG_H ++#define _HPDF_CONFIG_H ++ ++/* Define to 1 if you have the <dlfcn.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_DLFCN_H ++ ++/* Define to 1 if you have the <inttypes.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_INTTYPES_H ++ ++/* Define to 1 if you have the `png' library (-lpng). */ ++#cmakedefine HAVE_LIBPNG ++ ++/* Define to 1 if you have the `z' library (-lz). */ ++#cmakedefine HAVE_LIBZ ++ ++/* Define to 1 if you have the <memory.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_MEMORY_H ++ ++/* Define to 1 if you have the <stdint.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_STDINT_H ++ ++/* Define to 1 if you have the <stdlib.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_STDLIB_H ++ ++/* Define to 1 if you have the <strings.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_STRINGS_H ++ ++/* Define to 1 if you have the <string.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_STRING_H ++ ++/* Define to 1 if you have the <sys/stat.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_SYS_STAT_H ++ ++/* Define to 1 if you have the <sys/types.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_SYS_TYPES_H ++ ++/* Define to 1 if you have the <unistd.h> header file. */ ++#cmakedefine LIBHPDF_HAVE_UNISTD_H ++ ++/* debug build */ ++#cmakedefine LIBHPDF_DEBUG ++ ++/* debug trace enabled */ ++#cmakedefine LIBHPDF_DEBUG_TRACE ++ ++/* libpng is not available */ ++#cmakedefine HPDF_NOPNGLIB ++ ++/* zlib is not available */ ++#cmakedefine HPDF_NOZLIB ++ ++/* Define to the address where bug reports for this package should be sent. */ ++#cmakedefine LIBHPDF_PACKAGE_BUGREPORT ++ ++/* Define to the full name of this package. */ ++#cmakedefine LIBHPDF_PACKAGE_NAME ++ ++/* Define to the full name and version of this package. */ ++#cmakedefine LIBHPDF_PACKAGE_STRING ++ ++/* Define to the one symbol short name of this package. */ ++#cmakedefine LIBHPDF_PACKAGE_TARNAME ++ ++/* Define to the version of this package. */ ++#cmakedefine LIBHPDF_PACKAGE_VERSION ++ ++/* Define to 1 if you have the ANSI C header files. */ ++#cmakedefine LIBHPDF_STDC_HEADERS ++ ++/* Define to `unsigned int' if <sys/types.h> does not define. */ ++#cmakedefine LIBHPDF_size_t ++ ++#endif /* _HPDF_CONFIG_H */ +diff -Naur libharu-2.2.1_pristine/src/CMakeLists.txt libharu-2.2.1/src/CMakeLists.txt +--- libharu-2.2.1_pristine/src/CMakeLists.txt 1969-12-31 16:00:00.000000000 -0800 ++++ libharu-2.2.1/src/CMakeLists.txt 2013-10-21 10:53:23.164894950 -0700 +@@ -0,0 +1,150 @@ ++# src/CMakeLists.txt ++# ++# Copyright (C) 2008 Werner Smekal ++# Copyright (C) 2010 Alan W. Irwin ++# ++# This software is provided 'as-is', without any express or implied warranty. ++# ++# In no event will the authors be held liable for any damages arising from the ++# use of this software. ++# ++# Permission is granted to anyone to use this software for any purpose,including ++# commercial applications, and to alter it and redistribute it freely, subject ++# to the following restrictions: ++# ++# 1. The origin of this software must not be misrepresented; you must not claim ++# that you wrote the original software. If you use this software in a ++# product, an acknowledgment in the product documentation would be ++# appreciated but is not required. ++# 2. Altered source versions must be plainly marked as such, and must not be ++# misrepresented as being the original software. ++# 3. This notice may not be removed or altered from any source distribution. ++# ++# create library ++# ======================================================================= ++# libharu source files ++# ======================================================================= ++set( ++ libharu_SRCS ++ hpdf_annotation.c ++ hpdf_array.c ++ hpdf_binary.c ++ hpdf_boolean.c ++ hpdf_catalog.c ++ hpdf_destination.c ++ hpdf_dict.c ++ hpdf_doc_png.c ++ hpdf_doc.c ++ hpdf_encoder_cns.c ++ hpdf_encoder_cnt.c ++ hpdf_encoder_jp.c ++ hpdf_encoder_kr.c ++ hpdf_encoder.c ++ hpdf_encrypt.c ++ hpdf_encryptdict.c ++ hpdf_error.c ++ hpdf_ext_gstate.c ++ hpdf_font_cid.c ++ hpdf_font_tt.c ++ hpdf_font_type1.c ++ hpdf_font.c ++ hpdf_fontdef_base14.c ++ hpdf_fontdef_cid.c ++ hpdf_fontdef_cns.c ++ hpdf_fontdef_cnt.c ++ hpdf_fontdef_jp.c ++ hpdf_fontdef_kr.c ++ hpdf_fontdef_tt.c ++ hpdf_fontdef_type1.c ++ hpdf_fontdef.c ++ hpdf_gstate.c ++ hpdf_image_png.c ++ hpdf_image.c ++ hpdf_info.c ++ hpdf_list.c ++ hpdf_mmgr.c ++ hpdf_name.c ++ hpdf_null.c ++ hpdf_number.c ++ hpdf_objects.c ++ hpdf_outline.c ++ hpdf_page_label.c ++ hpdf_page_operator.c ++ hpdf_pages.c ++ hpdf_real.c ++ hpdf_streams.c ++ hpdf_string.c ++ hpdf_u3d.c ++ hpdf_utils.c ++ hpdf_xref.c ++ ) ++option(POST_2.1.0 "Version after 2.1.0?" ON) ++# Source code has one additional file in git version after 2.1.0 was released. ++if(POST_2.1.0) ++ list(APPEND libharu_SRCS ++ hpdf_namedict.c ++ ) ++endif(POST_2.1.0) ++ ++# Set macros to define visibility for various Windows platforms. ++# (gcc visibility support happens by default if none of these ++# are defined). ++ ++if(CYGWIN OR MINGW) ++ add_definitions(-DHPDF_DLL_MAKE_CDECL) ++elseif(WIN32) ++ add_definitions(-DHPDF_DLL_MAKE) ++endif(CYGWIN OR MINGW) ++ ++# ======================================================================= ++# create static and shared haru library ++# ======================================================================= ++if(LIBHARU_STATIC) ++ add_library(hpdf_static STATIC ${libharu_SRCS}) ++ target_link_libraries(hpdf_static ${ADDITIONAL_LIBRARIES}) ++ set_target_properties( ++ hpdf_static ++ PROPERTIES ++ OUTPUT_NAME hpdf ++ ) ++ install( ++ TARGETS hpdf_static ++ ARCHIVE DESTINATION lib ++ LIBRARY DESTINATION lib ++ RUNTIME DESTINATION bin ++ ) ++ if(WIN32 AND NOT CYGWIN) ++ foreach(addlib ${ADDITIONAL_LIBRARIES}) ++ install(FILES ${addlib} DESTINATION lib) ++ endforeach(addlib) ++ endif(WIN32 AND NOT CYGWIN) ++endif(LIBHARU_STATIC) ++if(LIBHARU_SHARED) ++ add_library(hpdf SHARED ${libharu_SRCS}) ++ target_link_libraries(hpdf ${ADDITIONAL_LIBRARIES}) ++ if(USE_RPATH) ++ set_target_properties( ++ hpdf ++ PROPERTIES ++ SOVERSION ${hpdf_SOVERSION} ++ VERSION ${hpdf_VERSION} ++ INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib" ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ else(USE_RPATH) ++ set_target_properties( ++ hpdf ++ PROPERTIES ++ SOVERSION ${hpdf_SOVERSION} ++ VERSION ${hpdf_VERSION} ++ INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ++ ) ++ endif(USE_RPATH) ++ ++ install( ++ TARGETS hpdf ++ ARCHIVE DESTINATION lib ++ LIBRARY DESTINATION lib ++ RUNTIME DESTINATION bin ++ ) ++endif(LIBHARU_SHARED) Deleted: trunk/cmake/build_projects/libharu/include_hpdf_config.h.patch =================================================================== --- trunk/cmake/build_projects/libharu/include_hpdf_config.h.patch 2013-10-21 01:11:34 UTC (rev 12614) +++ trunk/cmake/build_projects/libharu/include_hpdf_config.h.patch 2013-10-21 22:14:00 UTC (rev 12615) @@ -1,11 +0,0 @@ -diff -Naur build_libharu_original/src/hpdf_streams.c build_libharu/src/hpdf_streams.c ---- build_libharu_original/src/hpdf_streams.c 2008-05-27 11:23:31.000000000 -0700 -+++ build_libharu/src/hpdf_streams.c 2013-06-04 12:33:49.304096528 -0700 -@@ -17,6 +17,7 @@ - - #include <errno.h> - -+#include "hpdf_config.h" - #ifndef HPDF_NOZLIB - #include <zlib.h> - #include <zconf.h> Added: trunk/cmake/build_projects/libharu/large_font.patch =================================================================== --- trunk/cmake/build_projects/libharu/large_font.patch (rev 0) +++ trunk/cmake/build_projects/libharu/large_font.patch 2013-10-21 22:14:00 UTC (rev 12615) @@ -0,0 +1,24 @@ +diff -Naur libharu-2.2.1_pristine/include/hpdf_consts.h libharu-2.2.1/include/hpdf_consts.h +--- libharu-2.2.1_pristine/include/hpdf_consts.h 2010-11-22 01:57:44.000000000 -0800 ++++ libharu-2.2.1/include/hpdf_consts.h 2013-10-21 09:55:26.093664806 -0700 +@@ -142,7 +142,7 @@ + #define HPDF_MAX_WORDSPACE 300 + #define HPDF_MIN_CHARSPACE -30 + #define HPDF_MAX_CHARSPACE 300 +-#define HPDF_MAX_FONTSIZE 300 ++#define HPDF_MAX_FONTSIZE 600 + #define HPDF_MAX_ZOOMSIZE 10 + #define HPDF_MAX_LEADING 300 + #define HPDF_MAX_LINEWIDTH 100 +diff -Naur libharu-2.2.1_pristine/src/hpdf_page_operator.c libharu-2.2.1/src/hpdf_page_operator.c +--- libharu-2.2.1_pristine/src/hpdf_page_operator.c 2010-02-01 02:26:13.000000000 -0800 ++++ libharu-2.2.1/src/hpdf_page_operator.c 2013-10-21 09:55:26.093664806 -0700 +@@ -1162,7 +1162,7 @@ + return HPDF_RaiseError (page->error, HPDF_PAGE_INVALID_FONT, 0); + + if (size <= 0 || size > HPDF_MAX_FONTSIZE) +- return HPDF_RaiseError (page->error, HPDF_PAGE_INVALID_FONT_SIZE, 0); ++ return HPDF_RaiseError (page->error, HPDF_PAGE_INVALID_FONT_SIZE, size); + + if (page->mmgr != font->mmgr) + return HPDF_RaiseError (page->error, HPDF_PAGE_INVALID_FONT, 0); Added: trunk/cmake/build_projects/libharu/missing_zlib_headers.patch =================================================================== --- trunk/cmake/build_projects/libharu/missing_zlib_headers.patch (rev 0) +++ trunk/cmake/build_projects/libharu/missing_zlib_headers.patch 2013-10-21 22:14:00 UTC (rev 12615) @@ -0,0 +1,11 @@ +diff -Naur libharu-2.2.1_pristine/src/hpdf_streams.c libharu-2.2.1/src/hpdf_streams.c +--- libharu-2.2.1_pristine/src/hpdf_streams.c 2010-02-08 01:49:57.000000000 -0800 ++++ libharu-2.2.1/src/hpdf_streams.c 2013-10-21 11:47:12.026846086 -0700 +@@ -23,6 +23,7 @@ + #include "hpdf_consts.h" + #include "hpdf_utils.h" + #include "hpdf_streams.h" ++#include "hpdf_config.h" + + #ifndef LIBHPDF_HAVE_NOZLIB + #include <zlib.h> Added: trunk/cmake/build_projects/libharu/visibility.patch =================================================================== --- trunk/cmake/build_projects/libharu/visibility.patch (rev 0) +++ trunk/cmake/build_projects/libharu/visibility.patch 2013-10-21 22:14:00 UTC (rev 12615) @@ -0,0 +1,72 @@ +diff -Naur libharu-2.2.1_pristine/include/hpdf.h libharu-2.2.1/include/hpdf.h +--- libharu-2.2.1_pristine/include/hpdf.h 2010-11-22 01:57:27.000000000 -0800 ++++ libharu-2.2.1/include/hpdf.h 2013-10-21 11:35:14.480238924 -0700 +@@ -20,34 +20,33 @@ + #include "hpdf_config.h" + #include "hpdf_version.h" + +-#ifdef HPDF_DLL_MAKE +-# define HPDF_EXPORT(A) __declspec(dllexport) A __stdcall ++#if defined ( hpdf_EXPORTS ) ++ #if defined ( HPDF_DLL_MAKE ) ++ #define HPDF_EXPORT(A) __declspec(dllexport) A __stdcall ++ #elif defined ( HPDF_DLL_MAKE_CDECL ) ++ #define HPDF_EXPORT(A) __declspec(dllexport) A ++ #elif defined ( __GNUC__ ) && __GNUC__ > 3 ++ // Follow ideas in http://gcc.gnu.org/wiki/Visibility for GCC version 4.x ++ #define HPDF_EXPORT(A) __attribute__ ((visibility("default"))) A ++ #elif defined ( HPDF_SHARED_MAKE ) ++ #define HPDF_EXPORT(A) extern A ++ #else ++ #define HPDF_EXPORT(A) extern A ++ #endif + #else +-# ifdef HPDF_DLL_MAKE_CDECL +-# define HPDF_EXPORT(A) __declspec(dllexport) A +-# else +-# ifdef HPDF_SHARED_MAKE +-# define HPDF_EXPORT(A) extern A +-# endif /* HPDF_SHARED_MAKE */ +-# endif /* HPDF_DLL_MAKE_CDECL */ +-#endif /* HPDF_DLL_MAKE */ +- +-#ifdef HPDF_DLL +-# define HPDF_SHARED +-# define HPDF_EXPORT(A) __declspec(dllimport) A __stdcall +-#else +-# ifdef HPDF_DLL_CDECL +-# define HPDF_SHARED +-# define HPDF_EXPORT(A) __declspec(dllimport) A +-# endif /* HPDF_DLL_CDECL */ +-#endif /* HPDF_DLL */ ++ #if defined ( HPDF_DLL) ++ #define HPDF_SHARED ++ #define HPDF_EXPORT(A) __declspec(dllimport) A __stdcall ++ #elif defined ( HPDF_DLL_CDECL ) ++ #define HPDF_SHARED ++ #define HPDF_EXPORT(A) __declspec(dllimport) A ++ #else ++ #define HPDF_EXPORT(A) extern A ++ #endif ++#endif + + #ifdef HPDF_SHARED + +-#ifndef HPDF_EXPORT +-#define HPDF_EXPORT(A) extern A +-#endif /* HPDF_EXPORT */ +- + #include "hpdf_consts.h" + #include "hpdf_types.h" + +@@ -75,10 +74,6 @@ + + #else + +-#ifndef HPDF_EXPORT +-#define HPDF_EXPORT(A) A +-#endif /* HPDF_EXPORT */ +- + #include "hpdf_consts.h" + #include "hpdf_doc.h" + #include "hpdf_error.h" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |