initial commit

This commit is contained in:
2026-05-05 21:58:43 +03:00
commit 862b7abbac
79 changed files with 4132 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
.svn
Vendored
+71
View File
@@ -0,0 +1,71 @@
@Library('SHS.Platforms') _
node {
properties([
parameters(
[booleanParam(name: 'RPi_make_sysroot', defaultValue: false, description: 'Rebuild raspbian sysroot, or only execute Dockerfile'), booleanParam(name: 'no_docker_cache', defaultValue: false, description: 'Build dockers without use docker cache')]
)
])
def jobs = 4
if (env.JOBS_COUNT) {
jobs = "${env.JOBS_COUNT}"
}
def jobs_qt = 2
if (env.JOBS_QT_COUNT) {
jobs_qt = "${env.JOBS_QT_COUNT}"
}
def docker_cache_arg = ""
if (Boolean.valueOf(no_docker_cache)) {
docker_cache_arg = "--no-cache"
}
stage("Download SRC") {
checkout scm
}
def pl = new org.SHS.Platforms(this)
pl.get()
stage("Debian-base") {
docker.build("${env.DOCKER_PREFIX}/debian-base", "./debian-base ${docker_cache_arg}")
}
if (pl.root().platforms.OSX.enabled) {
stage("OSXcross") {
docker.build("${env.DOCKER_PREFIX}/osxcross", "./osxcross ${docker_cache_arg} --build-arg XCODE_XIP=172.17.0.1/Xcode_10.3.xip")
}
}
if (pl.root().platforms["Raspbian 10"].enabled) {
stage("Raspbian SYSROOT") {
if (Boolean.valueOf(RPi_make_sysroot)) {
echo 'Building Raspbian sysroot ...'
sh 'cd ./pi && bash ./umount_sysroot.sh && bash ./mount_sysroot.sh'
sh 'mkdir -p $HOME/rpi_image'
docker.image('${env.DOCKER_PREFIX}/debian-base').inside('-u root:root -v $HOME/rpi_image:/soft/rpi_image') {
sh 'cd ./pi && bash make_sysroot.sh'
}
sh 'cd ./pi && bash ./umount_sysroot.sh'
}
sh 'cp -vf $HOME/rpi_image/sysroot.tar.bz2 ./pi/'
}
}
pl.forEach ({ dist ->
def args = "./${dist.docker.directory} ${docker_cache_arg}"
for (arg in dist.docker.build_options) {
args += " --build-arg ${arg.key}=\"${arg.value}\""
}
args += " --build-arg JOBS_COUNT=${jobs}"
args += " --build-arg JOBS_QT_COUNT=${jobs_qt}"
def dprefix = "${env.DOCKER_PREFIX}"
if (dprefix != "" && !dprefix.endsWith("/")) dprefix += "/"
args += " --build-arg DOCKER_PREFIX=${dprefix}"
//print "${env.DOCKER_PREFIX}/${dist.docker.image_basename} -> ${args}"
docker.build("${env.DOCKER_PREFIX}/${dist.docker.image_basename}", args)
},
ondemand: true
)
stage("docker prune") {
sh 'docker system prune -f'
}
}
+5
View File
@@ -0,0 +1,5 @@
# Docker instrustions
There are instructions for build various docker images. They used as base for build https://git.shstk.ru/SHS/shstk docker images.
Also provide Jenkinsfile for automatic build
+125
View File
@@ -0,0 +1,125 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}debian-base
ARG JOBS_COUNT=4
ARG QT_DOWNLOAD_SERVER=shstk.ru/files
ENV CUR_SODIUM_VERSION=1.0.18
ENV CUR_FFTW_VERSION=3.3.8
ENV CUR_QT_VERSION_MAJOR=5.14
ENV CUR_QT_VERSION=5.14.1
# dev soft for our SDK
RUN mkdir -p /usr/share/man/man1 && apt-get update \
&& apt-get install -y cpio libglu1-mesa-dev libgl1-mesa-dev libwayland-dev libncurses-dev flex bison gperf \
python python-pip python-setuptools python-serial python-click python-cryptography python-future python-pyparsing python-pyelftools \
ccache libffi-dev libssl-dev doxygen graphviz libx11-dev libxkbcommon-dev libpkgconfig-perl libfreetype6-dev libfontconfig1-dev \
lzma-dev liblzma-dev libxml2-dev libbz2-dev libmpc-dev libmpfr-dev libgmp-dev libicu-dev libusb-1.0-0-dev libreadline-dev \
build-essential android-sdk openjdk-11-jdk && rm -rf /var/cache/apt/archives/*
# Android SDK and NDK
WORKDIR /soft/android
ENV ANDROID_HOME=/usr/lib/android-sdk
ENV ANDROID_NDK_HOME=${ANDROID_HOME}/ndk-bundle
ENV ANDROID_TOOLCHAIN=${ANDROID_NDK_HOME}/build/cmake/android.toolchain.cmake
ENV NDK_PLATFORM="android-21"
RUN wget -nv -O commandlinetools.zip https://dl.google.com/android/repository/commandlinetools-linux-6200805_latest.zip?hl=ru \
&& unzip -o commandlinetools.zip -d ${ANDROID_HOME} && rm -f commandlinetools.zip
RUN yes | ${ANDROID_HOME}/tools/bin/sdkmanager --sdk_root=${ANDROID_HOME} --licenses
RUN ${ANDROID_HOME}/tools/bin/sdkmanager --sdk_root=${ANDROID_HOME} --update
RUN ${ANDROID_HOME}/tools/bin/sdkmanager --sdk_root=${ANDROID_HOME} "platforms;android-21" "platforms;android-29" "platforms;android-30" "platforms;android-31" "platforms;android-32" "platforms;android-33" "platforms;android-34" "platforms;android-35" "ndk-bundle" "build-tools;28.0.3" "platform-tools" "tools"
COPY android.toolchain.cmake.add /soft/android/
RUN cat /soft/android/android.toolchain.cmake.add >> ${ANDROID_TOOLCHAIN}
RUN mkdir -p /soft/android/armeabi-v7a && mkdir -p /soft/android/arm64-v8a && mkdir -p /soft/android/x86 && mkdir -p /soft/android/x86_64
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz
WORKDIR /soft/libsodium-${CUR_SODIUM_VERSION}
RUN TARGET_ARCH=armv7-a \
CFLAGS="-O3 -mfloat-abi=softfp -mfpu=vfpv3-d16 -mthumb -marm -march=armv7-a" \
ARCH=arm \
HOST_COMPILER=arm-linux-androideabi \
dist-build/android-build.sh && \
cp -rfv /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-armv7-a/* /soft/android/armeabi-v7a/ && \
rm -rf /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-* && \
make distclean && rm -rf ./android-toolchain*
RUN TARGET_ARCH=armv8-a \
CFLAGS="-O3 -march=armv8-a" \
ARCH=arm64 \
HOST_COMPILER=aarch64-linux-android \
dist-build/android-build.sh && \
cp -rfv /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-armv8-a/* /soft/android/arm64-v8a/ && \
rm -rf /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-* && \
make distclean && rm -rf ./android-toolchain*
RUN TARGET_ARCH=i686 \
CFLAGS="-O3 -march=i686" \
ARCH=x86 \
HOST_COMPILER=i686-linux-android \
dist-build/android-build.sh && \
cp -rfv /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-i686/* /soft/android/x86/ && \
rm -rf /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-* && \
make distclean && rm -rf ./android-toolchain*
RUN TARGET_ARCH=westmere \
CFLAGS="-O3 -march=westmere" \
ARCH=x86_64 \
HOST_COMPILER=x86_64-linux-android \
dist-build/android-build.sh && \
cp -rfv /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-westmere/* /soft/android/x86_64/ && \
rm -rf /soft/libsodium-${CUR_SODIUM_VERSION}/libsodium-android-* && \
make distclean && rm -rf ./android-toolchain*
WORKDIR /soft
RUN rm -rf /soft/libsodium-*
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz
WORKDIR /soft/fftw-${CUR_FFTW_VERSION}_build
ENV _CUR_ABI=armeabi-v7a
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
ENV _CUR_ABI=arm64-v8a
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
ENV _CUR_ABI=x86
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
ENV _CUR_ABI=x86_64
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
RUN cmake -DCMAKE_INSTALL_PREFIX=/soft/android/${_CUR_ABI} -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=${ANDROID_TOOLCHAIN} -DANDROID_PLATFORM=${NDK_PLATFORM} -DANDROID_ABI=${_CUR_ABI} /soft/fftw-${CUR_FFTW_VERSION} && make install -j${JOBS_COUNT} && rm -rf ./*
# Qt
WORKDIR /soft/android
RUN wget -nv http://${QT_DOWNLOAD_SERVER}/qt-android-${CUR_QT_VERSION}.zip \
&& unzip -o qt-android-${CUR_QT_VERSION}.zip -d /soft/android/qt \
&& rm -f qt-android-${CUR_QT_VERSION}.zip
WORKDIR /soft/android/qt/lib/cmake/Qt5
COPY Qt5Config.patch /soft/android/qt/lib/cmake/Qt5
RUN patch < Qt5Config.patch
ENV BUILD_TYPE=Release
WORKDIR /soft
+18
View File
@@ -0,0 +1,18 @@
--- Qt5Config.cmake 2020-03-09 19:23:16.000000000 +0300
+++ ./1/Qt5Config.cmake 2020-04-05 15:27:08.135011149 +0300
@@ -25,11 +25,14 @@
include(${CMAKE_CURRENT_LIST_DIR}/Qt5ModuleLocation.cmake)
foreach(module ${Qt5_FIND_COMPONENTS})
- find_package(Qt5${module}
+ set(_ppref_ "${CMAKE_FIND_ROOT_PATH}")
+ set(CMAKE_FIND_ROOT_PATH "/")
+ find_package(Qt5${module}
${_Qt5_FIND_PARTS_QUIET}
${_Qt5_FIND_PARTS_REQUIRED}
PATHS ${_qt5_module_paths} NO_DEFAULT_PATH
)
+ set(CMAKE_FIND_ROOT_PATH "${_ppref_}")
if (NOT Qt5${module}_FOUND)
string(CONFIGURE ${_qt5_module_location_template} _expected_module_location @ONLY)
+6
View File
@@ -0,0 +1,6 @@
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
set(CMAKE_PREFIX_PATH /soft/android/${ANDROID_ABI})
list(APPEND CMAKE_FIND_ROOT_PATH ${CMAKE_PREFIX_PATH}/lib)
include_directories(${CMAKE_PREFIX_PATH}/include)
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+55
View File
@@ -0,0 +1,55 @@
ARG image_from
FROM ${image_from}
ARG image_prepare_script
ARG JOBS_COUNT=4
ENV QT_SELECT=5
ENV LANG=en_US.utf8
ENV CUR_FFTW_VERSION=3.3.10
ENV CUR_MICROHTTPD_VERSION=1.0.2
RUN apt-get update && apt-get install -y ca-certificates gpg
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
COPY os-release /usr/lib/os-release
COPY astra.list /etc/apt/sources.list.d/astra.list
COPY key.gpg /soft/key.gpg
RUN echo 'root:12345' | chpasswd
# prepare current distributive
RUN cat /soft/key.gpg | apt-key add -
RUN apt-get update
COPY *.sh /soft/
RUN if [ -n "${image_prepare_script}" ]; then \
bash /soft/${image_prepare_script} ${QT_FROM_SOURCE}; \
fi
ENV BUILD_TYPE=Release
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/build/fftw3 && cd /soft/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
# microhttpd
WORKDIR /soft/
RUN wget -nv https://mirror.tochlab.net/pub/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/build/microhttpd && cd /soft/build/microhttpd \
&& sh -c 'CFLAGS="-O3 -fPIC" LDFLAGS="-O3 -fPIC" /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --prefix=/usr/local/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/build/microhttpd && rm -rf /soft/libmicrohttpd-*
WORKDIR /soft
+5
View File
@@ -0,0 +1,5 @@
deb https://download.astralinux.ru/astra/stable/1.7_x86-64/repository-main/ 1.7_x86-64 main contrib non-free
deb https://download.astralinux.ru/astra/stable/1.7_x86-64/repository-update/ 1.7_x86-64 main contrib non-free
deb https://download.astralinux.ru/astra/stable/1.7_x86-64/repository-base/ 1.7_x86-64 main contrib non-free
deb https://download.astralinux.ru/astra/stable/1.7_x86-64/repository-extended/ 1.7_x86-64 main contrib non-free
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+113
View File
@@ -0,0 +1,113 @@
#!/bin/bash
apt-get update
# locales
apt-get install -y locales
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
TZ=Europe/Moscow
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
echo $TZ > /etc/timezone
# base soft
apt-get install -y \
"^libxcb.*" \
bison \
ccache \
cpio \
curl \
debconf \
debhelper \
default-libmysqlclient-dev \
doxygen \
dpkg \
flex \
g++ \
git \
gperf \
graphviz \
htop \
iputils-ping \
libbz2-dev \
libffi-dev \
libfontconfig1-dev \
libfreetype6-dev \
libgl1-mesa-dev \
libglew-dev \
libglu1-mesa-dev \
libgmp-dev \
libicu-dev \
liblzma-dev \
libmpc-dev \
libmpfr-dev \
libncurses-dev \
libpkgconfig-perl \
libpq-dev \
libreadline-dev \
libssl-dev \
libusb-1.0-0-dev \
libwayland-dev \
libx11-dev \
libx11-xcb-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
libxml2-dev \
libxrender-dev \
lsb-release \
lzma-dev \
mc \
md5deep \
nano \
net-tools \
ninja-build \
ocl-icd-opencl-dev \
p7zip-full \
patchelf \
python3 \
python3-click \
python3-cryptography \
python3-future \
python3-pip \
python3-pyelftools \
python3-pyparsing \
python3-serial \
python3-setuptools \
screen \
subversion \
unzip \
wget \
zip \
zlib1g-dev \
qtbase5-dev-tools \
qtconnectivity5-dev \
qtbase5-dev \
qttools5-dev \
qtscript5-dev \
qtdeclarative5-dev \
qtpositioning5-dev \
qtmultimedia5-dev \
libqt5datavisualization5-dev \
libqt5networkauth5-dev \
libqt5opengl5-dev \
qtscript5-dev \
libqt5serialport5-dev \
libqt5serialbus5-dev \
libqt5sensors5-dev \
libqt5svg5-dev \
libqt5websockets5-dev \
libqt5x11extras5-dev \
libqt5xmlpatterns5-dev \
libqt5charts5-dev \
qtbase5-private-dev \
qttools5-private-dev \
cmake \
libsodium-dev \
libassimp-dev \
discount \
libhdf5-dev \
libcurl4-openssl-dev \
libpcsclite-dev
# cleanup
rm -rf /var/cache/apt/archives/*
+76
View File
@@ -0,0 +1,76 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
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
=qIiz
-----END PGP PUBLIC KEY BLOCK-----
+8
View File
@@ -0,0 +1,8 @@
PRETTY_NAME="Astra Linux"
NAME="Astra Linux"
ID=astra
ID_LIKE=debian
HOME_URL="https://astralinux.ru"
SUPPORT_URL="https://astralinux.ru/support"
VERSION_ID=1.7
VERSION_CODENAME=1.7_x86-64
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+55
View File
@@ -0,0 +1,55 @@
ARG image_from
FROM ${image_from}
ARG image_prepare_script
ARG JOBS_COUNT=4
ENV QT_SELECT=5
ENV LANG=en_US.utf8
ENV CUR_FFTW_VERSION=3.3.10
ENV CUR_MICROHTTPD_VERSION=1.0.2
RUN apt-get update && apt-get install -y ca-certificates gpg
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
COPY os-release /usr/lib/os-release
COPY astra.list /etc/apt/sources.list.d/astra.list
COPY key.gpg /soft/key.gpg
RUN echo 'root:12345' | chpasswd
# prepare current distributive
RUN cat /soft/key.gpg | apt-key add -
RUN apt-get update
COPY *.sh /soft/
RUN if [ -n "${image_prepare_script}" ]; then \
bash /soft/${image_prepare_script} ${QT_FROM_SOURCE}; \
fi
ENV BUILD_TYPE=Release
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/build/fftw3 && cd /soft/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DBUILD_SHARED_LIBS=0 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
# microhttpd
WORKDIR /soft/
RUN wget -nv https://mirror.tochlab.net/pub/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/build/microhttpd && cd /soft/build/microhttpd \
&& sh -c 'CFLAGS="-O3 -fPIC" LDFLAGS="-O3 -fPIC" /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --prefix=/usr/local/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/build/microhttpd && rm -rf /soft/libmicrohttpd-*
WORKDIR /soft
+2
View File
@@ -0,0 +1,2 @@
deb https://download.astralinux.ru/astra/stable/1.8_x86-64/repository-main/ 1.8_x86-64 main contrib non-free non-free-firmware
deb https://download.astralinux.ru/astra/stable/1.8_x86-64/repository-extended/ 1.8_x86-64 main contrib non-free non-free-firmware
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+113
View File
@@ -0,0 +1,113 @@
#!/bin/bash
apt-get update
# locales
apt-get install -y locales
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
TZ=Europe/Moscow
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
echo $TZ > /etc/timezone
# base soft
apt-get install -y \
"^libxcb.*" \
bison \
ccache \
cpio \
curl \
debconf \
debhelper \
default-libmysqlclient-dev \
doxygen \
dpkg \
flex \
g++ \
git \
gperf \
graphviz \
htop \
iputils-ping \
libbz2-dev \
libffi-dev \
libfontconfig1-dev \
libfreetype6-dev \
libgl1-mesa-dev \
libglew-dev \
libglu1-mesa-dev \
libgmp-dev \
libicu-dev \
liblzma-dev \
libmpc-dev \
libmpfr-dev \
libncurses-dev \
libpkgconfig-perl \
libpq-dev \
libreadline-dev \
libssl-dev \
libusb-1.0-0-dev \
libwayland-dev \
libx11-dev \
libx11-xcb-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
libxml2-dev \
libxrender-dev \
lsb-release \
lzma-dev \
mc \
md5deep \
nano \
net-tools \
ninja-build \
ocl-icd-opencl-dev \
p7zip-full \
patchelf \
python3 \
python3-click \
python3-cryptography \
python3-future \
python3-pip \
python3-pyelftools \
python3-pyparsing \
python3-serial \
python3-setuptools \
screen \
subversion \
unzip \
wget \
zip \
zlib1g-dev \
qtbase5-dev-tools \
qtconnectivity5-dev \
qtbase5-dev \
qttools5-dev \
qtscript5-dev \
qtdeclarative5-dev \
qtpositioning5-dev \
qtmultimedia5-dev \
libqt5datavisualization5-dev \
libqt5networkauth5-dev \
libqt5opengl5-dev \
qtscript5-dev \
libqt5serialport5-dev \
libqt5serialbus5-dev \
libqt5sensors5-dev \
libqt5svg5-dev \
libqt5websockets5-dev \
libqt5x11extras5-dev \
libqt5xmlpatterns5-dev \
libqt5charts5-dev \
qtbase5-private-dev \
qttools5-private-dev \
cmake \
libsodium-dev \
libassimp-dev \
discount \
libhdf5-dev \
libcurl4-openssl-dev \
libpcsclite-dev
# cleanup
rm -rf /var/cache/apt/archives/*
+76
View File
@@ -0,0 +1,76 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
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
=LtGE
-----END PGP PUBLIC KEY BLOCK-----
+8
View File
@@ -0,0 +1,8 @@
PRETTY_NAME="Astra Linux"
NAME="Astra Linux"
ID=astra
ID_LIKE=debian
HOME_URL="https://astralinux.ru"
SUPPORT_URL="https://astralinux.ru/support"
VERSION_ID=1.8
VERSION_CODENAME=1.8_x86-64
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+24
View File
@@ -0,0 +1,24 @@
FROM debian:trixie-slim
# locales
RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8 \
&& rm -rf /var/cache/apt/archives/*
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
# base soft
RUN apt-get update && apt-get install -y subversion git zip unzip wget curl htop net-tools iputils-ping mc nano screen g++ patchelf p7zip-full ninja-build \
&& rm -rf /var/cache/apt/archives/*
# last cmake from sources, into /opt
ENV CUR_CMAKE_VERSION=3.20.0
WORKDIR /soft
RUN wget -nv https://github.com/Kitware/CMake/releases/download/v${CUR_CMAKE_VERSION}/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh \
&& mkdir -p /opt/cmake \
&& bash ./cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/opt/cmake \
&& rm -rf /soft/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh
ENV PATH=/opt/cmake/bin:$PATH
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+7
View File
@@ -0,0 +1,7 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}debian-base
RUN apt-get update && apt-get install -y dpkg debconf debhelper md5deep lsb-release libicu-dev libfftw3-dev libsodium-dev libassimp-dev libmarkdown2-dev ocl-icd-opencl-dev zlib1g-dev qtbase5-dev-tools qttools5-dev qtscript5-dev qtdeclarative5-dev qtpositioning5-dev qtmultimedia5-dev libqt5datavisualization5-dev qtbase5-private-dev qttools5-private-dev qt5-default libglew-dev doxygen graphviz liblua5.3-dev libmicrohttpd-dev libcurl4-openssl-dev && rm -rf /var/cache/apt/archives/*
ENV BUILD_TYPE=Release
WORKDIR /soft
+20
View File
@@ -0,0 +1,20 @@
FROM wapmobil/debian-base
WORKDIR /esp
RUN git clone --depth=1 -b release/v4.2 --recursive https://github.com/espressif/esp-idf.git
WORKDIR /esp/esp-idf
ENV IDF_TOOLS_PATH="/esp/espressif"
ENV IDF_PATH="/esp/esp-idf"
#RUN pip install --upgrade virtualenv==16.7.9 && ./install.sh
RUN apt-get update && apt-get install -y python3 python3-pip
RUN ./install.sh
RUN rm -rf /esp/espressif/dist
COPY miniz.patch /esp/esp-idf/
RUN patch -p 1 < miniz.patch
WORKDIR /esp
ENV PATH=/esp/esp-idf/components/esptool_py/esptool:/esp/esp-idf/components/espcoredump:/esp/esp-idf/components/partition_table:/esp/esp-idf/components/app_update:/esp/espressif/tools/xtensa-esp32-elf/esp-2020r3-8.4.0/xtensa-esp32-elf/bin:/esp/espressif/tools/xtensa-esp32s2-elf/esp-2020r3-8.4.0/xtensa-esp32s2-elf/bin:/esp/espressif/tools/openocd-esp32/v0.10.0-esp32-20200709/openocd-esp32/bin:/esp/espressif/python_env/idf4.2_py2.7_env/bin:/esp/esp-idf/tools:/opt/cmake/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
ENV IDF_PYTHON_ENV_PATH=/esp/espressif/python_env/idf4.2_py2.7_env
ENV OPENOCD_SCRIPTS=/esp/espressif/tools/openocd-esp32/v0.10.0-esp32-20200709/openocd-esp32/share/openocd/scripts
ENV IDF_TOOLS_EXPORT_CMD=/esp/esp-idf/export.sh
ENV IDF_TOOLS_INSTALL_CMD=/esp/esp-idf/install.sh
+13
View File
@@ -0,0 +1,13 @@
diff --git a/components/esp_rom/include/esp32/rom/miniz.h b/components/esp_rom/include/esp32/rom/miniz.h
index 773a0d0..96bc80f 100644
--- a/components/esp_rom/include/esp32/rom/miniz.h
+++ b/components/esp_rom/include/esp32/rom/miniz.h
@@ -21,7 +21,7 @@
#define MINIZ_NO_ARCHIVE_WRITING_APIS
// Define MINIZ_NO_ZLIB_APIS to remove all ZLIB-style compression/decompression API's.
-#define MINIZ_NO_ZLIB_APIS
+//#define MINIZ_NO_ZLIB_APIS
// Define MINIZ_NO_ZLIB_COMPATIBLE_NAME to disable zlib names, to prevent conflicts against stock zlib.
#define MINIZ_NO_ZLIB_COMPATIBLE_NAMES
BIN
View File
Binary file not shown.
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+63
View File
@@ -0,0 +1,63 @@
ARG image_from
FROM --platform=linux/amd64 ${image_from}
ARG JOBS_COUNT=4
ARG image_prepare_script
ARG arch
ARG toolchain
ARG triplet
# versions and environment
ENV CUR_CMAKE_VERSION=3.20.0
ENV CUR_GOOGLETEST=v1.13.x
ENV QT_SELECT=5
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
RUN echo 'root:12345' | chpasswd
# prepare current distributive
COPY *.sh /soft/
RUN if [ -n "${image_prepare_script}" ]; then \
bash /soft/${image_prepare_script} ${arch} ${toolchain}; \
fi
RUN rm /soft/*.sh -v
# toolchain
WORKDIR /soft
COPY toolchain.cmake.in /soft/
RUN sed -e s/\${PH_ARCH}/$arch/ -e s/\${PH_TRIPLET}/$triplet/ toolchain.cmake.in > toolchain.cmake
RUN rm toolchain.cmake.in
RUN mkdir -p /usr/${triplet}/lib
RUN mkdir -p /soft/target/lib
RUN ln -s /usr/lib/os-release /usr/${triplet}/lib/os-release
RUN ln -s /usr/lib/os-release /soft/target/lib/os-release
# last cmake from sources, into /opt
WORKDIR /soft
RUN wget -nv https://github.com/Kitware/CMake/releases/download/v${CUR_CMAKE_VERSION}/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh \
&& mkdir -p /opt/cmake \
&& bash ./cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/opt/cmake \
&& rm -rf /soft/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh
ENV PATH=/opt/cmake/bin:$PATH
# Remove invalid FindGtest.cmake
RUN cd "$(find /opt/cmake/share -name FindGTest.cmake -type f -printf '%h' -quit)" && rm FindGTest.cmake
# GTest
WORKDIR /soft
RUN git clone -b ${CUR_GOOGLETEST} https://github.com/google/googletest.git \
&& mkdir googletest/build && cd googletest/build \
&& cmake .. \
&& make -j${JOBS_COUNT} && make install && cd /soft && rm -rf googletest
ENV BUILD_TYPE=Release
WORKDIR /soft
+38
View File
@@ -0,0 +1,38 @@
--- CMakeLists.txt 2019-04-15 18:28:20.000000000 +0300
+++ CMakeLists_new.txt 2020-03-16 10:46:52.288128600 +0300
@@ -20,6 +20,9 @@
set(${PROJECT_NAME}_ONLY_LIBRARY OFF CACHE BOOL
"Set to ON to only build markdown library (default is OFF)")
+set(${PROJECT_NAME}_CXX_BINDING OFF CACHE BOOL
+ "Set to ON to install header files with c++ wrappers (default is OFF)")
+
# Check headers
include(CheckIncludeFile)
check_include_file(libgen.h HAVE_LIBGEN_H)
@@ -110,6 +113,13 @@
configure_file("${_ROOT}/mkdio.h.in"
"${_ROOT}/mkdio.h"
@ONLY)
+if(${PROJECT_NAME}_CXX_BINDING)
+ message(STATUS "Applying c++ glue to mkdio.h")
+ file(READ "${_ROOT}/mkdio.h" _ROOT_MKDIO_H)
+ file(WRITE "${_ROOT}/mkdio.h" "#ifdef __cplusplus\nextern \"C\" {\n#endif\n")
+ file(APPEND "${_ROOT}/mkdio.h" "${_ROOT_MKDIO_H}")
+ file(APPEND "${_ROOT}/mkdio.h" "#ifdef __cplusplus\n}\n#endif\n")
+endif()
include_directories("${_ROOT}")
@@ -182,7 +192,10 @@
target_include_directories(libmarkdown INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
- set(_TARGETS libmarkdown markdown)
+ set(_TARGETS libmarkdown)
+ if(NOT ${PROJECT_NAME}_ONLY_LIBRARY)
+ list(APPEND _TARGETS markdown)
+ endif()
if(${PROJECT_NAME}_INSTALL_SAMPLES)
list(APPEND _TARGETS mkd2html makepage)
endif()
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+157
View File
@@ -0,0 +1,157 @@
#!/bin/bash
arch=$1
toolchain=$2
export DEBIAN_FRONTEND=noninteractive
find "/etc/apt/sources.list.d/" -type f -exec sed -i "s|http://[a-zA-Z0-9_.]\+/|http://mirror.yandex.ru/|g" {} \;
dpkg --add-architecture $arch
apt-get update
# locales
apt-get install -y locales apt-utils
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
TZ=Europe/Moscow
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
echo $TZ > /etc/timezone
# base soft
apt-get install -y \
"^libxcb.*" \
bison \
ccache \
cpio \
curl \
debconf \
debhelper \
default-libmysqlclient-dev \
doxygen \
dpkg \
flex \
g++ \
git \
gperf \
graphviz \
htop \
iputils-ping \
libbz2-dev \
libffi-dev \
libfontconfig1-dev \
libfreetype6-dev \
libgl1-mesa-dev \
libglew-dev \
libglu1-mesa-dev \
libgmp-dev \
libicu-dev \
liblzma-dev \
libmpc-dev \
libmpfr-dev \
libncurses-dev \
libpkgconfig-perl \
libpq-dev \
libreadline-dev \
libssl-dev \
libusb-1.0-0-dev \
libwayland-dev \
libx11-dev \
libx11-xcb-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
libxml2-dev \
libxrender-dev \
lsb-release \
mc \
md5deep \
nano \
net-tools \
ninja-build \
ocl-icd-opencl-dev \
p7zip-full \
patchelf \
python3 \
screen \
subversion \
unzip \
wget \
zip \
zlib1g-dev \
apt-get install -y \
qtmultimedia5-dev:$arch \
qtbase5-private-dev:$arch \
qttools5-private-dev:$arch \
qtbase5-dev-tools \
apt-get install -y \
$toolchain \
libbz2-dev:$arch \
libffi-dev:$arch \
libfontconfig1-dev:$arch \
libfreetype6-dev:$arch \
libfftw3-dev:$arch \
libgl1-mesa-dev:$arch \
libglew-dev:$arch \
libglu1-mesa-dev:$arch \
libgmp-dev:$arch \
libicu-dev:$arch \
liblzma-dev:$arch \
libmpc-dev:$arch \
libmpfr-dev:$arch \
libncurses-dev:$arch \
libpq-dev:$arch \
libreadline-dev:$arch \
libssl-dev:$arch \
libusb-1.0-0-dev:$arch \
libwayland-dev:$arch \
libx11-dev:$arch \
libx11-xcb-dev:$arch \
libxkbcommon-dev:$arch \
libxkbcommon-x11-dev:$arch \
libxml2-dev:$arch \
libxrender-dev:$arch \
ocl-icd-opencl-dev:$arch \
libsodium-dev:$arch \
libassimp-dev:$arch \
libmicrohttpd-dev:$arch \
libhdf5-dev:$arch \
libcurl4-openssl-dev:$arch \
libpcsclite-dev:$arch \
qtconnectivity5-dev:$arch \
qtbase5-dev:$arch \
qttools5-dev:$arch \
qtscript5-dev:$arch \
qtdeclarative5-dev:$arch \
qtpositioning5-dev:$arch \
libqt5datavisualization5-dev:$arch \
libqt5networkauth5-dev:$arch \
libqt5opengl5-dev:$arch \
qtscript5-dev:$arch \
libqt5serialport5-dev:$arch \
libqt5serialbus5-dev:$arch \
libqt5sensors5-dev:$arch \
libqt5svg5-dev:$arch \
libqt5websockets5-dev:$arch \
libqt5x11extras5-dev:$arch \
libqt5xmlpatterns5-dev:$arch \
libqt5charts5-dev:$arch \
apt-get install -y lzma-dev || true
apt-get install -y python3-future || true
apt-get install -y python3-click || true
apt-get install -y python3-cryptography || true
apt-get install -y python3-pip || true
apt-get install -y python3-pyelftools || true
apt-get install -y python3-pyparsing || true
apt-get install -y python3-serial || true
apt-get install -y python3-setuptools || true
apt-get install -y libopencv-dev:$arch
# cleanup
rm -rf /var/cache/apt/archives/*
@@ -0,0 +1,8 @@
#!/bin/bash
arch=$1
toolchain=$2
cp -vf /soft/ubuntu.sources.24.04.arm64.sh /etc/apt/sources.list.d/ubuntu.sources
bash /soft/install_apt.sh $arch $toolchain
+22
View File
@@ -0,0 +1,22 @@
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR "${PH_ARCH}")
set(TRIPLET "${PH_TRIPLET}")
set(TOOL_PREFIX "/usr/bin/${TRIPLET}")
set(CMAKE_LIBRARY_ARCHITECTURE "${TRIPLET}")
set(CMAKE_C_COMPILER "${TOOL_PREFIX}-gcc")
set(CMAKE_CXX_COMPILER "${TOOL_PREFIX}-g++")
set(CMAKE_RANLIB "${TOOL_PREFIX}-ranlib" CACHE FILEPATH "ranlib")
set(CMAKE_AR "${TOOL_PREFIX}-ar" CACHE FILEPATH "ar")
set(CMAKE_READELF "${TOOL_PREFIX}-readelf" CACHE FILEPATH "readelf")
list(APPEND CMAKE_PREFIX_PATH "/soft/target")
set(CMAKE_FIND_ROOT_PATH "/usr/${TRIPLET}")
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE FIRST)
set(PIP_BINDIR "/usr/local/bin")
set(PIP_DEPLOY_LIBDIR "/usr/lib/${TRIPLET}")
#include_directories("${CMAKE_PREFIX_PATH}/include" "${CMAKE_PREFIX_PATH}/include/${TRIPLET}")
cmake_policy(SET CMP0025 NEW)
+33
View File
@@ -0,0 +1,33 @@
## See the sources.list(5) manual page for further settings.
Types: deb
URIs: http://mirror.yandex.ru/ubuntu/
Suites: noble noble-updates noble-backports
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Architectures: amd64
## Ubuntu security updates. Aside from URIs and Suites,
## this should mirror your choices in the previous section.
Types: deb
URIs: http://mirror.yandex.ru/ubuntu/
Suites: noble-security
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Architectures: amd64
## See the sources.list(5) manual page for further settings.
Types: deb
URIs: http://mirror.yandex.ru/ubuntu-ports/
Suites: noble noble-updates noble-backports
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Architectures: arm64
## Ubuntu security updates. Aside from URIs and Suites,
## this should mirror your choices in the previous section.
Types: deb
URIs: http://mirror.yandex.ru/ubuntu-ports/
Suites: noble-security
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Architectures: arm64
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+140
View File
@@ -0,0 +1,140 @@
ARG image_from
FROM ${image_from}
ARG image_prepare_script
ARG JOBS_COUNT=4
ARG JOBS_QT_COUNT=2
ARG QT_FROM_SOURCE=1
ARG VERSION_ID=
# versions and environment
ENV CUR_CMAKE_VERSION=3.20.0
ENV CUR_SODIUM_VERSION=1.0.21
ENV CUR_FFTW_VERSION=3.3.10
ENV CUR_ASSIMP_VERSION=4.1.0
ENV CUR_DISCOUNT_VERSION=2.2.6
ENV CUR_MICROHTTPD_VERSION=1.0.2
ENV CUR_QT_VERSION_MAJOR=5.15
ENV CUR_QT_VERSION=5.15.9
ENV CUR_GOOGLETEST=v1.13.x
ENV QT_SELECT=5
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
RUN echo 'root:12345' | chpasswd
# prepare current distributive
COPY *.sh /soft/
RUN if [ -n "${VERSION_ID}" ]; then \
echo "VERSION_ID=\"${VERSION_ID}\"" >> /usr/lib/os-release; \
fi
RUN if [ -n "${image_prepare_script}" ]; then \
bash /soft/${image_prepare_script} ${QT_FROM_SOURCE}; \
fi
RUN rm /soft/*.sh -v
# last cmake from sources, into /opt
WORKDIR /soft
RUN wget -nv https://github.com/Kitware/CMake/releases/download/v${CUR_CMAKE_VERSION}/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh \
&& mkdir -p /opt/cmake \
&& bash ./cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/opt/cmake \
&& rm -rf /soft/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh
ENV PATH=/opt/cmake/bin:$PATH
# Remove invalid FindGtest.cmake
RUN cd "$(find /opt/cmake/share -name FindGTest.cmake -type f -printf '%h' -quit)" && rm FindGTest.cmake
# GTest
WORKDIR /soft
RUN git clone -b ${CUR_GOOGLETEST} https://github.com/google/googletest.git \
&& mkdir googletest/build && cd googletest/build \
&& cmake .. \
&& make -j${JOBS_COUNT} && make install && cd /soft && rm -rf googletest
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/build/sodium && cd /soft/build/sodium \
&& sh -c 'CFLAGS="-O3 -fPIC" LDFLAGS="-O3 -fPIC" /soft/libsodium-*/configure --prefix=/usr/local/ && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/build/sodium && rm -rf /soft/libsodium-*
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/build/fftw3 && cd /soft/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/build/assimp && cd /soft/build/assimp \
&& cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
# markdown
WORKDIR /soft
RUN wget -nv https://github.com/Orc/discount/archive/v${CUR_DISCOUNT_VERSION}.tar.gz \
&& tar -xf v${CUR_DISCOUNT_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_DISCOUNT_VERSION}.tar.gz
RUN sed -i 's/DESTRUCTOR/ /' /soft/discount-${CUR_DISCOUNT_VERSION}/setup.c
WORKDIR /soft/discount-${CUR_DISCOUNT_VERSION}/cmake
COPY discount.cmake.patch /soft/discount-${CUR_DISCOUNT_VERSION}/cmake/cmake.patch
RUN patch < cmake.patch
WORKDIR /soft/linux/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-${CUR_DISCOUNT_VERSION}/cmake && make -j2 && mv mktags .. && rm -rf ./* \
&& mkdir -p /soft/build/discount && mv /soft/linux/build/mktags /soft/build/discount/mktags
WORKDIR /soft/build/discount
RUN cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/discount-*
# microhttpd
WORKDIR /soft/
RUN wget -nv https://mirror.tochlab.net/pub/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/build/microhttpd && cd /soft/build/microhttpd \
&& sh -c 'CFLAGS="-O3 -fPIC" LDFLAGS="-O3 -fPIC" /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --prefix=/usr/local/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/build/microhttpd && rm -rf /soft/libmicrohttpd-*
# Qt
WORKDIR /soft
RUN if [ "${QT_FROM_SOURCE}" = "1" ]; then \
wget -nv http://qt-mirror.dannhauer.de/archive/qt/${CUR_QT_VERSION_MAJOR}/${CUR_QT_VERSION}/single/qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& tar xf qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz -C /soft \
&& rm -f qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& mkdir -p /soft/build/qt && cd /soft/build/qt \
&& /soft/qt-everywhere-src-${CUR_QT_VERSION}/configure -opensource -confirm-license -release -shared -no-pch -extprefix "/usr/local" \
-opengl desktop -qt-libpng -system-zlib -qt-pcre -make tools -nomake tests -nomake examples -no-compile-examples -skip qtwebengine \
-skip qtwebglplugin -skip doc -skip qt3d -skip qtactiveqt -skip qtquick3d -openssl-linked -xcb \
&& make -j${JOBS_QT_COUNT} && make install && rm -rf ./* && rm -rf /soft/qt-everywhere-src-*; \
fi
ENV BUILD_TYPE=Release
WORKDIR /soft
+38
View File
@@ -0,0 +1,38 @@
--- CMakeLists.txt 2019-04-15 18:28:20.000000000 +0300
+++ CMakeLists_new.txt 2020-03-16 10:46:52.288128600 +0300
@@ -20,6 +20,9 @@
set(${PROJECT_NAME}_ONLY_LIBRARY OFF CACHE BOOL
"Set to ON to only build markdown library (default is OFF)")
+set(${PROJECT_NAME}_CXX_BINDING OFF CACHE BOOL
+ "Set to ON to install header files with c++ wrappers (default is OFF)")
+
# Check headers
include(CheckIncludeFile)
check_include_file(libgen.h HAVE_LIBGEN_H)
@@ -110,6 +113,13 @@
configure_file("${_ROOT}/mkdio.h.in"
"${_ROOT}/mkdio.h"
@ONLY)
+if(${PROJECT_NAME}_CXX_BINDING)
+ message(STATUS "Applying c++ glue to mkdio.h")
+ file(READ "${_ROOT}/mkdio.h" _ROOT_MKDIO_H)
+ file(WRITE "${_ROOT}/mkdio.h" "#ifdef __cplusplus\nextern \"C\" {\n#endif\n")
+ file(APPEND "${_ROOT}/mkdio.h" "${_ROOT_MKDIO_H}")
+ file(APPEND "${_ROOT}/mkdio.h" "#ifdef __cplusplus\n}\n#endif\n")
+endif()
include_directories("${_ROOT}")
@@ -182,7 +192,10 @@
target_include_directories(libmarkdown INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
- set(_TARGETS libmarkdown markdown)
+ set(_TARGETS libmarkdown)
+ if(NOT ${PROJECT_NAME}_ONLY_LIBRARY)
+ list(APPEND _TARGETS markdown)
+ endif()
if(${PROJECT_NAME}_INSTALL_SAMPLES)
list(APPEND _TARGETS mkd2html makepage)
endif()
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+120
View File
@@ -0,0 +1,120 @@
#!/bin/bash
export DEBIAN_FRONTEND=noninteractive
find "/etc/apt/sources.list.d/" -type f -exec sed -i "s|http://[a-zA-Z0-9_.]\+/|http://mirror.yandex.ru/|g" {} \;
apt-get update
# locales
apt-get install -y locales
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
TZ=Europe/Moscow
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
echo $TZ > /etc/timezone
# base soft
apt-get install -y \
"^libxcb.*" \
bison \
ccache \
cpio \
curl \
debconf \
debhelper \
default-libmysqlclient-dev \
doxygen \
dpkg \
flex \
g++ \
git \
gperf \
graphviz \
htop \
iputils-ping \
libbz2-dev \
libffi-dev \
libfontconfig1-dev \
libfreetype6-dev \
libgl1-mesa-dev \
libglew-dev \
libglu1-mesa-dev \
libgmp-dev \
libicu-dev \
libmpc-dev \
libmpfr-dev \
libncurses-dev \
libpkgconfig-perl \
libpq-dev \
libreadline-dev \
libssl-dev \
libusb-1.0-0-dev \
libwayland-dev \
libx11-dev \
libx11-xcb-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
libxml2-dev \
libxrender-dev \
lsb-release \
mc \
md5deep \
nano \
net-tools \
ninja-build \
ocl-icd-opencl-dev \
p7zip-full \
patchelf \
python3 \
screen \
subversion \
unzip \
wget \
zip \
zlib1g-dev \
libhdf5-dev \
libcurl4-openssl-dev \
libpcsclite-dev
# install qt if not build it from source
if [[ -n "$1" && "$1" != "1" ]]; then
apt-get install -y \
qtbase5-dev-tools \
qtbase5-dev \
qttools5-dev \
qtscript5-dev \
qtdeclarative5-dev \
qtpositioning5-dev \
qtmultimedia5-dev \
libqt5datavisualization5-dev \
libqt5networkauth5-dev \
libqt5opengl5-dev \
qtscript5-dev \
libqt5serialport5-dev \
libqt5sensors5-dev \
libqt5svg5-dev \
libqt5websockets5-dev \
libqt5x11extras5-dev \
libqt5xmlpatterns5-dev \
libqt5charts5-dev \
qtbase5-private-dev \
qttools5-private-dev
fi
apt-get install -y qtconnectivity5-dev || true
apt-get install -y libqt5serialbus5-dev || true
apt-get install -y lzma-dev || true
apt-get install -y python3-future || true
apt-get install -y python3-click || true
apt-get install -y python3-cryptography || true
apt-get install -y python3-pip || true
apt-get install -y python3-pyelftools || true
apt-get install -y python3-pyparsing || true
apt-get install -y python3-serial || true
apt-get install -y python3-setuptools || true
apt-get install -y libopencv-dev
# cleanup
rm -rf /var/cache/apt/archives/*
+106
View File
@@ -0,0 +1,106 @@
#!/bin/bash
export DEBIAN_FRONTEND=noninteractive
find "/etc/apt/sources.list.d/" -type f -exec sed -i "s|http://[a-zA-Z0-9_.]\+/|http://mirror.yandex.ru/|g" {} \;
apt-get update
# locales
apt-get install -y locales
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
TZ=Europe/Moscow
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime
echo $TZ > /etc/timezone
# base soft
apt-get install -y \
"^libxcb.*" \
bison \
ccache \
cpio \
curl \
debconf \
debhelper \
default-libmysqlclient-dev \
doxygen \
dpkg \
flex \
g++ \
git \
gperf \
graphviz \
htop \
iputils-ping \
libbz2-dev \
libffi-dev \
libfontconfig1-dev \
libfreetype6-dev \
libgl1-mesa-dev \
libglew-dev \
libglu1-mesa-dev \
libgmp-dev \
libicu-dev \
libmpc-dev \
libmpfr-dev \
libncurses-dev \
libpkgconfig-perl \
libpq-dev \
libreadline-dev \
libssl-dev \
libusb-1.0-0-dev \
libwayland-dev \
libx11-dev \
libx11-xcb-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
libxml2-dev \
libxrender-dev \
lsb-release \
mc \
md5deep \
nano \
net-tools \
ninja-build \
ocl-icd-opencl-dev \
p7zip-full \
patchelf \
python3 \
screen \
subversion \
unzip \
wget \
zip \
zlib1g-dev \
libhdf5-dev \
libcurl4-openssl-dev \
libpcsclite-dev
# install qt if not build it from source
if [[ -n "$1" && "$1" != "1" ]]; then
apt-get install -y \
qt6-tools-dev \
qt6-tools-private-dev \
qt6-declarative-dev \
qt6-positioning-dev \
qt6-datavisualization-dev \
qt6-serialport-dev \
qt6-serialbus-dev \
qt6-charts-dev
fi
apt-get install -y lzma-dev || true
apt-get install -y python3-future || true
apt-get install -y python3-click || true
apt-get install -y python3-cryptography || true
apt-get install -y python3-pip || true
apt-get install -y python3-pyelftools || true
apt-get install -y python3-pyparsing || true
apt-get install -y python3-serial || true
apt-get install -y python3-setuptools || true
apt-get install -y libopencv-dev
# cleanup
rm -rf /var/cache/apt/archives/*
+113
View File
@@ -0,0 +1,113 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}osxcross
ARG JOBS_COUNT=4
ARG JOBS_QT_COUNT=2
COPY toolchain-Darwin.cmake /soft/
ENV CUR_SODIUM_VERSION=1.0.21
ENV CUR_FFTW_VERSION=3.3.8
ENV CUR_ASSIMP_VERSION=4.1.0
ENV CUR_DISCOUNT_VERSION=2.2.6
ENV CUR_MICROHTTPD_VERSION=0.9.72
ENV CUR_QT_VERSION_MAJOR=5.15
ENV CUR_QT_VERSION=5.15.9
ENV QT_SELECT=5
ENV _DARWIN=apple-darwin18
ENV CROSS_COMPILE=x86_64-${_DARWIN}-
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/sodium && cd /soft/osx/build/sodium \
&& sh -c 'CFLAGS="-arch x86_64 -mmacosx-version-min=10.8 -march=core2 -O3" LDFLAGS="-arch x86_64 -mmacosx-version-min=10.8 -march=core2" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libsodium-${CUR_SODIUM_VERSION}/configure --host=x86_64-${_DARWIN} --prefix=/soft/osx/ && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/sodium && rm -rf /soft/libsodium-* \
&& /soft/osxcross/target/bin/x86_64-${_DARWIN}-install_name_tool -id @rpath/libsodium.23.dylib /soft/osx/lib/libsodium.23.dylib
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/fftw3 && cd /soft/osx/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/osx -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/osx -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/osx -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
RUN /soft/osxcross/target/bin/x86_64-${_DARWIN}-install_name_tool -id @rpath/libfftw3.dylib /soft/osx/lib/libfftw3.dylib
RUN /soft/osxcross/target/bin/x86_64-${_DARWIN}-install_name_tool -id @rpath/libfftw3f.dylib /soft/osx/lib/libfftw3f.dylib
RUN /soft/osxcross/target/bin/x86_64-${_DARWIN}-install_name_tool -id @rpath/libfftw3l.dylib /soft/osx/lib/libfftw3l.dylib
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/osx/build/assimp && cd /soft/osx/build/assimp \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/osx -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
RUN /soft/osxcross/target/bin/x86_64-${_DARWIN}-install_name_tool -id @rpath/libassimp.4.dylib /soft/osx/lib/libassimp.4.dylib
# markdown
WORKDIR /soft
RUN wget -nv https://github.com/Orc/discount/archive/v${CUR_DISCOUNT_VERSION}.tar.gz \
&& tar -xf v${CUR_DISCOUNT_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_DISCOUNT_VERSION}.tar.gz
RUN sed -i 's/DESTRUCTOR/ /' /soft/discount-${CUR_DISCOUNT_VERSION}/setup.c
WORKDIR /soft/discount-${CUR_DISCOUNT_VERSION}/cmake
COPY discount.cmake.patch /soft/discount-${CUR_DISCOUNT_VERSION}/cmake/cmake.patch
RUN patch < cmake.patch
WORKDIR /soft/linux/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-${CUR_DISCOUNT_VERSION}/cmake && make -j2 && mv mktags .. && rm -rf ./* \
&& mkdir -p /soft/osx/build/discount && mv /soft/linux/build/mktags /soft/osx/build/discount/mktags
WORKDIR /soft/osx/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/osx -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/discount-*
# microhttpd
WORKDIR /soft/
RUN wget -nv https://mirror.tochlab.net/pub/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/microhttpd && cd /soft/osx/build/microhttpd \
&& sh -c 'CFLAGS="-arch x86_64 -mmacosx-version-min=10.8 -march=core2 -O3" LDFLAGS="-arch x86_64 -mmacosx-version-min=10.8 -march=core2" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --host=x86_64-${_DARWIN} --prefix=/soft/osx/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/microhttpd && rm -rf /soft/libmicrohttpd-*
# Qt
ENV SYSROOT=/soft/osxcross/target/SDK/MacOSX10.14.sdk
ENV CROSS_COMPILE=/soft/osxcross/target/bin/x86_64-${_DARWIN}-
WORKDIR /soft
RUN wget -nv http://qt-mirror.dannhauer.de/archive/qt/${CUR_QT_VERSION_MAJOR}/${CUR_QT_VERSION}/single/qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& tar -xf qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz -C /soft \
&& rm -f qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& mkdir -p /soft/osx/build/qt && cd /soft/osx/build/qt \
&& sh -c 'echo "#!/bin/sh" > /usr/bin/xcode-select' \
&& sh -c 'echo "echo ${SYSROOT}" >> /usr/bin/xcode-select' \
&& chmod +x /usr/bin/xcode-select \
&& sh -c 'echo "#!/bin/sh" > /usr/bin/xcrun' \
&& sh -c 'echo "/soft/osxcross/target/bin/xcrun \"\$@\" 2>/dev/null" >> /usr/bin/xcrun' \
&& chmod +x /usr/bin/xcrun \
&& sed -i 's/license/version/' /soft/qt-everywhere-src-${CUR_QT_VERSION}/qtbase/mkspecs/features/mac/default_pre.prf \
&& /soft/qt-everywhere-src-${CUR_QT_VERSION}/configure -opensource -confirm-license -release -shared -no-pch -xplatform macx-clang -extprefix "/soft/osx" \
-sysroot ${SYSROOT} -gcc-sysroot -sdk macosx -device-option CROSS_COMPILE=${CROSS_COMPILE} \
-qt-libpng -system-zlib -qt-pcre \
-make tools -nomake tests -nomake examples -no-compile-examples \
-skip qtwebengine -skip qtwebglplugin -skip doc -skip qt3d \
&& make -j${JOBS_QT_COUNT} && make install && rm -rf ./* && rm -rf /soft/qt-everywhere-src-*
ENV BUILD_TYPE=Release
WORKDIR /soft
+214
View File
@@ -0,0 +1,214 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}osxcross
ARG JOBS_COUNT=4
ARG JOBS_QT_COUNT=2
COPY toolchain-Darwin.cmake /soft/
ENV CUR_SODIUM_VERSION=1.0.18
ENV CUR_FFTW_VERSION=3.3.8
ENV CUR_ASSIMP_VERSION=4.1.0
ENV CUR_DISCOUNT_VERSION=2.2.6
ENV CUR_MICROHTTPD_VERSION=0.9.72
ENV CUR_QT_VERSION_MAJOR=5.15
ENV CUR_QT_VERSION=5.15.2
ENV QT_SELECT=5
ENV _DARWIN=apple-darwin20.4
ENV ARCH=x86_64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/sodium && cd /soft/osx/build/sodium \
&& sh -c 'CFLAGS="-arch ${ARCH} -mmacosx-version-min=10.8 -march=core2 -O3" LDFLAGS="-arch ${ARCH} -mmacosx-version-min=10.8 -march=core2" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libsodium-${CUR_SODIUM_VERSION}/configure --host=${ARCH}-${_DARWIN} --prefix=/soft/osx/${ARCH}/ && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/sodium && rm -rf /soft/libsodium-* \
&& /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libsodium.23.dylib /soft/osx/${ARCH}/lib/libsodium.23.dylib
ENV ARCH=aarch64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/sodium && cd /soft/osx/build/sodium \
&& sh -c 'CFLAGS="-arch arm64 -mmacosx-version-min=10.8 -O3" LDFLAGS="-arch arm64 -mmacosx-version-min=10.8" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libsodium-${CUR_SODIUM_VERSION}/configure --host=${ARCH}-${_DARWIN} --prefix=/soft/osx/${ARCH}/ && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/sodium && rm -rf /soft/libsodium-* \
&& /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libsodium.23.dylib /soft/osx/${ARCH}/lib/libsodium.23.dylib
ENV ARCH=x86_64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/fftw3 && cd /soft/osx/build/fftw3 \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3.dylib /soft/osx/${ARCH}/lib/libfftw3.dylib
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3f.dylib /soft/osx/${ARCH}/lib/libfftw3f.dylib
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3l.dylib /soft/osx/${ARCH}/lib/libfftw3l.dylib
ENV ARCH=aarch64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/fftw3 && cd /soft/osx/build/fftw3 \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3.dylib /soft/osx/${ARCH}/lib/libfftw3.dylib
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3f.dylib /soft/osx/${ARCH}/lib/libfftw3f.dylib
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libfftw3l.dylib /soft/osx/${ARCH}/lib/libfftw3l.dylib
ENV ARCH=x86_64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/osx/build/assimp && cd /soft/osx/build/assimp \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libassimp.4.dylib /soft/osx/${ARCH}/lib/libassimp.4.dylib
ENV ARCH=aarch64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/osx/build/assimp && cd /soft/osx/build/assimp \
&& cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
RUN /soft/osxcross/target/bin/${ARCH}-${_DARWIN}-install_name_tool -id @rpath/libassimp.4.dylib /soft/osx/${ARCH}/lib/libassimp.4.dylib
# markdown
WORKDIR /soft
RUN wget -nv https://github.com/Orc/discount/archive/v${CUR_DISCOUNT_VERSION}.tar.gz \
&& tar -xf v${CUR_DISCOUNT_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_DISCOUNT_VERSION}.tar.gz
RUN sed -i 's/DESTRUCTOR/ /' /soft/discount-${CUR_DISCOUNT_VERSION}/setup.c
WORKDIR /soft/discount-${CUR_DISCOUNT_VERSION}/cmake
COPY discount.cmake.patch /soft/discount-${CUR_DISCOUNT_VERSION}/cmake/cmake.patch
RUN patch < cmake.patch
WORKDIR /soft/linux/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-${CUR_DISCOUNT_VERSION}/cmake && make -j2 && mv mktags .. && rm -rf ./* \
&& mkdir -p /soft/osx/build/discount && mv /soft/linux/build/mktags /soft/osx/build/discount/mktags
ENV ARCH=x86_64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
WORKDIR /soft/osx/build/discount
RUN cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake \
&& make install -j${JOBS_COUNT} && rm -rf ./*
ENV ARCH=aarch64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# markdown
RUN cmake -DCMAKE_SYSTEM_PROCESSOR=${ARCH} -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/osx/${ARCH} -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Darwin.cmake -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/discount-*
ENV ARCH=x86_64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# microhttpd
WORKDIR /soft/
RUN wget -nv https://ftp.gnu.org/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/microhttpd && cd /soft/osx/build/microhttpd \
&& sh -c 'CFLAGS="-arch ${ARCH} -mmacosx-version-min=10.8 -march=core2 -O3" LDFLAGS="-arch ${ARCH} -mmacosx-version-min=10.8 -march=core2" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --host=${ARCH}-${_DARWIN} --prefix=/soft/osx/${ARCH}/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/microhttpd && rm -rf /soft/libmicrohttpd-*
ENV ARCH=aarch64
ENV CROSS_COMPILE=${ARCH}-${_DARWIN}-
# microhttpd
WORKDIR /soft/
RUN wget -nv https://ftp.gnu.org/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/osx/build/microhttpd && cd /soft/osx/build/microhttpd \
&& sh -c 'CFLAGS="-arch arm64 -mmacosx-version-min=10.8 -O3" LDFLAGS="-arch arm64 -mmacosx-version-min=10.8" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}clang CXX=${CROSS_COMPILE}clang++ /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --host=${ARCH}-${_DARWIN} --prefix=/soft/osx/${ARCH}/ --enable-shared=no --enable-static=yes && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/osx/build/microhttpd && rm -rf /soft/libmicrohttpd-*
ENV ARCH=x86_64
# Qt
ENV SYSROOT=/soft/osxcross/target/SDK/MacOSX11.3.sdk
ENV CROSS_COMPILE=/soft/osxcross/target/bin/${ARCH}-${_DARWIN}-
WORKDIR /soft
RUN wget -nv http://download.qt.io/official_releases/qt/${CUR_QT_VERSION_MAJOR}/${CUR_QT_VERSION}/single/qt-everywhere-src-${CUR_QT_VERSION}.tar.xz \
&& tar -xf qt-everywhere-src-${CUR_QT_VERSION}.tar.xz -C /soft \
&& rm -f qt-everywhere-src-${CUR_QT_VERSION}.tar.xz \
&& mkdir -p /soft/osx/build/qt && cd /soft/osx/build/qt \
&& sh -c 'echo "#!/bin/sh" > /usr/bin/xcode-select' \
&& sh -c 'echo "echo ${SYSROOT}" >> /usr/bin/xcode-select' \
&& chmod +x /usr/bin/xcode-select \
&& sh -c 'echo "#!/bin/sh" > /usr/bin/xcrun' \
&& sh -c 'echo "/soft/osxcross/target/bin/xcrun \"\$@\" 2>/dev/null" >> /usr/bin/xcrun' \
&& chmod +x /usr/bin/xcrun \
&& sed -i 's/license/version/' /soft/qt-everywhere-src-${CUR_QT_VERSION}/qtbase/mkspecs/features/mac/default_pre.prf \
&& /soft/qt-everywhere-src-${CUR_QT_VERSION}/configure -opensource -confirm-license -release -shared -no-pch -xplatform macx-clang -extprefix "/soft/osx/${ARCH}" \
-sysroot ${SYSROOT} -gcc-sysroot -sdk macosx -device-option CROSS_COMPILE=${CROSS_COMPILE} \
-qt-libpng -system-zlib -qt-pcre \
-make tools -nomake tests -nomake examples -no-compile-examples \
-skip qtwebengine -skip qtwebglplugin -skip doc -skip qt3d \
&& make -j${JOBS_QT_COUNT} && make install && rm -rf ./* && rm -rf /soft/qt-everywhere-src-*
WORKDIR /soft
C:/sdk/MinGW/x64/bin;C:/sdk/Qt_5.15.0_x64/bin;C:/sdk/CMake/bin;C:/sdk/llvm-10.0.0_x64/bin;C:/Windows/system32;C:/Perl64/site/bin;C:/Perl64/bin;C:/Users/peri4/AppData/Local/Programs/Python/Python37-32/Scripts/;C:/Users/peri4/AppData/Local/Programs/Python/Python37-32/;c:/Ruby25/bin/
+38
View File
@@ -0,0 +1,38 @@
--- CMakeLists.txt 2019-04-15 18:28:20.000000000 +0300
+++ CMakeLists_new.txt 2020-03-16 10:46:52.288128600 +0300
@@ -20,6 +20,9 @@
set(${PROJECT_NAME}_ONLY_LIBRARY OFF CACHE BOOL
"Set to ON to only build markdown library (default is OFF)")
+set(${PROJECT_NAME}_CXX_BINDING OFF CACHE BOOL
+ "Set to ON to install header files with c++ wrappers (default is OFF)")
+
# Check headers
include(CheckIncludeFile)
check_include_file(libgen.h HAVE_LIBGEN_H)
@@ -110,6 +113,13 @@
configure_file("${_ROOT}/mkdio.h.in"
"${_ROOT}/mkdio.h"
@ONLY)
+if(${PROJECT_NAME}_CXX_BINDING)
+ message(STATUS "Applying c++ glue to mkdio.h")
+ file(READ "${_ROOT}/mkdio.h" _ROOT_MKDIO_H)
+ file(WRITE "${_ROOT}/mkdio.h" "#ifdef __cplusplus\nextern \"C\" {\n#endif\n")
+ file(APPEND "${_ROOT}/mkdio.h" "${_ROOT_MKDIO_H}")
+ file(APPEND "${_ROOT}/mkdio.h" "#ifdef __cplusplus\n}\n#endif\n")
+endif()
include_directories("${_ROOT}")
@@ -182,7 +192,10 @@
target_include_directories(libmarkdown INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
- set(_TARGETS libmarkdown markdown)
+ set(_TARGETS libmarkdown)
+ if(NOT ${PROJECT_NAME}_ONLY_LIBRARY)
+ list(APPEND _TARGETS markdown)
+ endif()
if(${PROJECT_NAME}_INSTALL_SAMPLES)
list(APPEND _TARGETS mkd2html makepage)
endif()
Binary file not shown.
+24
View File
@@ -0,0 +1,24 @@
set(CMAKE_SYSTEM_NAME Darwin)
set(CMAKE_SYSTEM_PROCESSOR x86_64)
set(OSXCROSS_TARGET_DIR "/soft/osxcross/target")
set(_DAWRIN_VERSION "apple-darwin18")
set(CMAKE_C_COMPILER ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-clang )
set(CMAKE_CXX_COMPILER ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-clang++ )
set(CMAKE_RANLIB ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-ranlib CACHE FILEPATH "ranlib" )
set(CMAKE_AR ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-ar CACHE FILEPATH "ar" )
set(CMAKE_INSTALL_NAME_TOOL ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-install_name_tool CACHE FILEPATH "install_name_tool" )
set(CMAKE_OTOOL ${OSXCROSS_TARGET_DIR}/bin/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION}-otool CACHE FILEPATH "otool" )
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,@executable_path/../Frameworks,-rpath,@executable_path/lib,-rpath,@loader_path/../lib")
list(APPEND CMAKE_PREFIX_PATH "/soft/osx")
set(CMAKE_FIND_ROOT_PATH ${OSXCROSS_TARGET_DIR}/${CMAKE_SYSTEM_PROCESSOR}-${_DAWRIN_VERSION} ${OSXCROSS_TARGET_DIR}/SDK/MacOSX10.14.sdk ${CMAKE_PREFIX_PATH}/lib)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE FIRST)
include_directories(${CMAKE_PREFIX_PATH}/include)
#link_directories(${CMAKE_PREFIX_PATH}/lib)
cmake_policy(SET CMP0025 NEW)
+32
View File
@@ -0,0 +1,32 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}debian-base
ARG XCODE_XIP=shstk.ru/files/Xcode_10.3.xip
# dev soft for our SDK
RUN apt-get update && apt-get install -y cpio libglu1-mesa-dev libgl1-mesa-dev libwayland-dev libncurses-dev flex bison gperf \
python python-pip python-setuptools python-serial python-click python-cryptography python-future python-pyparsing python-pyelftools \
python3 python3-pip python3-setuptools \
ccache libffi-dev libssl-dev doxygen graphviz libx11-dev libxkbcommon-dev libpkgconfig-perl libfreetype6-dev libfontconfig1-dev \
lzma-dev liblzma-dev libxml2-dev libbz2-dev libmpc-dev libmpfr-dev libgmp-dev libicu-dev libusb-1.0-0-dev libreadline-dev \
clang cpio libglu1-mesa-dev libxml2-dev libssl-dev liblzma-dev libbz2-dev genisoimage \
&& rm -rf /var/cache/apt/archives/*
ENV PATH=/soft/osxcross/target/bin:$PATH
ENV UNATTENDED=1
WORKDIR /soft
RUN git clone --depth=1 https://git.shstk.ru/mirrors/osxcross.git \
&& wget -nv http://${XCODE_XIP} -O Xcode.xip && osxcross/tools/gen_sdk_package_pbzx.sh ./Xcode.xip && rm -rvf /soft/Xcode.xip \
&& cd /soft/osxcross && mv Mac*.sdk.tar.xz tarballs/ \
&& ./build.sh \
&& ln -s llvm-config-7 /usr/bin/llvm-config \
&& ./build_compiler_rt.sh \
&& mkdir -p /usr/lib/llvm-7/lib/clang/7.0.1/include \
&& mkdir -p /usr/lib/llvm-7/lib/clang/7.0.1/lib/darwin \
&& cp -rv /soft/osxcross/build/compiler-rt/compiler-rt/include/sanitizer /usr/lib/llvm-7/lib/clang/7.0.1/include \
&& cp -v /soft/osxcross/build/compiler-rt/compiler-rt/build/lib/darwin/*.a /usr/lib/llvm-7/lib/clang/7.0.1/lib/darwin \
&& cp -v /soft/osxcross/build/compiler-rt/compiler-rt/build/lib/darwin/*.dylib /usr/lib/llvm-7/lib/clang/7.0.1/lib/darwin \
&& rm -rvf /soft/osxcross/tarballs/* \
&& rm -rvf /soft/osxcross/build/*
ENV PATH=/soft/osxcross/target/bin:/opt/cmake/bin:$PATH
WORKDIR /soft
+1
View File
@@ -0,0 +1 @@
/tmp
+109
View File
@@ -0,0 +1,109 @@
ARG DOCKER_PREFIX=wapmobil/
FROM ${DOCKER_PREFIX}debian
ARG JOBS_COUNT=4
ARG JOBS_QT_COUNT=2
WORKDIR /soft/picross
RUN apt-get update && apt-get install -y g++-arm-linux-gnueabihf && rm -rf /var/cache/apt/archives/*
COPY sysroot.tar.bz2 sysroot.tar.bz2
COPY toolchain-RPi.cmake /soft/
WORKDIR /soft/pi
RUN tar -xjf /soft/picross/sysroot.tar.bz2 && rm /soft/picross/sysroot.tar.bz2
WORKDIR /soft
ENV _TARGET=linux-gnueabihf
ENV CROSS_COMPILE=arm-${_TARGET}-
# sodium
WORKDIR /soft
RUN curl https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/pi/build/sodium && cd /soft/pi/build/sodium \
&& sh -c 'CFLAGS="-O3" LDFLAGS="-O3" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}gcc CXX=${CROSS_COMPILE}g++ /soft/libsodium-*/configure --host=arm-${_TARGET} --prefix=/soft/pi/usr && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/pi/build/sodium && rm -rf /soft/libsodium-*
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/pi/build/fftw3 && cd /soft/pi/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/pi/usr -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-RPi.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/pi/usr -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-RPi.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/pi/usr -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-RPi.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/pi/build/assimp && cd /soft/pi/build/assimp \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/pi/usr -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-RPi.cmake /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
# markdown
WORKDIR /soft
RUN wget -nv https://github.com/Orc/discount/archive/v${CUR_DISCOUNT_VERSION}.tar.gz \
&& tar -xf v${CUR_DISCOUNT_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_DISCOUNT_VERSION}.tar.gz
RUN sed -i 's/DESTRUCTOR/ /' /soft/discount-${CUR_DISCOUNT_VERSION}/setup.c
WORKDIR /soft/discount-${CUR_DISCOUNT_VERSION}/cmake
COPY discount.cmake.patch /soft/discount-${CUR_DISCOUNT_VERSION}/cmake/cmake.patch
RUN patch < cmake.patch
WORKDIR /soft/linux/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-${CUR_DISCOUNT_VERSION}/cmake && make -j2 && mv mktags .. && rm -rf ./* \
&& mkdir -p /soft/pi/build/discount && mv /soft/linux/build/mktags /soft/pi/build/discount/mktags
WORKDIR /soft/pi/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/pi/usr -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-RPi.cmake -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake && make install -j${JOBS_COUNT} && rm -rf ./*
# microhttpd
WORKDIR /soft/
RUN wget -nv https://mirror.tochlab.net/pub/gnu/libmicrohttpd/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& tar -xf /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz -C /soft/ \
&& rm /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}.tar.gz \
&& mkdir -p /soft/pi/build/microhttpd && cd /soft/pi/build/microhttpd \
&& sh -c 'CFLAGS="-O3" LDFLAGS="-O3" LD=${CROSS_COMPILE}ld CC=${CROSS_COMPILE}gcc CXX=${CROSS_COMPILE}g++ /soft/libmicrohttpd-${CUR_MICROHTTPD_VERSION}/configure --host=arm-${_TARGET} --prefix=/soft/pi/usr --enable-shared=no --enable-static=yes --enable-tests=no --enable-examples=no && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/pi/build/microhttpd && rm -rf /soft/libmicrohttpd-*
# Qt
WORKDIR /soft
ENV SYSROOT=/soft/pi
RUN ln -s /usr/bin/arm-linux-gnueabihf-g++ /usr/bin/arm-linux-gnueabi-g++
RUN ln -s /usr/bin/arm-linux-gnueabihf-gcc /usr/bin/arm-linux-gnueabi-gcc
RUN ln -s /usr/bin/arm-linux-gnueabihf-ar /usr/bin/arm-linux-gnueabi-ar
RUN ln -s /usr/bin/arm-linux-gnueabihf-nm /usr/bin/arm-linux-gnueabi-nm
RUN ln -s /usr/bin/arm-linux-gnueabihf-strip /usr/bin/arm-linux-gnueabi-strip
RUN ln -s /usr/bin/arm-linux-gnueabihf-objcopy /usr/bin/arm-linux-gnueabi-objcopy
RUN wget -nv http://qt-mirror.dannhauer.de/archive/qt/${CUR_QT_VERSION_MAJOR}/${CUR_QT_VERSION}/single/qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& tar -xf qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz -C /soft \
&& rm -f qt-everywhere-opensource-src-${CUR_QT_VERSION}.tar.xz \
&& mkdir -p /soft/build/qt && cd /soft/build/qt \
&& /soft/qt-everywhere-src-${CUR_QT_VERSION}/configure \
-opensource -confirm-license -release -shared -no-pch -xplatform "linux-arm-gnueabi-g++" -extprefix "/soft/pi/usr" \
-sysroot ${SYSROOT} -gcc-sysroot -device-option CROSS_COMPILE=${CROSS_COMPILE} \
MYSQL_INCDIR=/soft/pi/usr/include/mysql MYSQL_LIBDIR=/soft/pi/usr/lib/arm-linux-gnueabihf \
-opengl desktop -qt-libpng -system-zlib -qt-pcre -make tools -nomake tests -nomake examples -no-compile-examples \
-skip qtwebengine -skip qtwebglplugin -skip doc -skip qt3d -skip qtactiveqt -skip qtquick3d -openssl-linked -xcb \
&& make -j${JOBS_QT_COUNT} && make install && rm -rf ./* && rm -rf /soft/qt-everywhere-src-*
ENV BUILD_TYPE=Release
WORKDIR /soft
+38
View File
@@ -0,0 +1,38 @@
--- CMakeLists.txt 2019-04-15 18:28:20.000000000 +0300
+++ CMakeLists_new.txt 2020-03-16 10:46:52.288128600 +0300
@@ -20,6 +20,9 @@
set(${PROJECT_NAME}_ONLY_LIBRARY OFF CACHE BOOL
"Set to ON to only build markdown library (default is OFF)")
+set(${PROJECT_NAME}_CXX_BINDING OFF CACHE BOOL
+ "Set to ON to install header files with c++ wrappers (default is OFF)")
+
# Check headers
include(CheckIncludeFile)
check_include_file(libgen.h HAVE_LIBGEN_H)
@@ -110,6 +113,13 @@
configure_file("${_ROOT}/mkdio.h.in"
"${_ROOT}/mkdio.h"
@ONLY)
+if(${PROJECT_NAME}_CXX_BINDING)
+ message(STATUS "Applying c++ glue to mkdio.h")
+ file(READ "${_ROOT}/mkdio.h" _ROOT_MKDIO_H)
+ file(WRITE "${_ROOT}/mkdio.h" "#ifdef __cplusplus\nextern \"C\" {\n#endif\n")
+ file(APPEND "${_ROOT}/mkdio.h" "${_ROOT_MKDIO_H}")
+ file(APPEND "${_ROOT}/mkdio.h" "#ifdef __cplusplus\n}\n#endif\n")
+endif()
include_directories("${_ROOT}")
@@ -182,7 +192,10 @@
target_include_directories(libmarkdown INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
- set(_TARGETS libmarkdown markdown)
+ set(_TARGETS libmarkdown)
+ if(NOT ${PROJECT_NAME}_ONLY_LIBRARY)
+ list(APPEND _TARGETS markdown)
+ endif()
if(${PROJECT_NAME}_INSTALL_SAMPLES)
list(APPEND _TARGETS mkd2html makepage)
endif()
+20
View File
@@ -0,0 +1,20 @@
#! /bin/bash
set -e
# Fix absolute symlinks to RPi sysroot
# Run script in raspbian root
PREF="/lib/arm-linux-gnueabihf"
DIR="usr/lib/arm-linux-gnueabihf/"
#"/soft/pi/lib/arm-linux-gnueabihf/"
#NEWDIR="/soft/picross/pitools/arm-bcm2708/arm-linux-gnueabihf/arm-linux-gnueabihf/sysroot/lib/"
PLEN=`expr length "$PREF"`
for f in `find $DIR -maxdepth 1 -type l`
do
L=`readlink $f`
D=`expr substr "$L" 1 $PLEN`
if [[ "$D" = "$PREF" ]]
then
echo "Relink $f"
ln -sf "../../..$L" "$f"
fi
done
+17
View File
@@ -0,0 +1,17 @@
#! /bin/bash
set -e
home=$(pwd)
rm -vf $home/sysroot.tar.bz2
apt-get update --allow-releaseinfo-change && apt-get install -y rsync
mkdir /raspbian
rsync -a $home/raspbian /
rm /raspbian/etc/ld.so.preload
cp -vf /etc/resolv.conf /raspbian/etc/resolv.conf
chroot /raspbian /bin/bash -c "date && cat /etc/resolv.conf && ping 8.8.8.8 -c 4 && ping archive.raspberrypi.org -c 4"
chroot /raspbian /bin/bash -c "apt-get update --allow-releaseinfo-change && apt-get upgrade -y && apt-get install -y libicu-dev zlib1g-dev libglew-dev libffi-dev libssl-dev libmpc-dev libmpfr-dev libgmp-dev lzma-dev liblzma-dev libxml2-dev libbz2-dev zip \"^libxcb.*\" libx11-xcb-dev libxkbcommon-x11-dev libglu1-mesa-dev libxrender-dev mariadb-client mariadb-common mysql-common libmariadb-dev-compat libmariadbclient-dev libpq-dev ninja-build"
cd /raspbian
bash $home/fix_links.sh
tar -cjf /soft/rpi_image/sysroot.tar.bz2 lib/arm-linux-gnueabihf usr/lib usr/include usr/share var/lib/dpkg/ etc/*-release
chmod 777 /soft/rpi_image/sysroot.tar.bz2
+12
View File
@@ -0,0 +1,12 @@
#! /bin/bash
set -e
mkdir -p ./tmp ./raspbian
cd ./tmp
wget -nv https://downloads.raspberrypi.org/raspbian_lite_latest -O raspbian_lite_latest.zip
rm -vf *raspbian*.img
unzip ./raspbian_lite_latest.zip
sudo losetup -P /dev/loop9 `ls *raspbian*.img`
cd ..
sudo mount /dev/loop9p2 ./raspbian
#docker run -v $(pwd):/raspbian --rm wapmobil/debian bash make_sysroot.sh
+26
View File
@@ -0,0 +1,26 @@
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR arm)
set(triple "arm-linux-gnueabihf")
set(RPI_TOOLCHAIN "/usr/bin/${triple}")
#set(CMAKE_SYSROOT "/soft/pi/usr")
set(CMAKE_LIBRARY_ARCHITECTURE ${triple})
set(CMAKE_C_COMPILER ${RPI_TOOLCHAIN}-gcc)
set(CMAKE_CXX_COMPILER ${RPI_TOOLCHAIN}-g++)
set(CMAKE_RANLIB ${RPI_TOOLCHAIN}-ranlib CACHE FILEPATH "ranlib")
set(CMAKE_AR ${RPI_TOOLCHAIN}-ar CACHE FILEPATH "ar")
set(CMAKE_READELF ${RPI_TOOLCHAIN}-readelf CACHE FILEPATH "readelf")
set(CMAKE_DPKG_WORKDIR /soft/pi/var/lib/dpkg/)
list(APPEND CMAKE_PREFIX_PATH "/soft/pi/usr")
#set(CMAKE_FIND_ROOT_PATH ${CMAKE_PREFIX_PATH}/lib/${triple})
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE FIRST)
set(CMAKE_EXE_LINKER_FLAGS "-Wl,-rpath-link,/soft/pi/lib/${triple}")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS}")
include_directories(${CMAKE_PREFIX_PATH}/include ${CMAKE_PREFIX_PATH}/include/${triple})
cmake_policy(SET CMP0025 NEW)
+10
View File
@@ -0,0 +1,10 @@
#! /bin/bash
set -e
x=$(ls /dev | grep loop9p2 | wc -l)
if [ $x -ne 0 ]
then
echo "delete loop"
sudo umount ./raspbian || true
sudo losetup -d /dev/loop9 || true
fi
rm -rf ./tmp ./raspbian || true
+7
View File
@@ -0,0 +1,7 @@
FROM debian:stable-slim
RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
ENV LANG=en_US.utf8
RUN apt-get update && apt-get install -y cmake g++ git libsodium-dev
WORKDIR /soft
RUN git clone --depth 1 https://git.shstk.ru/SHS/pip.git && cd /soft/build && cmake -DICU=0 ../pip && make install -j4 && cd /soft && rm -rf ./*
+22
View File
@@ -0,0 +1,22 @@
FROM ubuntu:latest
# locales
RUN apt-get update && apt-get install -y locales wget gnupg && rm -rf /var/lib/apt/lists/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8 \
&& rm -rf /var/cache/apt/archives/*
ENV LANG=en_US.utf8
ENV TZ=Europe/Moscow
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
# install shs-server
RUN wget -qO - https://ppa.shstk.ru/SHS.gpg | apt-key add -
RUN echo "deb [arch=amd64] https://ppa.shstk.ru/ focal main" | tee /etc/apt/sources.list.d/SHS.list
RUN apt-get update && apt-get install -y shs-server && rm -rf /var/cache/apt/archives/*
# run shs-server
EXPOSE 13361/tcp
EXPOSE 13380/udp
EXPOSE 13392/udp
EXPOSE 13390/udp
ENTRYPOINT exec SHS_Server -platform minimal --no-graphics --help
+12
View File
@@ -0,0 +1,12 @@
node {
stage("Download SRC") {
checkout scm
}
stage("build and push") {
def img = docker.build("${env.DOCKER_PREFIX}/shs-server", ". --no-cache")
img.push()
}
stage("docker prune") {
sh 'docker system prune -f'
}
}
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+14
View File
@@ -0,0 +1,14 @@
FROM debian:stable-slim
# locales
RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
# base soft
RUN apt-get update && apt-get install -y gcc-arm-none-eabi make git && rm -rf /var/cache/apt/archives/*
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+21
View File
@@ -0,0 +1,21 @@
FROM debian:stable-slim
# locales
RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
# base soft
RUN apt-get update && apt-get install -y curl wget make git && rm -rf /var/cache/apt/archives/*
# mmwave SDK
WORKDIR /soft
RUN dpkg --add-architecture i386
RUN apt-get update && apt-get install -y build-essential mono-runtime libc6:i386 && rm -rf /var/cache/apt/archives/*
COPY mmwave_sdk_03_05_00_04-Linux-x86-Install.bin /soft/mmwave_sdk.bin
RUN /soft/mmwave_sdk.bin --prefix /soft/ti --mode unattended
RUN rm -f /soft/mmwave_sdk.bin
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
+113
View File
@@ -0,0 +1,113 @@
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;35m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
+183
View File
@@ -0,0 +1,183 @@
FROM debian:trixie-slim
ARG JOBS_COUNT=12
ENV CROSS_COMPILE=x86_64-w64-mingw32-
ENV SYSROOT=/usr/lib/gcc/x86_64-w64-mingw32/14-posix
# locales
RUN apt-get update && apt-get install -y locales \
&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8 \
&& rm -rf /var/cache/apt/archives/*
ENV LANG=en_US.utf8
# configs
COPY .bashrc /root/.bashrc
COPY inputrc /etc/inputrc
# base soft
RUN apt-get install -y subversion git zip unzip wget curl htop net-tools iputils-ping mc nano screen g++ patchelf p7zip-full ninja-build make python3 \
cpio libglu1-mesa-dev libgl1-mesa-dev libwayland-dev libncurses-dev flex bison gperf libdbus-1-3 \
ccache libffi-dev libssl-dev doxygen graphviz libx11-dev libxkbcommon-dev libpkgconfig-perl libfontconfig1-dev \
liblzma-dev libxml2-dev libbz2-dev libmpc-dev libmpfr-dev libgmp-dev libicu-dev libusb-1.0-0-dev libreadline-dev \
ninja-build mingw-w64 libz-mingw-w64-dev \
&& rm -rf /var/cache/apt/archives/*
# w64-mingw32 soft
RUN update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix \
&& update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
RUN x86_64-w64-mingw32-strip -v --strip-unneeded /usr/x86_64-w64-mingw32/lib/*.dll && \
x86_64-w64-mingw32-strip -v --strip-unneeded ${SYSROOT}/*.dll
WORKDIR /soft
COPY toolchain-Windows.cmake /soft/
COPY opencl_win.zip /soft/
COPY rpc.zip /soft/
COPY zlib1.dll /soft/windows/bin/
ENV CUR_SODIUM_VERSION=1.0.20
ENV CUR_FFTW_VERSION=3.3.8
ENV CUR_ASSIMP_VERSION=4.1.0
ENV CUR_DISCOUNT_VERSION=2.2.6
ENV CUR_OPENSSL_VERSION=1_1_1h
ENV CUR_OPENCV_VERSION=4.5.5
RUN mkdir -p /soft/windows/bin/ \
&& cp -v ${SYSROOT}/libgcc_s_seh-1.dll /soft/windows/bin/ \
&& cp -v ${SYSROOT}/libstdc++-6.dll /soft/windows/bin/ \
&& cp -v /usr/x86_64-w64-mingw32/lib/libwinpthread-1.dll /soft/windows/bin/
RUN unzip -o opencl_win.zip -d /soft/windows \
&& unzip -o rpc.zip -d /soft/windows/lib \
&& rm -vf /soft/opencl_win.zip /soft/rpc.zip
# last cmake from sources, into /opt
ENV CUR_CMAKE_VERSION=3.31.3
RUN wget -nv https://github.com/Kitware/CMake/releases/download/v${CUR_CMAKE_VERSION}/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh \
&& mkdir -p /opt/cmake \
&& bash ./cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/opt/cmake \
&& rm -rf /soft/cmake-${CUR_CMAKE_VERSION}-Linux-x86_64.sh
ENV PATH=/opt/cmake/bin:$PATH
# Remove invalid FindGtest.cmake
RUN cd "$(find /opt/cmake/share -name FindGTest.cmake -type f -printf '%h' -quit)" && rm FindGTest.cmake
# sodium
WORKDIR /soft
RUN curl -s https://download.libsodium.org/libsodium/releases/libsodium-${CUR_SODIUM_VERSION}.tar.gz \
-o libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& tar -xf libsodium-${CUR_SODIUM_VERSION}.tar.gz -C /soft \
&& rm -f libsodium-${CUR_SODIUM_VERSION}.tar.gz \
&& mkdir -p /soft/windows/build/sodium && cd /soft/windows/build/sodium \
&& sh -c 'CFLAGS="-O3 -fomit-frame-pointer -m64" LDFLAGS="-O3 -fomit-frame-pointer -m64" /soft/libsodium-${CUR_SODIUM_VERSION}/configure --host=x86_64-w64-mingw32 --prefix=/soft/windows/ --exec-prefix=/soft/windows && make install -j${JOBS_COUNT}' \
&& cd /soft && rm -rf /soft/windows/build/sodium && rm -rf /soft/libsodium-*
# fftw3
WORKDIR /soft
RUN wget -nv http://www.fftw.org/fftw-${CUR_FFTW_VERSION}.tar.gz \
&& tar -xf fftw-${CUR_FFTW_VERSION}.tar.gz -C /soft \
&& rm -f fftw-${CUR_FFTW_VERSION}.tar.gz \
&& mkdir -p /soft/windows/build/fftw3 && cd /soft/windows/build/fftw3 \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=1 -DENABLE_LONG_DOUBLE=0 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_FLOAT=0 -DENABLE_LONG_DOUBLE=1 -DENABLE_QUAD_PRECISION=0 -DENABLE_THREADS=1 -DWITH_COMBINED_THREADS=1 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake /soft/fftw-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* \
&& rm -rf /soft/fftw-*
# assimp
WORKDIR /soft
RUN wget -nv https://github.com/assimp/assimp/archive/v${CUR_ASSIMP_VERSION}.tar.gz \
&& tar -xf v${CUR_ASSIMP_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_ASSIMP_VERSION}.tar.gz pax_global_header \
&& mkdir -p /soft/windows/build/assimp && cd /soft/windows/build/assimp \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DASSIMP_BUILD_ASSIMP_TOOLS=0 -DASSIMP_BUILD_TESTS=0 -DBUILD_FRAMEWORK=0 -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake /soft/assimp-* \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/assimp-*
# markdown
WORKDIR /soft
RUN wget -nv https://github.com/Orc/discount/archive/v${CUR_DISCOUNT_VERSION}.tar.gz \
&& tar -xf v${CUR_DISCOUNT_VERSION}.tar.gz -C /soft \
&& rm -f v${CUR_DISCOUNT_VERSION}.tar.gz
RUN sed -i 's/DESTRUCTOR/ /' /soft/discount-${CUR_DISCOUNT_VERSION}/setup.c
WORKDIR /soft/discount-${CUR_DISCOUNT_VERSION}/cmake
COPY discount.cmake.patch /soft/discount-${CUR_DISCOUNT_VERSION}/cmake/cmake.patch
RUN patch < cmake.patch
WORKDIR /soft/linux/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-${CUR_DISCOUNT_VERSION}/cmake && make -j2 && mv mktags .. && rm -rf ./* \
&& mkdir -p /soft/windows/build/discount && mv /soft/linux/build/mktags /soft/windows/build/discount/mktags
WORKDIR /soft/windows/build/discount
RUN cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake -DDISCOUNT_ONLY_LIBRARY=1 /soft/discount-*/cmake \
&& make install -j${JOBS_COUNT} && rm -rf ./* && rm -rf /soft/discount-*
# mysql
COPY MySQL_C_x64.zip /soft/
RUN unzip -o /soft/MySQL_C_x64.zip -d ${SYSROOT}/ \
&& cp ${SYSROOT}/libmysql.dll /soft/windows/bin/ \
&& rm /soft/MySQL_C_x64.zip
# postgresql
COPY postgresql.zip /soft/
RUN unzip -o /soft/postgresql.zip -d ${SYSROOT}/ \
&& cp ${SYSROOT}/lib/*.dll /soft/windows/bin/ \
&& rm /soft/postgresql.zip
# OpenSSL
RUN wget -nv https://github.com/openssl/openssl/archive/OpenSSL_${CUR_OPENSSL_VERSION}.tar.gz \
&& tar -xf OpenSSL_${CUR_OPENSSL_VERSION}.tar.gz -C /soft \
&& rm -f OpenSSL_${CUR_OPENSSL_VERSION}.tar.gz \
&& mkdir -p /soft/windows/build/openssl && cd /soft/windows/build/openssl \
&& /soft/openssl-OpenSSL_${CUR_OPENSSL_VERSION}/Configure --cross-compile-prefix=x86_64-w64-mingw32- \
--prefix=/soft/windows/ --release no-idea no-mdc2 no-rc5 no-tests shared mingw64 \
&& make -j${JOBS_COUNT} && make install \
&& cd /soft && rm -rf /soft/windows/build/openssl && rm -rf /soft/openssl-OpenSSL_*
# microhttpd
RUN mkdir -p /soft/tmp && cd /soft/tmp \
&& wget https://ftpmirror.gnu.org/libmicrohttpd/libmicrohttpd-latest-w32-bin.zip \
&& unzip -o /soft/tmp/*.zip -d /soft/tmp \
&& cp -rfv /soft/tmp/libmicrohttpd-*-w32-bin/x86_64/MinGW/static/mingw64/* /soft/windows/ \
&& rm -rf /soft/tmp
# curl
RUN mkdir -p /soft/tmp && cd /soft/tmp \
&& wget https://curl.se/windows/latest.cgi?p=win64-mingw.zip \
&& unzip -o /soft/tmp/*.zip -d /soft/tmp \
&& cp -rv /soft/tmp/curl-*/bin /soft/tmp/curl-*/lib /soft/tmp/curl-*/include ${SYSROOT} \
&& cp -v ${SYSROOT}/bin/libcurl-x64.dll /soft/windows/bin/ \
&& cp -v ${SYSROOT}/lib/*curl.dll.a /soft/windows/lib/ \
&& rm -rf /soft/tmp
RUN chmod +r /soft/windows/bin/*
ENV BUILD_TYPE=Release
# GTest
WORKDIR /soft
RUN git clone https://github.com/google/googletest.git \
&& mkdir googletest/build && cd googletest/build \
&& cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake .. \
&& make -j${JOBS_COUNT} && make install && cd /soft && rm -rf googletest
WORKDIR /soft
RUN git clone --depth 1 --recursive -b 'release/21.x' https://github.com/llvm/llvm-project.git
WORKDIR /soft/llvm_build_windows
RUN cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake \
-DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" -DLLVM_ENABLE_RUNTIMES="" -DLLVM_ENABLE_RTTI=ON \
-DLLVM_BUILD_TESTS=OFF -DLLVM_INCLUDE_TESTS=OFF -DLLVM_INSTALL_GTEST=OFF ../llvm-project/llvm \
&& cmake --build ./ --target install -j8 \
&& rm -rf *
Binary file not shown.
+38
View File
@@ -0,0 +1,38 @@
--- CMakeLists.txt 2019-04-15 18:28:20.000000000 +0300
+++ CMakeLists_new.txt 2020-03-16 10:46:52.288128600 +0300
@@ -20,6 +20,9 @@
set(${PROJECT_NAME}_ONLY_LIBRARY OFF CACHE BOOL
"Set to ON to only build markdown library (default is OFF)")
+set(${PROJECT_NAME}_CXX_BINDING OFF CACHE BOOL
+ "Set to ON to install header files with c++ wrappers (default is OFF)")
+
# Check headers
include(CheckIncludeFile)
check_include_file(libgen.h HAVE_LIBGEN_H)
@@ -110,6 +113,13 @@
configure_file("${_ROOT}/mkdio.h.in"
"${_ROOT}/mkdio.h"
@ONLY)
+if(${PROJECT_NAME}_CXX_BINDING)
+ message(STATUS "Applying c++ glue to mkdio.h")
+ file(READ "${_ROOT}/mkdio.h" _ROOT_MKDIO_H)
+ file(WRITE "${_ROOT}/mkdio.h" "#ifdef __cplusplus\nextern \"C\" {\n#endif\n")
+ file(APPEND "${_ROOT}/mkdio.h" "${_ROOT_MKDIO_H}")
+ file(APPEND "${_ROOT}/mkdio.h" "#ifdef __cplusplus\n}\n#endif\n")
+endif()
include_directories("${_ROOT}")
@@ -182,7 +192,10 @@
target_include_directories(libmarkdown INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
- set(_TARGETS libmarkdown markdown)
+ set(_TARGETS libmarkdown)
+ if(NOT ${PROJECT_NAME}_ONLY_LIBRARY)
+ list(APPEND _TARGETS markdown)
+ endif()
if(${PROJECT_NAME}_INSTALL_SAMPLES)
list(APPEND _TARGETS mkd2html makepage)
endif()
+13
View File
@@ -0,0 +1,13 @@
set(HAVE_IOEO_EXITCODE 0 CACHE BOOL "")
set(H5_LDOUBLE_TO_LONG_SPECIAL_RUN 1 CACHE BOOL "")
set(H5_LONG_TO_LDOUBLE_SPECIAL_RUN 1 CACHE BOOL "")
set(H5_LDOUBLE_TO_LLONG_ACCURATE_RUN 0 CACHE BOOL "")
set(H5_LLONG_TO_LDOUBLE_CORRECT_RUN 0 CACHE BOOL "")
set(H5_DISABLE_SOME_LDOUBLE_CONV_RUN 1 CACHE BOOL "")
set(HAVE_IOEO_EXITCODE__TRYRUN_OUTPUT 0 CACHE BOOL "")
set(H5_LDOUBLE_TO_LONG_SPECIAL_RUN__TRYRUN_OUTPUT 1 CACHE BOOL "")
set(H5_LONG_TO_LDOUBLE_SPECIAL_RUN__TRYRUN_OUTPUT 1 CACHE BOOL "")
set(H5_LDOUBLE_TO_LLONG_ACCURATE_RUN__TRYRUN_OUTPUT 0 CACHE BOOL "")
set(H5_LLONG_TO_LDOUBLE_CORRECT_RUN__TRYRUN_OUTPUT 0 CACHE BOOL "")
set(H5_DISABLE_SOME_LDOUBLE_CONV_RUN__TRYRUN_OUTPUT 1 CACHE BOOL "")
+67
View File
@@ -0,0 +1,67 @@
# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.
# Be 8 bit clean.
set input-meta on
set output-meta on
# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.
# set convert-meta off
# try to enable the application keypad when it is called. Some systems
# need this to enable the arrow keys.
# set enable-keypad on
# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys
# do not bell on tab-completion
# set bell-style none
# set bell-style visible
# some defaults / modifications for the emacs mode
$if mode=emacs
# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line
# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert
# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history
# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving
"\e[1;5C": forward-word
"\e[1;5D": backward-word
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
$if term=rxvt
"\e[7~": beginning-of-line
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word
$endif
# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line
# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line
$endif
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+23
View File
@@ -0,0 +1,23 @@
set(CMAKE_SYSTEM_NAME Windows)
set(CMAKE_SYSTEM_PROCESSOR x86_64)
set(CMAKE_C_COMPILER /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-gcc-posix )
set(CMAKE_C_COMPILER_AR /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-gcc-ar-posix )
set(CMAKE_C_COMPILER_RANLIB /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-gcc-ranlib-posix )
set(CMAKE_CXX_COMPILER /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-g++-posix )
set(CMAKE_CXX_COMPILER_AR /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-gcc-ar-posix )
set(CMAKE_CXX_COMPILER_RANLIB /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-gcc-ranlib-posix )
set(CMAKE_ASM_NASM_COMPILER /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-as )
set(CMAKE_RC_COMPILER /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-windres)
set(CMAKE_OBJDUMP /usr/bin/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32-objdump)
add_definitions(-D_WIN32_WINNT=0x0A00 -D_GNU_SOURCE=1 -DNOWERROR=1)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fstack-protector-all")
list(APPEND CMAKE_PREFIX_PATH "/soft/windows")
SET(CMAKE_FIND_ROOT_PATH /usr/${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32 ${CMAKE_PREFIX_PATH}/lib)
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
include_directories(${CMAKE_PREFIX_PATH}/include)
set(OpenCL_INCLUDE_DIR ${CMAKE_PREFIX_PATH}/include)
set(OpenCL_LIBRARY ${CMAKE_PREFIX_PATH}/lib/opencl.lib)
Binary file not shown.
+74
View File
@@ -0,0 +1,74 @@
FROM windows-clang
ARG JOBS_COUNT=16
ARG LIBS_BUILD_NUMBER=9999
ENV CUR_QT_VERSION=6.9.2
RUN wget -nv http://shstk.ru/files/qt-all-${CUR_QT_VERSION}.zip \
&& unzip -o qt-all-${CUR_QT_VERSION}.zip -d /soft/qt \
&& rm -f qt-all-${CUR_QT_VERSION}.zip
COPY create_links.sh /soft/qt/gcc_64/lib/create_links.sh
RUN cd /soft/qt/gcc_64/lib/ && chmod +x ./create_links.sh && sh ./create_links.sh
RUN chmod +x /soft/qt/gcc_64/libexec/*
RUN chmod +x /soft/qt/gcc_64/bin/*
RUN ln -s /usr/x86_64-w64-mingw32/include/windows.h /usr/x86_64-w64-mingw32/include/Windows.h
WORKDIR /soft
RUN echo "hello!"
RUN git clone -b master --single-branch --depth 1 --recursive https://git.shstk.ru/SHS/shstk.git
WORKDIR /soft/shstk_build_host
RUN cmake -G Ninja -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../shstk \
&& cmake --build ./ --target install -j${JOBS_COUNT} \
&& rm -rf ./* && ldconfig
WORKDIR /soft/shstk_build_windows
RUN cmake -G Ninja -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake \
-DCMAKE_INSTALL_PREFIX=/soft/windows \
-DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 \
-DQT_HOST_PATH=/soft/qt/gcc_64 \
-DICU=0 -DLOCAL=1 -DQGLENGINE=1 -DQGLVIEW=0 -DPIP_BUILD_OPENCL=0 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} \
-DOpenCL_INCLUDE_DIRS=/soft/windows/include \
../shstk/ \
&& cmake --build ./ --target install -j${JOBS_COUNT} && rm -rf ./*
#RUN git clone -b v8 --single-branch --depth 1 https://git.shstk.ru/SHS/qtcreator.git /soft/qt-creator-plugins
#rm /soft/toolchain-Windows.cmake
#cp toolchain-Windows.cmake clangformatbaseindenter.patch clangformatutils.patch /soft/
#apt-get update && apt-get install -y qttools5-dev-tools
#cp -vf /usr/bin/qhelpgenerator /usr/bin/qcollectiongenerator /usr/x86_64-w64-mingw32/lib/zlib1.dll /soft/windows/bin/
#WORKDIR /soft
#RUN git clone -b "8.0" --depth 1 --recursive https://github.com/qt-creator/qt-creator.git /soft/qt-creator
#RUN patch /soft/qt-creator/src/plugins/clangformat/clangformatbaseindenter.cpp /soft/qt-creator-plugins/build_files/clangformatbaseindenter.patch
#RUN patch /soft/qt-creator/src/plugins/clangformat/clangformatutils.cpp /soft/qt-creator-plugins/build_files/clangformatutils.patch
WORKDIR /soft
#RUN git clone -b "15.0" --depth 1 --recursive https://github.com/qt-creator/qt-creator.git
#RUN git clone -b "v18.0.2" --depth 1 --recursive https://github.com/qt-creator/qt-creator.git
RUN git clone -b "v19.0.0" --depth 1 --recursive https://github.com/qt-creator/qt-creator.git
RUN wget https://go.dev/dl/go1.25.4.linux-amd64.tar.gz && tar -xf /soft/go*.linux-amd64.tar.gz -C /soft/windows/
ENV PATH=/soft/windows/go/bin:$PATH
WORKDIR /soft/qt-creator_build
RUN cmake -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake \
-DCMAKE_INSTALL_PREFIX=/soft/windows/qt-creator \
-DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 \
-DQT_HOST_PATH=/soft/qt/gcc_64 \
-DQT_NO_PRIVATE_MODULE_WARNING=1 \
-DWITH_QMLDESIGNER=0 \
-DBUILD_WITH_PCH=0 \
-Drcc_OPTIONS="--no-zstd" \
../qt-creator
RUN make -k -j${JOBS_COUNT} || true
RUN make -k -j${JOBS_COUNT} -i install || true
WORKDIR /soft/windows/qt-creator
RUN cp -vfr /soft/qt/mingw_64/plugins ./
RUN cp -vfr /soft/qt/mingw_64/qml ./
RUN cp -vfr /soft/qt/mingw_64/translations ./
RUN mv -vf ./libexec/qtcreator/* ./bin/ && rm -rf ./libexec
+87
View File
@@ -0,0 +1,87 @@
pipeline {
agent {
docker {
image 'windows-qtcreator'
args '-u root:root --privileged'
}
}
options {
copyArtifactPermission('*')
buildDiscarder(logRotator(numToKeepStr: "1000", artifactNumToKeepStr: "2"))
}
stages {
stage('shstk') {
steps {
script {
sh 'rm -rf /soft/shstk'
sh 'git clone -b master --single-branch --depth 1 --recursive https://git.shstk.ru/SHS/shstk.git /soft/shstk'
sh 'mkdir -p /soft/shstk_build_host && rm -rf /soft/shstk_build_host/*'
sh 'cd /soft/shstk_build_host && cmake -G Ninja -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=9999 ../shstk'
sh 'cd /soft/shstk_build_host && cmake --build ./ --target install -j${JOBS_COUNT}'
sh 'ldconfig'
sh 'mkdir -p /soft/shstk_build_windows && rm -rf /soft/shstk_build_windows/*'
sh 'cd /soft/shstk_build_windows && cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 -DQT_HOST_PATH=/soft/qt/gcc_64 -DICU=0 -DLOCAL=1 -DQGLENGINE=1 -DQGLVIEW=0 -DPIP_BUILD_OPENCL=0 -DBUILD_NUMBER=9999 -DOpenCL_INCLUDE_DIRS=/soft/windows/include ../shstk/'
sh 'cd /soft/shstk_build_windows && cmake --build ./ --target install -j${JOBS_COUNT}'
}
}
}
stage('SHS') {
steps {
script {
sh 'rm -rf /soft/SHS'
sh 'git clone -b v1_master --single-branch --depth 1 --recursive https://git.shstk.ru/SHS/SHS.git /soft/SHS'
sh 'mkdir -p /soft/SHS/build && rm -rf /soft/SHS/build/*'
sh 'cd /soft/SHS/build && cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake -DCMAKE_INSTALL_PREFIX=/soft/windows -DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 -DQT_HOST_PATH=/soft/qt/gcc_64 -DSHS_ONLY_LIBS=1 -DBUILD_NUMBER=9999 -DSHS_QT_VERSION=6 ../src'
sh 'cd /soft/SHS/build && cmake --build ./ --target install -j${JOBS_COUNT}'
sh 'cp -vf /soft/SHS/builds/Windows_x86_64/*.dll /soft/windows/bin/'
sh 'cp -vf /soft/SHS/builds/Windows_x86_64/lang/* /soft/windows/lang/'
sh 'cp -rvf /soft/SHS/builds/Windows_x86_64/designer /soft/qt/mingw_64/plugins/'
}
}
}
stage('llama') {
steps {
script {
sh 'rm -rf /soft/qt-creator-plugins'
sh 'git clone --single-branch --depth 1 https://github.com/cristianadam/llama.qtcreator.git /soft/qt-creator-plugins'
sh 'mkdir -p /soft/qt-creator-plugins/build && rm -rf /soft/qt-creator-plugins/build/*'
sh 'cd /soft/qt-creator-plugins/build && cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake -DCMAKE_INSTALL_PREFIX=/soft/windows/qt-creator -DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 -DQT_HOST_PATH=/soft/qt/gcc_64 -DQtCreator_DIR=/soft/qt-creator_build/cmake ../'
sh 'cd /soft/qt-creator-plugins/build && cmake --build ./ --target install -j${JOBS_COUNT}'
}
}
}
stage('qt-creator-plugins') {
steps {
script {
sh 'rm -rf /soft/qt-creator-plugins'
sh 'git clone -b v18 --single-branch --depth 1 https://git.shstk.ru/SHS/qtcreator.git /soft/qt-creator-plugins'
sh 'mkdir -p /soft/qt-creator-plugins/build && rm -rf /soft/qt-creator-plugins/build/*'
sh 'cd /soft/qt-creator-plugins/build && cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/soft/toolchain-Windows.cmake -DCMAKE_INSTALL_PREFIX=/soft/windows/qt-creator -DCMAKE_PREFIX_PATH=/soft/qt/mingw_64 -DQT_HOST_PATH=/soft/qt/gcc_64 -DQtCreator_DIR=/soft/qt-creator_build/cmake ../project_fs'
sh 'cd /soft/qt-creator-plugins/build && cmake --build ./ --target install -j${JOBS_COUNT}'
}
}
}
stage('deploy') {
steps {
script {
sh 'cd /soft/windows/qt-creator && cp -vfr /soft/qt/mingw_64/plugins ./'
sh 'cd /soft/windows/qt-creator && cp -vfr /soft/qt/gcc_64/plugins/designer/lib*.dll ./plugins/designer/'
sh 'cd /soft/windows/qt-creator && cp -vfr /soft/windows/lang/* ./translations/'
sh 'cd /soft/windows/qt-creator && cp -vfr /soft/qt/mingw_64/bin/* ./bin/'
sh 'cd /soft/windows/qt-creator && cp -vfrL /soft/windows/bin/* ./bin/ && rm -vf ./bin/llvm-*'
sh 'cd /soft/windows/qt-creator && cp -vf /usr/lib/gcc/x86_64-w64-mingw32/14-posix/*.dll ./bin/'
sh 'cd /soft/windows/qt-creator && for f in $(ls ./bin/*); do if [[ $(file -b $f | grep "ELF 64-bit") ]]; then rm -v $f; fi; done'
sh 'cd /soft/windows/qt-creator && zip -qr /soft/qt-creator-19_win_x64.zip *'
sh 'rm ./* || true'
sh 'mv -v /soft/qt-creator-19_win_x64.zip ./'
archiveArtifacts 'qt-creator-*.zip'
}
}
}
}
}
+18
View File
@@ -0,0 +1,18 @@
#! /bin/sh
for file in lib*.so.*; do
if [ -f "$file" ]; then
base_name1="${file%.*}"
base_name2="${base_name1%.*}"
if [ "$base_name1" != "$file" ]; then
ln -sf "$file" "$base_name1"
echo "$base_name1 -> $file"
fi
if [ "$base_name2" != "$base_name1" ]; then
ln -sf "$file" "$base_name2"
echo "$base_name2 -> $file"
fi
fi
done