Don't override the CC and C++ environment variables

Fixes an issue where some makefiles override the user's CC and C++
environment variables.
This commit is contained in:
Nino Tarantino 2024-12-05 08:46:30 -06:00
parent f9d9d6ea00
commit 31961f482c
37 changed files with 71 additions and 71 deletions

View File

@ -1,5 +1,5 @@
CPP = g++
CC = gcc
CPP ?= g++
CC ?= gcc
ifeq ($(shell uname), Darwin)
GL_LIBS = -framework GLUT -framework OpenGL

View File

@ -1,8 +1,8 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DECL_DIR = ..
GTEST_DIR = ${HOME}/gtest-1.7.0

View File

@ -1,6 +1,6 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
PROJECT_DIR = ../..

View File

@ -1,6 +1,6 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DECL_DIR = ..
GTEST_DIR = ${HOME}/gtest-1.7.0
@ -38,4 +38,4 @@ ElectricalCircuitTest.o : ElectricalCircuitTest.cpp
ElectricalCircuitTest : ElectricalCircuitTest.o gtest_main.o gtest-all.o
$(CPP) $(CFLAGS) -o $@ $^ $(LIBS)

View File

@ -1,8 +1,8 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DECL_DIR = ..
GTEST_DIR = ${HOME}/gtest-1.7.0

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DECL_DIR = ..
GTEST_DIR = ${HOME}/gtest-1.7.0

View File

@ -1,6 +1,6 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
PROJECT_DIR = ../..

View File

@ -1,4 +1,4 @@
CC = gcc
CC ?= gcc
ifndef TRICK_HOST_CPU
TRICK_HOST_CPU := $(shell trick-gte TRICK_HOST_CPU)
@ -34,7 +34,7 @@ TRICK_CFLAGS += -Wall
endif
ifeq ($(TRICK_HOST_TYPE),Darwin)
CC = cc
CC ?= cc
LD_SHARED = $(CC) -bundle
TRICK_CFLAGS += -Wall
endif

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DPX_DIR = ../..

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DPX_DIR = ../..

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DPX_DIR = ..

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DPX_DIR = ..

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
DPX_DIR = ../..

View File

@ -11,8 +11,8 @@ endif
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -3,8 +3,8 @@ include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -11,8 +11,8 @@ endif
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -3,8 +3,8 @@ include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -11,8 +11,8 @@ endif
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -11,8 +11,8 @@ endif
SHELL = /bin/sh
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
PWD = $(shell pwd)
DEV_NULL = > /dev/null 2>&1
GCC = $(shell which gcc)

View File

@ -2,8 +2,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
DPX_DIR = ${TRICK_HOME}/trick_source/data_products/DPX
DS_DIR = ${TRICK_HOME}/trick_source/data_products

View File

@ -1,7 +1,7 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
CC = cc
CC ?= cc
OBJ_DIR = object_${TRICK_HOST_CPU}
LIBDIR = ../lib_${TRICK_HOST_CPU}

View File

@ -1,7 +1,7 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
CC = c++
CC ?= c++
ifndef TRICK_HOST_CPU
TRICK_HOST_CPU := $(shell uname -s)

View File

@ -1,7 +1,7 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
CC = c++
CC ?= c++
ifndef TRICK_HOST_CPU
TRICK_HOST_CPU := $(shell uname -s)

View File

@ -1,8 +1,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
ifndef TRICK_HOST_CPU
TRICK_HOST_CPU := $(shell uname -s)

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CFLAGS = -g -Wall

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
DECL_DIR = ..

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CXXFLAGS = -g -Wall
INCLUDE_DIRS = -I../../include

View File

@ -1,7 +1,7 @@
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CFLAGS = -g -Wall -std=c++11 ${TRICK_CXXFLAGS}
INCLUDE_DIRS = -Iinclude

View File

@ -20,7 +20,7 @@ TRICK_HOST_TYPE := $(shell trick-gte TRICK_HOST_TYPE)
endif
CC = cc
CC ?= cc
FLAGS =
ifeq ($(TRICK_HOST_TYPE), Darwin)
LIBS =

View File

@ -9,8 +9,8 @@ TRICK_HOST_TYPE := $(shell trick-gte TRICK_HOST_TYPE)
endif
CC = gcc
CPP = g++
CC ?= gcc
CPP ?= g++
CFLAGS = -g -Wall -I../include

View File

@ -1,8 +1,8 @@
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
RM = rm -rf
CC = cc
CPP = c++
CC ?= cc
CPP ?= c++
CURL = curl
MV = mv
CP = cp