2019-12-02 13:30:41 +01:00
|
|
|
ARG img_version
|
|
|
|
FROM godot-mono:${img_version}
|
|
|
|
|
2019-01-07 21:51:22 +01:00
|
|
|
ARG mono_version
|
|
|
|
|
2019-11-15 10:49:02 +01:00
|
|
|
RUN if [ -z "${mono_version}" ]; then echo -e "\n\nargument mono-version is mandatory!\n\n"; exit 1; fi && \
|
|
|
|
dnf -y install --setopt=install_weak_deps=False \
|
2019-11-15 11:56:31 +01:00
|
|
|
mingw32-gcc mingw32-gcc-c++ mingw32-winpthreads-static mingw64-gcc mingw64-gcc-c++ mingw64-winpthreads-static yasm && \
|
2019-12-02 15:45:25 +01:00
|
|
|
dnf clean all
|
2019-11-15 10:49:02 +01:00
|
|
|
|
2019-11-21 09:44:11 +01:00
|
|
|
RUN git clone https://github.com/mono/mono --branch ${mono_version} --single-branch && \
|
2019-11-15 10:49:02 +01:00
|
|
|
cd mono && git submodule update --init && \
|
|
|
|
NOCONFIGURE=1 ./autogen.sh && \
|
2019-05-23 03:21:44 +02:00
|
|
|
./configure --prefix=/root/dependencies/mono-64 --host=x86_64-w64-mingw32 --disable-boehm --disable-mcs-build --disable-executables && \
|
2019-02-23 22:30:48 +01:00
|
|
|
echo '#define HAVE_STRUCT_SOCKADDR_IN6 1' >> config.h && \
|
2019-01-07 21:51:22 +01:00
|
|
|
make -j && \
|
|
|
|
make install && \
|
2019-11-15 10:49:02 +01:00
|
|
|
git clean -fdx && \
|
2019-01-07 21:51:22 +01:00
|
|
|
cp /root/dependencies/mono-64/bin/libMonoPosixHelper.dll /root/dependencies/mono-64/bin/MonoPosixHelper.dll && \
|
|
|
|
rm -f /root/dependencies/mono-64/bin/mono /root/dependencies/mono-64/bin/mono-sgen && \
|
|
|
|
ln -s /usr/bin/mono /root/dependencies/mono-64/bin/mono && \
|
|
|
|
ln -s /usr/bin/mono-sgen /root/dependencies/mono-64/bin/mono-sgen && \
|
|
|
|
ln -sf /usr/lib/mono/* /root/dependencies/mono-64/lib/mono || /bin/true && \
|
2019-11-15 10:49:02 +01:00
|
|
|
cp -rvp /etc/mono /root/dependencies/mono-64/etc && \
|
|
|
|
NOCONFIGURE=1 ./autogen.sh && \
|
2019-05-23 03:21:44 +02:00
|
|
|
./configure --prefix=/root/dependencies/mono-32 --host=i686-w64-mingw32 --disable-boehm --disable-mcs-build --disable-executables && \
|
2019-02-23 22:30:48 +01:00
|
|
|
echo '#define HAVE_STRUCT_SOCKADDR_IN6 1' >> config.h && \
|
2019-01-07 21:51:22 +01:00
|
|
|
make -j && \
|
|
|
|
make install && \
|
2019-08-31 13:05:27 +02:00
|
|
|
cd .. && \
|
2019-01-07 21:51:22 +01:00
|
|
|
cp /root/dependencies/mono-32/bin/libMonoPosixHelper.dll /root/dependencies/mono-32/bin/MonoPosixHelper.dll && \
|
|
|
|
rm -f /root/dependencies/mono-32/bin/mono /root/dependencies/mono-32/bin/mono-sgen && \
|
|
|
|
ln -s /usr/bin/mono /root/dependencies/mono-32/bin/mono && \
|
|
|
|
ln -s /usr/bin/mono-sgen /root/dependencies/mono-32/bin/mono-sgen && \
|
|
|
|
ln -sf /usr/lib/mono/* /root/dependencies/mono-32/lib/mono || /bin/true && \
|
2019-11-15 10:49:02 +01:00
|
|
|
cp -rvp /etc/mono /root/dependencies/mono-32/etc && \
|
|
|
|
rm -rf /root/mono
|
2019-01-07 21:51:22 +01:00
|
|
|
|
2019-01-17 23:06:38 +01:00
|
|
|
ENV MONO32_PREFIX=/root/dependencies/mono-32
|
|
|
|
ENV MONO64_PREFIX=/root/dependencies/mono-64
|
|
|
|
|
2019-11-15 11:22:07 +01:00
|
|
|
CMD /bin/bash
|