mirror of
https://github.com/nasa/trick.git
synced 2024-12-24 07:16:41 +00:00
Trick should not modify TRICK_CFLAGS and TRICK_CXXFLAGS
Well sims compiled, but I forgot to test if Trick itself would compile. It didn't. Added TRICK_SYSTEM_CFLAGS and TRICK_SYSTEM_CXXFLAGS where needed. refs #90
This commit is contained in:
parent
90c85c73fc
commit
b3d1a1d162
4
Makefile
4
Makefile
@ -210,7 +210,7 @@ endif
|
|||||||
# header files.
|
# header files.
|
||||||
.PHONY: icg_sim_serv
|
.PHONY: icg_sim_serv
|
||||||
icg_sim_serv: $(ICG_EXE)
|
icg_sim_serv: $(ICG_EXE)
|
||||||
${TRICK_HOME}/bin/trick-ICG -s -m ${TRICK_CXXFLAGS} ${TRICK_HOME}/include/trick/files_to_ICG.hh
|
${TRICK_HOME}/bin/trick-ICG -s -m ${TRICK_CXXFLAGS} ${TRICK_SYSTEM_CXXFLAGS} ${TRICK_HOME}/include/trick/files_to_ICG.hh
|
||||||
|
|
||||||
# 1.1.1.4.1 Build the Interface Code Generator (ICG) executable.
|
# 1.1.1.4.1 Build the Interface Code Generator (ICG) executable.
|
||||||
$(ICG_EXE) :
|
$(ICG_EXE) :
|
||||||
@ -398,7 +398,7 @@ uninstall:
|
|||||||
# ICG all sim_services files (for testing and debugging ICG).
|
# ICG all sim_services files (for testing and debugging ICG).
|
||||||
# The -f flag forces io_src files to be regenerated whether or not they need to be.
|
# The -f flag forces io_src files to be regenerated whether or not they need to be.
|
||||||
ICG: $(ICG_EXE)
|
ICG: $(ICG_EXE)
|
||||||
${TRICK_HOME}/bin/trick-ICG -f -s -m ${TRICK_CXXFLAGS} ${TRICK_HOME}/include/trick/files_to_ICG.hh
|
${TRICK_HOME}/bin/trick-ICG -f -s -m ${TRICK_CXXFLAGS} ${TRICK_SYSTEM_CXXFLAGS} ${TRICK_HOME}/include/trick/files_to_ICG.hh
|
||||||
|
|
||||||
# This builds a tricklib share library.
|
# This builds a tricklib share library.
|
||||||
ifeq ($(USE_ER7_UTILS_INTEGRATORS), 1)
|
ifeq ($(USE_ER7_UTILS_INTEGRATORS), 1)
|
||||||
|
@ -94,7 +94,7 @@ $(TRICK_LIB_DIR):
|
|||||||
#
|
#
|
||||||
|
|
||||||
$(IO_C_OBJS): $(OBJ_DIR)/%.o : $(IO_SRC_DIR)%.c | $(OBJ_DIR)
|
$(IO_C_OBJS): $(OBJ_DIR)/%.o : $(IO_SRC_DIR)%.c | $(OBJ_DIR)
|
||||||
$(TRICK_CC) $(TRICK_CFLAGS) -c $< -o $@
|
$(TRICK_CC) $(TRICK_CFLAGS) $(TRICK_SYSTEM_CFLAGS) -c $< -o $@
|
||||||
|
|
||||||
$(IO_CPP_OBJS): TRICK_CXXFLAGS += -Wno-invalid-offsetof
|
$(IO_CPP_OBJS): TRICK_CXXFLAGS += -Wno-invalid-offsetof
|
||||||
ifeq ($(IS_CC_CLANG), 0)
|
ifeq ($(IS_CC_CLANG), 0)
|
||||||
@ -107,7 +107,7 @@ endif
|
|||||||
|
|
||||||
|
|
||||||
$(IO_CPP_OBJS): $(OBJ_DIR)/%.o : $(IO_SRC_DIR)%.cpp | $(OBJ_DIR)
|
$(IO_CPP_OBJS): $(OBJ_DIR)/%.o : $(IO_SRC_DIR)%.cpp | $(OBJ_DIR)
|
||||||
$(TRICK_CPPC) $(TRICK_CXXFLAGS) -c $< -o $@
|
$(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c $< -o $@
|
||||||
|
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
@ -115,26 +115,26 @@ $(IO_CPP_OBJS): $(OBJ_DIR)/%.o : $(IO_SRC_DIR)%.cpp | $(OBJ_DIR)
|
|||||||
#
|
#
|
||||||
|
|
||||||
$(C_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.c | $(OBJ_DIR)
|
$(C_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.c | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CC) $(TRICK_CFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CC) $(TRICK_CFLAGS) $(TRICK_SYSTEM_CFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
#
|
#
|
||||||
# CPP_OBJS
|
# CPP_OBJS
|
||||||
#
|
#
|
||||||
|
|
||||||
$(CPP_C_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.C | $(OBJ_DIR)
|
$(CPP_C_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.C | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CFLAGS) $(TRICK_SYSTEM_CFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
$(CPP_CC_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cc | $(OBJ_DIR)
|
$(CPP_CC_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cc | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
$(CPP_CPP_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cpp | $(OBJ_DIR)
|
$(CPP_CPP_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cpp | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
$(CPP_CXX_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cxx | $(OBJ_DIR)
|
$(CPP_CXX_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.cxx | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
$(CPP_CPLUS_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.c++ | $(OBJ_DIR)
|
$(CPP_CPLUS_OBJS): $(OBJ_DIR)/%.o : $(SRC_DIR)%.c++ | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
#
|
#
|
||||||
# LEX/YACC SOURCE
|
# LEX/YACC SOURCE
|
||||||
@ -155,10 +155,10 @@ $(Y_C_PREMADE) : $(SRC_DIR)%.tab.c_premade : $(SRC_DIR)%.y
|
|||||||
$(YACC) -d -o $@ $<
|
$(YACC) -d -o $@ $<
|
||||||
|
|
||||||
$(L_OBJS) : $(OBJ_DIR)/%.lex.o : $(SRC_DIR)%.lex.c $(SRC_DIR)%.tab.h | $(OBJ_DIR)
|
$(L_OBJS) : $(OBJ_DIR)/%.lex.o : $(SRC_DIR)%.lex.c $(SRC_DIR)%.tab.h | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
$(Y_OBJS) : $(OBJ_DIR)/%.tab.o : $(SRC_DIR)%.tab.c | $(OBJ_DIR)
|
$(Y_OBJS) : $(OBJ_DIR)/%.tab.o : $(SRC_DIR)%.tab.c | $(OBJ_DIR)
|
||||||
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
$(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${<F} -o $(UP_DIR)$@
|
||||||
|
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -166,7 +166,7 @@ $(Y_OBJS) : $(OBJ_DIR)/%.tab.o : $(SRC_DIR)%.tab.c | $(OBJ_DIR)
|
|||||||
#
|
#
|
||||||
|
|
||||||
depend:
|
depend:
|
||||||
@ $(TRICK_CPPC) -MM $(TRICK_CXXFLAGS) $(C_SRC) $(CPP_SRC) >> $(DEPTEMPFILE)
|
@ $(TRICK_CPPC) -MM $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) $(C_SRC) $(CPP_SRC) >> $(DEPTEMPFILE)
|
||||||
@ $(PERL) ${TRICK_HOME}/$(LIBEXEC)/trick/depend_cp $(DEPTEMPFILE) > $(DEPFILE)
|
@ $(PERL) ${TRICK_HOME}/$(LIBEXEC)/trick/depend_cp $(DEPTEMPFILE) > $(DEPFILE)
|
||||||
@ $(RM) $(DEPTEMPFILE)
|
@ $(RM) $(DEPTEMPFILE)
|
||||||
@ echo "Created dependency file $(DEPFILE)"
|
@ echo "Created dependency file $(DEPFILE)"
|
||||||
|
@ -4,10 +4,10 @@ TRICK_CXXFLAGS += -I${TRICK_HOME}/trick_models
|
|||||||
|
|
||||||
S_main: tc_server tc_client
|
S_main: tc_server tc_client
|
||||||
tc_server: tc_server.c
|
tc_server: tc_server.c
|
||||||
${TRICK_CC} ${TRICK_CFLAGS} -I${TRICK_HOME}/trick_source -o $@ $< -L${TRICK_LIB_DIR} -ltrick_comm ${TRICK_EXEC_LINK_LIBS}
|
${TRICK_CC} ${TRICK_CFLAGS} ${TRICK_SYSTEM_CFLAGS} -I${TRICK_HOME}/trick_source -o $@ $< -L${TRICK_LIB_DIR} -ltrick_comm ${TRICK_EXEC_LINK_LIBS}
|
||||||
|
|
||||||
tc_client: tc_client.c
|
tc_client: tc_client.c
|
||||||
${TRICK_CC} ${TRICK_CFLAGS} -I${TRICK_HOME}/trick_source -o $@ $< -L${TRICK_LIB_DIR} -ltrick_comm ${TRICK_EXEC_LINK_LIBS}
|
${TRICK_CC} ${TRICK_CFLAGS} ${TRICK_SYSTEM_CFLAGS} -I${TRICK_HOME}/trick_source -o $@ $< -L${TRICK_LIB_DIR} -ltrick_comm ${TRICK_EXEC_LINK_LIBS}
|
||||||
|
|
||||||
clean: clean_tc_apps
|
clean: clean_tc_apps
|
||||||
spotless: clean_tc_apps
|
spotless: clean_tc_apps
|
||||||
|
@ -62,10 +62,10 @@ swig_${TRICK_HOST_CPU}:
|
|||||||
mkdir $@
|
mkdir $@
|
||||||
|
|
||||||
$(SWIG_OBJECT_FILES): $(OBJ_DIR)/%.o : swig_${TRICK_HOST_CPU}/%.cpp
|
$(SWIG_OBJECT_FILES): $(OBJ_DIR)/%.o : swig_${TRICK_HOST_CPU}/%.cpp
|
||||||
$(TRICK_CPPC) $(TRICK_CXXFLAGS) -c $< -o $@
|
$(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c $< -o $@
|
||||||
|
|
||||||
$(OBJECT_FILES): $(OBJ_DIR)/%.o : %.cpp
|
$(OBJECT_FILES): $(OBJ_DIR)/%.o : %.cpp
|
||||||
$(TRICK_CPPC) $(TRICK_CXXFLAGS) -c $< -o $@
|
$(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c $< -o $@
|
||||||
|
|
||||||
$(SWIG_SRC_FILES): swig_${TRICK_HOST_CPU}/%_wrap.cpp : %.i
|
$(SWIG_SRC_FILES): swig_${TRICK_HOST_CPU}/%_wrap.cpp : %.i
|
||||||
$(SWIG) $(SWIG_DEFS) -I${TRICK_HOME}/trick_source -I${TRICK_HOME}/include -I${TRICK_HOME} -c++ -python -includeall -ignoremissing -w201,362,389,451 -o $@ -outdir ${TRICK_HOME}/share/trick/swig $<
|
$(SWIG) $(SWIG_DEFS) -I${TRICK_HOME}/trick_source -I${TRICK_HOME}/include -I${TRICK_HOME} -c++ -python -includeall -ignoremissing -w201,362,389,451 -o $@ -outdir ${TRICK_HOME}/share/trick/swig $<
|
||||||
|
Loading…
Reference in New Issue
Block a user