add better working-g++ check (patch from #2017)
[openwrt.git] / tools / patch-cmdline / Makefile
1 #
2 # Copyright (C) 2007 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
9 PKG_NAME:=patch-cmdline
10
11 PKG_BUILD_DIR:=$(TOOL_BUILD_DIR)/$(PKG_NAME)
12
13 include $(INCLUDE_DIR)/host-build.mk
14
15 OS:=$(shell uname)
16 ifeq ($(HOST_OS),Darwin)
17 CFLAGS += -I./include
18 endif
19 CFLAGS += -I $(TOPDIR)/tools/include -include endian.h
20
21 define Build/Compile
22 $(CC) $(CFLAGS) -o $(PKG_BUILD_DIR)/$(PKG_NAME) src/$(PKG_NAME).c
23 endef
24
25 define Build/Install
26 mkdir -p $(STAGING_DIR)/bin
27 $(CP) $(PKG_BUILD_DIR)/patch-cmdline $(STAGING_DIR)/bin/
28 endef
29
30 define Build/Clean
31 -rm -f $(STAGING_DIR)/bin/patch-cmdline
32 endef
33
34 $(eval $(call HostBuild))
This page took 0.047536 seconds and 5 git commands to generate.