make-rules/shared-macros.mk
changeset 6043 2b2e083ef892
parent 5885 b62c528d39c8
child 6231 8b569784feeb
equal deleted inserted replaced
6042:a973ed82292e 6043:2b2e083ef892
   566 # Modules which are shipped by the OS but not with the core Python distribution
   566 # Modules which are shipped by the OS but not with the core Python distribution
   567 # belong in vendor-packages.
   567 # belong in vendor-packages.
   568 PYTHON_LIB= /usr/lib/python$(PYTHON_VERSION)/vendor-packages
   568 PYTHON_LIB= /usr/lib/python$(PYTHON_VERSION)/vendor-packages
   569 PYTHON_DATA= $(PYTHON_LIB)
   569 PYTHON_DATA= $(PYTHON_LIB)
   570 
   570 
       
   571 # If the component has python scripts then the first line should probably
       
   572 # point at the userland default build python so as not to be influenced
       
   573 # by the ips python mediator.
       
   574 # In the component's Makefile define PYTHON_SCRIPTS with a list of files
       
   575 # to be editted.
       
   576 
       
   577 # Edit the leading #!/usr/bin/python line in python scripts to use the
       
   578 # BUILD's $(PYTHON).
       
   579 PYTHON_SCRIPT_SHEBANG_FIX_FUNC = \
       
   580 	$(GSED) -i \
       
   581 		-e '1s@/usr/bin/python$$@$(PYTHON)@' \
       
   582 		-e '1s@/usr/bin/python\ @$(PYTHON) @' \
       
   583 		-e '1s@/usr/bin/env\ $(PYTHON)@$(PYTHON)@' \
       
   584 		-e '1s@/usr/bin/env\ python@$(PYTHON)@' $(1);
       
   585 
       
   586 # PYTHON_SCRIPTS is a list of files from the calling Makefile.
       
   587 PYTHON_SCRIPTS_PROCESS= \
       
   588 	$(foreach s,$(PYTHON_SCRIPTS), \
       
   589 	        $(call PYTHON_SCRIPT_SHEBANG_FIX_FUNC,$(s)))
       
   590 
       
   591 # Finally if PYTHON_SCRIPTS is defined in a Makefile then process them here.
       
   592 # If multiple installs in the component then clear
       
   593 # COMPONENT_POST_INSTALL_ACTION =
       
   594 # and re-add $(PYTHON_SCRIPTS_PROCESS)
       
   595 COMPONENT_POST_INSTALL_ACTION += $(PYTHON_SCRIPTS_PROCESS)
       
   596 
   571 JAVA8_HOME =	/usr/jdk/instances/jdk1.8.0
   597 JAVA8_HOME =	/usr/jdk/instances/jdk1.8.0
   572 JAVA_HOME = $(JAVA8_HOME)
   598 JAVA_HOME = $(JAVA8_HOME)
   573 
   599 
   574 # This is the default BUILD version of perl
   600 # This is the default BUILD version of perl
   575 # Not necessarily the system's default version, i.e. /usr/bin/perl
   601 # Not necessarily the system's default version, i.e. /usr/bin/perl