Merge branch 'newlangs' into docker
This commit is contained in:
commit
ce05a4f680
5 changed files with 92 additions and 0 deletions
6
languages/d/Dockerfile
Normal file
6
languages/d/Dockerfile
Normal file
|
@ -0,0 +1,6 @@
|
|||
FROM alpine
|
||||
LABEL author="SunRed"
|
||||
|
||||
RUN apk add --no-cache musl-dev gcc ldc
|
||||
|
||||
COPY run.sh /var/run/
|
2
languages/d/run.sh
Normal file
2
languages/d/run.sh
Normal file
|
@ -0,0 +1,2 @@
|
|||
cat > program.d
|
||||
ldc2 program.d -of program && ./program
|
17
languages/setlx/Dockerfile
Normal file
17
languages/setlx/Dockerfile
Normal file
|
@ -0,0 +1,17 @@
|
|||
FROM openjdk:17-alpine
|
||||
LABEL author="SunRed"
|
||||
|
||||
COPY setlX /usr/local/bin/
|
||||
COPY run.sh /var/run/
|
||||
|
||||
RUN apk add --no-cache curl unzip bash && \
|
||||
curl -O https://download.randoom.org/setlX/pc/setlX_v2-7-2.binary_only.zip && \
|
||||
unzip -d setlx setlX_v2-7-2.binary_only.zip && \
|
||||
rm -f setlX_v2-7-2.binary_only.zip && \
|
||||
mkdir -p /usr/local/setlX && \
|
||||
mv setlx/setlX*.jar /usr/local/setlX && \
|
||||
mkdir -p /usr/local/setlXlibrary && \
|
||||
mv setlx/setlXlibrary/* /usr/local/setlXlibrary && \
|
||||
chmod +x /usr/local/bin/setlX && \
|
||||
rm -rf setlx && \
|
||||
apk del --no-cache curl unzip
|
2
languages/setlx/run.sh
Normal file
2
languages/setlx/run.sh
Normal file
|
@ -0,0 +1,2 @@
|
|||
cat > program.stlx
|
||||
bash /usr/local/bin/setlX ./program.stlx
|
65
languages/setlx/setlX
Normal file
65
languages/setlx/setlX
Normal file
|
@ -0,0 +1,65 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
#
|
||||
# launcher script for the setlX interpreter on Unix-like systems
|
||||
#
|
||||
#
|
||||
|
||||
# insert path to the folder where you copied the jar files here
|
||||
setlXJarDirectory="/usr/local/setlX/"
|
||||
|
||||
# insert full path to library location here
|
||||
setlXlibraryPath="/usr/local/setlXlibrary/"
|
||||
|
||||
############################## additional options ##############################
|
||||
javaParameters=""
|
||||
|
||||
# uncomment to force execution in 64 bit mode
|
||||
#javaParameters="$javaParameters -d64"
|
||||
|
||||
# uncomment to execute with increased memory size (6GB) (>2GB needs 64 Bit mode!)
|
||||
#javaParameters="$javaParameters -Xmx6144m"
|
||||
|
||||
# uncomment to execute with increased stack size
|
||||
#javaParameters="$javaParameters -Xss48m"
|
||||
|
||||
################################################################################
|
||||
|
||||
if [ -n "$OVERRIDE_setlXJarDirectory" ]
|
||||
then
|
||||
setlXJarDirectory="$OVERRIDE_setlXJarDirectory"
|
||||
fi
|
||||
if [ -n "$OVERRIDE_setlXjavaParameters" ]
|
||||
then
|
||||
javaParameters="$OVERRIDE_setlXjavaParameters"
|
||||
fi
|
||||
if [ -z "$SETLX_LIBRARY_PATH" ]
|
||||
then
|
||||
export SETLX_LIBRARY_PATH="$setlXlibraryPath"
|
||||
fi
|
||||
|
||||
java_call="java"
|
||||
|
||||
if [[ -z "$INSIDE_EMACS" && $(which rlwrap > /dev/null 2>&1; echo $?) -eq 0 ]]
|
||||
then
|
||||
java_call="rlwrap -C $(basename $0) $java_call"
|
||||
fi
|
||||
|
||||
jarFiles=""
|
||||
while read -r -d $'\0' jarname
|
||||
do
|
||||
if [ -n "$jarFiles" ]
|
||||
then
|
||||
jarFiles="$jarFiles:"
|
||||
fi
|
||||
jarFiles="$jarFiles${jarname#./}"
|
||||
done < <( find "$setlXJarDirectory" -maxdepth 1 -name "*.jar" -print0 )
|
||||
|
||||
if [ -n "$jarFiles" ]
|
||||
then
|
||||
$java_call -cp "$jarFiles:$CLASSPATH" $javaParameters org.randoom.setlx.pc.ui.SetlX "$@"
|
||||
exit $?
|
||||
else
|
||||
echo "The setlX jar files cannot be found!"
|
||||
exit 1
|
||||
fi
|
Loading…
Reference in a new issue