pcb-rnd knowledge pool
How to cross-compile recent versions of pcb-rnd to windows on *nix
win32-cross by Tibor 'Igor2' Palinkas on 2019-10-25 | Tags: howto, cross-compile, win32, windows, exe |
Abstract: This howto is about compiling the latest svn version of pcb-rnd, starting from version 3.0.0.
The below manual process is the temporary solution for cross-compiling svn HEAD pcb-rnd to windows. (There are other nodes about cross-compiling 2.1.4 and the later 2.x.x series )
step 1: hidlib w32 deps
Download the binary development pack of hidlib.w32 (alternatively: cross-compile it)
Install the hidlib.w32 pack; this document assumes it is installed under ~/w32-rnd, but it can be placed anywhere
step 2: cross-compile librnd
- make an svn checkout of librnd from svn://repo.hu/librnd/trunk librnd/trunk
- copy configure.w in trunk/scconfig/configure.w and make it executable (chmod 775 configure.w)
- copy crossw32.conf in trunk/scconfig/crossw32.conf
- edit crossw32.conf: replace the path after the equation sign in the first line to the path where hidlib.w32 got copied to; the path entered here should have /usr/local/lib under it.
- edit configure.w: replace the path after the equation sign in the first of INSTPATH to a path where librnd win32 binaries will be installed (something under your home is fine)
- cd trunk/scconfig; ./configure.w
- make
- make install
This will install a couple of files under the INSTPATH you specified.
step 3: cross-compile pcb-rnd
Note: configure.w and crossw32.conf differ between librnd and pcb-rnd.
- make an svn checkout of pcb-rnd from svn://repo.hu/pcb-rnd/trunk pcb-rnd/trunk
- copy configure.w in trunk/scconfig/configure.w and make it executable (chmod 775 configure.w)
- edit configure.w: modify LIBRND_PREFIX to have the same value as INSTPATH had in step 2.
- copy crossw32.conf in trunk/scconfig/crossw32.conf
- edit crossw32.conf: replace the path after the equation sign in the first line to the path where hidlib.w32 got copied to; the path entered here should have /usr/local/lib under it.
- cd trunk/scconfig; ./configure.w
- make
This should produce trunk/src/pcb-rnd.exe (and some utils).
The whole, zippable pack is produced by pcb-rnd.w32.pack.sh : it should be copied to trunk/ and ran from there. It contains configuration at the top of the script (paths should be changed).