Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gargantext-ihaskell
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
gargantext-ihaskell
Commits
eb1670b2
Commit
eb1670b2
authored
Sep 06, 2015
by
Andrew Gibiansky
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #567 from sumitsahrawat/modular-build-script
Modularize build script
parents
a394a2b8
635a8fc4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
19 deletions
+37
-19
build.sh
build.sh
+37
-19
No files found.
build.sh
View file @
eb1670b2
...
...
@@ -32,9 +32,6 @@ fi
# What to install.
INSTALLS
=
""
# Remove my kernelspec
rm
-rf
~/.ipython/kernels/haskell
# Compile dependencies.
if
[
$#
-gt
0
]
;
then
if
[
$1
=
"all"
]
||
[
$1
=
"ihaskell"
]
;
then
...
...
@@ -47,7 +44,7 @@ INSTALLS="$INSTALLS ."
# Install ihaskell-display packages.
if
[
$#
-gt
0
]
;
then
if
[
$1
=
"display"
]
||
[
$1
=
"all"
]
;
then
if
[
$1
=
"display"
]
||
[
$1
=
"all"
]
;
then
# Install all the display libraries
cd
ihaskell-display
for
dir
in
`
ls
|
grep
-v
ihaskell-widgets
`
...
...
@@ -58,25 +55,46 @@ if [ $# -gt 0 ]; then
fi
fi
# Clean all required directories, just in case.
TOP
=
`
pwd
`
for
pkg
in
$INSTALLS
do
cd
./
$pkg
cabal clean
cd
$TOP
done
cleanup
()
{
# Remove old kernelspec
rm
-rf
~/.ipython/kernels/haskell
# Stick a "./" before everything.
INSTALL_DIRS
=
`
echo
$INSTALLS
|
tr
' '
'\n'
|
sed
's#^#./#'
|
tr
' '
'\n'
`
# Clean all required directories, just in case.
TOP
=
`
pwd
`
for
pkg
in
$INSTALLS
do
cd
./
$pkg
cabal clean
cd
$TOP
done
}
echo
CMD: cabal
install
--constraint
"arithmoi -llvm"
-j
$INSTALL_DIRS
--force-reinstalls
--max-backjumps
=
-1
--reorder-goals
cabal
install
--constraint
"arithmoi -llvm"
-j
$INSTALL_DIRS
--force-reinstalls
--max-backjumps
=
-1
--reorder-goals
install_selected
()
{
# Stick a "./" before everything.
INSTALL_DIRS
=
`
echo
$INSTALLS
|
tr
' '
'\n'
|
sed
's#^#./#'
|
tr
' '
'\n'
`
if
[
$2
=
"no-widgets"
]
;
then
echo
'Not installing ihaskell-widgets'
elif
[
$1
=
"display"
]
||
[
$1
=
"all"
]
;
then
echo
CMD: cabal
install
--constraint
"arithmoi -llvm"
-j
$INSTALL_DIRS
--force-reinstalls
--max-backjumps
=
-1
--reorder-goals
cabal
install
--constraint
"arithmoi -llvm"
-j
$INSTALL_DIRS
--force-reinstalls
--max-backjumps
=
-1
--reorder-goals
}
install_widgets
()
{
echo
CMD: cabal
install
ihaskell-display/ihaskell-widgets
cabal
install
ihaskell-display/ihaskell-widgets
}
# Check if arguments are correct, and proceed as required
if
[
-z
$2
]
;
then
cleanup
install_selected
if
[
$1
=
"display"
]
||
[
$1
=
"all"
]
;
then
install_widgets
fi
elif
[
$2
=
"no-widgets"
]
;
then
cleanup
install_selected
else
print_help
exit
1
fi
if
hash
ihaskell 2>/dev/null
;
then
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment