ccache: Build with ENABLE_DOCUMENTATION=OFF
[openwrt/openwrt.git] / tools / ccache / Makefile
1 #
2 # Copyright (C) 2006-2015 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 include $(TOPDIR)/rules.mk
8 include $(INCLUDE_DIR)/target.mk
9
10 PKG_NAME:=ccache
11 PKG_VERSION:=4.2.1
12
13 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
14 PKG_SOURCE_URL:=https://github.com/ccache/ccache/releases/download/v$(PKG_VERSION)
15 PKG_HASH:=9d6ba1cdefdc690401f404b747d81a9a1802b17af4235815866b7620d980477e
16
17 HOST_BUILD_PARALLEL:=1
18
19 include $(INCLUDE_DIR)/host-build.mk
20 include $(INCLUDE_DIR)/cmake.mk
21
22 CMAKE_HOST_OPTIONS += \
23 -DCMAKE_C_COMPILER_LAUNCHER="" \
24 -DCMAKE_CXX_COMPILER_LAUNCHER="" \
25 -DCMAKE_SKIP_RPATH=FALSE \
26 -DCMAKE_INSTALL_RPATH="${STAGING_DIR_HOST}/lib" \
27
28 ifneq (docs-$(CONFIG_BUILD_DOCUMENTATION),docs-y)
29 CMAKE_HOST_OPTIONS += -DENABLE_DOCUMENTATION=OFF
30 endif
31
32 define Host/Install/ccache
33 $(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/
34 $(CP) ./files/* $(STAGING_DIR_HOST)/bin/
35 endef
36
37 define Host/Install
38 $(call Host/Install/Default)
39 $(call Host/Install/ccache)
40 endef
41
42 $(eval $(call HostBuild))