Hi Lewis,
Try using forward slashes instead of back-slashes, and also enclose the whole file path inside double quotes.
- Andrew
--
Sent from my iPad
> On May 22, 2018, at 5:46 PM, J. Lewis Muir <[email protected]> wrote:
>
> Hello, all.
>
> On Windows, when msi is used to expand a template substitution file that
> looks like:
>
> ===
> file C:\tmp2\dbExample1.db
> {
> pattern { user }
> { "luke" }
> }
> ===
>
> it produces an error (the full output is at the end of this email):
>
> ===
> gmake[3]: Entering directory 'C:/tmp/myModuleApp/Db/O.win32-x86'
> echo "../O.Common/dbExampleMerge.db : " >> dbExampleMerge.db.d
> echo "dbExampleMerge.db.d: " >> dbExampleMerge.db.d
> "Inflating database from ../dbExampleMerge.substitutions "
> msi -I. -I.. -I../O.Common -I../../../db -IC:/opt/epics-base/db -S../dbExampleMerge.substitutions > dbExampleMerge.tmp
> Could not open C:\tmp2\dbExample1.db
> input: which is
> gmake[3]: *** [C:/opt/epics-base/configure/RULES.Db:318: ../O.Common/dbExampleMerge.db] Error 1
> gmake[3]: Leaving directory 'C:/tmp/myModuleApp/Db/O.win32-x86'
> ===
>
> The problem seems to be related to the absolute pathname for the file
> directive in the template substitution file. If I change it to a
> relative path (i.e., file ..\..\tmp2\dbExample1.db) it works. However,
> I need to be able to use an absolute path.
>
> Does anyone know what's wrong and how to fix this?
>
> To reproduce this on Windows:
>
> ===
> C:\>call C:\opt\epics-base\startup\win32.bat
> C:\>mkdir tmp
> C:\tmp>cd tmp
> C:\tmp>makeBaseApp.pl -t example myModule
> C:\tmp>makeBaseApp.pl -i -t example myModule
> C:\tmp>cd ..
> C:\>mkdir tmp2
> C:\>copy tmp\myModuleApp\Db\dbExample1.db tmp2
> C:\>copy tmp\myModuleApp\Db\dbExample2.db tmp2
> ===
>
> Create the file C:\tmp\myModuleApp\Db\dbExampleMerge.substitutions:
>
> ===
> file C:\tmp2\dbExample1.db
> {
> pattern { user }
> { "luke" }
> }
>
> file C:\tmp2\dbExample2.db
> {
> pattern { user, no, scan }
> { "han", "1", "5 second" }
> }
> ===
>
> Add the following line, below the "DB += userHost.substitutions" line,
> to C:\tmp\myModuleApp\Db\Makefile:
>
> ===
> DB += dbExampleMerge.db
> ===
>
> Build:
>
> ===
> C:\>cd tmp
> C:\tmp>gmake
> ===
>
> Environment:
>
> * 32-bit Windows 7 Pro
> * Visual Studio C++ 2010 Express SP1
> * 32-bit Strawberry Perl 5.26.2.1
> * EPICS Base 3.14.12.7 + Known Problems patches
> * msi 1-7 + Andrew Johnson's patch from [1]
> * EPICS_HOST_ARCH=win32-x86
>
> Thank you!
>
> Lewis
>
> [1] https://epics.anl.gov/tech-talk/2015/msg01691.php
>
> ===
> C:\tmp>gmake
> gmake: Entering directory 'C:/tmp'
> gmake -C ./configure install
> gmake[1]: Entering directory 'C:/tmp/configure'
> perl C:/opt/epics-base/bin/win32-x86/makeMakefile.pl O.win32-x86 ../..
> perl -MExtUtils::Command -e mkpath O.Common
> gmake -C O.win32-x86 -f ../Makefile TOP=../.. \
> T_A=win32-x86 install
> gmake[2]: Entering directory 'C:/tmp/configure/O.win32-x86'
> perl C:/opt/epics-base/bin/win32-x86/convertRelease.pl checkRelease
> gmake[2]: Leaving directory 'C:/tmp/configure/O.win32-x86'
> gmake[1]: Leaving directory 'C:/tmp/configure'
> gmake -C ./myModuleApp install
> gmake[1]: Entering directory 'C:/tmp/myModuleApp'
> gmake -C ./src install
> gmake[2]: Entering directory 'C:/tmp/myModuleApp/src'
> perl C:/opt/epics-base/bin/win32-x86/makeMakefile.pl O.win32-x86 ../../..
> perl -MExtUtils::Command -e mkpath O.Common
> gmake -C O.win32-x86 -f ../Makefile TOP=../../.. \
> T_A=win32-x86 install
> gmake[3]: Entering directory 'C:/tmp/myModuleApp/src/O.win32-x86'
> perl C:/opt/epics-base/bin/win32-x86/makeIncludeDbd.pl base.dbd xxxSupport.dbd dbSubExample.dbd myModuleHello.dbd initTrace.dbd myModuleInclude.dbd
> echo "../O.Common/myModuleInclude.dbd : ../Makefile" >> myModule.dbd.d
> "Expanding dbd"
> "Installing dbd file ../../../dbd/xxxSupport.dbd"
> mkdir ../../../dbd
> "Installing created dbd file ../../../dbd/myModule.dbd"
> "Installing dbd file ../../../dbd/xxxRecord.dbd"
> echo "../O.Common/xxxRecord.h : ../Makefile" >> xxxRecord.h.d
> C:\\opt\\epics-base\\bin\\win32-x86\\dbToRecordtypeH.exe -I. -I.. -I../O.Common -I../../../dbd -IC:/opt/epics-base/dbd ../xxxRecord.dbd xxxRecord.h
> "Installing generated generic include file ../../../include/xxxRecord.h"
> mkdir ../../../include
> cl -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -MD -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\xxxRecord.c
> xxxRecord.c
> ..\xxxRecord.c(211) : warning C4244: '=' : conversion from 'epicsFloat64' to 'float', possible loss of data
> ..\xxxRecord.c(211) : warning C4244: '=' : conversion from 'epicsFloat64' to 'float', possible loss of data
> cl -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -MD -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\devXxxSoft.c
> devXxxSoft.c
> cl -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -MD -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\dbSubExample.c
> dbSubExample.c
> cl -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -MD -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\myModuleHello.c
> myModuleHello.c
> cl -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -MD -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\initTrace.c
> initTrace.c
> link -nologo -subsystem:windows -dll -LTCG -incremental:no -opt:ref -release -implib:myModuleSupport.lib -out:myModuleSupport.dll xxxRecord.obj devXxxSoft.obj dbSubExample.obj myModuleHello.obj initTrace.obj C:\\opt\\epics-base\\lib\\win32-x86\\recIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\softDevIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\miscIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\rsrvIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbtoolsIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\asIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\registryIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbStaticIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\ca.lib C:\\opt\\epics-base\\lib\\win32-x86\\Com.lib
> Creating library myModuleSupport.lib and object myModuleSupport.exp
> Generating code
> Finished generating code
> "Installing shared library ../../../bin/win32-x86/myModuleSupport.dll"
> mkdir ../../../bin/win32-x86
> "Installing library ../../../lib/win32-x86/myModuleSupport.lib"
> mkdir ../../../lib/win32-x86
> perl C:/opt/epics-base/bin/win32-x86/registerRecordDeviceDriver.pl ../O.Common/myModule.dbd myModule_registerRecordDeviceDriver C:/tmp > myModule.tmp
> perl -MExtUtils::Command -e mv myModule.tmp myModule_registerRecordDeviceDriver.cpp
> cl -EHsc -GR -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -w44355 -w44344 -w44251 -MD -TP -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include myModule_registerRecordDeviceDriver.cpp
> myModule_registerRecordDeviceDriver.cpp
> cl -EHsc -GR -c -nologo -D__STDC__=0 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -Ox -GL -Oy- -W3 -w44355 -w44344 -w44251 -MD -TP -I. -I..\\O.Common -I. -I.. -I..\\..\\..\\include\\os\\WIN32 -I..\\..\\..\\include -IC:\\opt\\epics-base\\include\\os\\WIN32 -IC:\\opt\\epics-base\\include ..\\myModuleMain.cpp
> myModuleMain.cpp
> link -nologo -LTCG -incremental:no -opt:ref -release -out:myModule.exe myModule_registerRecordDeviceDriver.obj myModuleMain.obj ..\\..\\..\\lib\\win32-x86\\myModuleSupport.lib C:\\opt\\epics-base\\lib\\win32-x86\\recIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\softDevIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\miscIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\rsrvIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbtoolsIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\asIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\registryIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\dbStaticIoc.lib C:\\opt\\epics-base\\lib\\win32-x86\\ca.lib C:\\opt\\epics-base\\lib\\win32-x86\\Com.lib
> Generating code
> Finished generating code
> "Installing created file ../../../bin/win32-x86/myModule.exe"
> gmake[3]: Leaving directory 'C:/tmp/myModuleApp/src/O.win32-x86'
> gmake[2]: Leaving directory 'C:/tmp/myModuleApp/src'
> gmake -C ./Db install
> gmake[2]: Entering directory 'C:/tmp/myModuleApp/Db'
> perl C:/opt/epics-base/bin/win32-x86/makeMakefile.pl O.win32-x86 ../../..
> perl -MExtUtils::Command -e mkpath O.Common
> gmake -C O.win32-x86 -f ../Makefile TOP=../../.. \
> T_A=win32-x86 install
> gmake[3]: Entering directory 'C:/tmp/myModuleApp/Db/O.win32-x86'
> echo "../O.Common/dbExampleMerge.db : " >> dbExampleMerge.db.d
> echo "dbExampleMerge.db.d: " >> dbExampleMerge.db.d
> "Inflating database from ../dbExampleMerge.substitutions "
> msi -I. -I.. -I../O.Common -I../../../db -IC:/opt/epics-base/db -S../dbExampleMerge.substitutions > dbExampleMerge.tmp
> Could not open C:\tmp2\dbExample1.db
> input: which is
> gmake[3]: *** [C:/opt/epics-base/configure/RULES.Db:318: ../O.Common/dbExampleMerge.db] Error 1
> gmake[3]: Leaving directory 'C:/tmp/myModuleApp/Db/O.win32-x86'
> gmake[2]: *** [C:/opt/epics-base/configure/RULES_ARCHS:61: install.win32-x86] Error 2
> gmake[2]: Leaving directory 'C:/tmp/myModuleApp/Db'
> gmake[1]: *** [C:/opt/epics-base/configure/RULES_DIRS:83: Db.install] Error 2
> gmake[1]: Leaving directory 'C:/tmp/myModuleApp'
> gmake: *** [C:/opt/epics-base/configure/RULES_DIRS:83: myModuleApp.install] Error 2
> gmake: Leaving directory 'C:/tmp'
> ===
- Replies:
- Re: msi "Could not open" error on Windows with file absolute path J. Lewis Muir
- References:
- msi "Could not open" error on Windows with file absolute path J. Lewis Muir
- Navigate by Date:
- Prev:
RE: [UNTRUSTED] Problem accessing TextUpdate text property in Display Builder script. Gregory, Ray
- Next:
Re: Is it possible to make an IOC for an HTTP device? J. Lewis Muir
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
<2018>
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
msi "Could not open" error on Windows with file absolute path J. Lewis Muir
- Next:
Re: msi "Could not open" error on Windows with file absolute path J. Lewis Muir
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
<2018>
2019
2020
2021
2022
2023
2024
|