Use CROSS_COMPILE instead of CROSS as other projects are doing
(i.e. kernel, busybox, buildroot)

Signed-off-by: Carmelo Amoroso <[email protected]>
---
 INSTALL                             |    2 +-
 Makefile.help                       |    2 +-
 Makefile.in                         |    8 ++++----
 Rules.mak                           |   24 ++++++++++++------------
 extra/scripts/MAKEALL               |   16 +++++++---------
 libc/sysdeps/linux/m68k/README.m68k |    6 +++---
 6 files changed, 28 insertions(+), 30 deletions(-)

diff --git a/INSTALL b/INSTALL
index 79cde84..78fe3fc 100644
--- a/INSTALL
+++ b/INSTALL
@@ -54,7 +54,7 @@ COMPILING uClibc:
     to compile uClibc.  or if you are cross compiling, you would
     instead run something like:
 
-            make CROSS=arm-linux-
+            make CROSS_COMPILE=arm-linux-
 
 
 INSTALLING the uClibc development environment:
diff --git a/Makefile.help b/Makefile.help
index a98d330..bd8b0ec 100644
--- a/Makefile.help
+++ b/Makefile.help
@@ -54,7 +54,7 @@ help:
        @echo '  V=""                   - Quiet build (default)'
        @echo '  V=1                    - Brief build (show defines, ld flags)'
        @echo '  V=2                    - Very verbose build'
-       @echo '  CROSS=         - Override CROSS_COMPILER_PREFIX from .config'
+       @echo '  CROSS_COMPILE=         - Override CROSS_COMPILER_PREFIX from 
.config'
        @echo '  ARCH=          - Use given arch for config targets'
        @echo '  SHELL=         - Shell to use for make'
        @echo '  CONFIG_SHELL=          - Shell to use for menuconfig'
diff --git a/Makefile.in b/Makefile.in
index 75965ae..6966230 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -400,19 +400,19 @@ ifeq ($(HAVE_SHARED),y)
 endif
 
 utils: | pregen
-       $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils $@
+       $(Q)$(MAKE) CROSS_COMPILE="$(CROSS_COMPILE)" CC="$(CC)" -C utils $@
 
 # Installs helper applications, such as 'ldd' and 'ldconfig'
 install_utils: utils
-       $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" -C utils utils_install
+       $(Q)$(MAKE) CROSS_COMPILE="$(CROSS_COMPILE)" CC="$(CC)" -C utils 
utils_install
 
 endif # ifeq ($(HAVE_DOT_CONFIG),y)
 
 hostutils: | pregen
-       $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" HOSTCC="$(HOSTCC)" 
DOTHOST=.host -C utils $@
+       $(Q)$(MAKE) CROSS_COMPILE="$(CROSS_COMPILE)" CC="$(CC)" 
HOSTCC="$(HOSTCC)" DOTHOST=.host -C utils $@
 
 install_hostutils: hostutils
