OMDev=OpenModelica Development Environment ------------------------------------------- Adrian.Pop@liu.se, 2012-02-15, last update 2020-10-28 Checkout the OMDev package: - Install git for windows https://git-scm.com/downloads - make sure we git clone with the correct line endings, run in a terminal: git config --global core.eol lf git config --global core.autocrlf input - get OMDev from git git clone https://openmodelica.org/git/OMDev.git OMDev=a set of tools packaged togheter so no installation is necessary and everything works as expected. This is a specific release based on msys2/mingw32/mingw64 Quick course on msys2 --------------------- Adrian.Pop@liu.se 2016-03-11, update on 2020-10-28 More information here: http://msys2.org Install msys2 from: http://msys2.github.io/ start the msys2 shell and sync the local package database, and update the msys2 system: > pacman -Syuu RESTART the msys2 shell if you are told to do so! do a full system upgrade write: > pacman -Syuu install some usual packages: > pacman -S zip unzip tar make diffutils patch wget install needed configuration and build tools: > pacman -S autoconf automake m4 pkg-config libtool install gdb > pacman -S mingw-w64-{i686,x86_64}-gdb useful for exe|dll dependency analysis pacman -S mingw-w64-{i686,x86_64}-ntldd-git gcc & g++ & gfortran install mingw64 and mingw32: > pacman -S mingw-w64-{i686,x86_64}-toolchain clang & clang++ & gfortran pacman -S mingw-w64-{i686,x86_64}-clang pacman -S mingw-w64-{i686,x86_64}-gcc-fortran pacman -S mingw-w64-{i686,x86_64}-gcc-libgfortran install mingw32-make > pacman -S mingw-w64-{i686,x86_64}-make install cmake mingw32 and mingw64 > pacman -S mingw-w64-{i686,x86_64}-cmake mingw-w64-{i686,x86_64}-extra-cmake-modules install opencl headers > pacman -S mingw-w64-{i686,x86_64}-opencl-headers install lapack: openblas > pacman -S mingw-w64-{i686,x86_64}-openblas install bison needed for lpsolve compilation > pacman -S bison flex install binutils for -lbfd and -liberty > pacman -S mingw-w64-{i686,x86_64}-{gcc,binutils} result-files and tables pacman -S mingw-w64-{i686,x86_64}-hdf5 for omsimulator & cpp runtime pacman -S mingw-w64-{i686,x86_64}-boost pacman -S mingw-w64-{i686,x86_64}-libxml2 needed for runtimes and omc pacman -S mingw-w64-{i686,x86_64}-openmp package manager, curl pacman -S mingw-w64-{i686,x86_64}-gnutls for modelica3d install dbus > pacman -S mingw-w64-{i686,x86_64}-dbus mingw-w64-{i686,x86_64}-dbus-glib install gtk2 > pacman -S mingw-w64-{i686,x86_64}-gtk2 for 3d visualization in OMEdit install OSG open scene graph > pacman -S mingw-w64-{i686,x86_64}-OpenSceneGraph install qt-creator (will install all qt) > pacman -S mingw-w64-{i686,x86_64}-qt-creator install qtwebkit pacman -S mingw-w64-{i686,x86_64}-qtwebkit To make things move fast in msys2 one has to generate the group and passwd files on the host: > mkpasswd -l -c > /etc/passwd > mkgroup -l -c > /etc/group In /etc/nsswitch.conf one needs to change to: passwd: files #db group: files #db if you move the OMDev directory around then you need to path the qt files using: > cd $OMDEV/tools/msys/mingw64/bin > qtbinpatcher --nobackup > cd $OMDEV/tools/msys/mingw32/bin > qtbinpatcher --nobackup See all installed packages Start $OMDev\tools\msys\msys2_shell.bat > pacman -Qet list the files in a package > pacman -Ql mingw-w64-i686-openblas find which package a file belongs to: > pkgfile file To get the debug DLLs for qt5 and the qt5 examples reinstall the qt5 packages: Start $OMDev\tools\msys\msys2_shell.bat See which are the installed qt packages: > pacman -Ss qt5 | grep installed mingw32/mingw-w64-i686-qt5 5.15.1-1 (mingw-w64-i686-qt mingw-w64-i686-qt5) [installed] mingw32/mingw-w64-i686-qtwebkit 5.212.0alpha4-5 [installed] mingw64/mingw-w64-x86_64-qt5 5.15.1-1 (mingw-w64-x86_64-qt mingw-w64-x86_64-qt5) [installed] mingw64/mingw-w64-x86_64-qtwebkit 5.212.0alpha4-5 [installed] > pacman -S mingw-w64-i686-qt5 5.15.1-1 mingw-w64-x86_64-qt5 5.15.1-1 To clean the examples and the debug dlls do: > $OMDEV/util/msys2-clean.sh To clear the pacman cache: > pacman -Scc
Adrian Pop
authored