/[gentoo-x86]/eclass/cmake-utils.eclass
Gentoo

Diff of /eclass/cmake-utils.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.11 Revision 1.13
1# Copyright 1999-2007 Gentoo Foundation 1# Copyright 1999-2007 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/cmake-utils.eclass,v 1.11 2008/10/27 05:06:41 vapier Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/cmake-utils.eclass,v 1.13 2008/10/27 14:38:38 vapier Exp $
4 4
5# @ECLASS: cmake-utils.eclass 5# @ECLASS: cmake-utils.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# kde@gentoo.org 7# kde@gentoo.org
8# @BLURB: common ebuild functions for cmake-based packages 8# @BLURB: common ebuild functions for cmake-based packages
83# General function for configuring with cmake. Default behaviour is to start an 83# General function for configuring with cmake. Default behaviour is to start an
84# out-of-source build. 84# out-of-source build.
85cmake-utils_src_configure() { 85cmake-utils_src_configure() {
86 debug-print-function $FUNCNAME $* 86 debug-print-function $FUNCNAME $*
87 87
88 if has debug ${IUSE//+} && use debug ; then 88 if ! has debug ${IUSE//+} || ! use debug ; then
89 append-cppflags -DNDEBUG 89 append-cppflags -DNDEBUG
90 fi 90 fi
91 91
92 if [[ -n "${CMAKE_IN_SOURCE_BUILD}" ]]; then 92 if [[ -n "${CMAKE_IN_SOURCE_BUILD}" ]]; then
93 cmake-utils_src_configurein 93 cmake-utils_src_configurein
144 144
145# Internal use only. Common configuration options for all types of builds. 145# Internal use only. Common configuration options for all types of builds.
146_common_configure_code() { 146_common_configure_code() {
147 local tmp_libdir=$(get_libdir) 147 local tmp_libdir=$(get_libdir)
148 # CMAKE_BUILD_TYPE only modifies compiler flags, so set to None 148 # CMAKE_BUILD_TYPE only modifies compiler flags, so set to None
149 echo -DCMAKE_BUILD_TYPE=None 149 echo -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE:-None}
150 echo -DCMAKE_C_COMPILER=$(type -P $(tc-getCC)) 150 echo -DCMAKE_C_COMPILER=$(type -P $(tc-getCC))
151 echo -DCMAKE_CXX_COMPILER=$(type -P $(tc-getCXX)) 151 echo -DCMAKE_CXX_COMPILER=$(type -P $(tc-getCXX))
152 echo -DCMAKE_INSTALL_PREFIX=${PREFIX:-/usr} 152 echo -DCMAKE_INSTALL_PREFIX=${PREFIX:-/usr}
153 echo -DLIB_SUFFIX=${tmp_libdir/lib} 153 echo -DLIB_SUFFIX=${tmp_libdir/lib}
154 echo -DLIB_INSTALL_DIR=${PREFIX:-/usr}/${tmp_libdir} 154 echo -DLIB_INSTALL_DIR=${PREFIX:-/usr}/${tmp_libdir}

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.13

  ViewVC Help
Powered by ViewVC 1.1.20