-       $(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" HOSTCC="$(HOSTCC)" 
DOTHOST=.host -C utils utils_install
+       $(Q)$(MAKE) CROSS_COMPILE="$(CROSS_COMPILE)" CC="$(CC)" 
HOSTCC="$(HOSTCC)" DOTHOST=.host -C utils utils_install
 
 $(addprefix $(top_builddir),include include/bits include/sys include/config 
lib extra/config/lxdialog extra/locale extra/scripts $(subdirs)):
        $(do_mkdir)
diff --git a/Rules.mak b/Rules.mak
index 4e4baf9..f8df46b 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -30,24 +30,24 @@ endif
 
 #-----------------------------------------------------------
 # If you are running a cross compiler, you will want to set
-# 'CROSS' to something more interesting ...  Target
+# 'CROSS_COMPILE' to something more interesting ...  Target
 # architecture is determined by asking the CC compiler what
 # arch it compiles things for, so unless your compiler is
 # broken, you should not need to specify TARGET_ARCH.
 #
 # Most people will set this stuff on the command line, i.e.
-#        make CROSS=arm-linux-
+#        make CROSS_COMPILE=arm-linux-
 # will build uClibc for 'arm'.
 
-ifndef CROSS
-CROSS=
+ifndef CROSS_COMPILE
+CROSS_COMPILE=
 endif
-CC         = $(CROSS)gcc
-AR         = $(CROSS)ar
-LD         = $(CROSS)ld
-NM         = $(CROSS)nm
-OBJDUMP    = $(CROSS)objdump
-STRIPTOOL  = $(CROSS)strip
+CC         = $(CROSS_COMPILE)gcc
+AR         = $(CROSS_COMPILE)ar
+LD         = $(CROSS_COMPILE)ld
+NM         = $(CROSS_COMPILE)nm
+OBJDUMP    = $(CROSS_COMPILE)objdump
+STRIPTOOL  = $(CROSS_COMPILE)strip
 
 INSTALL    = install
 LN         = ln
@@ -159,8 +159,8 @@ endif
 comma:=,
 space:= #
 
-ifndef CROSS
-CROSS=$(call qstrip,$(CROSS_COMPILER_PREFIX))
+ifndef CROSS_COMPILE
+CROSS_COMPILE=$(call qstrip,$(CROSS_COMPILER_PREFIX))
 endif
 
 # A nifty macro to make testing gcc features easier
diff --git a/extra/scripts/MAKEALL b/extra/scripts/MAKEALL
index 6bacc9a..f467741 100755
--- a/extra/scripts/MAKEALL
+++ b/extra/scripts/MAKEALL
@@ -77,13 +77,11 @@ pass=""
 fail=""
 skip=""
 for a in "$@" ; do
-       if [ -n "${CROSS_COMPILE}" ] ; then
-               CROSS=${CROSS_COMPILE}
-       else
-               CROSS=$(find_compiler ${a})
+       if [ -z "${CROSS_COMPILE}" ] ; then
+               CROSS_COMPILE=$(find_compiler ${a})
        fi
 
-       if [ -z "${CROSS}" ] ; then
+       if [ -z "${CROSS_COMPILE}" ] ; then
                mark_arch skip $a
                echo " ### SKIP: ${a}: could not find compiler"
                continue
@@ -93,17 +91,17 @@ for a in "$@" ; do
        (
        set -e
 
-       echo " ### Building target ${a} (${CROSS})"
+       echo " ### Building target ${a} (${CROSS_COMPILE})"
 
        do_make distclean
        do_make ARCH=$a defconfig
        do_make oldconfig
 
-       setconfig CROSS_COMPILER_PREFIX ${CROSS}
+       setconfig CROSS_COMPILER_PREFIX ${CROSS_COMPILE}
 
-       header_path=${KERNEL_HEADERS:-$(echo '#include <linux/version.h>' | 
${CROSS}cpp 2>/dev/null | grep -o '[^"]*linux/version.h')} || :
+       header_path=${KERNEL_HEADERS:-$(echo '#include <linux/version.h>' | 
${CROSS_COMPILE}cpp 2>/dev/null | grep -o '[^"]*linux/version.h')} || :
        if [ -z "${header_path}" ] ; then
-               for p in /usr/${CROSS%-}/usr/include ; do
+               for p in /usr/${CROSS_COMPILE%-}/usr/include ; do
                        if [ -e ${p}/linux/version.h ] ; then
                                header_path=${p}
                                break
diff --git a/libc/sysdeps/linux/m68k/README.m68k 
b/libc/sysdeps/linux/m68k/README.m68k
index a6bb17e..c1c1b4b 100644
--- a/libc/sysdeps/linux/m68k/README.m68k
+++ b/libc/sysdeps/linux/m68k/README.m68k
@@ -16,9 +16,9 @@ Configuration:
        Read and edit the Config file, carefully.
 
        TARGET_ARCH=m68k
-       CROSS = m68k-pic-coff-
-       CC = $(CROSS)gcc
-       STRIPTOOL = $(CROSS)strip
+       CROSS_COMPILE = m68k-pic-coff-
+       CC = $(CROSS_COMPILE)gcc
+       STRIPTOOL = $(CROSS_COMPILE)strip
        KERNEL_SOURCE=/opt/uClinux/linux
        HAS_MMU = false
        HAS_FLOATS = false
-- 
1.7.4.4

_______________________________________________
uClibc mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/uclibc

Reply via email to