Issue 127731 - AOO fails to open ODBC manager
Summary: AOO fails to open ODBC manager
Status: CONFIRMED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: 4.2.0-dev
Hardware: All Windows, all
: P5 (lowest) Normal (vote)
Target Milestone: 4.2.0
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2018-03-11 10:09 UTC by Matthias Seidel
Modified: 2019-10-25 02:23 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---
jim: 4.2.0_release_blocker+


Attachments
Error when trying to open ODBC administrator from within AOO (20.19 KB, image/png)
2018-03-11 10:09 UTC, Matthias Seidel
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Matthias Seidel 2018-03-11 10:09:53 UTC
Created attachment 86363 [details]
Error when trying to open ODBC administrator from within AOO

This is a regression on Windows (AOO 4.1.5 works as expected).

Steps to reproduce:

 - File | New | Database
 - Choose Connect to existing database
 - Choose ODBC as type
 - Click Next >>
 - Click Browse
 - Click Organize...

Result:

ODBC administrator can not be opened. Sometimes I get an error message, sometimes it fails to load silently.

Expected behavior:

On Windows32 the ODBC administrator (odbcad32.exe) should be opened.
(On future Windows64 builds odbcad64.exe should be opened instead)
Comment 1 Matthias Seidel 2018-03-13 10:24:53 UTC
Actually AOO tries to open its own odbcconfig.exe which is only a "wrapper" to launch the ODBC manager from Windows.

See (lines 364 ff.):
https://svn.apache.org/repos/asf/openoffice/trunk/main/dbaccess/source/ui/dlg/odbcconfig.cxx

and:
https://svn.apache.org/repos/asf/openoffice/trunk/main/dbaccess/win32/source/odbcconfig/odbcconfig.cxx
Comment 2 Matthias Seidel 2018-03-13 10:55:18 UTC
Changes seem to be in Revision 1755455:

https://svn.apache.org/viewvc?limit_changes=0&view=revision&revision=1755455

"Merge branches/gbuild-reintegration to trunk."
Comment 3 Peter 2019-06-07 04:49:19 UTC
Hi Matthias,

are you the only one with this error?
Have you tried to fix this like suggested here:

https://errortools.com/windows/fix-runtime-error-r6034/
Comment 4 damjan 2019-06-07 05:26:42 UTC
Does this happen on a product build or non-product build?

Please post all your ./configure flags.

Also please post the output of:

DUMPBIN /IMPORTS C:\path\to\odbcconfig.exe

(you might need to run MSVC's VCVARS.BAT first)
Comment 5 Matthias Seidel 2019-06-07 22:21:23 UTC
(In reply to Peter from comment #3)
> Hi Matthias,
> 
> are you the only one with this error?
> Have you tried to fix this like suggested here:
> 
> https://errortools.com/windows/fix-runtime-error-r6034/

Hi Peter,

Damjan could reproduce it, see also i127732.
Comment 6 Matthias Seidel 2019-06-08 18:40:31 UTC
(In reply to damjan from comment #4)
> Does this happen on a product build or non-product build?
> 
> Please post all your ./configure flags.
> 
> Also please post the output of:
> 
> DUMPBIN /IMPORTS C:\path\to\odbcconfig.exe
> 
> (you might need to run MSVC's VCVARS.BAT first)

This happens with trunk and 42x so I wouldn't call it a production build.

But the configure is almost identical to a release version:
http://svn.apache.org/repos/asf/openoffice/devtools/build-scripts/4.2.0-Dev1/wntmsci/ReadMe.txt

dumpbin.exe gives me an error, see issue 127732.
Comment 7 Matthias Seidel 2019-07-07 12:57:04 UTC
Looking at the log from our Windows buildbot:

https://ci.apache.org/projects/openoffice/buildlogs/win/main/dbaccess/wntmsci12.pro/misc/logs/prj.txt

esp. this line seems wrong:

R=/cygdrive/e/slave14/aoo-win7/build && S=$R/main && O=$S/solver/450/wntmsci12.pro && W=$O/workdir &&  mkdir -p $O/bin/ && /usr/bin/cp --remove-destination -R -P --force --preserve=timestamps $W/LinkTarget/Executable/odbcconfig.exe $O/bin/odbcconfig.exe  && mkdir -p $O/bin/ && /usr/bin/cp --remove-destination -R -P --force --preserve=timestamps $W/LinkTarget/Executable//odbcconfig.exe.manifest $O/bin/odbcconfig.exe.manifest

Where does the double slash (//) come from?
Comment 8 damjan 2019-10-25 02:23:11 UTC
We should get hold of the odbcconfig.exe binary from before and after the commit that broke it, and examine its layout (imports, sections, symbols, etc.). There must be some difference there.