Dear all
I managed to get FAST and the Simulink S function compiled for my 64bit Ubuntu distro. I would like to share the work, as it took me a while to get everything working.
The builds are tested on Ubuntu/Xubuntu 11.10 64bit and with Matlab 2012a and 2011a.
I used the GNU fortran compiler, and it seems like you need at least 4.6.1 (Provided in the 11.10 *ubuntu distros). The build is done using the sources for FAST, AeroDyn and NWTC Lib that were released on the 16th Feb. 2012.
I have attached a tar ball with Makefiles, patches etc. The Makefiles are setup to compile FAST with a BladedSO interface with a dynamically linked DISCON.so file. This interface is the work of Stefano Cottafavi (see stefanocottafavi.com/?p=360).
The dynamically linked DISCON.so was tested with the DISCON.f90 file included in the 5MW reference wind turbine.
Steps to compile FAST, FAST S function and DISCON.so
- Download sources for FAST, AeroDyn and NWTC Subroutine Library.
- Create a folder for the sources, ex: ~/fast_build
- Extract the sources like so
FAST → ~/fast_build/fast
AeroDyn → ~/fast_build/aero
NWTC Lib → ~/fast_build/nwtc - Extract the attached tar ball fast_build.tar in ~/fast_build/
- Apply the two patches in the folder
cd ~/fast_build/
patch -p1 -d nwtc < nwtc.patch
patch -p1 -d fast < fast.patch
6. If the patches doesn’t apply, you might need to convert the source files from windows line endings to unix line endings. This can be done by the dos2unix tool.
dos2unix nwtc/Source/*
dos2unix fast/Source/*
dos2unix fast/Simulink/Source/*
7. If you are compiling the S function you need to change the MATLAB_DIR in the file ~/fast_build/Makefile to your Matlab installation. (Default is /opt/matlab)
8. To compilee FAST, FAST S function and a dummy DISCON.so file run
make
Or to compile them individually
[code] make FAST
make FAST_SFunc.mexa64
make DISCON.so[code]
I hope this is to some use.
Sincerly, Jesper
fast_build.tar (140 KB)