2018-02-28 10:02:06 +01:00
|
|
|
# ---------- C++ support ----------
|
2018-03-02 13:41:00 +01:00
|
|
|
.PHONY: help_cc # Generate list of C++ targets with descriptions.
|
2018-02-28 10:02:06 +01:00
|
|
|
help_cc:
|
2018-03-02 13:41:00 +01:00
|
|
|
@echo Use one of the following C++ targets:
|
2018-02-28 10:02:06 +01:00
|
|
|
ifeq ($(SYSTEM),win)
|
2018-07-05 16:08:54 +02:00
|
|
|
@$(GREP) "^.PHONY: .* #" $(CURDIR)/makefiles/Makefile.cpp.mk | $(SED) "s/\.PHONY: \(.*\) # \(.*\)/\1\t\2/"
|
2018-03-06 15:03:19 +01:00
|
|
|
@echo off & echo(
|
2018-02-28 10:02:06 +01:00
|
|
|
else
|
2018-07-05 16:08:54 +02:00
|
|
|
@$(GREP) "^.PHONY: .* #" $(CURDIR)/makefiles/Makefile.cpp.mk | $(SED) "s/\.PHONY: \(.*\) # \(.*\)/\1\t\2/" | expand -t20
|
2018-03-06 13:58:23 +01:00
|
|
|
@echo
|
2018-02-28 10:02:06 +01:00
|
|
|
endif
|
2012-01-10 14:16:39 +00:00
|
|
|
|
2018-04-25 16:52:01 +02:00
|
|
|
# Checks if the user has overwritten default install prefix.
|
|
|
|
|
# cf https://www.gnu.org/prep/standards/html_node/Directory-Variables.html#index-prefix
|
|
|
|
|
ifeq ($(SYSTEM),win)
|
2018-05-04 08:57:28 +02:00
|
|
|
prefix ?= C:\\Program Files\\or-tools
|
2018-04-25 16:52:01 +02:00
|
|
|
else
|
|
|
|
|
prefix ?= /usr/local
|
|
|
|
|
endif
|
|
|
|
|
|
2018-09-04 10:05:59 +02:00
|
|
|
# All libraries and dependecies
|
|
|
|
|
OR_TOOLS_LIBS = $(LIB_DIR)/$(LIB_PREFIX)ortools.$L
|
|
|
|
|
|
2018-08-31 18:14:17 +02:00
|
|
|
HAS_CCC = true
|
|
|
|
|
ifndef CCC
|
|
|
|
|
HAS_CCC =
|
|
|
|
|
endif
|
|
|
|
|
|
2012-01-20 16:39:15 +00:00
|
|
|
# Main target
|
2018-09-27 10:38:29 +02:00
|
|
|
.PHONY: cc # Build C++ OR-Tools library.
|
2018-11-09 09:21:33 +01:00
|
|
|
.PHONY: check_cc # Quick check only running C++ OR-Tools samples targets.
|
|
|
|
|
.PHONY: test_cc # Run all C++ OR-Tools test targets.
|
2018-09-27 10:38:29 +02:00
|
|
|
.PHONY: test_fz # Run all Flatzinc OR-Tools examples.
|
2020-04-07 18:59:25 +02:00
|
|
|
.PHONY: package_cc # Create C++ OR-Tools "package" (archive).
|
2018-08-31 18:14:17 +02:00
|
|
|
ifndef HAS_CCC
|
|
|
|
|
cc:
|
|
|
|
|
@echo CCC = $(CCC)
|
2018-09-27 10:38:29 +02:00
|
|
|
$(warning Cannot find '$@' command which is needed for build. Please make sure it is installed and in system PATH.)
|
2018-09-26 11:02:04 +02:00
|
|
|
check_cc: cc
|
2018-10-12 11:48:03 +02:00
|
|
|
test_cc: cc
|
2018-08-31 18:14:17 +02:00
|
|
|
test_fz: cc
|
2020-04-07 18:59:25 +02:00
|
|
|
package_cc: cc
|
2018-08-31 18:14:17 +02:00
|
|
|
else
|
2018-09-04 10:05:59 +02:00
|
|
|
cc: $(OR_TOOLS_LIBS)
|
2018-11-09 09:21:33 +01:00
|
|
|
check_cc: check_cc_pimpl
|
|
|
|
|
test_cc: test_cc_pimpl
|
|
|
|
|
test_fz: test_fz_pimpl
|
2020-04-07 18:59:25 +02:00
|
|
|
package_cc: package_cc_pimpl
|
2017-01-10 21:05:56 +01:00
|
|
|
BUILT_LANGUAGES += C++
|
2018-08-31 18:14:17 +02:00
|
|
|
endif
|
|
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR):
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(GEN_PATH)
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools: | $(GEN_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(GEN_PATH)$Sortools
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/algorithms: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Salgorithms
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/bop: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sbop
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/constraint_solver: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sconstraint_solver
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/data: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sdata
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/flatzinc: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sflatzinc
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/glop: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sglop
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/graph: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sgraph
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2020-10-18 17:02:16 +02:00
|
|
|
$(GEN_DIR)/ortools/gscip: | $(GEN_DIR)/ortools
|
|
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sgscip
|
|
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/linear_solver: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Slinear_solver
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/sat: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Ssat
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(GEN_DIR)/ortools/util: | $(GEN_DIR)/ortools
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(GEN_PATH)$Sortools$Sutil
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(BIN_DIR):
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(BIN_DIR)
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(LIB_DIR):
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(LIB_DIR)
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR):
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) $(OBJ_DIR)
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/algorithms: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Salgorithms
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/base: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sbase
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/bop: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sbop
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/constraint_solver: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sconstraint_solver
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/data: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sdata
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/flatzinc: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sflatzinc
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/glop: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sglop
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/graph: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sgraph
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2020-10-18 17:02:16 +02:00
|
|
|
$(OBJ_DIR)/gscip: | $(OBJ_DIR)
|
|
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sgscip
|
|
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/linear_solver: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Slinear_solver
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/lp_data: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Slp_data
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/port: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sport
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/sat: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Ssat
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/util: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sutil
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(OBJ_DIR)/swig: | $(OBJ_DIR)
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR_P) $(OBJ_DIR)$Sswig
|
2018-04-17 16:41:08 +02:00
|
|
|
|
2018-08-31 18:14:17 +02:00
|
|
|
###############
|
|
|
|
|
## CPP LIB ##
|
|
|
|
|
###############
|
2018-10-31 16:18:18 +01:00
|
|
|
# build from: $> grep "pb\.h:" makefiles/Makefile.gen.mk
|
|
|
|
|
PROTO_DEPS = \
|
|
|
|
|
$(GEN_DIR)/ortools/util/optional_boolean.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/data/jobshop_scheduling.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/data/rcpsp.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/glop/parameters.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/graph/flow_problem.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/sat/boolean_problem.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/sat/cp_model.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/sat/sat_parameters.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/bop/bop_parameters.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/linear_solver/linear_solver.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/constraint_solver/assignment.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/constraint_solver/demon_profiler.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/constraint_solver/routing_enums.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/constraint_solver/routing_parameters.pb.h \
|
|
|
|
|
$(GEN_DIR)/ortools/constraint_solver/search_limit.pb.h \
|
2020-10-18 17:02:16 +02:00
|
|
|
$(GEN_DIR)/ortools/constraint_solver/search_stats.pb.h \
|
2018-10-31 16:18:18 +01:00
|
|
|
$(GEN_DIR)/ortools/constraint_solver/solver_parameters.pb.h
|
2018-07-10 17:34:35 +02:00
|
|
|
include $(OR_ROOT)makefiles/Makefile.gen.mk
|
|
|
|
|
|
2018-10-31 16:18:18 +01:00
|
|
|
all_protos: $(PROTO_DEPS)
|
|
|
|
|
|
2018-07-10 17:34:35 +02:00
|
|
|
# OR Tools unique library.
|
|
|
|
|
$(OR_TOOLS_LIBS): \
|
2018-09-04 15:50:22 +02:00
|
|
|
dependencies/check.log \
|
2018-08-31 18:14:17 +02:00
|
|
|
$(BASE_LIB_OBJS) \
|
|
|
|
|
$(PORT_LIB_OBJS) \
|
|
|
|
|
$(UTIL_LIB_OBJS) \
|
|
|
|
|
$(DATA_LIB_OBJS) \
|
|
|
|
|
$(LP_DATA_LIB_OBJS) \
|
|
|
|
|
$(GLOP_LIB_OBJS) \
|
2018-09-26 13:38:12 +02:00
|
|
|
$(BOP_LIB_OBJS) \
|
|
|
|
|
$(LP_LIB_OBJS) \
|
2018-08-31 18:14:17 +02:00
|
|
|
$(GRAPH_LIB_OBJS) \
|
|
|
|
|
$(ALGORITHMS_LIB_OBJS) \
|
|
|
|
|
$(SAT_LIB_OBJS) \
|
|
|
|
|
$(CP_LIB_OBJS) | $(LIB_DIR)
|
2018-07-10 17:34:35 +02:00
|
|
|
$(LINK_CMD) \
|
|
|
|
|
$(LD_OUT)$(LIB_DIR)$S$(LIB_PREFIX)ortools.$L \
|
|
|
|
|
$(BASE_LIB_OBJS) \
|
|
|
|
|
$(PORT_LIB_OBJS) \
|
|
|
|
|
$(UTIL_LIB_OBJS) \
|
|
|
|
|
$(DATA_LIB_OBJS) \
|
|
|
|
|
$(LP_DATA_LIB_OBJS) \
|
|
|
|
|
$(GLOP_LIB_OBJS) \
|
|
|
|
|
$(GRAPH_LIB_OBJS) \
|
|
|
|
|
$(ALGORITHMS_LIB_OBJS) \
|
|
|
|
|
$(SAT_LIB_OBJS) \
|
|
|
|
|
$(BOP_LIB_OBJS) \
|
|
|
|
|
$(LP_LIB_OBJS) \
|
|
|
|
|
$(CP_LIB_OBJS) \
|
|
|
|
|
$(DEPENDENCIES_LNK) \
|
|
|
|
|
$(LDFLAGS)
|
2018-09-04 17:12:24 +02:00
|
|
|
|
2018-07-10 17:34:35 +02:00
|
|
|
#####################
|
|
|
|
|
## Flatzinc code ##
|
|
|
|
|
#####################
|
|
|
|
|
FLATZINC_LIBS = $(LIB_DIR)/$(LIB_PREFIX)fz.$L
|
|
|
|
|
FLATZINC_PATH = $(subst /,$S,$(FLATZINC_LIBS))
|
|
|
|
|
FLATZINC_DEPS = \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/checker.h \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/cp_model_fz_solver.h \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/logging.h \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/model.h \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/parser.h \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/parser.tab.hh \
|
|
|
|
|
$(SRC_DIR)/ortools/flatzinc/presolve.h \
|
|
|
|
|
$(CP_DEPS) \
|
|
|
|
|
$(SAT_DEPS)
|
|
|
|
|
FLATZINC_LNK = $(PRE_LIB)fz$(POST_LIB) $(OR_TOOLS_LNK)
|
|
|
|
|
ifeq ($(PLATFORM),MACOSX)
|
2020-10-01 18:08:57 +02:00
|
|
|
FLATZINC_LDFLAGS = -install_name @rpath/$(LIB_PREFIX)fz.$L #
|
2018-07-10 17:34:35 +02:00
|
|
|
endif
|
|
|
|
|
|
2016-06-28 10:27:27 +02:00
|
|
|
FLATZINC_OBJS=\
|
2016-10-05 13:53:30 +02:00
|
|
|
$(OBJ_DIR)/flatzinc/checker.$O \
|
2017-05-29 14:49:34 +02:00
|
|
|
$(OBJ_DIR)/flatzinc/cp_model_fz_solver.$O \
|
2016-09-21 11:54:53 +02:00
|
|
|
$(OBJ_DIR)/flatzinc/logging.$O \
|
|
|
|
|
$(OBJ_DIR)/flatzinc/model.$O \
|
|
|
|
|
$(OBJ_DIR)/flatzinc/parser.$O \
|
|
|
|
|
$(OBJ_DIR)/flatzinc/parser.tab.$O \
|
|
|
|
|
$(OBJ_DIR)/flatzinc/parser.yy.$O \
|
2019-11-07 13:22:44 +01:00
|
|
|
$(OBJ_DIR)/flatzinc/presolve.$O
|
2018-07-10 17:34:35 +02:00
|
|
|
|
2017-09-08 13:20:30 +02:00
|
|
|
fz_parser: #$(SRC_DIR)/ortools/flatzinc/parser.lex $(SRC_DIR)/ortools/flatzinc/parser.yy
|
2018-07-10 17:34:35 +02:00
|
|
|
flex -o $(SRC_DIR)/ortools/flatzinc/parser.yy.cc $(SRC_DIR)/ortools/flatzinc/parser.lex
|
2017-09-08 13:20:30 +02:00
|
|
|
bison -t -o $(SRC_DIR)/ortools/flatzinc/parser.tab.cc -d $(SRC_DIR)/ortools/flatzinc/parser.yy
|
2014-02-07 19:37:29 +00:00
|
|
|
|
2018-07-10 17:34:35 +02:00
|
|
|
$(OBJ_DIR)/flatzinc/%.$O: $(SRC_DIR)/ortools/flatzinc/%.cc $(FLATZINC_DEPS) | $(OBJ_DIR)/flatzinc
|
|
|
|
|
$(CCC) $(CFLAGS) -c $(SRC_DIR)$Sortools$Sflatzinc$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$Sflatzinc$S$*.$O
|
2016-09-21 11:54:53 +02:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(FLATZINC_LIBS): $(OR_TOOLS_LIBS) $(FLATZINC_OBJS) | $(LIB_DIR)
|
2018-05-14 17:30:40 +02:00
|
|
|
$(LINK_CMD) \
|
2020-10-01 18:08:57 +02:00
|
|
|
$(FLATZINC_LDFLAGS) \
|
2018-05-14 17:30:40 +02:00
|
|
|
$(LD_OUT)$(LIB_DIR)$S$(LIB_PREFIX)fz.$L \
|
|
|
|
|
$(FLATZINC_OBJS) \
|
|
|
|
|
$(OR_TOOLS_LNK) \
|
|
|
|
|
$(OR_TOOLS_LDFLAGS)
|
2014-01-30 19:11:57 +00:00
|
|
|
|
2018-07-10 17:34:35 +02:00
|
|
|
.PHONY: fz # Build Flatzinc binaries.
|
|
|
|
|
fz: \
|
|
|
|
|
$(BIN_DIR)/fz$E \
|
2019-11-07 13:22:44 +01:00
|
|
|
$(BIN_DIR)/parser_main$E
|
2014-01-30 19:11:57 +00:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(BIN_DIR)/fz$E: $(OBJ_DIR)/flatzinc/fz.$O $(FLATZINC_LIBS) $(OR_TOOLS_LIBS) | $(BIN_DIR)
|
2018-05-14 17:30:40 +02:00
|
|
|
$(CCC) $(CFLAGS) $(OBJ_DIR)$Sflatzinc$Sfz.$O $(FLATZINC_LNK) $(OR_TOOLS_LDFLAGS) $(EXE_OUT)$(BIN_DIR)$Sfz$E
|
2013-08-02 22:21:12 +00:00
|
|
|
|
2018-06-29 18:00:32 +02:00
|
|
|
$(BIN_DIR)/parser_main$E: $(OBJ_DIR)/flatzinc/parser_main.$O $(FLATZINC_LIBS) $(OR_TOOLS_LIBS) | $(BIN_DIR)
|
2018-05-14 17:30:40 +02:00
|
|
|
$(CCC) $(CFLAGS) $(OBJ_DIR)$Sflatzinc$Sparser_main.$O $(FLATZINC_LNK) $(OR_TOOLS_LDFLAGS) $(EXE_OUT)$(BIN_DIR)$Sparser_main$E
|
2014-04-22 14:46:38 +00:00
|
|
|
|
2018-07-10 17:34:35 +02:00
|
|
|
##################
|
|
|
|
|
## Sat solver ##
|
|
|
|
|
##################
|
|
|
|
|
sat: $(BIN_DIR)/sat_runner$E
|
|
|
|
|
|
|
|
|
|
$(OBJ_DIR)/sat_runner.$O: \
|
2018-09-18 10:10:25 +02:00
|
|
|
$(CC_EX_DIR)/sat_runner.cc \
|
|
|
|
|
$(CC_EX_DIR)/opb_reader.h \
|
|
|
|
|
$(CC_EX_DIR)/sat_cnf_reader.h \
|
2018-07-10 17:34:35 +02:00
|
|
|
$(SAT_DEPS) | $(OBJ_DIR)
|
2018-09-18 10:10:25 +02:00
|
|
|
$(CCC) $(CFLAGS) -c $(CC_EX_PATH)$Ssat_runner.cc $(OBJ_OUT)$(OBJ_DIR)$Ssat_runner.$O
|
2016-06-27 15:30:24 +02:00
|
|
|
|
2018-10-29 14:17:53 +01:00
|
|
|
##################
|
|
|
|
|
## C++ SOURCE ##
|
|
|
|
|
##################
|
|
|
|
|
ifeq ($(SOURCE_SUFFIX),.cc) # Those rules will be used if SOURCE contain a .cc file
|
|
|
|
|
$(OBJ_DIR)/$(SOURCE_NAME).$O: $(SOURCE) $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) \
|
|
|
|
|
-c $(SOURCE_PATH) \
|
|
|
|
|
$(OBJ_OUT)$(OBJ_DIR)$S$(SOURCE_NAME).$O
|
|
|
|
|
|
|
|
|
|
$(BIN_DIR)/$(SOURCE_NAME)$E: $(OBJ_DIR)/$(SOURCE_NAME).$O $(OR_TOOLS_LIBS) | $(BIN_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) \
|
|
|
|
|
$(OBJ_DIR)$S$(SOURCE_NAME).$O \
|
|
|
|
|
$(OR_TOOLS_LNK) $(OR_TOOLS_LDFLAGS) \
|
|
|
|
|
$(EXE_OUT)$(BIN_DIR)$S$(SOURCE_NAME)$E
|
|
|
|
|
|
|
|
|
|
.PHONY: build # Build a C++ program.
|
|
|
|
|
build: $(BIN_DIR)/$(SOURCE_NAME)$E
|
|
|
|
|
|
|
|
|
|
.PHONY: run # Run a C++ program.
|
|
|
|
|
run: build
|
|
|
|
|
$(BIN_DIR)$S$(SOURCE_NAME)$E $(ARGS)
|
|
|
|
|
endif
|
2018-10-12 11:48:03 +02:00
|
|
|
|
2018-10-29 14:17:53 +01:00
|
|
|
##################################
|
|
|
|
|
## CPP Tests/Examples/Samples ##
|
|
|
|
|
##################################
|
2018-10-29 17:46:20 +01:00
|
|
|
# Generic Command
|
|
|
|
|
$(OBJ_DIR)/%.$O: $(TEST_DIR)/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c $(TEST_PATH)$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
|
|
|
|
$(OBJ_DIR)/%.$O: $(CC_EX_DIR)/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c $(CC_EX_PATH)$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-11-07 21:31:58 +01:00
|
|
|
$(OBJ_DIR)/%.$O: $(CONTRIB_EX_DIR)/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c $(CONTRIB_EX_PATH)$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-11-16 15:10:15 +01:00
|
|
|
$(OBJ_DIR)/%.$O: ortools/algorithms/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Salgorithms$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
|
|
|
|
$(OBJ_DIR)/%.$O: ortools/graph/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Sgraph$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-11-09 09:21:33 +01:00
|
|
|
$(OBJ_DIR)/%.$O: ortools/linear_solver/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Slinear_solver$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-11-23 10:49:46 +01:00
|
|
|
$(OBJ_DIR)/%.$O: ortools/constraint_solver/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Sconstraint_solver$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-10-29 17:46:20 +01:00
|
|
|
$(OBJ_DIR)/%.$O: ortools/sat/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Ssat$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-11-23 10:49:46 +01:00
|
|
|
$(OBJ_DIR)/%.$O: ortools/routing/samples/%.cc $(OR_TOOLS_LIBS) | $(OBJ_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) -c ortools$Srouting$Ssamples$S$*.cc $(OBJ_OUT)$(OBJ_DIR)$S$*.$O
|
|
|
|
|
|
2018-10-29 17:46:20 +01:00
|
|
|
$(BIN_DIR)/%$E: $(OBJ_DIR)/%.$O $(OR_TOOLS_LIBS) | $(BIN_DIR)
|
|
|
|
|
$(CCC) $(CFLAGS) $(OBJ_DIR)$S$*.$O $(OR_TOOLS_LNK) $(OR_TOOLS_LDFLAGS) $(EXE_OUT)$(BIN_DIR)$S$*$E
|
|
|
|
|
|
2018-10-29 14:17:53 +01:00
|
|
|
rcc_%: $(BIN_DIR)/%$E FORCE
|
2018-08-31 18:14:17 +02:00
|
|
|
$(BIN_DIR)$S$*$E $(ARGS)
|
|
|
|
|
|
2018-11-16 15:10:15 +01:00
|
|
|
.PHONY: test_cc_algorithms_samples # Build and Run all C++ Algorithms Samples (located in ortools/algorithms/samples)
|
|
|
|
|
test_cc_algorithms_samples: \
|
2019-05-10 22:51:10 +02:00
|
|
|
rcc_knapsack \
|
2018-11-26 17:30:10 +01:00
|
|
|
rcc_simple_knapsack_program
|
2018-11-16 15:10:15 +01:00
|
|
|
|
|
|
|
|
.PHONY: test_cc_graph_samples # Build and Run all C++ Graph Samples (located in ortools/graph/samples)
|
|
|
|
|
test_cc_graph_samples: \
|
2018-11-26 17:30:10 +01:00
|
|
|
rcc_simple_max_flow_program \
|
|
|
|
|
rcc_simple_min_cost_flow_program
|
2018-11-16 15:10:15 +01:00
|
|
|
|
|
|
|
|
.PHONY: test_cc_linear_solver_samples # Build and Run all C++ LP Samples (located in ortools/linear_solver/samples)
|
|
|
|
|
test_cc_linear_solver_samples: \
|
2020-06-04 17:15:34 +02:00
|
|
|
rcc_assignment_mip \
|
2020-05-26 09:30:42 +02:00
|
|
|
rcc_bin_packing_mip \
|
|
|
|
|
rcc_integer_programming_example \
|
2018-11-26 17:30:10 +01:00
|
|
|
rcc_linear_programming_example \
|
2020-05-26 09:30:42 +02:00
|
|
|
rcc_mip_var_array \
|
|
|
|
|
rcc_multiple_knapsack_mip \
|
|
|
|
|
rcc_simple_lp_program \
|
|
|
|
|
rcc_simple_mip_program
|
2018-11-16 15:10:15 +01:00
|
|
|
|
2018-11-23 10:49:46 +01:00
|
|
|
.PHONY: test_cc_constraint_solver_samples # Build and Run all C++ CP Samples (located in ortools/constraint_solver/samples)
|
|
|
|
|
test_cc_constraint_solver_samples: \
|
|
|
|
|
rcc_minimal_jobshop_cp \
|
2018-12-27 10:47:37 +01:00
|
|
|
rcc_nurses_cp \
|
|
|
|
|
rcc_rabbits_and_pheasants_cp \
|
|
|
|
|
rcc_simple_ls_program \
|
2019-03-14 12:58:56 +01:00
|
|
|
rcc_simple_cp_program \
|
2018-12-27 14:18:19 +01:00
|
|
|
rcc_simple_routing_program \
|
2018-12-27 10:47:37 +01:00
|
|
|
rcc_tsp \
|
2019-02-18 17:19:01 +01:00
|
|
|
rcc_tsp_cities \
|
|
|
|
|
rcc_tsp_circuit_board \
|
2019-01-10 10:43:43 +01:00
|
|
|
rcc_tsp_distance_matrix \
|
|
|
|
|
rcc_vrp \
|
|
|
|
|
rcc_vrp_capacity \
|
|
|
|
|
rcc_vrp_drop_nodes \
|
|
|
|
|
rcc_vrp_global_span \
|
2019-03-04 11:25:55 +01:00
|
|
|
rcc_vrp_initial_routes \
|
2019-01-10 16:01:24 +01:00
|
|
|
rcc_vrp_pickup_delivery \
|
2019-01-17 13:20:00 +01:00
|
|
|
rcc_vrp_pickup_delivery_fifo \
|
|
|
|
|
rcc_vrp_pickup_delivery_lifo \
|
2019-03-08 17:21:54 +01:00
|
|
|
rcc_vrp_resources \
|
2019-01-10 10:43:43 +01:00
|
|
|
rcc_vrp_starts_ends \
|
|
|
|
|
rcc_vrp_time_windows \
|
2019-04-19 18:47:28 +02:00
|
|
|
rcc_vrp_with_time_limit
|
2018-11-23 10:49:46 +01:00
|
|
|
|
2018-11-09 09:21:33 +01:00
|
|
|
.PHONY: test_cc_sat_samples # Build and Run all C++ Sat Samples (located in ortools/sat/samples)
|
|
|
|
|
test_cc_sat_samples: \
|
2020-06-04 17:15:49 +02:00
|
|
|
rcc_assignment_sat \
|
2018-11-15 10:56:34 -08:00
|
|
|
rcc_binpacking_problem_sat \
|
|
|
|
|
rcc_bool_or_sample_sat \
|
|
|
|
|
rcc_channeling_sample_sat \
|
|
|
|
|
rcc_cp_is_fun_sat \
|
2019-03-25 13:30:23 +01:00
|
|
|
rcc_earliness_tardiness_cost_sample_sat \
|
2018-11-15 10:56:34 -08:00
|
|
|
rcc_interval_sample_sat \
|
|
|
|
|
rcc_literal_sample_sat \
|
|
|
|
|
rcc_no_overlap_sample_sat \
|
|
|
|
|
rcc_optional_interval_sample_sat \
|
|
|
|
|
rcc_rabbits_and_pheasants_sat \
|
|
|
|
|
rcc_ranking_sample_sat \
|
|
|
|
|
rcc_reified_sample_sat \
|
|
|
|
|
rcc_search_for_all_solutions_sample_sat \
|
|
|
|
|
rcc_simple_sat_program \
|
2019-09-08 22:57:47 +02:00
|
|
|
rcc_solution_hinting_sample_sat \
|
2018-11-15 10:56:34 -08:00
|
|
|
rcc_solve_and_print_intermediate_solutions_sample_sat \
|
|
|
|
|
rcc_solve_with_time_limit_sample_sat \
|
2019-03-25 13:30:23 +01:00
|
|
|
rcc_step_function_sample_sat \
|
2018-11-15 10:56:34 -08:00
|
|
|
rcc_stop_after_n_solutions_sample_sat
|
2018-11-09 09:21:33 +01:00
|
|
|
|
|
|
|
|
.PHONY: check_cc_pimpl
|
|
|
|
|
check_cc_pimpl: \
|
2018-11-16 15:10:15 +01:00
|
|
|
test_cc_algorithms_samples \
|
2018-11-23 14:41:28 +01:00
|
|
|
test_cc_constraint_solver_samples \
|
2018-12-27 10:47:37 +01:00
|
|
|
test_cc_graph_samples \
|
2018-11-09 09:21:33 +01:00
|
|
|
test_cc_linear_solver_samples \
|
2018-11-16 15:10:15 +01:00
|
|
|
test_cc_sat_samples \
|
|
|
|
|
\
|
2018-10-29 14:17:53 +01:00
|
|
|
rcc_linear_programming \
|
|
|
|
|
rcc_stigler_diet \
|
|
|
|
|
rcc_constraint_programming_cp \
|
|
|
|
|
rcc_integer_programming \
|
|
|
|
|
rcc_knapsack \
|
|
|
|
|
rcc_max_flow \
|
2018-11-23 14:41:28 +01:00
|
|
|
rcc_min_cost_flow ;
|
2018-10-29 14:17:53 +01:00
|
|
|
|
2018-11-09 09:21:33 +01:00
|
|
|
.PHONY: test_cc_tests # Build and Run all C++ Tests (located in ortools/examples/tests)
|
|
|
|
|
test_cc_tests: \
|
2019-04-23 13:16:20 +02:00
|
|
|
rcc_lp_test \
|
2018-11-09 09:21:33 +01:00
|
|
|
rcc_bug_fz1 \
|
|
|
|
|
rcc_cpp11_test \
|
|
|
|
|
rcc_forbidden_intervals_test \
|
|
|
|
|
rcc_issue57 \
|
2018-12-03 10:51:15 +01:00
|
|
|
rcc_min_max_test
|
2018-11-09 09:21:33 +01:00
|
|
|
# $(MAKE) rcc_issue173 # error: too long
|
|
|
|
|
|
|
|
|
|
.PHONY: test_cc_contrib # Build and Run all C++ Contrib (located in ortools/examples/contrib)
|
|
|
|
|
test_cc_contrib: ;
|
|
|
|
|
|
|
|
|
|
.PHONY: test_cc_cpp # Build and Run all C++ Examples (located in ortools/examples/cpp)
|
|
|
|
|
test_cc_cpp: \
|
2018-11-28 11:33:36 +01:00
|
|
|
rcc_costas_array_sat \
|
|
|
|
|
rcc_cvrp_disjoint_tw \
|
|
|
|
|
rcc_cvrptw \
|
|
|
|
|
rcc_cvrptw_with_breaks \
|
|
|
|
|
rcc_cvrptw_with_refueling \
|
|
|
|
|
rcc_cvrptw_with_resources \
|
|
|
|
|
rcc_cvrptw_with_stop_times_and_resources \
|
|
|
|
|
rcc_flow_api \
|
|
|
|
|
rcc_linear_assignment_api \
|
|
|
|
|
rcc_linear_solver_protocol_buffers \
|
|
|
|
|
rcc_magic_square_sat \
|
2018-10-29 14:17:53 +01:00
|
|
|
rcc_nqueens \
|
|
|
|
|
rcc_random_tsp \
|
2018-11-22 01:30:28 -08:00
|
|
|
rcc_slitherlink_sat \
|
2018-10-29 14:17:53 +01:00
|
|
|
rcc_strawberry_fields_with_column_generation \
|
2020-03-26 15:18:46 -04:00
|
|
|
rcc_uncapacitated_facility_location \
|
2018-10-29 14:17:53 +01:00
|
|
|
rcc_weighted_tardiness_sat
|
|
|
|
|
$(MAKE) run \
|
|
|
|
|
SOURCE=examples/cpp/dimacs_assignment.cc \
|
|
|
|
|
ARGS=examples/data/dimacs/assignment/small.asn
|
|
|
|
|
$(MAKE) run \
|
2018-11-28 11:37:32 +01:00
|
|
|
SOURCE=examples/cpp/dobble_ls.cc \
|
|
|
|
|
ARGS="--time_limit_in_ms=10000"
|
|
|
|
|
$(MAKE) run \
|
2018-11-24 23:06:05 +01:00
|
|
|
SOURCE=examples/cpp/golomb_sat.cc \
|
2018-10-29 14:17:53 +01:00
|
|
|
ARGS="--size=5"
|
|
|
|
|
$(MAKE) run \
|
|
|
|
|
SOURCE=examples/cpp/jobshop_sat.cc \
|
|
|
|
|
ARGS="--input=examples/data/jobshop/ft06"
|
|
|
|
|
$(MAKE) run \
|
2018-11-28 11:37:32 +01:00
|
|
|
SOURCE=examples/cpp/mps_driver.cc \
|
|
|
|
|
ARGS="--input examples/data/tests/test.mps"
|
|
|
|
|
$(MAKE) run \
|
2018-11-25 11:10:12 +01:00
|
|
|
SOURCE=examples/cpp/network_routing_sat.cc \
|
2018-10-29 14:17:53 +01:00
|
|
|
ARGS="--clients=10 --backbones=5 --demands=10 --traffic_min=5 --traffic_max=10 --min_client_degree=2 --max_client_degree=5 --min_backbone_degree=3 --max_backbone_degree=5 --max_capacity=20 --fixed_charge_cost=10"
|
|
|
|
|
$(MAKE) run \
|
2018-11-22 01:30:28 -08:00
|
|
|
SOURCE=examples/cpp/sports_scheduling_sat.cc \
|
|
|
|
|
ARGS="--params max_time_in_seconds:10.0"
|
2018-10-29 14:17:53 +01:00
|
|
|
# $(MAKE) run SOURCE=examples/cpp/frequency_assignment_problem.cc # Need data file
|
|
|
|
|
# $(MAKE) run SOURCE=examples/cpp/pdptw.cc ARGS="--pdp_file examples/data/pdptw/LC1_2_1.txt" # Fails on windows...
|
2018-11-22 01:30:28 -08:00
|
|
|
$(MAKE) run SOURCE=examples/cpp/shift_minimization_sat.cc ARGS="--input examples/data/shift_scheduling/minimization/data_1_23_40_66.dat"
|
2019-04-24 17:59:42 +02:00
|
|
|
$(MAKE) run \
|
2018-11-28 11:37:32 +01:00
|
|
|
SOURCE=examples/cpp/solve.cc \
|
|
|
|
|
ARGS="--input examples/data/tests/test2.mps"
|
2018-10-29 14:17:53 +01:00
|
|
|
|
2018-11-09 09:21:33 +01:00
|
|
|
.PHONY: test_cc_pimpl
|
|
|
|
|
test_cc_pimpl: \
|
|
|
|
|
check_cc_pimpl \
|
|
|
|
|
test_cc_tests \
|
|
|
|
|
test_cc_contrib \
|
|
|
|
|
test_cc_cpp
|
2018-10-29 14:17:53 +01:00
|
|
|
|
2018-11-09 09:21:33 +01:00
|
|
|
.PHONY: test_fz_pimpl
|
|
|
|
|
test_fz_pimpl: \
|
2018-10-29 14:17:53 +01:00
|
|
|
rfz_golomb \
|
|
|
|
|
rfz_alpha
|
2018-08-31 18:14:17 +02:00
|
|
|
|
2018-09-18 10:10:25 +02:00
|
|
|
rfz_%: fz $(FZ_EX_DIR)/%.fzn
|
|
|
|
|
$(BIN_DIR)$Sfz$E $(FZ_EX_PATH)$S$*.fzn
|
2018-08-31 18:14:17 +02:00
|
|
|
|
2020-04-07 18:59:25 +02:00
|
|
|
#################
|
|
|
|
|
## Packaging ##
|
|
|
|
|
#################
|
|
|
|
|
TEMP_PACKAGE_CC_DIR = temp_package_cc
|
|
|
|
|
|
|
|
|
|
$(TEMP_PACKAGE_CC_DIR):
|
|
|
|
|
-$(MKDIR_P) $(TEMP_PACKAGE_CC_DIR)
|
|
|
|
|
|
|
|
|
|
package_cc_pimpl: cc | $(TEMP_PACKAGE_CC_DIR)
|
|
|
|
|
$(MAKE) install_libortools prefix=$(TEMP_PACKAGE_CC_DIR)$S$(INSTALL_DIR)
|
|
|
|
|
$(MAKE) install_third_party prefix=$(TEMP_PACKAGE_CC_DIR)$S$(INSTALL_DIR)
|
|
|
|
|
ifeq ($(SYSTEM),win)
|
|
|
|
|
cd $(TEMP_PACKAGE_CC_DIR) && ..$S$(ZIP) -r ..$S$(INSTALL_DIR)$(ARCHIVE_EXT) $(INSTALL_DIR)
|
|
|
|
|
else
|
|
|
|
|
$(TAR) -C $(TEMP_PACKAGE_CC_DIR) --no-same-owner -czvf $(INSTALL_DIR)$(ARCHIVE_EXT) $(INSTALL_DIR)
|
|
|
|
|
endif
|
|
|
|
|
|
2018-04-25 16:52:01 +02:00
|
|
|
###############
|
|
|
|
|
## INSTALL ##
|
|
|
|
|
###############
|
2018-05-14 17:30:40 +02:00
|
|
|
# ref: https://www.gnu.org/prep/standards/html_node/Directory-Variables.html#index-prefix
|
|
|
|
|
# ref: https://www.gnu.org/prep/standards/html_node/DESTDIR.html
|
2018-04-25 16:52:01 +02:00
|
|
|
install_dirs:
|
2018-07-06 17:24:09 +02:00
|
|
|
-$(MKDIR_P) "$(DESTDIR)$(prefix)"
|
2018-05-14 17:30:40 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude"
|
2018-05-31 11:49:48 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Slib"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sbin"
|
2020-08-01 14:33:36 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sshare"
|
2018-07-13 15:22:41 +02:00
|
|
|
|
|
|
|
|
install_ortools_dirs: install_dirs
|
2018-05-14 17:30:40 +02:00
|
|
|
-$(DELREC) "$(DESTDIR)$(prefix)$Sinclude$Sortools"
|
2018-10-29 14:17:53 +01:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Salgorithms"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sbase"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sbop"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sconstraint_solver"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sglop"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sgraph"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Slinear_solver"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Slp_data"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sport"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Ssat"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sutil"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sdata"
|
2018-05-14 17:30:40 +02:00
|
|
|
|
|
|
|
|
.PHONY: install_cc # Install C++ OR-Tools to $(DESTDIR)$(prefix)
|
2018-05-31 11:49:48 +02:00
|
|
|
install_cc: install_libortools install_third_party install_doc
|
2018-05-14 17:30:40 +02:00
|
|
|
|
2018-07-05 14:56:31 +02:00
|
|
|
.PHONY: install_libortools
|
2018-09-04 10:05:59 +02:00
|
|
|
install_libortools: $(OR_TOOLS_LIBS) install_ortools_dirs
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) LICENSE-2.0.txt "$(DESTDIR)$(prefix)"
|
|
|
|
|
$(COPY) ortools$Salgorithms$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Salgorithms"
|
|
|
|
|
$(COPY) ortools$Sbase$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sbase"
|
|
|
|
|
$(COPY) ortools$Sconstraint_solver$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sconstraint_solver"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sconstraint_solver$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sconstraint_solver"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Sbop$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sbop"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sbop$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sbop"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Sglop$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sglop"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sglop$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sglop"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Sgraph$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sgraph"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sgraph$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sgraph"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Slinear_solver$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Slinear_solver"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Slinear_solver$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Slinear_solver"
|
2018-07-06 19:53:05 +02:00
|
|
|
$(COPY) ortools$Slp_data$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Slp_data"
|
|
|
|
|
$(COPY) ortools$Sport$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sport"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Ssat$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Ssat"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Ssat$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Ssat"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) ortools$Sutil$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sutil"
|
2018-06-29 18:00:32 +02:00
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sutil$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sutil"
|
2018-07-13 14:38:13 +02:00
|
|
|
$(COPY) ortools$Sdata$S*.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sdata"
|
|
|
|
|
$(COPY) $(GEN_PATH)$Sortools$Sdata$S*.pb.h "$(DESTDIR)$(prefix)$Sinclude$Sortools$Sdata"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPY) $(LIB_DIR)$S$(LIB_PREFIX)ortools.$L "$(DESTDIR)$(prefix)$Slib"
|
2018-04-25 16:52:01 +02:00
|
|
|
|
2018-07-05 14:56:31 +02:00
|
|
|
.PHONY: install_third_party
|
2018-05-31 11:49:48 +02:00
|
|
|
install_third_party: install_dirs
|
2018-05-14 17:30:40 +02:00
|
|
|
ifeq ($(UNIX_GFLAGS_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Sgflags "$(DESTDIR)$(prefix)$Sinclude"
|
2019-05-07 11:32:34 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$Slibgflags* "$(DESTDIR)$(prefix)$Slib"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Sbin$Sgflags_completions.sh "$(DESTDIR)$(prefix)$Sbin"
|
2018-05-16 13:28:12 +02:00
|
|
|
endif
|
2018-05-14 17:30:40 +02:00
|
|
|
ifeq ($(UNIX_GLOG_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Sglog "$(DESTDIR)$(prefix)$Sinclude"
|
2019-05-07 11:32:34 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$Slibglog* "$(DESTDIR)$(prefix)$Slib"
|
2018-05-16 13:28:12 +02:00
|
|
|
endif
|
2018-05-14 17:30:40 +02:00
|
|
|
ifeq ($(UNIX_PROTOBUF_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Sgoogle "$(DESTDIR)$(prefix)$Sinclude"
|
2020-09-07 18:46:29 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$Slibproto* "$(DESTDIR)$(prefix)$Slib"
|
2019-05-08 22:40:53 +02:00
|
|
|
$(COPY) dependencies$Sinstall$Sbin$Sprotoc* "$(DESTDIR)$(prefix)$Sbin"
|
2018-05-16 13:28:12 +02:00
|
|
|
endif
|
2018-12-06 16:11:47 +01:00
|
|
|
ifeq ($(UNIX_ABSL_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Sabsl "$(DESTDIR)$(prefix)$Sinclude"
|
2019-02-22 15:00:54 +01:00
|
|
|
-$(COPYREC) $(subst /,$S,$(_ABSL_STATIC_LIB_DIR))$Slibabsl* "$(DESTDIR)$(prefix)$Slib"
|
2018-12-06 16:11:47 +01:00
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
ifeq ($(USE_COINOR),ON)
|
2018-05-14 17:30:40 +02:00
|
|
|
ifeq ($(UNIX_CBC_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Scoin "$(DESTDIR)$(prefix)$Sinclude"
|
2019-05-07 11:32:34 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$SlibCbc* "$(DESTDIR)$(prefix)$Slib"
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$SlibCgl* "$(DESTDIR)$(prefix)$Slib"
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$SlibClp* "$(DESTDIR)$(prefix)$Slib"
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$SlibOsi* "$(DESTDIR)$(prefix)$Slib"
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Slib*$SlibCoinUtils* "$(DESTDIR)$(prefix)$Slib"
|
2018-05-14 17:30:40 +02:00
|
|
|
$(COPYREC) dependencies$Sinstall$Sbin$Scbc "$(DESTDIR)$(prefix)$Sbin"
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sbin$Sclp "$(DESTDIR)$(prefix)$Sbin"
|
2018-05-16 13:28:12 +02:00
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
endif # USE_COINOR
|
2020-08-12 18:46:38 +02:00
|
|
|
ifeq ($(USE_SCIP),ON)
|
2020-08-01 14:33:36 +02:00
|
|
|
ifeq ($(UNIX_SCIP_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
$(COPYREC) dependencies$Sinstall$Sinclude$Sscip "$(DESTDIR)$(prefix)$Sinclude"
|
|
|
|
|
$(COPY) dependencies$Ssources$Sscip-7.0.1$Sapplications$SPolySCIP$SLICENCE "$(DESTDIR)$(prefix)$Sshare$Sscip_license.txt"
|
|
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
endif # USE_SCIP
|
2018-08-07 11:37:58 +02:00
|
|
|
ifeq ($(WINDOWS_ZLIB_DIR),$(OR_ROOT)dependencies/install)
|
2018-07-24 08:32:30 +02:00
|
|
|
$(COPY) dependencies$Sinstall$Sinclude$Szlib.h "$(DESTDIR)$(prefix)$Sinclude"
|
|
|
|
|
$(COPY) dependencies$Sinstall$Sinclude$Szconf.h "$(DESTDIR)$(prefix)$Sinclude"
|
|
|
|
|
endif
|
2018-08-07 11:37:58 +02:00
|
|
|
ifeq ($(WINDOWS_GFLAGS_DIR),$(OR_ROOT)dependencies/install)
|
2018-07-24 10:55:29 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sgflags"
|
2018-12-10 15:49:45 +01:00
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Sgflags "$(DESTDIR)$(prefix)$Sinclude$Sgflags"
|
2018-07-24 08:32:30 +02:00
|
|
|
endif
|
2018-08-07 11:37:58 +02:00
|
|
|
ifeq ($(WINDOWS_GLOG_DIR),$(OR_ROOT)dependencies/install)
|
2018-07-24 10:55:29 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sglog"
|
2018-12-10 15:49:45 +01:00
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Sglog "$(DESTDIR)$(prefix)$Sinclude$Sglog"
|
2018-07-24 08:32:30 +02:00
|
|
|
endif
|
2018-08-07 11:37:58 +02:00
|
|
|
ifeq ($(WINDOWS_PROTOBUF_DIR),$(OR_ROOT)dependencies/install)
|
2018-07-24 10:55:29 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sgoogle"
|
2018-12-10 15:49:45 +01:00
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Sgoogle "$(DESTDIR)$(prefix)$Sinclude$Sgoogle"
|
2018-07-24 08:32:30 +02:00
|
|
|
endif
|
2018-12-06 16:11:47 +01:00
|
|
|
ifeq ($(WINDOWS_ABSL_DIR),$(OR_ROOT)dependencies/install)
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sabsl"
|
2018-12-10 15:49:45 +01:00
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Sabsl "$(DESTDIR)$(prefix)$Sinclude$Sabsl"
|
2018-12-06 16:11:47 +01:00
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
ifeq ($(USE_COINOR),ON)
|
2018-08-07 11:37:58 +02:00
|
|
|
ifeq ($(WINDOWS_CBC_DIR),$(OR_ROOT)dependencies/install)
|
2018-07-24 10:55:29 +02:00
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Scoin"
|
2018-12-10 15:49:45 +01:00
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Scoin "$(DESTDIR)$(prefix)$Sinclude$Scoin"
|
2018-07-24 08:32:30 +02:00
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
endif # USE_COINOR
|
2020-08-12 18:46:38 +02:00
|
|
|
ifeq ($(USE_SCIP),ON)
|
2020-08-01 14:33:36 +02:00
|
|
|
ifeq ($(WINDOWS_SCIP_DIR),$(OR_TOOLS_TOP)/dependencies/install)
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sinclude$Sscip"
|
|
|
|
|
$(COPYREC) /E /Y dependencies$Sinstall$Sinclude$Sscip "$(DESTDIR)$(prefix)$Sinclude$Sscip"
|
|
|
|
|
$(COPY) dependencies$Ssources$Sscip-7.0.1$Sapplications$SPolySCIP$SLICENCE "$(DESTDIR)$(prefix)$Sshare$Sscip_license.txt"
|
|
|
|
|
endif
|
2020-08-17 15:58:14 +02:00
|
|
|
endif # USE_SCIP
|
2018-05-16 13:28:12 +02:00
|
|
|
|
2018-05-31 11:49:48 +02:00
|
|
|
install_doc:
|
|
|
|
|
-$(MKDIR_P) "$(DESTDIR)$(prefix)$Sshare$Sdoc$Sortools"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sshare$Sdoc$Sortools$Ssat"
|
|
|
|
|
-$(MKDIR) "$(DESTDIR)$(prefix)$Sshare$Sdoc$Sortools$Ssat$Sdoc"
|
|
|
|
|
#$(COPY) ortools$Ssat$S*.md "$(DESTDIR)$(prefix)$Sshare$Sdoc$Sortools$Ssat"
|
|
|
|
|
$(COPY) ortools$Ssat$Sdoc$S*.md "$(DESTDIR)$(prefix)$Sshare$Sdoc$Sortools$Ssat$Sdoc"
|
|
|
|
|
|
2020-09-25 17:45:25 +02:00
|
|
|
#######################
|
|
|
|
|
## EXAMPLE ARCHIVE ##
|
|
|
|
|
#######################
|
|
|
|
|
TEMP_CC_DIR=temp_cpp
|
|
|
|
|
|
|
|
|
|
$(TEMP_CC_DIR):
|
|
|
|
|
$(MKDIR) $(TEMP_CC_DIR)
|
|
|
|
|
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples: | $(TEMP_CC_DIR)
|
|
|
|
|
$(MKDIR) $(TEMP_CC_DIR)$Sortools_examples
|
|
|
|
|
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples/examples: | $(TEMP_CC_DIR)/ortools_examples
|
|
|
|
|
$(MKDIR) $(TEMP_CC_DIR)$Sortools_examples$Sexamples
|
|
|
|
|
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples/examples/cpp: | $(TEMP_CC_DIR)/ortools_examples/examples
|
|
|
|
|
$(MKDIR) $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples/examples/data: | $(TEMP_CC_DIR)/ortools_examples/examples
|
|
|
|
|
$(MKDIR) $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Sdata
|
|
|
|
|
|
|
|
|
|
.PHONY: cc_examples_archive # Build stand-alone C++ examples archive file for redistribution.
|
|
|
|
|
cc_examples_archive: | \
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples/examples/cpp \
|
|
|
|
|
$(TEMP_CC_DIR)/ortools_examples/examples/data
|
2020-09-28 14:09:54 +02:00
|
|
|
$(COPY) $(CC_EX_PATH)$S*.h $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) $(CC_EX_PATH)$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
2020-09-25 17:45:25 +02:00
|
|
|
# $(COPY) $(CONTRIB_EX_PATH)$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) ortools$Salgorithms$Ssamples$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) ortools$Sgraph$Ssamples$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) ortools$Slinear_solver$Ssamples$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) ortools$Sconstraint_solver$Ssamples$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
|
|
|
|
$(COPY) ortools$Ssat$Ssamples$S*.cc $(TEMP_CC_DIR)$Sortools_examples$Sexamples$Scpp
|
2020-10-02 17:47:54 +02:00
|
|
|
$(COPY) tools$SREADME.cpp.md $(TEMP_CC_DIR)$Sortools_examples$SREADME.md
|
2020-09-25 17:45:25 +02:00
|
|
|
$(COPY) LICENSE-2.0.txt $(TEMP_CC_DIR)$Sortools_examples
|
|
|
|
|
ifeq ($(SYSTEM),win)
|
|
|
|
|
cd $(TEMP_CC_DIR)\ortools_examples \
|
|
|
|
|
&& ..\..\$(TAR) -C ..\.. -c -v \
|
|
|
|
|
--exclude *svn* --exclude *roadef* --exclude *vector_packing* \
|
|
|
|
|
examples\data | ..\..\$(TAR) xvm
|
|
|
|
|
cd $(TEMP_CC_DIR) \
|
|
|
|
|
&& ..\$(ZIP) \
|
|
|
|
|
-r ..\or-tools_cpp_examples_v$(OR_TOOLS_VERSION).zip \
|
|
|
|
|
ortools_examples
|
|
|
|
|
else
|
|
|
|
|
cd $(TEMP_CC_DIR)/ortools_examples \
|
|
|
|
|
&& tar -C ../.. -c -v \
|
|
|
|
|
--exclude *svn* --exclude *roadef* --exclude *vector_packing* \
|
|
|
|
|
examples/data | tar xvm
|
|
|
|
|
cd $(TEMP_CC_DIR) \
|
|
|
|
|
&& tar -c -v -z --no-same-owner \
|
|
|
|
|
-f ../or-tools_cpp_examples$(PYPI_OS)_v$(OR_TOOLS_VERSION).tar.gz \
|
|
|
|
|
ortools_examples
|
|
|
|
|
endif
|
|
|
|
|
-$(DELREC) $(TEMP_CC_DIR)$Sortools_examples
|
|
|
|
|
|
|
|
|
|
################
|
|
|
|
|
## Cleaning ##
|
|
|
|
|
################
|
|
|
|
|
CC_SAMPLES := $(wildcard ortools/*/samples/*.cc)
|
|
|
|
|
CC_SAMPLES := $(notdir $(CC_SAMPLES))
|
|
|
|
|
CC_SAMPLES := $(addsuffix $E, $(addprefix $(BIN_DIR)$S, $(basename $(CC_SAMPLES))))
|
|
|
|
|
|
|
|
|
|
CC_EXAMPLES := $(wildcard $(CC_EX_DIR)/*.cc)
|
|
|
|
|
CC_EXAMPLES := $(notdir $(CC_EXAMPLES))
|
|
|
|
|
CC_EXAMPLES := $(addsuffix $E, $(addprefix $(BIN_DIR)$S, $(basename $(CC_EXAMPLES))))
|
|
|
|
|
|
|
|
|
|
CC_TESTS := $(wildcard $(TEST_DIR)/*.cc)
|
|
|
|
|
CC_TESTS := $(notdir $(CC_TESTS))
|
|
|
|
|
CC_TESTS := $(addsuffix $E, $(addprefix $(BIN_DIR)$S, $(basename $(CC_TESTS))))
|
|
|
|
|
|
|
|
|
|
.PHONY: clean_cc # Clean C++ output from previous build.
|
|
|
|
|
clean_cc:
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)cvrptw_lib.$L
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)dimacs.$L
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)fap.$L
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)fz.$L
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)ortools.$L
|
|
|
|
|
-$(DEL) $(LIB_DIR)$S$(LIB_PREFIX)*.a
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Salgorithms$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sbase$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sbop$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sconstraint_solver$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sdata$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sflatzinc$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sglop$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sgraph$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Slinear_solver$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Slp_data$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sport$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Ssat$S*.$O
|
|
|
|
|
-$(DEL) $(OBJ_DIR)$Sutil$S*.$O
|
|
|
|
|
-$(DEL) $(BIN_DIR)$Sfz$E
|
|
|
|
|
-$(DEL) $(BIN_DIR)$Sparser_main$E
|
|
|
|
|
-$(DEL) $(BIN_DIR)$Ssat_runner$E
|
|
|
|
|
-$(DEL) $(CC_SAMPLES)
|
|
|
|
|
-$(DEL) $(CC_EXAMPLES)
|
|
|
|
|
-$(DEL) $(CC_TESTS)
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sbop$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sconstraint_solver$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sdata$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sflatzinc$S*.tab.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sflatzinc$S*.yy.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sflatzinc$Sparser.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sglop$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sgraph$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Slinear_solver$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Ssat$S*.pb.*
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Sutil$S*.pb.*
|
|
|
|
|
-$(DEL) $(BIN_DIR)$S*.exp
|
|
|
|
|
-$(DEL) $(BIN_DIR)$S*.lib
|
|
|
|
|
-$(DELREC) $(GEN_PATH)$Sflatzinc$S*
|
|
|
|
|
-$(DELREC) $(OBJ_DIR)$Sflatzinc$S*
|
|
|
|
|
-$(DELREC) $(TEMP_PACKAGE_CC_DIR)
|
|
|
|
|
-$(DELREC) $(TEMP_CC_DIR)
|
|
|
|
|
-$(DEL) $(GEN_PATH)$Sortools$Slinear_solver$Slpi_glop.cc
|
|
|
|
|
|
|
|
|
|
.PHONY: clean_compat
|
|
|
|
|
clean_compat:
|
|
|
|
|
-$(DELREC) $(OR_ROOT)constraint_solver
|
|
|
|
|
-$(DELREC) $(OR_ROOT)linear_solver
|
|
|
|
|
-$(DELREC) $(OR_ROOT)algorithms
|
|
|
|
|
-$(DELREC) $(OR_ROOT)graph
|
|
|
|
|
-$(DELREC) $(OR_ROOT)gen
|
|
|
|
|
|
2018-08-31 18:14:17 +02:00
|
|
|
#############
|
|
|
|
|
## DEBUG ##
|
|
|
|
|
#############
|
2018-03-02 09:56:34 +01:00
|
|
|
.PHONY: detect_cc # Show variables used to build C++ OR-Tools.
|
|
|
|
|
detect_cc:
|
2018-03-06 14:34:17 +01:00
|
|
|
@echo Relevant info for the C++ build:
|
2018-05-14 17:30:40 +02:00
|
|
|
@echo PROTOC = $(PROTOC)
|
2018-03-02 09:56:34 +01:00
|
|
|
@echo CCC = $(CCC)
|
|
|
|
|
@echo CFLAGS = $(CFLAGS)
|
2018-05-14 17:30:40 +02:00
|
|
|
@echo LDFLAGS = $(LDFLAGS)
|
2018-05-16 13:28:12 +02:00
|
|
|
@echo LINK_CMD = $(LINK_CMD)
|
2020-07-06 17:25:30 +02:00
|
|
|
@echo DEPENDENCIES_INC = $(DEPENDENCIES_INC)
|
2018-03-02 15:58:25 +01:00
|
|
|
@echo DEPENDENCIES_LNK = $(DEPENDENCIES_LNK)
|
2018-05-14 17:30:40 +02:00
|
|
|
@echo SRC_DIR = $(SRC_DIR)
|
2018-06-29 18:00:32 +02:00
|
|
|
@echo GEN_DIR = $(GEN_DIR)
|
2018-09-18 10:10:25 +02:00
|
|
|
@echo CC_EX_DIR = $(CC_EX_DIR)
|
2018-05-14 17:30:40 +02:00
|
|
|
@echo OBJ_DIR = $(OBJ_DIR)
|
2014-05-23 16:52:10 +00:00
|
|
|
@echo LIB_DIR = $(LIB_DIR)
|
|
|
|
|
@echo BIN_DIR = $(BIN_DIR)
|
2018-05-14 17:30:40 +02:00
|
|
|
@echo prefix = $(prefix)
|
|
|
|
|
@echo OR_TOOLS_LNK = $(OR_TOOLS_LNK)
|
|
|
|
|
@echo OR_TOOLS_LDFLAGS = $(OR_TOOLS_LDFLAGS)
|
|
|
|
|
@echo OR_TOOLS_LIBS = $(OR_TOOLS_LIBS)
|
2018-04-25 16:32:46 +02:00
|
|
|
ifeq ($(SYSTEM),win)
|
|
|
|
|
@echo off & echo(
|
|
|
|
|
else
|
|
|
|
|
@echo
|
|
|
|
|
endif
|