Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Check for required tools on 'make prepare'

Fixes #221.
  • Loading branch information...
commit 36ae42b8ffec847819b16d3e257794f8d5e2f45f 1 parent 06fdc7b
@chelmuth chelmuth authored
View
8 base-codezero/Makefile
@@ -12,6 +12,14 @@ CONTRIB_DIR = contrib
PATCHES = $(shell find patches -name *.patch)
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,git)
+$(call check_tool,patch)
+
+#
# Print help information by default
#
help::
View
8 base-foc/Makefile
@@ -31,6 +31,14 @@ SVN_TARGETS = tools/preprocess \
l4/pkg/libvcpu
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,patch)
+$(call check_tool,svn)
+
+#
# Print help information by default
#
help::
View
8 base-nova/Makefile
@@ -12,6 +12,14 @@ NOVA_ARCHIVE = nova-hypervisor-0.4.tar.bz2
NOVA_URI = http://os.inf.tu-dresden.de/~us15/nova/$(NOVA_ARCHIVE)
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+
+#
# Print help information by default
#
help:
View
9 base-okl4/Makefile
@@ -15,6 +15,15 @@ PATCHES = $(shell find patches -name *.patch)
SHELL = bash
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+$(call check_tool,sed)
+
+#
# Determine python version to use for OKL4's elfweaver
#
PYTHON2 := $(notdir $(lastword $(shell which python2 python2.{4,5,6,7,8})))
View
11 base-pistachio/Makefile
@@ -12,6 +12,17 @@ CONTRIB_DIR = contrib
PATCHES = $(shell find patches -name *.patch)
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,git)
+$(call check_tool,patch)
+$(call check_tool,sed)
+$(call check_tool,autoheader)
+$(call check_tool,autoconf)
+
+#
# Print help information by default
#
help::
View
8 dde_ipxe/Makefile
@@ -13,6 +13,14 @@ CONTRIB_DIR = contrib
PATCH_FILE = patches/dde_ipxe.patch
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,git)
+$(call check_tool,patch)
+
+#
# Print help information by default
#
help:
View
8 dde_linux/Makefile
@@ -58,6 +58,14 @@ CONTENT += include/linux/input/mt.h
CONTRIB_CONTENT := $(addprefix $(CONTRIB_DIR)/,$(CONTENT))
+#
+#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
#
# Print help information by default
View
9 libports/Makefile
@@ -23,6 +23,14 @@ SHELL = bash
prepare: $(DOWNLOAD_DIR) $(CONTRIB_DIR)
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+
+#
# Include information about available ports
#
# Each '<port>.mk' file in the 'ports/' directory extends the following
@@ -66,4 +74,3 @@ clean: $(addprefix clean-,$(PKG))
cleanall: clean
$(VERBOSE)rm -rf $(DOWNLOAD_DIR)
-
View
5 libports/ports/ffat.mk
@@ -13,6 +13,11 @@ FFAT_URL = http://genode.org/files/$(FFAT_ZIP)
#
PORTS += ffat-0.07e
+#
+# Check for tools
+#
+$(call check_tool,unzip)
+
prepare-ffat: $(CONTRIB_DIR)/$(FFAT)
$(CONTRIB_DIR)/$(FFAT): clean-ffat
View
8 libports/ports/libc.mk
@@ -6,11 +6,11 @@ LIBC := libc-8.2.0
PORTS += $(LIBC)
#
-# Sanity check for tools
+# Check for tools
#
-ifeq ($(shell which lex),)
-$(error Missing installation of 'lex' (package flex))
-endif
+$(call check_tool,svn)
+$(call check_tool,lex)
+$(call check_tool,yacc)
#
# Subdirectories to check out from FreeBSD's Subversion repository
View
5 libports/ports/lwip.mk
@@ -7,6 +7,11 @@ LWIP_URL = http://mirrors.zerg.biz/nongnu/lwip/$(LWIP_ZIP)
#
PORTS += $(LWIP)
+#
+# Check for tools
+#
+$(call check_tool,unzip)
+
prepare-lwip: $(CONTRIB_DIR)/$(LWIP) include/lwip/lwip include/lwip/netif
$(CONTRIB_DIR)/$(LWIP): clean-lwip
View
6 libports/ports/ncurses.mk
@@ -7,6 +7,12 @@ NCURSES_URL := http://ftp.gnu.org/pub/gnu/ncurses/$(NCURSES_TGZ)
#
PORTS += $(NCURSES)
+#
+# Check for tools
+#
+$(call check_tool,sed)
+$(call check_tool,mawk)
+
NCURSES_SYMLINKED_INC := nc_alloc.h nc_panel.h nc_tparm.h term_entry.h \
tic.h hashed_db.h capdefaults.c
NCURSES_GENERATED_INC := curses.h ncurses_def.h ncurses_dll.h term.h \
View
9 ports-foc/Makefile
@@ -16,11 +16,20 @@ PATCH-l4android = patches/l4android_genode.patch
REV-l4android = 90ca43bd629452ffd38d85fe8c976f069b5bb3d9
REPO-l4android = git://git.l4android.org/kernel.git
+#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,patch)
+
ifeq ($(TARGET), l4android)
+$(call check_tool,git)
DIFF = git diff
UPDATE = cd $(REAL_CONTRIB_DIR)/l4android; git fetch; git reset --hard $(REV-l4android)
PATCH = patch -p1
else
+$(call check_tool,svn)
DIFF = svn diff
UPDATE = svn up -r $(REV-l4linux) $(REAL_CONTRIB_DIR)/l4linux
PATCH = patch -p0
View
9 ports-okl4/Makefile
@@ -16,6 +16,15 @@ OKLX_ARCHIVE = $(OKLX_VERSION).tar.gz
OKLX_CONTRIB = kernel-2.6.23-v2
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+$(call check_tool,sed)
+
+#
# Print help information by default
#
help:
View
8 ports/Makefile
@@ -23,6 +23,14 @@ SHELL = bash
prepare:: $(DOWNLOAD_DIR) $(CONTRIB_DIR)
#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+
+#
# Include information about available ports
#
# Each '<port>.mk' file in the 'ports/' directory extends the following
View
5 ports/ports/vim.mk
@@ -7,6 +7,11 @@ VIM_URL = ftp://ftp.vim.org/pub/vim/unix/$(VIM_TBZ2)
#
PORTS += $(VIM)
+#
+# Check for tools
+#
+$(call check_tool,sed)
+
prepare:: $(CONTRIB_DIR)/$(VIM)
#
View
8 qt4/Makefile
@@ -33,6 +33,14 @@ PATCHES = qt4_genode.patch \
qt4_renderwidget.patch \
qt4_include_time_h.patch
+#
+# Utility to check if a tool is installed
+#
+check_tool = $(if $(shell which $(1)),,$(error Need to have '$(1)' installed.))
+
+$(call check_tool,wget)
+$(call check_tool,patch)
+
help:
$(ECHO)
$(ECHO) "Prepare the Qt4 repository"
Please sign in to comment.
Something went wrong with that request. Please try again.