diff options
-rw-r--r-- | rules/Rules.make | 2 | ||||
-rw-r--r-- | rules/host-cmake.in | 6 | ||||
-rw-r--r-- | rules/host-cmake.make | 108 | ||||
-rw-r--r-- | rules/hosttools.in | 1 |
4 files changed, 117 insertions, 0 deletions
diff --git a/rules/Rules.make b/rules/Rules.make index b1d50de50..d22af75a6 100644 --- a/rules/Rules.make +++ b/rules/Rules.make @@ -21,6 +21,7 @@ DEP_TREE_A4_PS = deptree-a4.ps SUDO = sudo HOSTCC = gcc +HOSTCXX = g++ DOT = dot SH = /bin/sh # FIXME: disabled caching in wget. Make sure that all patches on the webserver @@ -68,6 +69,7 @@ CHECKINSTALL = endif HOSTCC_ENV = CC=$(HOSTCC) +HOSTCXX_ENV = CXX=$(HOSTCXX) CHECK_PIPE_STATUS = \ for i in "$${PIPESTATUS[@]}"; do [ $$i -gt 0 ] && { \ diff --git a/rules/host-cmake.in b/rules/host-cmake.in new file mode 100644 index 000000000..a37c434c5 --- /dev/null +++ b/rules/host-cmake.in @@ -0,0 +1,6 @@ +config HOST_CMAKE + bool + prompt "cmake 2.4.2" + select HOST_FAKEROOT + help + diff --git a/rules/host-cmake.make b/rules/host-cmake.make new file mode 100644 index 000000000..093b58179 --- /dev/null +++ b/rules/host-cmake.make @@ -0,0 +1,108 @@ +# -*-makefile-*- +# $Id$ +# +# Copyright (C) 2006 by Erwin Rol +# +# 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 +# +HOST_PACKAGES-$(PTXCONF_HOST_CMAKE) += host-cmake + +# +# Paths and names +# +HOST_CMAKE_VERSION = 2.4.2 +HOST_CMAKE = cmake-$(HOST_CMAKE_VERSION) +HOST_CMAKE_SUFFIX = tar.gz +HOST_CMAKE_URL = http://www.cmake.org/files/v2.4/$(HOST_CMAKE).$(HOST_CMAKE_SUFFIX) +HOST_CMAKE_SOURCE = $(SRCDIR)/$(HOST_CMAKE).$(HOST_CMAKE_SUFFIX) +HOST_CMAKE_DIR = $(HOST_BUILDDIR)/$(HOST_CMAKE) + +-include $(call package_depfile) + +# ---------------------------------------------------------------------------- +# Get +# ---------------------------------------------------------------------------- + +host-cmake_get: $(STATEDIR)/host-cmake.get + +$(STATEDIR)/host-cmake.get: $(host-cmake_get_deps_default) + @$(call targetinfo, $@) + @$(call touch, $@) + +$(HOST_CMAKE_SOURCE): + @$(call targetinfo, $@) + @$(call get, HOST_CMAKE) + +# ---------------------------------------------------------------------------- +# Extract +# ---------------------------------------------------------------------------- + +host-cmake_extract: $(STATEDIR)/host-cmake.extract + +$(STATEDIR)/host-cmake.extract: $(host-cmake_extract_deps_default) + @$(call targetinfo, $@) + @$(call clean, $(HOST_CMAKE_DIR)) + @$(call extract, HOST_CMAKE, $(HOST_BUILDDIR)) + @$(call patchin, HOST_CMAKE, $(HOST_CMAKE_DIR)) + @$(call touch, $@) + +# ---------------------------------------------------------------------------- +# Prepare +# ---------------------------------------------------------------------------- + +host-cmake_prepare: $(STATEDIR)/host-cmake.prepare + +HOST_CMAKE_PATH = PATH=$(HOST_PATH) +HOST_CMAKE_ENV = $(HOSTCC_ENV) $(HOSTCXX_ENV) + +# +# autoconf +# +HOST_CMAKE_AUTOCONF = $(HOST_AUTOCONF) + +$(STATEDIR)/host-cmake.prepare: $(host-cmake_prepare_deps_default) + @$(call targetinfo, $@) + @$(call clean, $(HOST_CMAKE_DIR)/config.cache) + cd $(HOST_CMAKE_DIR) && \ + $(HOST_CMAKE_PATH) $(HOST_CMAKE_ENV) \ + ./configure $(HOST_CMAKE_AUTOCONF) + @$(call touch, $@) + +# ---------------------------------------------------------------------------- +# Compile +# ---------------------------------------------------------------------------- + +host-cmake_compile: $(STATEDIR)/host-cmake.compile + +$(STATEDIR)/host-cmake.compile: $(host-cmake_compile_deps_default) + @$(call targetinfo, $@) + cd $(HOST_CMAKE_DIR) && $(HOST_CMAKE_ENV) $(HOST_CMAKE_PATH) make VERBOSE=1 + @$(call touch, $@) + +# ---------------------------------------------------------------------------- +# Install +# ---------------------------------------------------------------------------- + +host-cmake_install: $(STATEDIR)/host-cmake.install + +$(STATEDIR)/host-cmake.install: $(host-cmake_install_deps_default) + @$(call targetinfo, $@) + @$(call install, HOST_CMAKE,,h) + @$(call touch, $@) + +# ---------------------------------------------------------------------------- +# Clean +# ---------------------------------------------------------------------------- + +host-cmake_clean: + rm -rf $(STATEDIR)/host-cmake.* + rm -rf $(HOST_CMAKE_DIR) + +# vim: syntax=make diff --git a/rules/hosttools.in b/rules/hosttools.in index df8d661e3..78ffb1ece 100644 --- a/rules/hosttools.in +++ b/rules/hosttools.in @@ -38,6 +38,7 @@ source "rules/host-mico.in" source "rules/host-pkg-config-wrapper.in" source "rules/host-qte.in" source "rules/host-slirp.in" +source "rules/host-cmake.in" ############################################################################## comment "Scripting Languages" |