changeset 524:296131d12ed8

Add checks for build dir.
author Oleksandr Gavenko <gavenkoa@gmail.com>
date Wed, 24 Oct 2012 23:33:37 +0300
parents ca2ade61b724
children 74d60f61a8aa
files printarg/Makefile
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/printarg/Makefile	Tue Oct 23 23:54:51 2012 +0300
+++ b/printarg/Makefile	Wed Oct 24 23:33:37 2012 +0300
@@ -13,6 +13,12 @@
 
 S := $(dir $(abspath $(firstword $(MAKEFILE_LIST))))
 B := $(abspath .)/
+ifeq '' '$(filter %/,${B})'
+  $(error B value must end with slash but actually is '${B}')
+endif
+ifeq '' '$(wildcard ${B})'
+  $(shell mkdir -p ${B})
+endif
 
 ifeq '' '$(prefix)'
   ifneq '' '$(HOME)'