diff options
author | Robert Schwebel <r.schwebel@pengutronix.de> | 2005-06-10 06:26:58 +0000 |
---|---|---|
committer | Robert Schwebel <r.schwebel@pengutronix.de> | 2005-06-10 06:26:58 +0000 |
commit | b7acf87b24c3ac54be88ade5718c9d9f307ee3ea (patch) | |
tree | 4cbed68c018d68e39d7a87a1dfe7c98c2fec4d96 /rules/cppunit.make | |
parent | f80be9107c6db05e438d9688d3b888990d1c6326 (diff) | |
download | ptxdist-b7acf87b24c3ac54be88ade5718c9d9f307ee3ea.tar.gz ptxdist-b7acf87b24c3ac54be88ade5718c9d9f307ee3ea.tar.xz |
* cppunit: added; patch by Shahar Livne
git-svn-id: https://svn.pengutronix.de/svn/ptxdist/trunks/ptxdist-0.7-trunk@2728 33e552b5-05e3-0310-8538-816dae2090ed
Diffstat (limited to 'rules/cppunit.make')
-rw-r--r-- | rules/cppunit.make | 155 |
1 files changed, 155 insertions, 0 deletions
diff --git a/rules/cppunit.make b/rules/cppunit.make new file mode 100644 index 000000000..b1d75b62f --- /dev/null +++ b/rules/cppunit.make @@ -0,0 +1,155 @@ +# -*-makefile-*- +# $Id: cppunit.make $ +# +# Copyright (C) 2005 by Shahar Livne <shahar@livnex.com> +# +# See CREDITS for details about who has contributed to this project. +# +# For further information about the PTXdist project and license conditions +# see the README file. +# + +# +# We provide this package +# +ifdef PTXCONF_CPPUNIT +PACKAGES += cppunit +endif + +# +# Paths and names +# +CPPUNIT_VERSION = 1.10.2 +CPPUNIT = cppunit-$(CPPUNIT_VERSION) +CPPUNIT_SUFFIX = tar.gz +CPPUNIT_URL = $(PTXCONF_SETUP_SFMIRROR)/cppunit/$(CPPUNIT).$(CPPUNIT_SUFFIX) +CPPUNIT_SOURCE = $(SRCDIR)/$(CPPUNIT).$(CPPUNIT_SUFFIX) +CPPUNIT_DIR = $(BUILDDIR)/$(CPPUNIT) + +# ---------------------------------------------------------------------------- +# Get +# ---------------------------------------------------------------------------- + +cppunit_get: $(STATEDIR)/cppunit.get + +cppunit_get_deps = $(CPPUNIT_SOURCE) + +$(STATEDIR)/cppunit.get: $(cppunit_get_deps) + @$(call targetinfo, $@) + @$(call get_patches, $(CPPUNIT)) + touch $@ + +$(CPPUNIT_SOURCE): + @$(call targetinfo, $@) + @$(call get, $(CPPUNIT_URL)) + +# ---------------------------------------------------------------------------- +# Extract +# ---------------------------------------------------------------------------- + +cppunit_extract: $(STATEDIR)/cppunit.extract + +cppunit_extract_deps = $(STATEDIR)/cppunit.get + +$(STATEDIR)/cppunit.extract: $(cppunit_extract_deps) + @$(call targetinfo, $@) + @$(call clean, $(CPPUNIT_DIR)) + @$(call extract, $(CPPUNIT_SOURCE)) + @$(call patchin, $(CPPUNIT)) + touch $@ + +# ---------------------------------------------------------------------------- +# Prepare +# ---------------------------------------------------------------------------- + +cppunit_prepare: $(STATEDIR)/cppunit.prepare + +# +# dependencies +# +cppunit_prepare_deps = \ + $(STATEDIR)/cppunit.extract + + +CPPUNIT_PATH = PATH=$(CROSS_PATH) +CPPUNIT_ENV = $(CROSS_ENV) +#CPPUNIT_ENV += + +# +# autoconf +# +CPPUNIT_AUTOCONF = $(CROSS_AUTOCONF) + +$(STATEDIR)/cppunit.prepare: $(cppunit_prepare_deps) + @$(call targetinfo, $@) + @$(call clean, $(CPPUNIT_DIR)/config.cache) + cd $(CPPUNIT_DIR) && \ + $(CPPUNIT_PATH) $(CPPUNIT_ENV) \ + ./configure $(CPPUNIT_AUTOCONF) + touch $@ + +# ---------------------------------------------------------------------------- +# Compile +# ---------------------------------------------------------------------------- + +cppunit_compile: $(STATEDIR)/cppunit.compile + +cppunit_compile_deps = $(STATEDIR)/cppunit.prepare + +$(STATEDIR)/cppunit.compile: $(cppunit_compile_deps) + @$(call targetinfo, $@) + cd $(CPPUNIT_DIR) && $(CPPUNIT_ENV) $(CPPUNIT_PATH) make + touch $@ + +# ---------------------------------------------------------------------------- +# Install +# ---------------------------------------------------------------------------- + +cppunit_install: $(STATEDIR)/cppunit.install + +$(STATEDIR)/cppunit.install: $(STATEDIR)/cppunit.compile + @$(call targetinfo, $@) + cd $(CPPUNIT_DIR) && $(CPPUNIT_PATH) make install + touch $@ + +# ---------------------------------------------------------------------------- +# Target-Install +# ---------------------------------------------------------------------------- + +cppunit_targetinstall: $(STATEDIR)/cppunit.targetinstall + +cppunit_targetinstall_deps = $(STATEDIR)/cppunit.install + +$(STATEDIR)/cppunit.targetinstall: $(cppunit_targetinstall_deps) + @$(call targetinfo, $@) + + @$(call install_init,default) + @$(call install_fixup,PACKAGE,$(CPPUNIT)) + @$(call install_fixup,PRIORITY,optional) + @$(call install_fixup,VERSION,$(CPPUNIT_VERSION)) + @$(call install_fixup,SECTION,base) + @$(call install_fixup,AUTHOR,"Shahar Livne <shahar\@livnex.com>") + @$(call install_fixup,DEPENDS,) + @$(call install_fixup,DESCRIPTION,missing) + + @$(call install_copy, 0, 0, 0644, \ + $(CPPUNIT_DIR)/src/cppunit/.libs/libcppunit-1.10.so.2.0.0, \ + /usr/lib/libcppunit-1.10.so.2.0.0) + + @$(call install_link, libcppunit-1.10.so.2.0.0, /usr/lib/libcppunit-1.10.so.2) + @$(call install_link, libcppunit-1.10.so.2.0.0, /usr/lib/libcppunit.so) + + @$(call install_finish) + + touch $@ + +# ---------------------------------------------------------------------------- +# Clean +# ---------------------------------------------------------------------------- + +cppunit_clean: + rm -rf $(STATEDIR)/cppunit.* + rm -rf $(IMAGEDIR)/cppunit_* + rm -rf $(CPPUNIT_DIR) + +# vim: syntax=make |