-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #47 from Julia-Embedded/support-v1.5.0
Support v1.5.0
- Loading branch information
Showing
9 changed files
with
152 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Build Julia binary for arm32-bit armv7-a devices e.g. RaspberryPi 2 or 3 | ||
|
||
FROM balenalib/raspberrypi3:buster-20200502 | ||
|
||
MAINTAINER SATOSHI TERASAKI | ||
|
||
# insta dependencies | ||
RUN apt-get update && \ | ||
apt-get install -y build-essential libatomic1 python gfortran perl wget m4 cmake pkg-config \ | ||
git && \ | ||
apt-get clean && rm -rf /var/cache/apt/archives/* /var/lib/apt/lists/* | ||
|
||
# build julia from source | ||
ARG JL_VERSION="v1.5.0" | ||
ARG WDIR=/home/pi/work | ||
ARG JL_BUILD_DIR=$WDIR/build | ||
WORKDIR $WDIR | ||
RUN echo "\ | ||
CXXFLAGS=-D_GLIBCXX_USE_CXX11_ABI=0\n\ | ||
prefix=/home/pi/julia-$JL_VERSION\n\ | ||
USE_BINARYBUILDER=0\n\ | ||
LDFLAGS=-latomic\n\ | ||
CFLAGS += "-mfpu=neon-vfpv4"\n\ | ||
CXXFLAGS += "-mfpu=neon-vfpv4"\n\ | ||
MARCH="armv7-a"\n\ | ||
JULIA_CPU_TARGET=\"armv7-a\;armv7-a,neon\;armv7-a,neon,vfp4\"\n\ | ||
JULIA_CPU_THREADS=4\n\ | ||
" > Make.user && \ | ||
cat Make.user && \ | ||
git clone --depth=1 -b $JL_VERSION https://github.com/JuliaLang/julia.git $JL_BUILD_DIR &&\ | ||
cp Make.user $JL_BUILD_DIR && \ | ||
# add patches | ||
sed -i -e '69s/devnull/stdout/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
sed -i -e '63,65 s/^/#/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
sed -i -e '190 s/^/#/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
cat ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
cd $JL_BUILD_DIR && make -j 16 && make install && \ | ||
echo "clean up $JL_BUILD_DIR" && \ | ||
rm -r $JL_BUILD_DIR && \ | ||
echo "Done" | ||
|
||
# add path of Julia | ||
ENV PATH=/home/pi/julia-$JL_VERSION/bin:$PATH | ||
# runtime test | ||
RUN julia -e "using InteractiveUtils; versioninfo()" | ||
CMD ["julia"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Build Julia binary for arm32-bit devices e.g. RaspberryPi Zero(W/WH) | ||
|
||
FROM balenalib/raspberry-pi:buster-20200518 | ||
|
||
MAINTAINER SATOSHI TERASAKI | ||
|
||
# install dependencies | ||
RUN apt-get update && \ | ||
apt-get install -y build-essential libatomic1 python gfortran perl wget m4 cmake pkg-config \ | ||
libopenblas-dev \ | ||
liblapack-dev \ | ||
libgmp3-dev \ | ||
libmpfr-dev \ | ||
git && \ | ||
apt-get clean && rm -rf /var/cache/apt/archives/* /var/lib/apt/lists/* | ||
|
||
# build julia from source | ||
ARG JL_VERSION="v1.5.0" | ||
ARG WDIR=/home/pi/work | ||
ARG JL_BUILD_DIR=$WDIR/build | ||
WORKDIR $WDIR | ||
RUN echo "\ | ||
prefix=/home/pi/julia-$JL_VERSION\n\ | ||
JULIA_CPU_TARGET=arm1176jzf-s\n\ | ||
LDFLAGS=-latomic\n\ | ||
USE_BINARYBUILDER=0\n\ | ||
JULIA_PRECOMPILE=0\n\ | ||
override USE_SYSTEM_BLAS=1\n\ | ||
override USE_SYSTEM_LAPACK=1\n\ | ||
override USE_SYSTEM_LIBM=1\n\ | ||
override USE_SYSTEM_GMP=1\n\ | ||
override USE_SYSTEM_MPFR=1\n\ | ||
" > Make.user && \ | ||
cat Make.user && \ | ||
git clone --depth=1 -b $JL_VERSION https://github.com/JuliaLang/julia.git $JL_BUILD_DIR &&\ | ||
cp Make.user $JL_BUILD_DIR && \ | ||
# add patches | ||
sed -i -e '69s/devnull/stdout/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
sed -i -e '63,65 s/^/#/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
sed -i -e '190 s/^/#/' ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
cat ${JL_BUILD_DIR}/contrib/generate_precompile.jl && \ | ||
cd $JL_BUILD_DIR && make -j 16 OPENBLAS_USE_THREAD=0 && make install && \ | ||
rm -r $JL_BUILD_DIR && \ | ||
echo "Done" | ||
|
||
# add path of Julia | ||
ENV PATH=/home/pi/julia-$JL_VERSION/bin:$PATH | ||
# runtime test | ||
RUN julia -e "using InteractiveUtils; versioninfo()" | ||
CMD ["julia"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters