toplevel.mk 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. # Makefile for OpenWrt
  2. #
  3. # Copyright (C) 2007-2011 OpenWrt.org
  4. # Copyright (C) 2013 Project Gluon
  5. #
  6. # This is free software, licensed under the GNU General Public License v2.
  7. # See /LICENSE for more information.
  8. #
  9. RELEASE:=Attitude Adjustment
  10. PREP_MK= OPENWRT_BUILD= QUIET=0
  11. include $(GLUONDIR)/include/verbose.mk
  12. REVISION:=$(shell [ -d $(TOPDIR) ] && cd $(TOPDIR) && ./scripts/getver.sh 2>/dev/null)
  13. HOSTCC ?= gcc
  14. OPENWRTVERSION:=$(RELEASE)$(if $(REVISION), ($(REVISION)))
  15. export RELEASE
  16. export REVISION
  17. export OPENWRTVERSION
  18. export IS_TTY=$(shell tty -s && echo 1 || echo 0)
  19. export LD_LIBRARY_PATH:=$(subst ::,:,$(if $(LD_LIBRARY_PATH),$(LD_LIBRARY_PATH):)$(STAGING_DIR_HOST)/lib)
  20. export DYLD_LIBRARY_PATH:=$(subst ::,:,$(if $(DYLD_LIBRARY_PATH),$(DYLD_LIBRARY_PATH):)$(STAGING_DIR_HOST)/lib)
  21. export GIT_CONFIG_PARAMETERS='core.autocrlf=false'
  22. export MAKE_JOBSERVER=$(filter --jobserver%,$(MAKEFLAGS))
  23. # prevent perforce from messing with the patch utility
  24. unexport P4PORT P4USER P4CONFIG P4CLIENT
  25. # prevent user defaults for quilt from interfering
  26. unexport QUILT_PATCHES QUILT_PATCH_OPTS
  27. unexport C_INCLUDE_PATH CROSS_COMPILE ARCH
  28. # prevent distro default LPATH from interfering
  29. unexport LPATH
  30. # make sure that a predefined CFLAGS variable does not disturb packages
  31. export CFLAGS=
  32. SCAN_COOKIE?=$(shell echo $$$$)
  33. export SCAN_COOKIE
  34. SUBMAKE:=umask 022; $(SUBMAKE)
  35. FORCE: ;
  36. .PHONY: FORCE
  37. .NOTPARALLEL: