Ok, so issue with standalone utility is irrelevant to ours. Thank you for hint about flag
I testedthat solution.
First, pvf_dll’s project didn’t had path setup, but I supplied it - I guess, it was determined by fact that it requires full path to .exe.
Second - it didn’t work. Setting pvf_dll as StartUp project and running Debug session resulted in Visual Studio hanging.
Edit:
Apparently, debug for that project didn’t worked at all, although program was compiled succefully. Even if I used pvf_calling_dll as StartUp. Next, I tried to copy project folder to other location, trying to check if issue is with folder permissions and way Win7 treats Program Files. Surprisingly, it failed to compile at all. Despite projects are identical, logs for pvf_dll are quite different and in relocated project it failed to generate .lib file and gave weird messages:
Succeful build
PVF Build Log
Begin rebuild: clean project
Deleting intermediate and output files for project 'pvf_dll', configuration 'Debug'
Compiling Project ...
sub1.f90
c:\program files (x86)\pgi\win32\12.10\bin\pgfortran.exe -Hx,123,8 -Hx,123,0x40000 -Hx,0,0x40000000 -Mx,0,0x40000000 -Hx,0,0x20000000 -g -Bdynamic -Mbackslash -Mfree -I"c:\program files (x86)\pgi\win32\12.10\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\include" -I"C:\Program Files\PGI\Microsoft Open Tools 10\PlatformSDK\include" -Minform=warn -module "Win32\Debug" -o "Win32\Debug\sub1.obj" -c "C:\Program Files (x86)\Microsoft Visual Studio 10.0\PGI Visual Fortran\Samples\dlls\pvf_dll\pvf_dll\sub1.f90"
Command exit code: 0
--------------------------------------------------------------------------------
Linking...
c:\program files (x86)\pgi\win32\12.10\bin\pgfortran.exe -Wl,/libpath:"c:\program files (x86)\pgi\win32\12.10\lib" -Wl,/libpath:"C:\Program Files\PGI\Microsoft Open Tools 10\lib" -Wl,/libpath:"C:\Program Files\PGI\Microsoft Open Tools 10\PlatformSDK\lib" -Wl,/libpath:"C:\Program Files (x86)\PGI\win32\12.10\lib" -Wl,/libpath:"C:\Program Files\PGI\win64\12.10\lib" -Yl,"C:\Program Files\PGI\Microsoft Open Tools 10\bin" -Mmakedll -g -Bdynamic -o "C:\Program Files (x86)\Microsoft Visual Studio 10.0\PGI Visual Fortran\Samples\dlls\pvf_dll\Win32\Debug\pvf_dll.dll" "Win32\Debug\sub1.obj"
Command exit code: 0
Command output: [ Creating library C:\Program Files (x86)\Microsoft Visual Studio 10.0\PGI Visual Fortran\Samples\dlls\pvf_dll\Win32\Debug\pvf_dll.lib and object C:\Program Files (x86)\Microsoft Visual Studio 10.0\PGI Visual Fortran\Samples\dlls\pvf_dll\Win32\Debug\pvf_dll.exp ]
pvf_dll build succeeded.
Failed build
PVF Build Log
Begin rebuild: clean project
Deleting intermediate and output files for project 'pvf_dll', configuration 'Debug'
Compiling Project ...
Linking...
c:\program files (x86)\pgi\win32\12.10\bin\pgfortran.exe -Wl,/libpath:"c:\program files (x86)\pgi\win32\12.10\lib" -Wl,/libpath:"C:\Program Files\PGI\Microsoft Open Tools 10\lib" -Wl,/libpath:"C:\Program Files\PGI\Microsoft Open Tools 10\PlatformSDK\lib" -Wl,/libpath:"C:\Program Files (x86)\PGI\win32\12.10\lib" -Wl,/libpath:"C:\Program Files\PGI\win64\12.10\lib" -Yl,"C:\Program Files\PGI\Microsoft Open Tools 10\bin" -Mmakedll -g -Bdynamic -o "D:\Programming\Fortran\pvf_dll\Win32\Debug\pvf_dll.dll" ""
Command exit code: 0
Command output: [LINK : warning LNK4001: no object files specified; libraries used LINK : warning LNK4068: /MACHINE not specified; defaulting to X86 ]
pvf_dll build succeeded.