/[gentoo-x86]/eclass/flag-o-matic.eclass
Gentoo

Diff of /eclass/flag-o-matic.eclass

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

Revision 1.153 Revision 1.154
1# Copyright 1999-2009 Gentoo Foundation 1# Copyright 1999-2009 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/flag-o-matic.eclass,v 1.153 2011/08/17 17:54:48 vapier Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/flag-o-matic.eclass,v 1.154 2011/08/17 17:59:35 vapier Exp $
4 4
5# @ECLASS: flag-o-matic.eclass 5# @ECLASS: flag-o-matic.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# toolchain@gentoo.org 7# toolchain@gentoo.org
8# @BLURB: common functions to manipulate and query toolchain flags 8# @BLURB: common functions to manipulate and query toolchain flags
128 128
129# @FUNCTION: filter-lfs-flags 129# @FUNCTION: filter-lfs-flags
130# @DESCRIPTION: 130# @DESCRIPTION:
131# Remove flags that enable Large File Support. 131# Remove flags that enable Large File Support.
132filter-lfs-flags() { 132filter-lfs-flags() {
133 [[ -n $@ ]] && die "filter-lfs-flags takes no arguments" 133 [[ $# -ne 0 ]] && die "filter-lfs-flags takes no arguments"
134 # http://www.gnu.org/s/libc/manual/html_node/Feature-Test-Macros.html 134 # http://www.gnu.org/s/libc/manual/html_node/Feature-Test-Macros.html
135 # _LARGEFILE_SOURCE: enable support for new LFS funcs (ftello/etc...) 135 # _LARGEFILE_SOURCE: enable support for new LFS funcs (ftello/etc...)
136 # _LARGEFILE64_SOURCE: enable support for 64bit variants (off64_t/fseeko64/etc...) 136 # _LARGEFILE64_SOURCE: enable support for 64bit variants (off64_t/fseeko64/etc...)
137 # _FILE_OFFSET_BITS: default to 64bit variants (off_t is defined as off64_t) 137 # _FILE_OFFSET_BITS: default to 64bit variants (off_t is defined as off64_t)
138 filter-flags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE 138 filter-flags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
181 181
182# @FUNCTION: append-lfs-flags 182# @FUNCTION: append-lfs-flags
183# @DESCRIPTION: 183# @DESCRIPTION:
184# Add flags that enable Large File Support. 184# Add flags that enable Large File Support.
185append-lfs-flags() { 185append-lfs-flags() {
186 [[ -n $@ ]] && die "append-lfs-flags takes no arguments" 186 [[ $# -ne 0 ]] && die "append-lfs-flags takes no arguments"
187 append-cppflags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE 187 append-cppflags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
188} 188}
189 189
190# @FUNCTION: append-flags 190# @FUNCTION: append-flags
191# @USAGE: <flags> 191# @USAGE: <flags>

Legend:
Removed from v.1.153  
changed lines
  Added in v.1.154

  ViewVC Help
Powered by ViewVC 1.1.20