Skip to content

Commit

Permalink
Beef up the CPack-based packaging options.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.openimageio.org/oiio/trunk@692 31904243-a364-42ac-a3db-9305396518ba
  • Loading branch information
lgritz committed May 20, 2009
1 parent 30d3f6d commit 84e8511
Show file tree
Hide file tree
Showing 4 changed files with 78 additions and 42 deletions.
54 changes: 27 additions & 27 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
OpenImageIO and all code, documentation, and other materials contained
therein are:
OpenImageIO and all code, documentation, and other materials contained
therein are:

Copyright 2008 Larry Gritz and the other authors and contributors.
All Rights Reserved.
Copyright 2008 Larry Gritz and the other authors and contributors.
All Rights Reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of the software's owners nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of the software's owners nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

(This is the Modified BSD License)
(This is the Modified BSD License)
41 changes: 26 additions & 15 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ SET (CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE)
MESSAGE ( STATUS "Project source dir = ${PROJECT_SOURCE_DIR}" )
MESSAGE ( STATUS "Project build dir = ${CMAKE_BINARY_DIR}" )

#PROJECT_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR} )
# MESSAGE ( FATAL_ERROR "Not allowed to run in-source build!" )
#ENDIF ()
IF ( ${PROJECT_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR} )
MESSAGE ( FATAL_ERROR "Not allowed to run in-source build!" )
ENDIF ()


IF ( NOT CMAKE_BUILD_TYPE )
Expand Down Expand Up @@ -93,7 +93,7 @@ ADD_SUBDIRECTORY ( include )
ADD_SUBDIRECTORY ( doc )



#########################################################################
# Testing
INCLUDE ( CTest )
ADD_SUBDIRECTORY ( testtex )
Expand All @@ -105,29 +105,40 @@ EXEC_PROGRAM ( "cmake -E create_symlink ${PROJECT_SOURCE_DIR}/../testsuite ${PRO
ADD_SUBDIRECTORY ( testsuite )


#########################################################################
# Packaging
SET ( CPACK_PACKAGE_VERSION_MAJOR ${OpenImageIO_VERSION_MAJOR} )
SET ( CPACK_PACKAGE_VERSION_MINOR ${OpenImageIO_VERSION_MINOR} )
SET ( CPACK_PACKAGE_VERSION_PATCH ${OpenImageIO_VERSION_PATCH} )
#SET ( CPACK_PACKAGE_DESCRIPTION_FILE ...FIXME... )
#SET ( CPACK_PACKAGE_DESCRIPTION_SUMMARY ...FIXME... )
#SET ( CPACK_PACKAGE_DESCRIPTION_FILE ...FIXME... )
# "Vendor" is only used in copyright notices, so we use the same thing that
# the rest of the copyright notices say.
SET ( CPACK_PACKAGE_VENDOR "Larry Gritz et al.")
SET ( CPACK_PACKAGE_DESCRIPTION_SUMMARY "OpenImageIO is an open source library for reading and writing image file formats, a nice format-agnostic image viewer, and other image-related classes and utilities." )
SET ( CPACK_PACKAGE_DESCRIPTION_FILE "${PROJECT_SOURCE_DIR}/doc/Description.txt" )
SET ( CPACK_PACKAGE_FILE_NAME OpenImageIO-${OpenImageIO_VERSION_MAJOR}.${OpenImageIO_VERSION_MINOR}.${OpenImageIO_VERSION_PATCH}-${platform} )
#SET ( CPACK_PACKAGE_INSTALL_DIRECTORY ${PROJECT_SOURCE_DIR}/.. )
#SET ( CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/../LICENSE" )
#SET ( CPACK_RESOURCE_FILE_README "${PROJECT_SOURCE_DIR}/../README" )
#SET ( CPACK_RESOURCE_FILE_WELCOME ...FIXME... )
#SET ( CPACK_PACKAGE_EXECUTABLES iv )
#SET ( CPACK_STRIP_FILES ...FIXME... )
EXEC_PROGRAM ( "cmake -E copy ${PROJECT_SOURCE_DIR}/../LICENSE ${CMAKE_BINARY_DIR}/License.txt" )
SET ( CPACK_RESOURCE_FILE_LICENSE "${CMAKE_BINARY_DIR}/License.txt" )
EXEC_PROGRAM ( "cmake -E copy ${PROJECT_SOURCE_DIR}/../README ${CMAKE_BINARY_DIR}/Readme.txt" )
SET ( CPACK_RESOURCE_FILE_README "${CMAKE_BINARY_DIR}/Readme.txt" )
SET ( CPACK_RESOURCE_FILE_WELCOME "${PROJECT_SOURCE_DIR}/doc/Welcome.txt" )
#SET ( CPACK_PACKAGE_EXECUTABLES I'm not sure what this is for )
#SET ( CPACK_STRIP_FILES Do we need this? )
IF ( ${CMAKE_SYSTEM_NAME} STREQUAL "Linux" )
SET ( CPACK_GENERATOR "TGZ;STGZ;RPM;DEB" )
SET ( CPACK_SOURCE_GENERATOR "TGZ" )
ENDIF ()
IF ( APPLE )
SET ( CPACK_GENERATOR "TGZ;STGZ;PackageMaker" )
SET ( CPACK_SOURCE_GENERATOR "TGZ" )
ENDIF ()
SET ( CPACK_SOURCE_PACKAGE_FILE_NAME OpenImageIO-${OpenImageIO_VERSION_MAJOR}.${OpenImageIO_VERSION_MINOR}.${OpenImageIO_VERSION_PATCH}-source )
#SET ( CPACK_SOURCE_STRIP_FILES ...FIXME... )
#SET ( CPACK_SOURCE_IGNORE_FILES "\\.svn;\\.#;.*~" )
#SET ( CPACK_SOURCE_STRIP_FILES Do we need this? )
SET ( CPACK_SOURCE_IGNORE_FILES ".*~" )
INCLUDE ( CPack )

# TODO: equivalents of the old:
# * make doxygen
# * make help
# * BOOST_DYNAMIC

# Do TIFF, JPEG, PNG actually look in external?
11 changes: 11 additions & 0 deletions src/doc/Description.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
OpenImageIO consists of:

* Simple APIs for reading and writing image files in a format-agnostic
manner, and plugins to read many common image formats including
TIFF, JPEG, OpenEXR, PNG, HDR, ICO, and BMP.
* Image utilities, including an image viewer, printing image information,
format conversion, image comparison, and others.
* A library for image texture lookups, and a managed image cache
that allows an application to access hundreds of GB of image data
using little runtime RAM.

14 changes: 14 additions & 0 deletions src/doc/Welcome.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Thank you for selecting OpenImageIO. You must be very wise, as well
as irresistably attractive!

OpenImageIO consists of:

* Simple APIs for reading and writing image files in a format-agnostic
manner, and plugins to read many common image formats including
TIFF, JPEG, OpenEXR, PNG, HDR, ICO, and BMP.
* Image utilities, including an image viewer, printing image information,
format conversion, image comparison, and others.
* A library for image texture lookups, and a managed image cache
that allows an application to access hundreds of GB of image data
using little runtime RAM.

0 comments on commit 84e8511

Please sign in to comment.