Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
workspaces
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ssa
workspaces
Commits
6c44801c
Commit
6c44801c
authored
4 years ago
by
Nathan Hertz
Browse files
Options
Downloads
Patches
Plain Diff
Updated Makefile structure; needs more iteration to be functional
parent
bb39f938
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
Makefile
+11
-37
11 additions, 37 deletions
Makefile
alma_fetch.mk
+4
-13
4 additions, 13 deletions
alma_fetch.mk
conda.mk
+27
-0
27 additions, 0 deletions
conda.mk
setuptools.mk
+14
-0
14 additions, 0 deletions
setuptools.mk
with
56 additions
and
50 deletions
Makefile
+
11
−
37
View file @
6c44801c
include
make_alma_fetch
include
conda.mk
include
setuptools.mk
include
alma_fetch.mk
SHELL
:=
/bin/bash
SHELL
:=
/bin/bash
py
:=
python3
os
:=
$(
shell
uname
-s
)
home_dir
:=
$(
shell
pwd
)
setup_dirs
:=
$(
shell find
.
-name
setup.py |
tr
'\n'
' '
|
sed
"s/setup.py//g"
)
.PHONY
:
${HOME}/miniconda3 clean
build-base
:
@
echo
"Building..."
make miniconda-installed
make build-python
@
echo
"Finished build."
all
:
miniconda-installed build-python build-alma
build-almafetch
:
@
echo
"Building ALMA fetcher."
make build-alma
miniconda-installed ${HOME}/miniconda3
:
conda
env
update
${HOME}/miniconda3
:
@
url
=
"https://repo.anaconda.com/miniconda/"
if
[
"
$(
os
)
"
==
"Darwin"
]
;
\
then
\
file
=
"Miniconda3-latest-MacOSX-x86_64.sh"
;
\
elif
[
"
$(
os
)
"
==
"Linux"
]
;
\
then
\
file
=
"Miniconda3-latest-Linux-x86_64.sh"
;
\
fi
echo
$(
addsuffix
$(
file
)
,
$(
url
))
wget
$(
addsuffix
$(
file
)
,
$(
url
))
-P
${
HOME
}
chmod
+x
$$
HOME/
$$
file
$$
HOME/
$$
file
build-python $(setup_dirs)
:
@
for
dir
in
$(
setup_dirs
)
;
do
\
cd
$$
dir
;
\
$(
py
)
setup.py develop
;
\
cd
$(
home_dir
)
;
\
done
clean
:
find
.
-name
'*.pyc'
-exec
rm
--force
{}
+
find
.
-name
'*.pyo'
-exec
rm
--force
{}
+
find
.
-name
'*~'
-exec
rm
--force
{}
+
rm
-f
-R
*
.egg-info
conda deactivate
\ No newline at end of file
This diff is collapsed.
Click to expand it.
make_
alma_fetch
→
alma_fetch
.mk
+
4
−
13
View file @
6c44801c
.PHONY: all build-python clean-alma
SHELL
:=
/bin/bash
all: build-alma
alma_product_fetch_sources
:=
$(
shell find apps/cli/executables/alma_product_fetch
-type
f
)
#miniconda-installed: ${HOME}/miniconda3
# echo "found miniconda3 install"
#
#${HOME}/miniconda3:
# echo "looks like I have to install miniconda"
# touch $@
build-alma
:
apps/cli/executables/alma_product_fetch/dist/alma_product_fetch-4.0.0a1.dev1.macosx-10.9-x86_64.tar.gz
build-alma
:
apps/cli/executables/alma_product_fetch/dist/alma_product_fetch-4.0.0a1.dev1.macosx-10.9-x86_64.tar.gz
echo "built"
@
echo
"built"
alma_product_fetch_sources := $(shell find apps/cli/executables/alma_product_fetch -type f)
apps/cli/executables/alma_product_fetch/dist/alma_product_fetch-4.0.0a1.dev1.macosx-10.9-x86_64.tar.gz
:
$(alma_product_fetch_sources)
apps/cli/executables/alma_product_fetch/dist/alma_product_fetch-4.0.0a1.dev1.macosx-10.9-x86_64.tar.gz
:
$(alma_product_fetch_sources)
echo building alma product fetch
@
echo
building alma product fetch
cd
apps/cli/executables/alma_product_fetch
&&
\
cd
apps/cli/executables/alma_product_fetch
&&
\
python setup.py bdist
python setup.py bdist
...
...
This diff is collapsed.
Click to expand it.
conda.mk
0 → 100644
+
27
−
0
View file @
6c44801c
SHELL
:=
/bin/bash
os
:=
$(
shell
uname
-s
)
conda-install
:=
$(
shell which conda
)
miniconda-installed conda-install
:
# Check if data env is activated
@
([
${
CONDA_DEFAULT_ENV
}
==
data
]
&&
conda
env
update
)
||
\
conda activate data
conda-install
:
if
[
-z
conda-install
]
;
\
then
\
@url
=
"https://repo.anaconda.com/miniconda/"
\
if
[
"
$(
os
)
"
==
"Darwin"
]
;
\
then
\
file
=
"Miniconda3-latest-MacOSX-x86_64.sh"
;
\
elif
[
"
$(
os
)
"
==
"Linux"
]
;
\
then
\
file
=
"Miniconda3-latest-Linux-x86_64.sh"
;
\
fi
\
wget
$(
addsuffix
$(
file
)
,
$(
url
))
-P
${
HOME
}
\
chmod
+x
${
HOME
}
/
$$
file
\
$$
HOME/
$$
file
\
fi
clean-conda
:
conda deactivate
\ No newline at end of file
This diff is collapsed.
Click to expand it.
setuptools.mk
0 → 100644
+
14
−
0
View file @
6c44801c
SHELL
:=
/bin/bash
py
:=
python3
home_dir
:=
$(
shell
pwd
)
setup_dirs
:=
$(
shell find
.
-name
setup.py |
tr
'\n'
' '
|
sed
"s/setup.py//g"
)
build-python $(setup_dirs)
:
@
for
dir
in
$(
setup_dirs
)
;
do
\
cd
$$
dir
;
\
$(
py
)
setup.py develop
;
\
cd
$(
home_dir
)
;
\
done
clean-python
:
rm
-Rf
*
.pyc
*
.pyo
*
~
*
.egg-info
\ No newline at end of file
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