├── .dockerignore ├── .github └── workflows │ ├── build_bundles.yml │ ├── build_snap.yml │ └── prep_sources.yml ├── .gitignore ├── .hgignore ├── Dockerfile ├── Makefile ├── README.md ├── beremiz_ide.cmd ├── build_docker_image.sh ├── build_in_docker.sh ├── clean_docker_container.sh ├── clean_docker_image.sh ├── create_docker_container.sh ├── distfiles ├── 034d891cc947.zip.md5 ├── M2Crypto-0.22.5.tar.gz.md5 ├── Nevow-0.10.0.tar.gz.md5 ├── Pyro-3.16.tar.gz.md5 ├── Pyro-3.9.1.tar.gz.md5 ├── Twisted-11.0.0.winxp32-py2.7.msi.md5 ├── Twisted-17.9.0-cp27-cp27m-win32.whl.md5 ├── autobahn-17.10.1.tar.gz.md5 ├── bash-3.1.17-3-msys-1.0.13-bin.tar.lzma.md5 ├── bash-3.1.23-1-msys-1.0.18-bin.tar.xz.md5 ├── binutils-2.28-1-mingw32-bin.tar.xz.md5 ├── cffi-1.11.2-cp27-cp27m-win32.whl.md5 ├── characteristic-14.3.0.tar.gz.md5 ├── coreutils-5.97-3-msys-1.0.13-bin.tar.lzma.md5 ├── cryptography-2.1.4-cp27-cp27m-win32.whl.md5 ├── enum34-1.1.6-py2-none-any.whl.md5 ├── enum34-1.1.6.tar.gz.md5 ├── gcc-core-4.6.1-2-mingw32-bin.tar.lzma.md5 ├── gcc-core-6.3.0-1-mingw32-bin.tar.xz.md5 ├── innounp036.rar.md5 ├── libgettextpo-0.17-1-mingw32-dll-0.tar.lzma.md5 ├── libgettextpo-0.18.3.2-2-mingw32-dll-0.tar.xz.md5 ├── libgmp-5.0.1-1-mingw32-dll-10.tar.lzma.md5 ├── libgmp-6.1.2-2-mingw32-dll-10.tar.xz.md5 ├── libiconv-1.13.1-1-mingw32-dll-2.tar.lzma.md5 ├── libiconv-1.13.1-2-msys-1.0.13-bin.tar.lzma.md5 ├── libiconv-1.13.1-2-msys-1.0.13-dll-2.tar.lzma.md5 ├── libiconv-1.14-1-msys-1.0.17-bin.tar.lzma.md5 ├── libiconv-1.14-1-msys-1.0.17-dll-2.tar.lzma.md5 ├── libiconv-1.14-3-mingw32-dll.tar.lzma.md5 ├── libintl-0.17-1-mingw32-dll-8.tar.lzma.md5 ├── libintl-0.17-2-msys-dll-8.tar.lzma.md5 ├── libintl-0.18.1.1-1-msys-1.0.17-dll-8.tar.lzma.md5 ├── libintl-0.18.3.2-2-mingw32-dll-8.tar.xz.md5 ├── libmpc-0.8.1-1-mingw32-dll-2.tar.lzma.md5 ├── libmpc-1.0.3-1-mingw32-dll-3.tar.xz.md5 ├── libmpfr-2.4.1-1-mingw32-dll-1.tar.lzma.md5 ├── libmpfr-3.1.5-1-mingw32-dll-4.tar.xz.md5 ├── libregex-1.20090805-2-msys-1.0.13-dll-1.tar.lzma.md5 ├── libtermcap-0.20050421_1-2-msys-1.0.13-dll-0.tar.lzma.md5 ├── lxml-3.2.3.win32-py2.7.exe.md5 ├── lxml-4.1.1-cp27-cp27m-win32.whl.md5 ├── make-3.81-3-msys-1.0.13-bin.tar.lzma.md5 ├── matplotlib-1.2.0.win32-py2.7.exe.md5 ├── mingwrt-3.20-2-mingw32-dev.tar.lzma.md5 ├── mingwrt-3.20-2-mingw32-dll.tar.lzma.md5 ├── mingwrt-3.20-mingw32-dev.tar.gz.md5 ├── mingwrt-3.20-mingw32-dll.tar.gz.md5 ├── mingwrt-5.0.1-mingw32-dev.tar.xz.md5 ├── mingwrt-5.0.1-mingw32-dll.tar.xz.md5 ├── msys2-base-i686-20210705.tar.xz.md5 ├── msys2-base-x86_64-20230718.tar.xz.md5 ├── msysCORE-1.0.13-2-msys-1.0.13-bin.tar.lzma.md5 ├── msysCORE-1.0.19-1-msys-1.0.19-bin.tar.xz.md5 ├── netifaces-0.10.6-py2.7-win32.egg.md5 ├── numpy-1.13.3-2-cp27-none-win32.whl.md5 ├── numpy-1.6.1.win32-py2.7.exe.md5 ├── openssl-1.0.1p.tar.gz.md5 ├── pacman-6.0.0.tar.xz.md5 ├── pyOpenSSL-17.5.0-py2.py3-none-any.whl.md5 ├── pyasn1-0.4.2.tar.gz.md5 ├── pyasn1-modules-0.2.1.tar.gz.md5 ├── python-2.7.13.msi.md5 ├── python-2.7.2.msi.md5 ├── pywin32-216.win32-py2.7.exe.md5 ├── service_identity-17.0.0.tar.gz.md5 ├── simplejson-2.2.1.tar.gz.md5 ├── six-1.11.0-py2.py3-none-any.whl.md5 ├── txaio-2.8.2.tar.gz.md5 ├── v0.8.3.zip.md5 ├── v1.3.2.tar.gz.md5 ├── v1.3.7.tar.gz.md5 ├── vcredist_x86.exe.md5 ├── w32api-3.17-2-mingw32-dev.tar.lzma.md5 ├── w32api-5.0.1-mingw32-dev.tar.xz.md5 ├── wxPython2.8-win32-unicode-2.8.12.1-py27.exe.md5 ├── wxPython3.0-win32-3.0.2.0-py27.exe.md5 ├── zeroconf-0.19.1-py2.py3-none-any.whl.md5 └── zope.interface-4.3.2-py2.7-win32.egg.md5 ├── enter_docker.sh ├── enter_docker_as_root.sh ├── install.nsi ├── license.txt ├── pacman-6.0.0-nogpg-relative_conf.patch ├── plcopen_editor.cmd ├── provision_noble64.sh ├── rebuild_docker.sh ├── revisions.txt ├── snap.mk ├── snap ├── gui │ ├── beremiz.desktop │ └── beremiz.png └── snapcraft.yaml ├── win32.mk ├── windows_installer.mk └── winpaths.py /.dockerignore: -------------------------------------------------------------------------------- 1 | * 2 | !provision_noble64.sh 3 | -------------------------------------------------------------------------------- /.github/workflows/build_bundles.yml: -------------------------------------------------------------------------------- 1 | name: Build windows installer in Docker 2 | 3 | on: 4 | workflow_dispatch: 5 | # push: 6 | # branches: [ default ] 7 | 8 | jobs: 9 | sources: 10 | uses: ./.github/workflows/prep_sources.yml 11 | 12 | build: 13 | needs: sources 14 | runs-on: ubuntu-latest 15 | 16 | steps: 17 | 18 | - name: Download source artifact 19 | uses: actions/download-artifact@v3 20 | with: 21 | name: source_package 22 | 23 | - name: untar files 24 | run: tar -xvf sources.tar 25 | 26 | - name: Cache docker image 27 | id: cache-docker 28 | uses: actions/cache@v3 29 | env: 30 | cache-name: cache-docker 31 | with: 32 | path: /tmp/latest.tar 33 | key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('beremiz_public_dist/Dockerfile', 'beremiz_public_dist/*.sh') }} 34 | 35 | - if: ${{ steps.cache-docker.outputs.cache-hit == false }} 36 | name: Create docker image 37 | run: | 38 | cd beremiz_public_dist 39 | ./build_docker_image.sh 40 | docker image save --output="/tmp/latest.tar" beremiz_public_builder 41 | 42 | 43 | - if: ${{ steps.cache-docker.outputs.cache-hit == false }} 44 | name: Save docker image in cache 45 | id: cache-docker-save 46 | uses: actions/cache/save@v3 47 | with: 48 | path: /tmp/latest.tar 49 | key: ${{ steps.cache-docker.outputs.cache-primary-key }} 50 | 51 | - if: ${{ steps.cache-docker.outputs.cache-hit != false }} 52 | name: Re-use docker image 53 | run: | 54 | docker image load --input="/tmp/latest.tar" 55 | 56 | - name: Create docker container 57 | run: | 58 | cd beremiz_public_dist 59 | ./create_docker_container.sh ${{ github.workspace }}/build 60 | 61 | - name: Run build in docker 62 | run: | 63 | cd beremiz_public_dist 64 | # override HG revision IDs in Makefile 65 | ./build_in_docker.sh \ 66 | beremiz_revisionid=stamp \ 67 | matiec_revisionid=stamp \ 68 | canfestival_revisionid=stamp \ 69 | Modbus_revisionid=stamp \ 70 | open62541_revisionid=stamp 71 | 72 | - name: Upload built artifact 73 | uses: actions/upload-artifact@v3 74 | with: 75 | name: windows_bundles 76 | path: | 77 | ${{ github.workspace }}/build/Beremiz-*.exe 78 | ${{ github.workspace }}/build/Beremiz-*.zip 79 | retention-days: 5 80 | 81 | -------------------------------------------------------------------------------- /.github/workflows/build_snap.yml: -------------------------------------------------------------------------------- 1 | name: Build Snap 2 | 3 | on: 4 | workflow_dispatch: 5 | # push: 6 | # branches: [ default ] 7 | 8 | jobs: 9 | sources: 10 | uses: ./.github/workflows/prep_sources.yml 11 | 12 | build: 13 | needs: sources 14 | runs-on: ubuntu-latest 15 | 16 | steps: 17 | 18 | - name: Download source artifact 19 | uses: actions/download-artifact@v3 20 | with: 21 | name: source_package 22 | 23 | - name: untar files 24 | run: tar -xvf sources.tar 25 | 26 | - name: Move snap dir and revisions.txt in build/sources 27 | run: | 28 | mv beremiz_public_dist/snap build/sources 29 | mv build/revisions.txt build/sources/revisions.txt 30 | 31 | - name: Invoke snapcraft build 32 | uses: snapcore/action-build@v1 33 | id: snapcraft 34 | with: 35 | path: build/sources 36 | 37 | - name: Upload built artifact 38 | uses: actions/upload-artifact@v3 39 | with: 40 | name: snap 41 | path: ${{ steps.snapcraft.outputs.snap }} 42 | 43 | 44 | -------------------------------------------------------------------------------- /.github/workflows/prep_sources.yml: -------------------------------------------------------------------------------- 1 | name: Prepare sources 2 | 3 | on: 4 | workflow_call: 5 | 6 | 7 | jobs: 8 | get_sources: 9 | runs-on: ubuntu-latest 10 | 11 | env: 12 | beremiz_revisionid: 34d4c77ccb1bcb14601ab347ec6080466b7e143d 13 | matiec_revisionid: d3196244bf50b2d6d512a0240e10dfa75edbeb7b 14 | canfestival_revisionid: 12a05e422666c738d1312259703f80150c747cb5 15 | Modbus_revisionid: 4d7d67a8e911d744165709c20a254b5cb924ec71 16 | # v1.3.7 17 | open62541_revisionid: b8ac9e77f703e6ba5c012b886a8821037503daa6 18 | 19 | 20 | steps: 21 | - uses: actions/checkout@v3 22 | with: 23 | path: beremiz_public_dist 24 | 25 | # repositories are directly checked out where Makerfile expects them to be 26 | - uses: actions/checkout@v3 27 | with: 28 | repository: beremiz/beremiz 29 | ref: ${{ env.beremiz_revisionid }} 30 | path: build/sources/beremiz 31 | 32 | - uses: actions/checkout@v3 33 | with: 34 | repository: beremiz/matiec 35 | ref: ${{ env.matiec_revisionid }} 36 | path: build/sources/matiec 37 | 38 | - uses: actions/checkout@v3 39 | with: 40 | repository: beremiz/canfestival 41 | ref: ${{ env.canfestival_revisionid }} 42 | path: build/sources/canfestival 43 | 44 | - uses: actions/checkout@v3 45 | with: 46 | repository: beremiz/Modbus 47 | ref: ${{ env.Modbus_revisionid }} 48 | path: build/sources/Modbus 49 | 50 | - uses: actions/checkout@v3 51 | with: 52 | repository: open62541/open62541 53 | ref: ${{ env.open62541_revisionid }} 54 | path: build/sources/open62541 55 | 56 | - name: Keep Makfile satisfied and generate revisions.txt 57 | run: | 58 | touch build/sources/beremiz_stamp 59 | touch build/sources/matiec_stamp 60 | touch build/sources/canfestival_stamp 61 | touch build/sources/Modbus_stamp 62 | touch build/sources/open62541_stamp 63 | touch build/sources/beremiz_src 64 | touch build/sources/matiec_src 65 | touch build/sources/canfestival_src 66 | touch build/sources/Modbus_src 67 | touch build/sources/open62541_src 68 | touch build/own_sources 69 | cat >> build/revisions.txt < /usr/local/bin/build 29 | RUN chmod +x /usr/local/bin/build 30 | 31 | USER $UNAME 32 | 33 | RUN mkdir /home/$UNAME/build /home/$UNAME/src 34 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | #! gmake 2 | 3 | # This is top level Makefile for beremiz_public_dist 4 | 5 | # see also: 6 | # build_in_docker.sh : use case example 7 | # provision_*.sh : prerequisites 8 | 9 | all: main_target 10 | 11 | DIST ?= win32 12 | 13 | src := $(abspath $(dir $(lastword $(MAKEFILE_LIST)))) 14 | WORKSPACE ?= $(abspath $(src)/..) 15 | CPUS := `cat /proc/cpuinfo | grep -e 'processor\W*:\W*[[:digit:]]*' | nl -n ln | tail -n1 | cut -f1` 16 | 17 | distfiles = $(src)/distfiles 18 | sfmirror = downloads 19 | tmp := $(shell rm -rf $${TMPDIR:-/tmp}/beremiz_dist_build_tmp.* ; mktemp -d -t beremiz_dist_build_tmp.XXXXXXXXXX) 20 | 21 | define hg_get_archive 22 | hg -R $(WORKSPACE)/`basename $(1)` archive $(2) $(1);\ 23 | hg -R $(WORKSPACE)/`basename $(1)` id -i | sed 's/\+//' > $(1)/revision; 24 | endef 25 | 26 | define get_src_hg 27 | rm -rf $(1);\ 28 | $(call hg_get_archive, $(1), $(2)) 29 | endef 30 | 31 | define get_src_git 32 | endef 33 | 34 | define get_src_http 35 | dld=$(distfiles)/`echo $(2) | tr ' ()' '___'`;( ( [ -f $$dld ] || wget $(1)/$(2) -O $$dld ) && ( [ ! -f $$dld.md5 ] && (cd $(distfiles);md5sum `basename $$dld`) > $$dld.md5 || (cd $(distfiles);md5sum -c `basename $$dld.md5`) ) ) && 36 | endef 37 | 38 | ifneq ("$(DIST)","") 39 | include $(src)/$(DIST).mk 40 | endif 41 | 42 | FROM_SOURCE_PROJECTS=beremiz matiec $(DIST_FROM_SOURCE_PROJECTS) 43 | 44 | define get_revision 45 | $(1)_revision?=$(lastword $(shell grep $(1) $(src)/revisions.txt)) 46 | endef 47 | $(foreach project,$(FROM_SOURCE_PROJECTS),$(eval $(call get_revision,$(project)))) 48 | 49 | tar_opts=--absolute-names --exclude=.hg --exclude=.git --exclude=.*.pyc --exclude=.*.swp --exclude=__pycache__ 50 | 51 | define get_revisionid 52 | $(1)_revisionid ?=\ 53 | $(if $(filter local, $($(1)_revision)),\ 54 | $(shell tar $(tar_opts) -P -c $(WORKSPACE)/$(1) | sha1sum | cut -d ' ' -f 1),\ 55 | $(1)_revisionid?=$$(shell hg -R $(WORKSPACE)/$(1) id -i -r $($(1)_revision))) 56 | endef 57 | $(foreach project,$(FROM_SOURCE_PROJECTS),$(eval $(call get_revisionid,$(project)))) 58 | 59 | sources: 60 | mkdir -p sources 61 | 62 | define make_src_rule 63 | sources/$(1)_src: sources/$(1)_$($(1)_revisionid) 64 | touch $$@ 65 | 66 | sources/$(1)_$($(1)_revisionid): | sources 67 | rm -rf sources/$(1)* 68 | ifeq ($($(1)_revision),local) 69 | echo "Copy local source code for $(1)_$($(1)_revisionid)" 70 | tar -C $(WORKSPACE) $(tar_opts) -P -c $(1) | tar -C sources -x 71 | else 72 | echo "Checkout HG source $(1)_$($(1)_revisionid)" 73 | $(call get_src_hg,sources/$(1),-r $($(1)_revisionid)) 74 | endif 75 | touch $$@ 76 | endef 77 | $(foreach project,$(FROM_SOURCE_PROJECTS),$(eval $(call make_src_rule,$(project)))) 78 | 79 | own_sources: $(foreach project,$(FROM_SOURCE_PROJECTS), sources/$(project)_src) 80 | touch $@ 81 | 82 | all_sources: own_sources sources/open62541_src 83 | touch $@ 84 | 85 | sources/open62541_src: | sources 86 | rm -rf sources/open62541 87 | $(call get_src_http,https://github.com/open62541/open62541/archive/refs/tags,v1.3.7.tar.gz)\ 88 | tar -xzf $$dld 89 | mv open62541-1.3.7 sources/open62541 90 | 91 | 92 | define show_revision_details 93 | $(if $(filter local, $($(1)_revision)),\ 94 | echo -n $(1) "state is: "; test -d .hg \ 95 | && (hg -R $(WORKSPACE)/$(1) id; echo; hg -R $(WORKSPACE)/$(1) st) \ 96 | || (git -C $(WORKSPACE)/$(1) show --pretty=format:'%P' -s; echo; git -C $(WORKSPACE)/$(1) status --porcelain);,\ 97 | echo -n $(1) "revision is: "; hg -R $(WORKSPACE)/$(1) id -r $($(1)_revisionid); ) 98 | endef 99 | 100 | revisions.txt: $(src)/revisions.txt own_sources 101 | echo "Generate revisions.txt" 102 | echo "\n******* PACKAGE REVISIONS ********\n" > revisions.txt 103 | (echo -n "beremiz_public_dist revision is: "; test -d .hg && (hg -R $(src) id ; echo; hg -R $(src) st) || (git -C $(src) show --pretty=format:'%P' -s; echo; git -C $(src) status --porcelain)) >> revisions.txt 104 | ($(foreach project,$(FROM_SOURCE_PROJECTS),$(call show_revision_details,$(project)))) >> revisions.txt 105 | 106 | 107 | 108 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Beremiz public distribution # 2 | 3 | This repository holds recipes and patches to build the Beremiz 4 | packages and installers for [Beremiz website](http://beremiz.org/). 5 | 6 | Patches have same license as projects being patched. For other files, 7 | unless made explicit in file header, GPLv3 applies. 8 | 9 | ## Use cases ## 10 | 11 | Beremiz development uses Mercurial, but git repositories that are kept in sync. 12 | 13 | Build from both Mercurial and Git repositories is supported. 14 | 15 | ### GitHub CI ## 16 | 17 | Use code from https://github.com/beremiz repositories. 18 | 19 | Workflows described in .github/workflows are meant to run on a GitHub runner. Please refer to GitHub documentation to run workflows on your own fork. 20 | 21 | Dockerfile and part of Makefiles are used for windows installer build, but for Snap build, only snapcraft.yaml is used. 22 | 23 | ### Manual build ### 24 | 25 | Use code from your local Mercurial repositories, cloned from https://hg.beremiz.org 26 | 27 | Uses Makefiles and Dockerfile to build windows installer and Makefile+snapcraft.yaml for Snap package. 28 | 29 | Hereafter is documented how to use Makefile and Docker in case of Manual Build 30 | 31 | ## Prerequisites ## 32 | 33 | A usable Docker is required. Docker is used to ensure a reproducible build 34 | environment. 35 | 36 | Other containerization/virtualization could be used to achieve the same effect. 37 | 38 | Reference build environment is obtained by applying [provision_focal64.sh](provision_focal64.sh) on Ubuntu 20.04 amd64. 39 | 40 | ## Preparing source ## 41 | 42 | The top Makefile expects source code of Beremiz, Matiec and CanFestival to be 43 | sibling to beremiz_public_dist directory, in the 'source directory'. 44 | For example : 45 | 46 | ``` 47 | ~/src 48 | /beremiz 49 | /beremiz_public_dist 50 | /matiec 51 | /canfestival [optional] 52 | /Modbus [optional] 53 | /open62541 [optional] 54 | ``` 55 | 56 | Repositories can be cloned from https://hg.beremiz.org . 57 | 58 | Intermediate and final results are all placed in a single 'build directory' 59 | during build process. 60 | 61 | ## Windows installer Build ## 62 | 63 | ### Prepare Docker image ### 64 | 65 | The script [rebuild_docker.sh](rebuild_docker.sh) is used for that purpose. 66 | 67 | Synopsis: 68 | 69 | ./rebuild_docker.sh [build directory] 70 | 71 | 72 | Source and Build Volumes : 73 | 74 | Role | Docker Volume | Host path in example | Rationale 75 | ------------------|-------------------|----------------------|------------------------------------------------ 76 | source directory | /home/runner/src | ~/src | Always relative to CWD : "../" 77 | build directory | /home/runner/build | ~/build | First argument to rebuild_docker.sh or ~/build 78 | 79 | 'build directory' can be specified as absolute path argument of rebuild_docker.sh. 80 | If not specified it defaults to ~/build 81 | 82 | ``` 83 | #!sh 84 | ./rebuild_docker.sh ~/build_next 85 | ``` 86 | 87 | Note: 'build directory' is created if not already existing. 88 | 89 | ### Build Windows Installer ### 90 | 91 | The script [build_in_docker.sh](build_in_docker.sh) is used for that purpose. 92 | 93 | ``` 94 | #!sh 95 | ./build_in_docker.sh 96 | ``` 97 | 98 | Note: 'build directory' must exist before calling build_in_docker.sh, otherwise 99 | Docker will create it as root user. Be sure to create it again if you delete it. 100 | 101 | Resulting installer is Beremiz-${timestamp}.exe in 'build directory'. 102 | 103 | ### Manhole ### 104 | 105 | Once Docker image ready, the scripts [enter_docker.sh](enter_docker.sh) and 106 | [enter_docker_as_root.sh](enter_docker_as_root.sh) let you issue build 107 | commands, or install additional packages. 108 | 109 | [clean_docker_container.sh](clean_docker_container.sh) and [create_docker_container.sh](create_docker_container.sh) and 110 | [clean_docker_image.sh](clean_docker_image.sh) and [build_docker_image.sh](build_docker_image.sh) are invoked by 111 | [rebuild_docker.sh](rebuild_docker.sh). 112 | 113 | ## Snap Package Build ## 114 | 115 | snapcraft.yaml does not rely on HG or GIT repos, but refers to local sources, this is responsibility of caller to prepare sources for snapcraft. 116 | 117 | Reasons for this are : 118 | - no parameters or conditional variables exist to tell snapcraft.yaml where to get the source from 119 | - building from local source should be always possible 120 | - revisions.txt must be updated in any case so that it is always possible to know what version was used to build resulting package 121 | - when Snap is built from GitHub actions, Makefile isn't used at all, and GitHub action workflow organize sources and revisions.txt on its own. 122 | 123 | In the end, instead of just calling `snapcraft` to get a snap package, it is more complicated: 124 | 125 | ``` 126 | # assuming source repositories are cloned in ~/src 127 | # and build happens in ~/build 128 | 129 | cd ~/build 130 | make -f ~/src/beremiz_public_dist/Makefile DIST=snap 131 | 132 | ``` 133 | Resulting snap package is sources/beremiz_${version}_${platform}.snap. 134 | It can be installed this way: 135 | 136 | ``` 137 | sudo snap install sources/beremiz_1.4-beta2_amd64.snap --dangerous --devmode 138 | ``` 139 | 140 | -------------------------------------------------------------------------------- /beremiz_ide.cmd: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal 3 | 4 | rem Get the directory of the current script 5 | set "script_dir=%~dp0" 6 | 7 | rem Set the path to the executable relative to the script directory 8 | set "python_exe=%script_dir%\$MSYS_DIR\$MSYS_ENV_DIR\bin\pythonw.exe" 9 | set "beremiz_py=%script_dir%\Beremiz\Beremiz.py" 10 | 11 | set MSYSTEM=$MSYSTEM 12 | 13 | rem Launch the executable with winpaths extension added to the command line arguments 14 | start "Beremiz IDE" /d %HOMEDRIVE%%HOMEPATH% "%python_exe%" "%beremiz_py%" -e "%script_dir%\winpaths.py" %* 15 | 16 | endlocal -------------------------------------------------------------------------------- /build_docker_image.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | OWNDIRBASENAME=$(basename $(cd $(dirname "${BASH_SOURCE[0]}") && pwd)) 6 | 7 | echo "Building docker image" 8 | docker build \ 9 | --build-arg UID=$(id -u) \ 10 | --build-arg GID=$(id -g) \ 11 | --build-arg OWNDIRBASENAME="$OWNDIRBASENAME" \ 12 | -t beremiz_public_builder . 13 | 14 | -------------------------------------------------------------------------------- /build_in_docker.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | CONTAINER=beremiz_public_builder_current 4 | 5 | docker start $CONTAINER 6 | echo exec docker with $* 7 | docker exec $CONTAINER bash -c "build $*" 8 | docker stop $CONTAINER 9 | 10 | -------------------------------------------------------------------------------- /clean_docker_container.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # delete container 4 | docker rm beremiz_public_builder_current 5 | 6 | -------------------------------------------------------------------------------- /clean_docker_image.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # delete image 4 | docker rmi beremiz_public_builder 5 | 6 | -------------------------------------------------------------------------------- /create_docker_container.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | # absolute path to directory containing parent directory of that script 6 | # (i.e. source directory containing beremiz, matiec, etc..) 7 | SRCDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" 8 | echo "SOURCE direcory : $SRCDIR" 9 | 10 | # absolute path to build directory. ~/build if not given as only argument 11 | BUILDDIR=${1:-~/build} 12 | mkdir -p $BUILDDIR 13 | echo "BUILD direcory : $BUILDDIR" 14 | 15 | UNAME=runner 16 | UHOME=/home/$UNAME 17 | 18 | echo "Creating docker container" 19 | docker create \ 20 | --name beremiz_public_builder_current \ 21 | -v $SRCDIR:$UHOME/src \ 22 | -v $BUILDDIR:$UHOME/build \ 23 | -v /tmp/.X11-unix/X0:/tmp/.X11-unix/X0 \ 24 | -w $UHOME/build \ 25 | -i -t beremiz_public_builder /bin/bash 26 | -------------------------------------------------------------------------------- /distfiles/034d891cc947.zip.md5: -------------------------------------------------------------------------------- 1 | 46fac34fd7a93b46aafb08fd37590aa8 034d891cc947.zip 2 | -------------------------------------------------------------------------------- /distfiles/M2Crypto-0.22.5.tar.gz.md5: -------------------------------------------------------------------------------- 1 | f84eb07aa1687f39bc26ee7b1ba5a105 M2Crypto-0.22.5.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/Nevow-0.10.0.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 66dda2ad88f42dea05911add15f4d1b2 Nevow-0.10.0.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/Pyro-3.16.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 59d4d3f4a8786776c9d7f9051b8f1a69 Pyro-3.16.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/Pyro-3.9.1.tar.gz.md5: -------------------------------------------------------------------------------- 1 | fd2fb19d5690825690e1b962a50afdc9 Pyro-3.9.1.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/Twisted-11.0.0.winxp32-py2.7.msi.md5: -------------------------------------------------------------------------------- 1 | edc63d41222fdb9ef4545ee33931eca0 Twisted-11.0.0.winxp32-py2.7.msi 2 | -------------------------------------------------------------------------------- /distfiles/Twisted-17.9.0-cp27-cp27m-win32.whl.md5: -------------------------------------------------------------------------------- 1 | 066c8a53a0bf946d1ecf60aa9bd61f69 Twisted-17.9.0-cp27-cp27m-win32.whl 2 | -------------------------------------------------------------------------------- /distfiles/autobahn-17.10.1.tar.gz.md5: -------------------------------------------------------------------------------- 1 | f8c8d74bf73644719b751e6fb11dc4a3 autobahn-17.10.1.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/bash-3.1.17-3-msys-1.0.13-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 8872b0b88a0626c24a9dc65983b1a7e2 bash-3.1.17-3-msys-1.0.13-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/bash-3.1.23-1-msys-1.0.18-bin.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 53043793a56815ee69d42f13e686502d bash-3.1.23-1-msys-1.0.18-bin.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/binutils-2.28-1-mingw32-bin.tar.xz.md5: -------------------------------------------------------------------------------- 1 | d9ede5b43ac380c342a95e68434d9957 binutils-2.28-1-mingw32-bin.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/cffi-1.11.2-cp27-cp27m-win32.whl.md5: -------------------------------------------------------------------------------- 1 | d7154640e957a27bc4b764f349a25ea4 cffi-1.11.2-cp27-cp27m-win32.whl 2 | -------------------------------------------------------------------------------- /distfiles/characteristic-14.3.0.tar.gz.md5: -------------------------------------------------------------------------------- 1 | b249368dd021fde1c06b4802867c0913 characteristic-14.3.0.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/coreutils-5.97-3-msys-1.0.13-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 1fdbbeba10b5c17222f98d867814e9cd coreutils-5.97-3-msys-1.0.13-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/cryptography-2.1.4-cp27-cp27m-win32.whl.md5: -------------------------------------------------------------------------------- 1 | 0f0a959be72586e76ce0b6f1135918fa cryptography-2.1.4-cp27-cp27m-win32.whl 2 | -------------------------------------------------------------------------------- /distfiles/enum34-1.1.6-py2-none-any.whl.md5: -------------------------------------------------------------------------------- 1 | 68f6982cc07dde78f4b500db829860bd enum34-1.1.6-py2-none-any.whl 2 | -------------------------------------------------------------------------------- /distfiles/enum34-1.1.6.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 5f13a0841a61f7fc295c514490d120d0 enum34-1.1.6.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/gcc-core-4.6.1-2-mingw32-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 4c32ce090586e4fd3ca85028a8f8309b gcc-core-4.6.1-2-mingw32-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/gcc-core-6.3.0-1-mingw32-bin.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 1cfe1fdee114eef48fdd73152d86359f gcc-core-6.3.0-1-mingw32-bin.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/innounp036.rar.md5: -------------------------------------------------------------------------------- 1 | 414fde4c67f5fd86941d2fab50becf32 innounp036.rar 2 | -------------------------------------------------------------------------------- /distfiles/libgettextpo-0.17-1-mingw32-dll-0.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | ddcd7c17ddfe6f2fe8cb4bb244fed197 libgettextpo-0.17-1-mingw32-dll-0.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libgettextpo-0.18.3.2-2-mingw32-dll-0.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 947791bab6222a5235d22eaa08abae02 libgettextpo-0.18.3.2-2-mingw32-dll-0.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/libgmp-5.0.1-1-mingw32-dll-10.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 5429715e4788eab934229d3941efc2dc libgmp-5.0.1-1-mingw32-dll-10.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libgmp-6.1.2-2-mingw32-dll-10.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 42272c91de90179a88d96a883c90fe6f libgmp-6.1.2-2-mingw32-dll-10.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.13.1-1-mingw32-dll-2.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | df315275e770cc6c232ee5de6bfa5d85 libiconv-1.13.1-1-mingw32-dll-2.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.13.1-2-msys-1.0.13-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 8fa36ac50edeae7f1ebb5ef820b6a3e4 libiconv-1.13.1-2-msys-1.0.13-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.13.1-2-msys-1.0.13-dll-2.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 576a7971950f256f51558fa465ae364b libiconv-1.13.1-2-msys-1.0.13-dll-2.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.14-1-msys-1.0.17-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 6b6f6d7d5b65bed9163324e73bdd6e28 libiconv-1.14-1-msys-1.0.17-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.14-1-msys-1.0.17-dll-2.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 6ffa2b9fdb3711582d6a99bab4389de6 libiconv-1.14-1-msys-1.0.17-dll-2.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libiconv-1.14-3-mingw32-dll.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 8681a7ccae5834d9e1f81284de3fb29e libiconv-1.14-3-mingw32-dll.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libintl-0.17-1-mingw32-dll-8.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 3eb8590e4caddc037f21f6148aa42a09 libintl-0.17-1-mingw32-dll-8.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libintl-0.17-2-msys-dll-8.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 236dd344ed4a671707e8fe40bd8ec944 libintl-0.17-2-msys-dll-8.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libintl-0.18.1.1-1-msys-1.0.17-dll-8.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 8d3561e8f94acfe0b9139aa658bb5e34 libintl-0.18.1.1-1-msys-1.0.17-dll-8.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libintl-0.18.3.2-2-mingw32-dll-8.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 0721c923462f175edf6238ccbaa55978 libintl-0.18.3.2-2-mingw32-dll-8.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/libmpc-0.8.1-1-mingw32-dll-2.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | a4e341b0cd1d407d8c03cacc715088f7 libmpc-0.8.1-1-mingw32-dll-2.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libmpc-1.0.3-1-mingw32-dll-3.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 6399bf33822bdc727c0b824918657610 libmpc-1.0.3-1-mingw32-dll-3.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/libmpfr-2.4.1-1-mingw32-dll-1.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | f7341132ca48b4cfa01446b8a561342f libmpfr-2.4.1-1-mingw32-dll-1.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libmpfr-3.1.5-1-mingw32-dll-4.tar.xz.md5: -------------------------------------------------------------------------------- 1 | b749fb6c64e0853eb079c46dd277075b libmpfr-3.1.5-1-mingw32-dll-4.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/libregex-1.20090805-2-msys-1.0.13-dll-1.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | b928aed6d689cb57283b2520607e5eca libregex-1.20090805-2-msys-1.0.13-dll-1.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/libtermcap-0.20050421_1-2-msys-1.0.13-dll-0.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 9ba68b4ccdcb751f4f60f9d289ebd2f8 libtermcap-0.20050421_1-2-msys-1.0.13-dll-0.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/lxml-3.2.3.win32-py2.7.exe.md5: -------------------------------------------------------------------------------- 1 | 14ab978b7f0a3382719b65a1ca938d33 lxml-3.2.3.win32-py2.7.exe 2 | -------------------------------------------------------------------------------- /distfiles/lxml-4.1.1-cp27-cp27m-win32.whl.md5: -------------------------------------------------------------------------------- 1 | a983cad1d9429cb35c26b8e963c3324e lxml-4.1.1-cp27-cp27m-win32.whl 2 | -------------------------------------------------------------------------------- /distfiles/make-3.81-3-msys-1.0.13-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 4fe6fe4dd974c73803413a44bbd9bb1d make-3.81-3-msys-1.0.13-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/matplotlib-1.2.0.win32-py2.7.exe.md5: -------------------------------------------------------------------------------- 1 | d8ad635cf5e4b54986be61180955c62e matplotlib-1.2.0.win32-py2.7.exe 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-3.20-2-mingw32-dev.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 1da321aa03a810616de1c59c516b9f9c mingwrt-3.20-2-mingw32-dev.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-3.20-2-mingw32-dll.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | dd3fdb516bc191a6afcbb60c41f2f3fb mingwrt-3.20-2-mingw32-dll.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-3.20-mingw32-dev.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 2d2f5c8165ff9c29661a5be96336a4f7 mingwrt-3.20-mingw32-dev.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-3.20-mingw32-dll.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 9115617aad0cab7fdfa124d2a9c59552 mingwrt-3.20-mingw32-dll.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-5.0.1-mingw32-dev.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 2c6dd5cfe83d415e6355a493ff8a5ab4 mingwrt-5.0.1-mingw32-dev.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/mingwrt-5.0.1-mingw32-dll.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 7ccecfda7883b0a3f78f154a0260001c mingwrt-5.0.1-mingw32-dll.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/msys2-base-i686-20210705.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 1b69961d9ff13cbace8036bc04eae28a msys2-base-i686-20210705.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/msys2-base-x86_64-20230718.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 27ecf0d49d5fe293e4372e7d7f6d5e8b msys2-base-x86_64-20230718.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/msysCORE-1.0.13-2-msys-1.0.13-bin.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | 5fed039c5982bab48cf658b992755368 msysCORE-1.0.13-2-msys-1.0.13-bin.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/msysCORE-1.0.19-1-msys-1.0.19-bin.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 07035115c5ea57c3aae81df1b676f2c0 msysCORE-1.0.19-1-msys-1.0.19-bin.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/netifaces-0.10.6-py2.7-win32.egg.md5: -------------------------------------------------------------------------------- 1 | adcc1bfae02e1373a7539c16ba4aeed2 netifaces-0.10.6-py2.7-win32.egg 2 | -------------------------------------------------------------------------------- /distfiles/numpy-1.13.3-2-cp27-none-win32.whl.md5: -------------------------------------------------------------------------------- 1 | 53600ccf171825920dddf0e9a1d9e0c8 numpy-1.13.3-2-cp27-none-win32.whl 2 | -------------------------------------------------------------------------------- /distfiles/numpy-1.6.1.win32-py2.7.exe.md5: -------------------------------------------------------------------------------- 1 | 30bec16292be262bd78ff1878a7d8953 numpy-1.6.1.win32-py2.7.exe 2 | -------------------------------------------------------------------------------- /distfiles/openssl-1.0.1p.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 7563e92327199e0067ccd0f79f436976 openssl-1.0.1p.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/pacman-6.0.0.tar.xz.md5: -------------------------------------------------------------------------------- 1 | d68ce8f9cc69fb58d2ee3a932b9df6d5 pacman-6.0.0.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/pyOpenSSL-17.5.0-py2.py3-none-any.whl.md5: -------------------------------------------------------------------------------- 1 | 487aa7248e7389c2abd05c212cf6872a pyOpenSSL-17.5.0-py2.py3-none-any.whl 2 | -------------------------------------------------------------------------------- /distfiles/pyasn1-0.4.2.tar.gz.md5: -------------------------------------------------------------------------------- 1 | cb5883ddc6a9f405600429f37cf0759c pyasn1-0.4.2.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/pyasn1-modules-0.2.1.tar.gz.md5: -------------------------------------------------------------------------------- 1 | ff938698590f314ff9b3d5c48737d899 pyasn1-modules-0.2.1.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/python-2.7.13.msi.md5: -------------------------------------------------------------------------------- 1 | 0f057ab4490e63e528eaa4a70df711d9 python-2.7.13.msi 2 | -------------------------------------------------------------------------------- /distfiles/python-2.7.2.msi.md5: -------------------------------------------------------------------------------- 1 | 44c8bbe92b644d78dd49e18df354386f python-2.7.2.msi 2 | -------------------------------------------------------------------------------- /distfiles/pywin32-216.win32-py2.7.exe.md5: -------------------------------------------------------------------------------- 1 | 042a633e727bf8e1a899a94abf45be01 pywin32-216.win32-py2.7.exe 2 | -------------------------------------------------------------------------------- /distfiles/service_identity-17.0.0.tar.gz.md5: -------------------------------------------------------------------------------- 1 | f509cb41ca2f8420bd8496291136d6cc service_identity-17.0.0.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/simplejson-2.2.1.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 070c6467462bd63306f1756b01df6d70 simplejson-2.2.1.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/six-1.11.0-py2.py3-none-any.whl.md5: -------------------------------------------------------------------------------- 1 | 866ab722be6bdfed6830f3179af65468 six-1.11.0-py2.py3-none-any.whl 2 | -------------------------------------------------------------------------------- /distfiles/txaio-2.8.2.tar.gz.md5: -------------------------------------------------------------------------------- 1 | a20e3431c95896a49fa3ffa84f77cde1 txaio-2.8.2.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/v0.8.3.zip.md5: -------------------------------------------------------------------------------- 1 | b02cbf378f3d14f929afea43302feb6f v0.8.3.zip 2 | -------------------------------------------------------------------------------- /distfiles/v1.3.2.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 9fecf3e64983e372f4c20066180829ea v1.3.2.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/v1.3.7.tar.gz.md5: -------------------------------------------------------------------------------- 1 | 5d79dfd16940aab816816beb9aaac262 v1.3.7.tar.gz 2 | -------------------------------------------------------------------------------- /distfiles/vcredist_x86.exe.md5: -------------------------------------------------------------------------------- 1 | b936f0f378b9a35489353e878154e899 vcredist_x86.exe 2 | -------------------------------------------------------------------------------- /distfiles/w32api-3.17-2-mingw32-dev.tar.lzma.md5: -------------------------------------------------------------------------------- 1 | c3a86ffa6b8c21de868df54e4e38f05e w32api-3.17-2-mingw32-dev.tar.lzma 2 | -------------------------------------------------------------------------------- /distfiles/w32api-5.0.1-mingw32-dev.tar.xz.md5: -------------------------------------------------------------------------------- 1 | 4cd1e3342a047dbc00cce21bc231f21a w32api-5.0.1-mingw32-dev.tar.xz 2 | -------------------------------------------------------------------------------- /distfiles/wxPython2.8-win32-unicode-2.8.12.1-py27.exe.md5: -------------------------------------------------------------------------------- 1 | 895ba07ea6c05fcdbc273a921bad787b wxPython2.8-win32-unicode-2.8.12.1-py27.exe 2 | -------------------------------------------------------------------------------- /distfiles/wxPython3.0-win32-3.0.2.0-py27.exe.md5: -------------------------------------------------------------------------------- 1 | c0119e46357dcfc480d50825c64a90c2 wxPython3.0-win32-3.0.2.0-py27.exe 2 | -------------------------------------------------------------------------------- /distfiles/zeroconf-0.19.1-py2.py3-none-any.whl.md5: -------------------------------------------------------------------------------- 1 | 27cb34c684aa2c6ed5b66279d8d81082 zeroconf-0.19.1-py2.py3-none-any.whl 2 | -------------------------------------------------------------------------------- /distfiles/zope.interface-4.3.2-py2.7-win32.egg.md5: -------------------------------------------------------------------------------- 1 | f011c5fbd4c2e0f21df80afb52c833c3 zope.interface-4.3.2-py2.7-win32.egg 2 | -------------------------------------------------------------------------------- /enter_docker.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | CNT=beremiz_public_builder_current 4 | 5 | docker start -i $CNT 6 | -------------------------------------------------------------------------------- /enter_docker_as_root.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | CONTAINER=beremiz_public_builder_current 4 | 5 | docker start $CONTAINER 6 | docker exec -i -t -u root $CONTAINER bash 7 | docker stop $CONTAINER 8 | -------------------------------------------------------------------------------- /install.nsi: -------------------------------------------------------------------------------- 1 | 2 | SetCompressor /SOLID /FINAL lzma 3 | ;SetCompress off 4 | SetDatablockOptimize off 5 | 6 | !include MUI2.nsh 7 | ;!include LogicLib.nsh 8 | !include x64.nsh 9 | 10 | 11 | ; MUI Settings 12 | !define MUI_ICON "installer\beremiz\images\brz.ico" 13 | !define MUI_HEADERIMAGE 14 | !define MUI_HEADERIMAGE_BITMAP "${NSISDIR}\Contrib\Graphics\Header\nsis.bmp" ; optional 15 | !define MUI_ABORTWARNING 16 | 17 | ; Documentation 18 | !insertmacro MUI_PAGE_WELCOME 19 | !define MUI_LICENSEPAGE_CHECKBOX 20 | !insertmacro MUI_PAGE_LICENSE "installer/license.txt" 21 | !insertmacro MUI_PAGE_DIRECTORY 22 | !insertmacro MUI_PAGE_INSTFILES 23 | !insertmacro MUI_PAGE_FINISH 24 | 25 | !insertmacro MUI_UNPAGE_CONFIRM 26 | !insertmacro MUI_UNPAGE_INSTFILES 27 | 28 | !insertmacro MUI_LANGUAGE "English" 29 | 30 | Name "Beremiz $BVERSION" 31 | OutFile "Beremiz-nsis-installer.exe" 32 | InstallDir "$PROGRAMFILES64\Beremiz" 33 | 34 | Section "Beremiz" 35 | SetOutPath $INSTDIR 36 | ${If} ${IsNativeAMD64} 37 | File /r /x debian /x *.pyc "installer/*" 38 | ${Else} 39 | Abort "Unsupported CPU architecture!" 40 | ${EndIf} 41 | SectionEnd 42 | 43 | Section "Install" 44 | SetRegView 64 45 | ;Store installation folder 46 | WriteRegStr HKCU "Software\Beremiz" "" $INSTDIR 47 | ;Create uninstaller 48 | WriteUninstaller "$INSTDIR\Uninstall.exe" 49 | WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" "Contact" "contact@beremiz.fr" 50 | WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" "DisplayName" "Beremiz" 51 | WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" "Publisher" "Beremiz" 52 | WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" "URLInfoAbout" "http://www.beremiz.org" 53 | WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" "UninstallString" "$INSTDIR\uninstall.exe" 54 | SectionEnd 55 | 56 | Section "Shortcuts" 57 | SetShellVarContext all 58 | CreateDirectory "$SMPROGRAMS\Beremiz" 59 | SetOutPath "%HOMEDRIVE%%HOMEPATH%" 60 | CreateShortCut "$SMPROGRAMS\Beremiz\PlcopenEditor.lnk" "$INSTDIR\plcopen_editor.cmd" "" "$INSTDIR\beremiz\images\poe.ico" "" SW_SHOWMINIMIZED 61 | CreateShortCut "$SMPROGRAMS\Beremiz\Beremiz.lnk" "$INSTDIR\beremiz_ide.cmd" "" "$INSTDIR\beremiz\images\brz.ico" "" SW_SHOWMINIMIZED 62 | CreateShortCut "$SMPROGRAMS\Beremiz\Uninstall.lnk" "$INSTDIR\uninstall.exe" 63 | SectionEnd 64 | 65 | Section "Uninstall" 66 | SetRegView 64 67 | SetShellVarContext all 68 | Delete "$INSTDIR\Uninstall.exe" 69 | Delete "$SMPROGRAMS\Beremiz\PlcopenEditor.lnk" 70 | Delete "$SMPROGRAMS\Beremiz\Beremiz.lnk" 71 | RMDir /R "$SMPROGRAMS\Beremiz" 72 | RMDir /R "$INSTDIR" 73 | DeleteRegKey /ifempty HKCU "Software\Beremiz" 74 | DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Beremiz" 75 | SetShellVarContext current 76 | SectionEnd 77 | -------------------------------------------------------------------------------- /license.txt: -------------------------------------------------------------------------------- 1 | Beremiz $BVERSION 2 | http://www.beremiz.org 3 | 4 | License, Use and Redistribution 5 | 6 | BEREMIZ development environment itself is licensed with "GNU GENERAL PUBLIC LICENSE V2 or later". PLC Runtime code (IEC-61131-3 Standard Function Block Library and platform specific C code templates) is licensed "GNU LESSER GENERAL PUBLIC LICENSE V2 or later" 7 | 8 | This distribution comes with several packages included, whose licensing should be compatible : 9 | 10 | - wxWidgets, wxPython is currently licensed under the "wxWindows Licence". Refer to http://www.wxwidgets.org/about/licence3.txt 11 | 12 | - mingw toolchain itself is licensed under the "GNU GENERAL PUBLIC LICENSE V2" whereas libraries are licensed under the "GNU LESSER GENERAL PUBLIC LICENSE V2", 13 | 14 | - python and many other additional packages come "As is" with GPL compatible license 15 | 16 | You may use BEREMIZ on any number of systems. There is no restriction to your use. You may use BEREMIZ commercially as well as privately. You the user assume the responsibility for the use of the files, binary or text, and there is no guarantee or warranty, expressed or implied, including but not limited to the implied warranties of merchantability and fitness for a particular purpose. You assume all responsibility and agree to hold no entity, copyright holder or distributors liable for any loss of data or inaccurate representations of data as a result of using BEREMIZ. 17 | 18 | You may redistribute BEREMIZ in part or in whole as long as you follow the guidelines of redistribution of each license contained within. To be certain that you are being legally compliant, always distribute the source. Distribution of source is your responsibility should you decide to redistribute BEREMIZ. 19 | 20 | Binaries created from the use of BEREMIZ and of MinGW are not bound by any license found within this package unless you use a library that is itself covered by the GPL license. If you wish to create proprietary software then don't use any other GPL licensed library. A library licensed with LGPL (Lesser GPL) may be used by proprietary software without GPL infection as special permission within the LGPL has given you this right. 21 | 22 | ################################################################## 23 | ################################################################## 24 | 25 | GNU GENERAL PUBLIC LICENSE 26 | Version 2, June 1991 27 | 28 | Copyright (C) 1989, 1991 Free Software Foundation, Inc. 29 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 30 | Everyone is permitted to copy and distribute verbatim copies 31 | of this license document, but changing it is not allowed. 32 | 33 | Preamble 34 | 35 | The licenses for most software are designed to take away your 36 | freedom to share and change it. By contrast, the GNU General Public 37 | License is intended to guarantee your freedom to share and change free 38 | software--to make sure the software is free for all its users. This 39 | General Public License applies to most of the Free Software 40 | Foundation's software and to any other program whose authors commit to 41 | using it. (Some other Free Software Foundation software is covered by 42 | the GNU Library General Public License instead.) You can apply it to 43 | your programs, too. 44 | 45 | When we speak of free software, we are referring to freedom, not 46 | price. Our General Public Licenses are designed to make sure that you 47 | have the freedom to distribute copies of free software (and charge for 48 | this service if you wish), that you receive source code or can get it 49 | if you want it, that you can change the software or use pieces of it 50 | in new free programs; and that you know you can do these things. 51 | 52 | To protect your rights, we need to make restrictions that forbid 53 | anyone to deny you these rights or to ask you to surrender the rights. 54 | These restrictions translate to certain responsibilities for you if you 55 | distribute copies of the software, or if you modify it. 56 | 57 | For example, if you distribute copies of such a program, whether 58 | gratis or for a fee, you must give the recipients all the rights that 59 | you have. You must make sure that they, too, receive or can get the 60 | source code. And you must show them these terms so they know their 61 | rights. 62 | 63 | We protect your rights with two steps: (1) copyright the software, and 64 | (2) offer you this license which gives you legal permission to copy, 65 | distribute and/or modify the software. 66 | 67 | Also, for each author's protection and ours, we want to make certain 68 | that everyone understands that there is no warranty for this free 69 | software. If the software is modified by someone else and passed on, we 70 | want its recipients to know that what they have is not the original, so 71 | that any problems introduced by others will not reflect on the original 72 | authors' reputations. 73 | 74 | Finally, any free program is threatened constantly by software 75 | patents. We wish to avoid the danger that redistributors of a free 76 | program will individually obtain patent licenses, in effect making the 77 | program proprietary. To prevent this, we have made it clear that any 78 | patent must be licensed for everyone's free use or not licensed at all. 79 | 80 | The precise terms and conditions for copying, distribution and 81 | modification follow. 82 | 83 | ################################################################## 84 | ################################################################## 85 | 86 | GNU GENERAL PUBLIC LICENSE 87 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 88 | 89 | 0. This License applies to any program or other work which contains 90 | a notice placed by the copyright holder saying it may be distributed 91 | under the terms of this General Public License. The "Program", below, 92 | refers to any such program or work, and a "work based on the Program" 93 | means either the Program or any derivative work under copyright law: 94 | that is to say, a work containing the Program or a portion of it, 95 | either verbatim or with modifications and/or translated into another 96 | language. (Hereinafter, translation is included without limitation in 97 | the term "modification".) Each licensee is addressed as "you". 98 | 99 | Activities other than copying, distribution and modification are not 100 | covered by this License; they are outside its scope. The act of 101 | running the Program is not restricted, and the output from the Program 102 | is covered only if its contents constitute a work based on the 103 | Program (independent of having been made by running the Program). 104 | Whether that is true depends on what the Program does. 105 | 106 | 1. You may copy and distribute verbatim copies of the Program's 107 | source code as you receive it, in any medium, provided that you 108 | conspicuously and appropriately publish on each copy an appropriate 109 | copyright notice and disclaimer of warranty; keep intact all the 110 | notices that refer to this License and to the absence of any warranty; 111 | and give any other recipients of the Program a copy of this License 112 | along with the Program. 113 | 114 | You may charge a fee for the physical act of transferring a copy, and 115 | you may at your option offer warranty protection in exchange for a fee. 116 | 117 | 2. You may modify your copy or copies of the Program or any portion 118 | of it, thus forming a work based on the Program, and copy and 119 | distribute such modifications or work under the terms of Section 1 120 | above, provided that you also meet all of these conditions: 121 | 122 | a) You must cause the modified files to carry prominent notices 123 | stating that you changed the files and the date of any change. 124 | 125 | b) You must cause any work that you distribute or publish, that in 126 | whole or in part contains or is derived from the Program or any 127 | part thereof, to be licensed as a whole at no charge to all third 128 | parties under the terms of this License. 129 | 130 | c) If the modified program normally reads commands interactively 131 | when run, you must cause it, when started running for such 132 | interactive use in the most ordinary way, to print or display an 133 | announcement including an appropriate copyright notice and a 134 | notice that there is no warranty (or else, saying that you provide 135 | a warranty) and that users may redistribute the program under 136 | these conditions, and telling the user how to view a copy of this 137 | License. (Exception: if the Program itself is interactive but 138 | does not normally print such an announcement, your work based on 139 | the Program is not required to print an announcement.) 140 | 141 | These requirements apply to the modified work as a whole. If 142 | identifiable sections of that work are not derived from the Program, 143 | and can be reasonably considered independent and separate works in 144 | themselves, then this License, and its terms, do not apply to those 145 | sections when you distribute them as separate works. But when you 146 | distribute the same sections as part of a whole which is a work based 147 | on the Program, the distribution of the whole must be on the terms of 148 | this License, whose permissions for other licensees extend to the 149 | entire whole, and thus to each and every part regardless of who wrote it. 150 | 151 | Thus, it is not the intent of this section to claim rights or contest 152 | your rights to work written entirely by you; rather, the intent is to 153 | exercise the right to control the distribution of derivative or 154 | collective works based on the Program. 155 | 156 | In addition, mere aggregation of another work not based on the Program 157 | with the Program (or with a work based on the Program) on a volume of 158 | a storage or distribution medium does not bring the other work under 159 | the scope of this License. 160 | 161 | 3. You may copy and distribute the Program (or a work based on it, 162 | under Section 2) in object code or executable form under the terms of 163 | Sections 1 and 2 above provided that you also do one of the following: 164 | 165 | a) Accompany it with the complete corresponding machine-readable 166 | source code, which must be distributed under the terms of Sections 167 | 1 and 2 above on a medium customarily used for software interchange; or, 168 | 169 | b) Accompany it with a written offer, valid for at least three 170 | years, to give any third party, for a charge no more than your 171 | cost of physically performing source distribution, a complete 172 | machine-readable copy of the corresponding source code, to be 173 | distributed under the terms of Sections 1 and 2 above on a medium 174 | customarily used for software interchange; or, 175 | 176 | c) Accompany it with the information you received as to the offer 177 | to distribute corresponding source code. (This alternative is 178 | allowed only for noncommercial distribution and only if you 179 | received the program in object code or executable form with such 180 | an offer, in accord with Subsection b above.) 181 | 182 | The source code for a work means the preferred form of the work for 183 | making modifications to it. For an executable work, complete source 184 | code means all the source code for all modules it contains, plus any 185 | associated interface definition files, plus the scripts used to 186 | control compilation and installation of the executable. However, as a 187 | special exception, the source code distributed need not include 188 | anything that is normally distributed (in either source or binary 189 | form) with the major components (compiler, kernel, and so on) of the 190 | operating system on which the executable runs, unless that component 191 | itself accompanies the executable. 192 | 193 | If distribution of executable or object code is made by offering 194 | access to copy from a designated place, then offering equivalent 195 | access to copy the source code from the same place counts as 196 | distribution of the source code, even though third parties are not 197 | compelled to copy the source along with the object code. 198 | 199 | 4. You may not copy, modify, sublicense, or distribute the Program 200 | except as expressly provided under this License. Any attempt 201 | otherwise to copy, modify, sublicense or distribute the Program is 202 | void, and will automatically terminate your rights under this License. 203 | However, parties who have received copies, or rights, from you under 204 | this License will not have their licenses terminated so long as such 205 | parties remain in full compliance. 206 | 207 | 5. You are not required to accept this License, since you have not 208 | signed it. However, nothing else grants you permission to modify or 209 | distribute the Program or its derivative works. These actions are 210 | prohibited by law if you do not accept this License. Therefore, by 211 | modifying or distributing the Program (or any work based on the 212 | Program), you indicate your acceptance of this License to do so, and 213 | all its terms and conditions for copying, distributing or modifying 214 | the Program or works based on it. 215 | 216 | 6. Each time you redistribute the Program (or any work based on the 217 | Program), the recipient automatically receives a license from the 218 | original licensor to copy, distribute or modify the Program subject to 219 | these terms and conditions. You may not impose any further 220 | restrictions on the recipients' exercise of the rights granted herein. 221 | You are not responsible for enforcing compliance by third parties to 222 | this License. 223 | 224 | 7. If, as a consequence of a court judgment or allegation of patent 225 | infringement or for any other reason (not limited to patent issues), 226 | conditions are imposed on you (whether by court order, agreement or 227 | otherwise) that contradict the conditions of this License, they do not 228 | excuse you from the conditions of this License. If you cannot 229 | distribute so as to satisfy simultaneously your obligations under this 230 | License and any other pertinent obligations, then as a consequence you 231 | may not distribute the Program at all. For example, if a patent 232 | license would not permit royalty-free redistribution of the Program by 233 | all those who receive copies directly or indirectly through you, then 234 | the only way you could satisfy both it and this License would be to 235 | refrain entirely from distribution of the Program. 236 | 237 | If any portion of this section is held invalid or unenforceable under 238 | any particular circumstance, the balance of the section is intended to 239 | apply and the section as a whole is intended to apply in other 240 | circumstances. 241 | 242 | It is not the purpose of this section to induce you to infringe any 243 | patents or other property right claims or to contest validity of any 244 | such claims; this section has the sole purpose of protecting the 245 | integrity of the free software distribution system, which is 246 | implemented by public license practices. Many people have made 247 | generous contributions to the wide range of software distributed 248 | through that system in reliance on consistent application of that 249 | system; it is up to the author/donor to decide if he or she is willing 250 | to distribute software through any other system and a licensee cannot 251 | impose that choice. 252 | 253 | This section is intended to make thoroughly clear what is believed to 254 | be a consequence of the rest of this License. 255 | 256 | 8. If the distribution and/or use of the Program is restricted in 257 | certain countries either by patents or by copyrighted interfaces, the 258 | original copyright holder who places the Program under this License 259 | may add an explicit geographical distribution limitation excluding 260 | those countries, so that distribution is permitted only in or among 261 | countries not thus excluded. In such case, this License incorporates 262 | the limitation as if written in the body of this License. 263 | 264 | 9. The Free Software Foundation may publish revised and/or new versions 265 | of the General Public License from time to time. Such new versions will 266 | be similar in spirit to the present version, but may differ in detail to 267 | address new problems or concerns. 268 | 269 | Each version is given a distinguishing version number. If the Program 270 | specifies a version number of this License which applies to it and "any 271 | later version", you have the option of following the terms and conditions 272 | either of that version or of any later version published by the Free 273 | Software Foundation. If the Program does not specify a version number of 274 | this License, you may choose any version ever published by the Free Software 275 | Foundation. 276 | 277 | 10. If you wish to incorporate parts of the Program into other free 278 | programs whose distribution conditions are different, write to the author 279 | to ask for permission. For software which is copyrighted by the Free 280 | Software Foundation, write to the Free Software Foundation; we sometimes 281 | make exceptions for this. Our decision will be guided by the two goals 282 | of preserving the free status of all derivatives of our free software and 283 | of promoting the sharing and reuse of software generally. 284 | 285 | NO WARRANTY 286 | 287 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 288 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 289 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 290 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 291 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 292 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 293 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 294 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 295 | REPAIR OR CORRECTION. 296 | 297 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 298 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 299 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 300 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 301 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 302 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 303 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 304 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 305 | POSSIBILITY OF SUCH DAMAGES. 306 | 307 | END OF TERMS AND CONDITIONS 308 | 309 | ################################################################## 310 | ################################################################## 311 | -------------------------------------------------------------------------------- /pacman-6.0.0-nogpg-relative_conf.patch: -------------------------------------------------------------------------------- 1 | diff -ruN pacman-6.0.0.orig/lib/libalpm/util.c pacman-6.0.0/lib/libalpm/util.c 2 | --- pacman-6.0.0.orig/lib/libalpm/util.c 2021-05-20 03:38:45.948119900 +0000 3 | +++ pacman-6.0.0/lib/libalpm/util.c 2021-08-26 17:26:09.719703392 +0000 4 | @@ -652,6 +652,12 @@ 5 | /* use fprintf instead of _alpm_log to send output through the parent */ 6 | if(chroot(handle->root) != 0) { 7 | fprintf(stderr, _("could not change the root directory (%s)\n"), strerror(errno)); 8 | + fprintf(stderr, "cmd : %s", cmd); 9 | + for(int i=0; argv[i]; i++){ 10 | + fprintf(stderr, " %s", argv[i]); 11 | + } 12 | + fprintf(stderr, "\n"); 13 | + return 0; //be happy 14 | exit(1); 15 | } 16 | if(chdir("/") != 0) { 17 | diff -ruN pacman-6.0.0.orig/src/pacman/conf.c pacman-6.0.0/src/pacman/conf.c 18 | --- pacman-6.0.0.orig/src/pacman/conf.c 2021-05-20 03:38:45.964786500 +0000 19 | +++ pacman-6.0.0/src/pacman/conf.c 2021-08-26 17:27:32.228666450 +0000 20 | @@ -477,7 +477,7 @@ 21 | } 22 | 23 | /* now parse out and store actual flag if it is valid */ 24 | - if(strcmp(value, "Never") == 0) { 25 | + if(1 || strcmp(value, "Never") == 0) { 26 | if(package) { 27 | SLUNSET(ALPM_SIG_PACKAGE); 28 | } 29 | @@ -1071,9 +1071,11 @@ 30 | break; 31 | default: 32 | for(gindex = 0; gindex < globbuf.gl_pathc; gindex++) { 33 | + char buf[1024]; 34 | + snprintf(buf, 1023, "%s%s",ROOTDIR, globbuf.gl_pathv[gindex]); 35 | pm_printf(ALPM_LOG_DEBUG, "config file %s, line %d: including %s\n", 36 | - file, linenum, globbuf.gl_pathv[gindex]); 37 | - ret = parse_ini(globbuf.gl_pathv[gindex], _parse_directive, data); 38 | + file, linenum, buf); 39 | + ret = parse_ini(buf, _parse_directive, data); 40 | if(ret) { 41 | goto cleanup; 42 | } 43 | diff -ruN pacman-6.0.0.orig/lib/libalpm/be_local.c pacman-6.0.0/lib/libalpm/be_local.c 44 | --- pacman-6.0.0.orig/lib/libalpm/be_local.c 2023-09-05 15:52:38.385979363 +0200 45 | +++ pacman-6.0.0/lib/libalpm/be_local.c 2023-09-05 16:04:41.553345845 +0200 46 | @@ -423,7 +423,7 @@ 47 | 48 | static int local_db_create(alpm_db_t *db, const char *dbpath) 49 | { 50 | - if(mkdir(dbpath, 0755) != 0) { 51 | + if(mkdir(dbpath, 0755) != 0 && errno != EEXIST) { 52 | _alpm_log(db->handle, ALPM_LOG_ERROR, _("could not create directory %s: %s\n"), 53 | dbpath, strerror(errno)); 54 | RET_ERR(db->handle, ALPM_ERR_DB_CREATE, -1); 55 | @@ -905,10 +905,12 @@ 56 | oldmask = umask(0000); 57 | pkgpath = _alpm_local_db_pkgpath(db, info, NULL); 58 | 59 | - if((retval = mkdir(pkgpath, 0755)) != 0) { 60 | + if((retval = mkdir(pkgpath, 0755)) != 0 && errno != EEXIST) { 61 | _alpm_log(db->handle, ALPM_LOG_ERROR, _("could not create directory %s: %s\n"), 62 | pkgpath, strerror(errno)); 63 | - } 64 | + } else { 65 | + retval = 0; 66 | + } 67 | 68 | free(pkgpath); 69 | umask(oldmask); 70 | -------------------------------------------------------------------------------- /plcopen_editor.cmd: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal 3 | 4 | rem Get the directory of the current script 5 | set "script_dir=%~dp0" 6 | 7 | rem Set the path to the executable relative to the script directory 8 | set "python_exe=%script_dir%\$MSYS_DIR\$MSYS_ENV_DIR\bin\pythonw.exe" 9 | set "plcopeneditor_py=%script_dir%\Beremiz\PLCOpenEditor.py" 10 | 11 | set MSYSTEM=$MSYSTEM 12 | 13 | rem Launch PLCOpen editor with all command line arguments 14 | start "Beremiz IDE" /d %HOMEDRIVE%%HOMEPATH% "%python_exe%" "%plcopeneditor_py%" %* 15 | 16 | endlocal -------------------------------------------------------------------------------- /provision_noble64.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -xe 4 | 5 | apt-get update 6 | 7 | apt-get install -y --no-install-recommends \ 8 | build-essential \ 9 | `# building pacman` \ 10 | meson \ 11 | cmake \ 12 | pkg-config \ 13 | libarchive-dev \ 14 | libcurl4-openssl-dev \ 15 | libssl-dev \ 16 | `# running pacman` \ 17 | fakeroot \ 18 | `# egg/whl download` \ 19 | python3-pip \ 20 | git \ 21 | `# run win python3` \ 22 | xvfb \ 23 | `# matiec cross build` \ 24 | mingw-w64 \ 25 | automake \ 26 | bison \ 27 | flex \ 28 | `# installer` \ 29 | nsis \ 30 | zip 31 | 32 | # run win python3 33 | dpkg --add-architecture i386 34 | apt-get install -y --install-recommends \ 35 | wine-stable 36 | -------------------------------------------------------------------------------- /rebuild_docker.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | ./clean_docker_container.sh || true 6 | ./clean_docker_image.sh || true 7 | ./build_docker_image.sh 8 | ./create_docker_container.sh $1 9 | 10 | -------------------------------------------------------------------------------- /revisions.txt: -------------------------------------------------------------------------------- 1 | beremiz local 2 | canfestival local 3 | Modbus local 4 | open62541 local 5 | matiec local 6 | -------------------------------------------------------------------------------- /snap.mk: -------------------------------------------------------------------------------- 1 | # Snap distribution 2 | 3 | main_target: Snap 4 | 5 | DIST_FROM_SOURCE_PROJECTS=canfestival Modbus 6 | // open62541 is systematically downloaded in main Makefile 7 | 8 | tar_opts=--absolute-names --exclude=.hg --exclude=.git --exclude=.*.pyc --exclude=.*.swp 9 | 10 | Snap: snap_built 11 | snap_built: all_sources revisions.txt 12 | tar -C $(src) $(tar_opts) -c snap | tar -C sources -x 13 | cp revisions.txt sources 14 | cd sources; snapcraft --debug 15 | touch $@ 16 | -------------------------------------------------------------------------------- /snap/gui/beremiz.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Name=Beremiz IDE 4 | Comment=IEC-61131 Open Source PLC programming 5 | Exec=beremiz.ide %f 6 | Icon=${SNAP}/meta/gui/beremiz.png 7 | -------------------------------------------------------------------------------- /snap/gui/beremiz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/beremiz/beremiz_public_dist/d30d195332ea26a5b6767683868fba10f1efefd8/snap/gui/beremiz.png -------------------------------------------------------------------------------- /snap/snapcraft.yaml: -------------------------------------------------------------------------------- 1 | name: beremiz 2 | adopt-info: beremiz 3 | title: Beremiz 4 | summary: Beremiz Open Source PLC. 5 | description: | 6 | Beremiz is a framework for machine automation. It is meant to add PLC-like programing to embedded systems. 7 | 8 | Beremiz is [Free Software](https://en.wikipedia.org/wiki/Free_software), and conforms to 9 | [IEC_61131](https://en.wikipedia.org/wiki/IEC_61131-3) and [PLCopen](https://plcopen.org/technical-activities/xml-exchange) among other standards. 10 | 11 | Beremiz supports all languages described in IEC_61131: 12 | * Structured Text (ST) 13 | * Instruction List (IL) 14 | * Function Block Diagram (FBD) 15 | * Sequencial Function Chart (SFC) 16 | * Ladder Diagram (LD) 17 | 18 | IDE also includes tools to create Human-Machine Interfaces (HMI), and to connect your PLC programs to existing supervisions, databases, or fieldbuses: 19 | * Modbus 20 | * OPC-UA 21 | * CANopen 22 | * SVG HMI 23 | * Wx HMI 24 | * Python 25 | * ... 26 | 27 | Runtime can be programmed remotely and allows variables tracing and forcing. 28 | 29 | icon: snap/gui/beremiz.png 30 | contact: 31 | - https://beremiz.org 32 | - snap@beremiz.fr 33 | 34 | 35 | grade: stable 36 | confinement: strict 37 | base: core22 38 | architectures: [amd64, arm64] 39 | 40 | parts: 41 | 42 | beremiz: 43 | # Beremiz python source and dependencies, inc. native GCC 44 | # source tree is expected to be just aside snap directory 45 | plugin: python 46 | source: beremiz 47 | source-type: local 48 | python-requirements: 49 | - requirements.txt 50 | # native GCC toolchain 51 | # note: GCC toolchain cannot be move to separate part 52 | # otherwise there is a file conflict about lib64 in prime step 53 | # caused apparently by libc6 (needed to have consistent sysroot) 54 | stage-packages: 55 | - gcc 56 | - libc6 57 | - libc6-dev 58 | - linux-libc-dev 59 | - libgcc-9-dev 60 | - libgcc-s1 61 | - libssl-dev 62 | override-pull: | 63 | snapcraftctl pull 64 | snapcraftctl set-version `python3 $CRAFT_PART_SRC/version.py` 65 | override-build: | 66 | snapcraftctl build 67 | cp -a $CRAFT_PART_SRC $CRAFT_PART_INSTALL/beremiz 68 | 69 | matiec: 70 | # Matiec ST, SFC and IL compiler. 71 | # source tree is expected to be just aside snap directory 72 | plugin: nil 73 | source: matiec 74 | source-type: local 75 | build-packages: 76 | - build-essential 77 | - automake 78 | - flex 79 | - bison 80 | override-build: | 81 | autoreconf -i && ./configure && make 82 | cp -a $CRAFT_PART_BUILD $CRAFT_PART_INSTALL/matiec 83 | 84 | modbus: 85 | plugin: nil 86 | source: Modbus 87 | source-type: local 88 | build-packages: 89 | - build-essential 90 | - automake 91 | override-build: | 92 | make 93 | cp -a $CRAFT_PART_BUILD $CRAFT_PART_INSTALL/Modbus 94 | 95 | open62541: 96 | plugin: nil 97 | source: open62541 98 | source-type: local 99 | build-packages: 100 | - build-essential 101 | - cmake 102 | override-build: | 103 | mkdir build && cd build && cmake .. && make 104 | cp -a $CRAFT_PART_BUILD $CRAFT_PART_INSTALL/open62541 105 | 106 | inkscape: 107 | # CLI only, used in SVGHMI build 108 | # GUI fails to launch couldn't find a way 109 | plugin: nil 110 | stage-packages: 111 | - inkscape 112 | - libgtk-3-0 113 | # libgtk3 needs to be explicitely given 114 | # otherwise wxGtk doesn't start, with this error : 115 | # libgtk-3.so.0: undefined symbol: pango_font_family_get_face 116 | # ... why ? 117 | 118 | revisiontxt: 119 | # Makefile generated "revisions.txt" 120 | plugin: nil 121 | source: . 122 | source-type: local 123 | override-build: | 124 | cp $CRAFT_PART_SRC/revisions.txt $CRAFT_PART_INSTALL 125 | 126 | apps: 127 | ide: 128 | # Launcher for the IDE 129 | environment: 130 | SYSROOT: $SNAP 131 | command: bin/python3 $SNAP/beremiz/Beremiz.py 132 | extensions: [gnome] 133 | plugs: 134 | - network 135 | - network-bind 136 | - wayland 137 | 138 | beremiz: 139 | # Beremiz Command Line interface 140 | environment: 141 | SYSROOT: $SNAP 142 | command: bin/python3 $SNAP/beremiz/Beremiz_cli.py 143 | plugs: 144 | - network 145 | - network-bind 146 | 147 | runtime: 148 | # Standalone runtime 149 | environment: 150 | SYSROOT: $SNAP 151 | command: bin/python3 $SNAP/beremiz/Beremiz_service.py 152 | plugs: 153 | - network 154 | - network-bind 155 | 156 | -------------------------------------------------------------------------------- /win32.mk: -------------------------------------------------------------------------------- 1 | # Win32 only distribution 2 | 3 | main_target: Beremiz-nsis-installer.exe Beremiz-portable.zip 4 | 5 | include $(src)/windows_installer.mk 6 | 7 | ide_targets_from_dist: 8 | touch $@ 9 | 10 | # TODO CANFESTIVAL 11 | # TODO MODBUS 12 | # TODO OPCUA 13 | 14 | # DIST_FROM_SOURCE_PROJECTS=canfestival Modbus open62541 15 | 16 | # ide_targets_from_dist: canfestival Modbus open62541 17 | # touch $@ 18 | 19 | 20 | # canfestival_dir = installer/canfestival 21 | # canfestival: $(canfestival_dir)/.stamp 22 | # $(canfestival_dir)/.stamp: sources/canfestival_src | installer 23 | # canfestival: $(canfestival_dir)/.stamp 24 | # rm -rf $(canfestival_dir) 25 | # cp -a sources/canfestival $(canfestival_dir) 26 | # cd $(canfestival_dir); \ 27 | # ./configure --can=tcp_win32 \ 28 | # --cc=$(CC) \ 29 | # --cxx=$(CXX) \ 30 | # --target=win32 \ 31 | # --wx=0 32 | # $(MAKE) -C $(canfestival_dir) 33 | # cd $(canfestival_dir); find . -name "*.o" -exec rm {} ';' #remove object files only 34 | # touch $@ 35 | 36 | -------------------------------------------------------------------------------- /windows_installer.mk: -------------------------------------------------------------------------------- 1 | 2 | installer: 3 | mkdir -p installer 4 | 5 | CURDIR:=$(shell pwd) 6 | PACMANPFX=$(CURDIR)/pacman 7 | MSYS_DIR=msys64 8 | MSYSTEM=UCRT64 9 | MSYS_ENV_DIR=ucrt64 10 | MSYS_ENV=mingw-w64-ucrt-x86_64 11 | MSYS_ROOT=$(CURDIR)/$(MSYS_DIR) 12 | 13 | XVFBRUN ?= xvfb-run -a 14 | 15 | msysfinaldir=installer/$(MSYS_DIR) 16 | 17 | pacman-6.0.0/src.stamp: 18 | rm -rf pacman pacman-6.0.0 19 | $(call get_src_http,https://sources.archlinux.org/other/pacman,pacman-6.0.0.tar.xz)\ 20 | tar -xJf $$dld 21 | touch $@ 22 | 23 | pacman-6.0.0/patched.stamp: pacman-6.0.0/src.stamp 24 | cd pacman-6.0.0 ;\ 25 | patch -p1 < $(src)/pacman-6.0.0-nogpg-relative_conf.patch ; 26 | touch $@ 27 | 28 | pacman/.stamp: pacman-6.0.0/patched.stamp 29 | cd pacman-6.0.0 ;\ 30 | meson -Droot-dir=$(MSYS_ROOT) -Dsysconfdir=$(MSYS_ROOT)/etc -Dlocalstatedir=$(MSYS_ROOT)/var build ;\ 31 | DESTDIR=$(PACMANPFX) ninja -C build install 32 | touch $@ 33 | 34 | define pacman_call 35 | LD_LIBRARY_PATH=$(PACMANPFX)/usr/lib/x86_64-linux-gnu/ fakeroot pacman/usr/bin/pacman $(1) 36 | endef 37 | 38 | pacman_update=$(call pacman_call, -Sy --noconfirm --cachedir $(distfiles)); 39 | pacman_install_ming=$(call pacman_call, -S $(1) --arch x86_64 --noconfirm --cachedir $(distfiles)); 40 | pacman_install_msys=$(call pacman_call, -S $(1) --noconfirm --cachedir $(distfiles)); 41 | 42 | # First part are python packages requested by our app and available in msys 43 | # Second part are dependencies of packages to be later installed with pip 44 | # Third part : neede for cross-install operation 45 | # -> all those packages are installed with pacman, ignoring version given in requirements.txt 46 | define MSYS_PY_PACKAGES 47 | brotli 48 | click 49 | fonttools 50 | lxml 51 | matplotlib 52 | msgpack 53 | pycountry 54 | u-msgpack 55 | zeroconf 56 | twisted 57 | 58 | cryptography 59 | aiosqlite 60 | pytz 61 | sortedcontainers 62 | 63 | pip 64 | endef 65 | 66 | define MSYS_PACKAGES_NAMES 67 | gcc 68 | make 69 | wxPython 70 | $(foreach package, $(MSYS_PY_PACKAGES), python-$(package)) 71 | endef 72 | 73 | MSYS_PACKAGES=$(foreach package, $(MSYS_PACKAGES_NAMES), $(MSYS_ENV)-$(package)) 74 | 75 | $(MSYS_DIR)/.stamp: pacman/.stamp 76 | rm -rf $(MSYS_DIR) 77 | 78 | $(call get_src_http,https://repo.msys2.org/distrib/x86_64,msys2-base-x86_64-20230718.tar.xz)\ 79 | tar -xJf $$dld 80 | 81 | # Do NOT update package lists to make build reproducible 82 | # All packages version are as given in base image. 83 | ## $(pacman_update) 84 | 85 | $(call pacman_install_ming,$(MSYS_PACKAGES)) 86 | touch $@ 87 | 88 | # filter-out all python packages already installed by pacman 89 | filtered_requirements.txt: $(MSYS_DIR)/.stamp sources/beremiz_src 90 | grep sources/beremiz/requirements.txt -i -v \ 91 | `$(call pacman_call, -Qqs 'python-.*') | sed -e 's/$(MSYS_ENV)-python-/ -e /'` \ 92 | -e wxPython \ 93 | $(foreach package, $(MSYS_PY_PACKAGES), -e $(package)) > filtered_requirements.txt 94 | 95 | # download remaining pip packages separtately with local python 96 | # workaround msys2's git crashing when launched from pip on wine 97 | # bug: https://bugs.winehq.org/show_bug.cgi?id=40528 98 | pip_downloads/.stamp: filtered_requirements.txt 99 | rm -rf pip_downloads 100 | mkdir pip_downloads 101 | python3 -m pip download --platform mingw_x86_64_ucrt --no-deps -r filtered_requirements.txt -d pip_downloads 102 | touch $@ 103 | 104 | # install downloaded .whl files with wine 105 | # TODO: find a less convoluited way instead of wine to build/install packages 106 | # but still populating __pycache__ for this particular python version 107 | winpythonbin = $(MSYS_ROOT)/$(MSYS_ENV_DIR)/bin/python.exe 108 | wine = WINEPREFIX=$(tmp) $(XVFBRUN) wine 109 | pip.stamp: pip_downloads/.stamp 110 | cd pip_downloads; SETUPTOOLS_USE_DISTUTILS=stdlib $(wine) $(winpythonbin) -m pip install --no-deps * 111 | touch $@ 112 | 113 | $(msysfinaldir)/.stamp: pip.stamp | installer 114 | rm -rf $(msysfinaldir) 115 | cp -a $(MSYS_DIR) $(msysfinaldir) 116 | sed -i '/^db_home:/c\db_home: /%H/BeremizHome' $(msysfinaldir)/etc/nsswitch.conf 117 | touch $@ 118 | 119 | CROSS_COMPILE=x86_64-w64-mingw32 120 | CROSS_COMPILE_LIBS_DIR=$(shell dirname $(shell $(CROSS_COMPILE)-gcc -print-libgcc-file-name)) 121 | 122 | matiecdir = installer/matiec 123 | matiec: $(matiecdir)/.stamp 124 | $(matiecdir)/.stamp: sources/matiec_src | installer 125 | cp -a sources/matiec $(tmp);\ 126 | cd $(tmp)/matiec;\ 127 | autoreconf ;\ 128 | automake --add-missing ;\ 129 | LDFLAGS=-lstdc++ ./configure --host=$(CROSS_COMPILE);\ 130 | $(MAKE) -j$(CPUS); 131 | rm -rf $(matiecdir) 132 | mkdir -p $(matiecdir) 133 | mv $(tmp)/matiec/*.exe $(matiecdir) 134 | 135 | # install necessary shared libraries from local cross-compiler 136 | cp $(CROSS_COMPILE_LIBS_DIR)/libgcc_s_seh-1.dll $(matiecdir) 137 | cp $(CROSS_COMPILE_LIBS_DIR)/libstdc++-6.dll $(matiecdir) 138 | 139 | mv $(tmp)/matiec/lib $(matiecdir) 140 | touch $@ 141 | 142 | beremizdir = installer/beremiz 143 | 144 | beremiz: $(beremizdir)/.stamp 145 | $(beremizdir)/.stamp: sources/beremiz_src | installer 146 | rm -rf $(beremizdir);\ 147 | cp -a sources/beremiz $(beremizdir);\ 148 | # populate __pycache__'s .pyc files 149 | cd $(beremizdir) ;\ 150 | find . -name "*.py" | grep -v \ 151 | -e \./etherlab \ 152 | -e .*/web_settings.py \ 153 | -e \./tests \ 154 | -e \./exemples \ 155 | > tocompile.lst ;\ 156 | $(wine) $(winpythonbin) -m compileall -i tocompile.lst 157 | rm $(beremizdir)/tocompile.lst 158 | touch $@ 159 | 160 | ide_revisions = installer/revisions.txt 161 | $(ide_revisions): revisions.txt 162 | cp $< $@ 163 | 164 | Beremiz-windows-build: $(src)/license.txt $(src)/beremiz_ide.cmd $(src)/plcopen_editor.cmd $(src)/winpaths.py $(msysfinaldir)/.stamp pip.stamp $(matiecdir)/.stamp $(beremizdir)/.stamp ide_targets_from_dist $(ide_revisions) 165 | export BVERSION=`python3 $(VERSIONPY)` ;\ 166 | sed -e "s/\$$BVERSION/$$BVERSION/g" $(src)/license.txt > installer/license.txt 167 | 168 | sed -e "s#\$$MSYS_DIR#$(MSYS_DIR)#g" $(src)/beremiz_ide.cmd |\ 169 | sed -e "s#\$$MSYSTEM#$(MSYSTEM)#g" |\ 170 | sed -e "s#\$$MSYS_ENV_DIR#$(MSYS_ENV_DIR)#g" > installer/beremiz_ide.cmd 171 | 172 | sed -e "s#\$$MSYS_DIR#$(MSYS_DIR)#g" $(src)/plcopen_editor.cmd |\ 173 | sed -e "s#\$$MSYSTEM#$(MSYSTEM)#g" |\ 174 | sed -e "s#\$$MSYS_ENV_DIR#$(MSYS_ENV_DIR)#g" > installer/plcopen_editor.cmd 175 | 176 | sed -e "s#\$$MSYS_DIR#$(MSYS_DIR)#g" $(src)/winpaths.py |\ 177 | sed -e "s#\$$MSYS_ENV_DIR#$(MSYS_ENV_DIR)#g" > installer/winpaths.py 178 | 179 | touch $@ 180 | 181 | Beremiz-portable.zip: Beremiz-windows-build 182 | rm -f $@ 183 | cd installer; zip -r -q ../$@ . 184 | 185 | VERSIONPY=sources/beremiz/version.py 186 | 187 | Beremiz-nsis-installer.exe: Beremiz-windows-build $(src)/install.nsi 188 | export BVERSION=`python3 $(VERSIONPY)` ;\ 189 | sed -e "s/\$$BVERSION/$$BVERSION/g" $(src)/install.nsi > install.nsi 190 | makensis install.nsi 191 | 192 | 193 | -------------------------------------------------------------------------------- /winpaths.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | # In order to avoid spurious terminal windows, MSYS2's pythonw.exe is launched directly. 4 | # Since it is launched outside of any MSYS2 login shell (bash -l), 5 | # it doesn't have the MSYS2 paths in the PATH. This script adds them. 6 | 7 | # Beremiz installation directory, relative to this script 8 | instdir = os.path.dirname(os.path.dirname(os.path.realpath(__file__))) 9 | 10 | # Promote MSYS2 paths to the front of PATH 11 | paths = os.environ["PATH"].split(os.pathsep) 12 | new_PATH_1st = [] 13 | new_PATH_2nd = [] 14 | for path in paths: 15 | (new_PATH_1st if path.startswith(instdir) else new_PATH_2nd).append(path) 16 | 17 | # re-compose PATH 18 | os.environ["PATH"] = os.pathsep.join(new_PATH_1st + [ 19 | os.path.join(instdir, "$MSYS_DIR", "bin"), 20 | os.path.join(instdir, "$MSYS_DIR", "usr", "bin"), 21 | ] + new_PATH_2nd) 22 | # Note: $MSYSTEM/bin is already added to PATH when calling pythonw.exe 23 | # -> no need of os.path.join(instdir, "$MSYS_DIR", "$MSYS_ENV_DIR", "bin"), 24 | 25 | os.environ["HOME"] = os.path.join(os.environ["HOMEDRIVE"], os.environ["HOMEPATH"], "BeremizHome") 26 | --------------------------------------------------------------------------------