1.

Solve : makefile and enviromental varriable confusion?

Answer»

Hi I'm trying define functions in a makefile such as echo and sed using the following code:-

Code: [Select]
# CHECK EXPECTED variables are defined
define ASSERT_VARIABLE_EXISTS
ifndef $(1)
$$(error Environment Variable $(1) must be defined )
endif
endef

$(eval $(call ASSERT_VARIABLE_EXISTS,MINGW_TOOL_DRIVE))
$(eval $(call ASSERT_VARIABLE_EXISTS,MINGW_TOOL_PATH))


# MinGW Commands
ECHO := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\echo
DATE := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\date
HOSTNAME := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\hostname
UNAME := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\uname
WHOAMI := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\whoami
SED := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\sed
GREP := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\grep
MKDIR := $(MINGW_TOOL_DRIVE):\$(MINGW_TOOL_PATH)\msys\1.0\bin\mkdir


I have the following added to my path: C:\MinGW\bin;C:\MinGW\msys\1.0\bin;C:\MinGW\MSYS\1.0\local\bin
However each TIME I run the make file I receive the error that I set up to say that the varriables are are not defined
Is there anything else I must do to set up the environmental variables.

Any help is appreciated
Thanks Problem sorted, just a misunderstanding of environmental variables Quote from: souslatable on JUNE 21, 2011, 09:10:59 AM

environmental variables

Environment variables.


Discussion

No Comment Found