Commit 079aac50 authored by Daniel Brown's avatar Daniel Brown

Merge branch 'master' into develop

parents 753ef007 2c1dd590
......@@ -224,6 +224,13 @@ build()
fi
fi
#------------ don't know why this is here ---------------------
#gsl_libpath=`gsl-config --libs | cut -d " " -f1`
#gsl_libpath=${gsl_libpath#-L}
#gsl_libpath=${gsl_libpath#-l}
# Setting GSL_LIBS flags to allow static linking
#export GSL_LIBS="$gsl_libpath/libgslcblas.a $gsl_libpath/libgsl.a"
echo "Calling make file, see make.log for more details..."
echo ""
......@@ -362,7 +369,7 @@ case "$1" in
NATIVE="-march=native"
CPUARCH=""
target_arch=$platform
if [[ "$platform" == 'linux' ]]; then
TARGET=$TARGET_LINUX
elif [[ "$platform" == 'mac' ]]; then
......
Install packages to build Anaconda packages:
conda install conda-build anaconda-client
conda install conda-build anaconda-client git
To clean up run:
conda build purge
......
@ECHO ON
SET LookForFile="%SRC_DIR%\kat.exe"
chdir /d %SRC_DIR%
IF "%ARCH%"=="64" (
c:\msys64\mingw64 /bin/bash ./finesse.sh --build-win64
)
IF "%ARCH%"=="32" (
c:\msys32\mingw32 /bin/bash ./finesse.sh --build-win32
)
@ECHO OFF
:CheckForFile
IF EXIST %LookForFile% GOTO FoundIt
TIMEOUT /T 2 >nul
GOTO CheckForFile
:FoundIt
ECHO Found: %LookForFile%
@ECHO ON
TIMEOUT /T 2 >nul
xcopy %SRC_DIR%\kat.exe "%PREFIX%\Library\bin\"
xcopy %SRC_DIR%\kat.ini "%PREFIX%\Library\bin\"
mkdir %PREFIX%\etc\conda\activate.d
mkdir %PREFIX%\etc\conda\deactivate.d
type NUL > %PREFIX%\etc\conda\activate.d\finesse_vars.bat
type NUL > %PREFIX%\etc\conda\deactivate.d\finesse_vars.bat
type NUL > %PREFIX%\etc\conda\activate.d\finesse_vars.ps1
type NUL > %PREFIX%\etc\conda\deactivate.d\finesse_vars.ps1
echo @ECHO OFF >> %PREFIX%\etc\conda\activate.d\finesse_vars.bat
echo SET KATINI=%%CONDA_PREFIX%%\Library\bin\kat.ini >> %PREFIX%\etc\conda\activate.d\finesse_vars.bat
echo SET FINESSE_DIR=%%CONDA_PREFIX%%\Library\bin >> %PREFIX%\etc\conda\activate.d\finesse_vars.bat
echo $env:KATINI="$env:CONDA_PREFIX\Library\bin\kat.ini" >> %PREFIX%\etc\conda\activate.d\finesse_vars.ps1
echo $env:FINESSE_DIR="$env:CONDA_PREFIX\Library\bin"" >> %PREFIX%\etc\conda\activate.d\finesse_vars.ps1
echo @ECHO OFF >> %PREFIX%\etc\conda\deactivate.d\finesse_vars.bat
echo SET KATINI= >> %PREFIX%\etc\conda\deactivate.d\finesse_vars.bat
echo SET FINESSE_DIR= >> %PREFIX%\etc\conda\deactivate.d\finesse_vars.bat
echo $env:KATINI= >> %PREFIX%\etc\conda\deactivate.d\finesse_vars.ps1
echo $env:FINESSE_DIR= >> %PREFIX%\etc\conda\deactivate.d\finesse_vars.ps1
\ No newline at end of file
#!/bin/bash
platform='unknown'
unamestr=`uname`
unamem=`uname -m`
branch=`git rev-parse --abbrev-ref HEAD`
if [[ "$unamestr" == 'Linux' ]]; then
if [[ "${ARCH}" == '32' ]]; then
./finesse.sh --build-linux32
else
./finesse.sh --build-linux
fi
cp ./kat ${PREFIX}/bin
cp ./kat.ini ${PREFIX}/bin
elif [[ "$unamestr" == 'Darwin' ]]; then
if [[ "${ARCH}" == '32' ]]; then
./finesse.sh --build-mac32
else
./finesse.sh --build-mac
fi
cp ./kat ${PREFIX}/bin
cp ./kat.ini ${PREFIX}/bin
elif [[ "$unamestr" == *CYGWIN* ]]; then
if [[ "$unamem" == 'i686' ]]; then
./finesse.sh --build-win32
else
./finesse.sh --build-win64
fi
cp ./kat.exe ${PREFIX}/bin
cp ./kat.ini ${PREFIX}/bin
elif [[ "$unamestr" == *MINGW32* ]]; then
echo "Platform not supported" | tee -a $LOGFILE
failure
else
echo "Platform could not be determined" | tee -a $LOGFILE
failure
fi
# Setup saved env vars https://conda.io/docs/using/envs.html
mkdir -p ${PREFIX}/etc/conda/activate.d
mkdir -p ${PREFIX}/etc/conda/deactivate.d
touch ${PREFIX}/etc/conda/activate.d/finesse_vars.sh
touch ${PREFIX}/etc/conda/deactivate.d/finesse_vars.sh
echo "#!/bin/bash" >> ${PREFIX}/etc/conda/activate.d/finesse_vars.sh
echo "export KATINI=\${CONDA_PREFIX}/bin/kat.ini" >> ${PREFIX}/etc/conda/activate.d/finesse_vars.sh
echo "export FINESSE_DIR=\${CONDA_PREFIX}/bin/" >> ${PREFIX}/etc/conda/activate.d/finesse_vars.sh
echo "#!/bin/bash" >> ${PREFIX}/etc/conda/deactivate.d/finesse_vars.sh
echo "unset KATINI" >> ${PREFIX}/etc/conda/deactivate.d/finesse_vars.sh
echo "unset FINESSE_DIR" >> ${PREFIX}/etc/conda/deactivate.d/finesse_vars.sh
\ No newline at end of file
package:
name: finesse
version: 2.3
source:
git_rev: 2.3-0-gd4652a77
git_url: ../../
build:
number: 0
about:
home: www.gwoptics.org/finesse
license: GPL3
license_file: LICENSES
......@@ -11050,7 +11050,7 @@ int assign_lens_parameter(component_param_t *component_param) {
*component_param->uborder = 0;
} else if (strcasecmp("Px", component_param->parameter) == 0) {
if(lens->is_astigmatic){
if(!lens->is_astigmatic){
gerror("Use P parameter when tuning spherical lens %s\n", lens->name);
}
if(lens->is_focal_length){
......@@ -11068,7 +11068,7 @@ int assign_lens_parameter(component_param_t *component_param) {
*component_param->uborder = 0;
} else if (strcasecmp("Py", component_param->parameter) == 0) {
if(lens->is_astigmatic){
if(!lens->is_astigmatic){
gerror("Use P parameter when tuning spherical lens %s\n", lens->name);
}
if(lens->is_focal_length){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment