Commit 754c0771 authored by Alois SCHLOEGL's avatar Alois SCHLOEGL
Browse files

fix install.bat

parent b4702b83
......@@ -5,25 +5,19 @@ REM
REM Copyright (C) 2021 Alois Schlögl, IST Austria
REM make install run as admin
REM https://developpaper.com/how-to-make-bat-batch-run-with-administrators-permission/
REM mshta vbscript:CreateObject("Shell.Application").ShellExecute("cmd.exe","/c %~s0 ::","","runas",1)(window.close)&&exit /B
ECHO OFF
REM directory of FPulse
REM source directory of FPulse
set SRCDIR="%~dp0"
REM installation directory of FPulse
set DESTDIR=C:\FPulse
REM Directory to Igor Pro User files - here are some examples
REM Windows10
SET IPUF=%UserProfile%"\Documents\WaveMetrics\Igor Pro 6 User Files\"
REM https://superuser.com/questions/253935/what-is-the-difference-between-symbolic-link-and-shortcut
if not exist %IPUF% (
REM WinXP
SET IPUF="C:\Program Files (x86)\WaveMetrics\Igor Pro Folder\"
)
SET IPUF="C:\Program Files (x86)\WaveMetrics\Igor Pro Folder\"
if not exist %IPUF% (
echo ERROR: Igor-pro-user-files-folder not found
exit /B
......@@ -31,12 +25,14 @@ if not exist %IPUF% (
REM === UNINSTALL ===
if [%1]==[-u] (
del /Q %SRCDIR%UserIgor\FPulse_
del /Q %IPUF%"Igor Extensions\"FP_Mc700Tg.xop
del /Q %IPUF%"Igor Extensions\"FPulseCed.xop
del /Q %IPUF%"Igor Help Files\"FPulse.ihf
del /Q %IPUF%"Igor Procedures\"FPulse.ipf
del /Q %IPUF%"User Procedures\"FPulse_
rmdir %IPUF%"User Procedures\"FPulse
rmdir %IPUF%"User Procedures\"FPulse_
rmdir /S /Q %DESTDIR%
REM --- FIXME: need elevated permissions ---
del /Q C:\windows\SysWOW64\Use1432.dll
del /Q C:\windows\SysWOW64\CFS32.dll
del /Q C:\windows\SysWOW64\AxMultiClampMsg.dll
......@@ -45,25 +41,26 @@ if [%1]==[-u] (
REM === COPYING THE FILES ===
xcopy %SRCDIR%UserIgor\FPulse %DESTDIR% /E /I
mkdir %DESTDIR%\XOPs
copy %SRCDIR%\UserIgor\XOP_Axon\FP_Mc700Tg\VC2015\FP_Mc700Tg.xop %DESTDIR%\XOPs\
copy %SRCDIR%\UserIgor\XOP_Ced\FPulseCed\VC2015\FPulseCed.xop %DESTDIR%\XOPs\
REM --- FIXME: need elevated permissions ---
copy %SRCDIR%UserIgor\XOP_Dll\Use1432.dll c:\windows\SysWOW64\
copy %SRCDIR%UserIgor\XOP_Dll\CFS32.dll c:\windows\SysWOW64\
copy %SRCDIR%UserIgor\XOP_Dll\AxMultiClampMsg.dll c:\windows\SysWOW64\
copy %SRCDIR%UserIgor\FPulse %SRCDIR%UserIgor\FPulse_
mkdir %SRCDIR%UserIgor\FPulse_\XOPs
copy %SRCDIR%UserIgor\XOP_Axon\FP_Mc700Tg\VC2015\FP_Mc700Tg.xop %SRCDIR%UserIgor\FPulse_\XOPs\
copy %SRCDIR%UserIgor\XOP_Ced\FPulseCed\VC2015\FPulseCed.xop %SRCDIR%UserIgor\FPulse_\XOPs\
REM === CREATING THE REQUIRED LINKS ===
mklink %IPUF%"Igor Extensions\"FP_Mc700Tg.xop %SRCDIR%"UserIgor\FPulse_\XOPs\FP_Mc700Tg.xop"
mklink %IPUF%"Igor Extensions\"FPulseCed.xop %SRCDIR%"UserIgor\FPulse_\XOPs\FPulseCed.xop"
mklink %IPUF%"Igor Help Files\"FPulse.ihf %SRCDIR%"UserIgor\FPulse_\FPulse.ihf"
mklink %IPUF%"Igor Procedures\"FPulse.ipf %SRCDIR%"UserIgor\FPulse_\FPulse.ipf"
mklink /D %IPUF%"User Procedures\"FPulse_ %SRCDIR%"UserIgor\FPulse_"
mklink %IPUF%"Igor Extensions\"FP_Mc700Tg.xop %DESTDIR%\XOPs\FP_Mc700Tg.xop
mklink %IPUF%"Igor Extensions\"FPulseCed.xop %DESTDIR%\XOPs\FPulseCed.xop
mklink %IPUF%"Igor Help Files\"FPulse.ihf %DESTDIR%\FPulse.ihf
mklink %IPUF%"Igor Procedures\"FPulse.ipf %DESTDIR%\FPulse.ipf
mklink /D %IPUF%"User Procedures\"FPulse %DESTDIR%
REM === START IgorPro ===
ECHO start Igor.exe
Echo execution completed, any key to exit
exit /B
Supports Markdown
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