/[gentoo-x86]/eclass/vdr-plugin.eclass
Gentoo

Diff of /eclass/vdr-plugin.eclass

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

Revision 1.31 Revision 1.33
1# Copyright 1999-2005 Gentoo Foundation 1# Copyright 1999-2005 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/Attic/vdr-plugin.eclass,v 1.31 2006/09/07 18:49:44 zzam Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/Attic/vdr-plugin.eclass,v 1.33 2006/09/19 19:31:33 zzam Exp $
4# 4#
5# Author: 5# Author:
6# Matthias Schwarzott <zzam@gentoo.org> 6# Matthias Schwarzott <zzam@gentoo.org>
7# Joerg Bornkessel <hd_brummy@gentoo.org> 7# Joerg Bornkessel <hd_brummy@gentoo.org>
8 8
185 -e '/@.*strip/d' \ 185 -e '/@.*strip/d' \
186 -e '/strip \$(LIBDIR)\/\$@/d' \ 186 -e '/strip \$(LIBDIR)\/\$@/d' \
187 -e '/^STRIP =/d' \ 187 -e '/^STRIP =/d' \
188 -e '/@.*\$(STRIP)/d' 188 -e '/@.*\$(STRIP)/d'
189 eend $? 189 eend $?
190
191 # Use a file instead of an variable as single-stepping via ebuild
192 # destroys environment.
193 touch ${WORKDIR}/.vdr-plugin_makefile_patched
190 ;; 194 ;;
191 add_local_patch) 195 add_local_patch)
192 cd ${S} 196 cd ${S}
193 if test -d "${VDR_LOCAL_PATCHES_DIR}/${PN}"; then 197 if test -d "${VDR_LOCAL_PATCHES_DIR}/${PN}"; then
194 echo 198 echo
203 shift 207 shift
204 done 208 done
205} 209}
206 210
207vdr-plugin_copy_source_tree() { 211vdr-plugin_copy_source_tree() {
212 pushd . >/dev/null
208 cp -r ${S} ${T}/source-tree 213 cp -r ${S} ${T}/source-tree
209 cd ${T}/source-tree 214 cd ${T}/source-tree
210 mv Makefile.orig Makefile 215 mv Makefile.orig Makefile
211 sed -i Makefile \ 216 sed -i Makefile \
212 -e "s:^DVBDIR.*$:DVBDIR = ${DVB_INCLUDE_DIR}:" \ 217 -e "s:^DVBDIR.*$:DVBDIR = ${DVB_INCLUDE_DIR}:" \
213 -e 's:^CXXFLAGS:#CXXFLAGS:' \ 218 -e 's:^CXXFLAGS:#CXXFLAGS:' \
214 -e 's:-I$(DVBDIR)/include:-I$(DVBDIR):' \ 219 -e 's:-I$(DVBDIR)/include:-I$(DVBDIR):' \
215 -e 's:-I$(VDRDIR) -I$(DVBDIR):-I$(DVBDIR) -I$(VDRDIR):' 220 -e 's:-I$(VDRDIR) -I$(DVBDIR):-I$(DVBDIR) -I$(VDRDIR):'
221 popd >/dev/null
216} 222}
217 223
218vdr-plugin_install_source_tree() { 224vdr-plugin_install_source_tree() {
219 einfo "Installing sources" 225 einfo "Installing sources"
220 destdir=${VDRSOURCE_DIR}/vdr-${VDRVERSION}/PLUGINS/src/${VDRPLUGIN} 226 destdir=${VDRSOURCE_DIR}/vdr-${VDRVERSION}/PLUGINS/src/${VDRPLUGIN}
232 case "$1" in 238 case "$1" in
233 prepare) 239 prepare)
234 [[ -n "${VDRSOURCE_DIR}" ]] && vdr-plugin_copy_source_tree 240 [[ -n "${VDRSOURCE_DIR}" ]] && vdr-plugin_copy_source_tree
235 ;; 241 ;;
236 compile) 242 compile)
243 if [[ ! -f ${WORKDIR}/.vdr-plugin_makefile_patched ]]; then
244 eerror "Wrong use of vdr-plugin.eclass."
245 eerror "An ebuild for a vdr-plugin will not work without"
246 eerror "calling vdr-plugin_src_unpack to patch the Makefile."
247 echo
248 eerror "Please report this at bugs.gentoo.org."
249 die "vdr-plugin_src_unpack not called!"
250 fi
237 cd ${S} 251 cd ${S}
238 252
239 emake ${BUILD_PARAMS} ${VDRPLUGIN_MAKE_TARGET:-all} || die "emake failed" 253 emake ${BUILD_PARAMS} ${VDRPLUGIN_MAKE_TARGET:-all} || die "emake failed"
240 ;; 254 ;;
241 esac 255 esac

Legend:
Removed from v.1.31  
changed lines
  Added in v.1.33

  ViewVC Help
Powered by ViewVC 1.1.20