Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
ATFM optimization
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hailu, Dawit
ATFM optimization
Commits
d9c2a111
Commit
d9c2a111
authored
Jul 16, 2021
by
daveabiy
Browse files
Options
Downloads
Patches
Plain Diff
Main makefile in Linux systems
parent
3abde29b
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Makefile
+164
-0
164 additions, 0 deletions
Makefile
with
164 additions
and
0 deletions
Makefile
0 → 100644
+
164
−
0
View file @
d9c2a111
#* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
#* *
#* This file is part of the program and library *
#* SCIP --- Solving Constraint Integer Programs *
#* *
#* Copyright (C) 2002-2020 Konrad-Zuse-Zentrum *
#* fuer Informationstechnik Berlin *
#* *
#* SCIP is distributed under the terms of the ZIB Academic License. *
#* *
#* You should have received a copy of the ZIB Academic License *
#* along with SCIP; see the file COPYING. If not email to scip@zib.de. *
#* *
#* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
#@file Makefile
#@brief Makefile for SCIP project
#@author Timo Berthold
#@author Stefan Heinz
#-----------------------------------------------------------------------------
# path
#-----------------------------------------------------------------------------
SCIPDIR
=
../..
#-----------------------------------------------------------------------------
# include default project Makefile from SCIP (need to do this twice, once to
# find the correct binary, then, after getting the correct flags from the
# binary (which is necessary since the ZIMPL flags differ from the default
# if compiled with the SCIP Optsuite instead of SCIP), we need to set the
# compile flags, e.g., for the ZIMPL library, which is again done in make.project
#-----------------------------------------------------------------------------
include
$(SCIPDIR)/make/make.project
SCIPVERSION
:=
$(
shell
$(
SCIPDIR
)
/bin/scip.
$(
BASE
)
.
$(
LPS
)
.
$(
TPI
)$(
EXEEXTENSION
)
-v
|
sed
-e
's/$$/@/'
)
override
ARCH
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* ARCH=\([^@]*\).*/\1/'
)
override
EXPRINT
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* EXPRINT=\([^@]*\).*/\1/'
)
override
GAMS
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* GAMS=\([^@]*\).*/\1/'
)
override
GMP
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* GMP=\([^@]*\).*/\1/'
)
override
SYM
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* SYM=\([^@]*\).*/\1/'
)
override
IPOPT
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* IPOPT=\([^@]*\).*/\1/'
)
override
IPOPTOPT
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* IPOPTOPT=\([^@]*\).*/\1/'
)
override
LPSCHECK
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* LPSCHECK=\([^@]*\).*/\1/'
)
override
LPSOPT
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* LPSOPT=\([^@]*\).*/\1/'
)
override
NOBLKBUFMEM
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* NOBLKBUFMEM=\([^@]*\).*/\1/'
)
override
NOBLKMEM
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* NOBLKMEM=\([^@]*\).*/\1/'
)
override
NOBUFMEM
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* NOBUFMEM=\([^@]*\).*/\1/'
)
override
PARASCIP
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* PARASCIP=\([^@]*\).*/\1/'
)
override
READLINE
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* READLINE=\([^@]*\).*/\1/'
)
override
SANITIZE
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* SANITIZE=\([^@]*\).*/\1/'
)
override
ZIMPL
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* ZIMPL=\([^@]*\).*/\1/'
)
override
ZIMPLOPT
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* ZIMPLOPT=\([^@]*\).*/\1/'
)
override
ZLIB
:=
$(
shell
echo
"
$(
SCIPVERSION
)
"
|
sed
-e
's/.* ZLIB=\([^@]*\).*/\1/'
)
include
$(SCIPDIR)/make/make.project
#-----------------------------------------------------------------------------
# Main Program
#-----------------------------------------------------------------------------
MAINNAME
=
LagrangianRelaxation
CMAINOBJ
=
cmain.o
CXXMAINOBJ
=
relax_lagr.o
\
vardata_lagr.o
\
probdata_lagr.o
MAINSRC
=
$(
addprefix
$(
SRCDIR
)
/,
$(
CMAINOBJ:.o
=
.c
))
MAINSRC
+=
$(
addprefix
$(
SRCDIR
)
/,
$(
CXXMAINOBJ:.o
=
.cpp
))
MAIN
=
$(
MAINNAME
)
.
$(
BASE
)
.
$(
LPS
)$(
EXEEXTENSION
)
MAINFILE
=
$(
BINDIR
)
/
$(
MAIN
)
MAINSHORTLINK
=
$(
BINDIR
)
/
$(
MAINNAME
)
MAINOBJFILES
=
$(
addprefix
$(
OBJDIR
)
/,
$(
CMAINOBJ
))
MAINOBJFILES
+=
$(
addprefix
$(
OBJDIR
)
/,
$(
CXXMAINOBJ
))
#-----------------------------------------------------------------------------
# External libraries
#-----------------------------------------------------------------------------
FLAGS
+=
LDFLAGS
+=
#-----------------------------------------------------------------------------
# Rules
#-----------------------------------------------------------------------------
ifeq
($(VERBOSE),false)
.SILENT
:
$(MAINFILE) $(MAINOBJFILES) $(MAINSHORTLINK)
endif
.PHONY
:
all
all
:
$(SCIPDIR) $(MAINFILE) $(MAINSHORTLINK)
.PHONY
:
lint
lint
:
$(MAINSRC)
-
rm
-f
lint.out
$(
SHELL
)
-ec
'for i in $^; \
do \
echo $$i; \
$(
LINT
)
-I
$(
SCIPDIR
)
lint/main-gcc.lnt +os\(lint.out\) -u -zero \
$(
FLAGS
)
-UNDEBUG -USCIP_WITH_READLINE -USCIP_ROUNDING_FE $$i; \
done'
.PHONY
:
scip
scip
:
@$(
MAKE
)
-C
$(
SCIPDIR
)
libs
$^
$(MAINSHORTLINK)
:
$(MAINFILE)
@
rm
-f
$@
cd
$(
dir
$@
)
&&
ln
-s
$(
notdir
$(
MAINFILE
))
$(
notdir
$@
)
$(OBJDIR)
:
@
-mkdir
-p
$(
OBJDIR
)
$(BINDIR)
:
@
-mkdir
-p
$(
BINDIR
)
.PHONY
:
clean
clean
:
$(OBJDIR)
ifneq
($(OBJDIR),)
@
-
(
rm
-f
$(
OBJDIR
)
/
*
.o
$(
OBJDIR
)
/
*
.d
&&
rmdir
$(
OBJDIR
)
)
;
@
echo
"-> remove main objective files"
endif
@
-rm
-f
$(
MAINFILE
)
$(
MAINLINK
)
$(
MAINSHORTLINK
)
@
echo
"-> remove binary"
.PHONY
:
test
test
:
$(MAINFILE)
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/check.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/evaluate.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/evalcheck.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/evalcheck_cluster.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/check.awk
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/getlastprob.awk
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/configuration_set.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/configuration_solufile.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/configuration_logfiles.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/configuration_tmpfile_setup_scip.sh configuration_tmpfile_setup_binpacking.sh
)
;
@
-
(
cd
check
&&
ln
-fs
../
$(
SCIPDIR
)
/check/run.sh
)
;
cd
check
;
\
$(
SHELL
)
./check.sh
$(
TEST
)
$(
EXECUTABLE
)
$(
SETTINGS
)
$(
BINID
)
$(
OUTPUTDIR
)
$(
TIME
)
$(
NODES
)
$(
MEM
)
$(
THREADS
)
$(
FEASTOL
)
$(
DISPFREQ
)
$(
CONTINUE
)
$(
LOCK
)
"example"
$(
LPS
)
$(
DEBUGTOOL
)
$(
CLIENTTMPDIR
)
false
$(
OPTCOMMAND
)
$(
SETCUTOFF
)
$(
MAXJOBS
)
$(
VISUALIZE
)
$(
PERMUTE
)
$(
SEEDS
)
$(
GLBSEEDSHIFT
)
$(
STARTPERM
);
.PHONY
:
tags
tags
:
rm
-f
TAGS
;
ctags
-e
src/
*
.c src/
*
.h
$(
SCIPDIR
)
/src/scip/
*
.c
$(
SCIPDIR
)
/src/scip/
*
.h
;
-include
$(MAINOBJFILES:.o=.d)
$(MAINFILE)
:
$(BINDIR) $(OBJDIR) $(SCIPLIBFILE) $(LPILIBFILE) $(NLPILIBFILE) $(MAINOBJFILES)
@
echo
"-> linking
$@
"
$(
LINKCXX
)
$(
MAINOBJFILES
)
$(
LINKCXXSCIPALL
)
$(
LDFLAGS
)
$(
LINKCXX_o
)
$@
$(OBJDIR)/%.o
:
$(SRCDIR)/%.c
@
echo
"-> compiling
$@
"
$(
CC
)
$(
FLAGS
)
$(
OFLAGS
)
$(
BINOFLAGS
)
$(
CFLAGS
)
$(
DFLAGS
)
-c
$<
$(
CC_o
)
$@
$(OBJDIR)/%.o
:
$(SRCDIR)/%.cpp
@
echo
"-> compiling
$@
"
$(
CXX
)
$(
FLAGS
)
$(
OFLAGS
)
$(
BINOFLAGS
)
$(
CXXFLAGS
)
$(
DFLAGS
)
-c
$<
$(
CXX_o
)
$@
#---- EOF --------------------------------------------------------------------
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment