java - Makefile losing access to environment variables -


i've got makefile has couple of targets (all, install, uninstall). i'm trying use $java_home environment variable, works perfect in target, when install target executed, $java_home variable seems empty (although not - have checked in terminal). have ideas?

all:         # works         @echo ${java_home}   ifeq ($(uname), linux) install:         # prints blank line.         @echo ${java_home}         # doing stuff here  uninstall:         # doing stuff here endif 


thanks,
chris

i don't see problem have posted, way set java_home before calling make may contributing factor. using export create environment variable? if not, make process might not inheriting part of environment.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -