History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: CORE-1814
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Adriano dos Santos Fernandes
Reporter: Adriano dos Santos Fernandes
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Change the root determination of the embedded Windows engine and load DLLs with altered search path (to search dependent DLLs on the same path of the loaded DLL)

Created: 01/Apr/08 11:25 AM   Updated: 03/Apr/08 11:27 AM
Component/s: API / Client Library, Engine, UDF
Affects Version/s: 2.5 Initial
Fix Version/s: 2.5 Alpha 1

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown

Resolution Date: 01/Apr/08
Planning Status: Unspecified


 Description  « Hide
This is a Windows specific proposal, with three items. The first is
independent, the second depends one the first and the third depends one
the first and the second.

1) If I use an UDF DLL that depends one others DLLs, I current can't put
all DLLs in <root>\udf. I need to put the dependencies in <root>\bin or
in some other place in %PATH%.

I propose we change ModuleLoader to load with LoadLibraryEx(...,
LOAD_WITH_ALTERED_SEARCH_PATH), so the dependencies are searched in the
same directory as the library being loaded.

2) Above change makes it possible to the application developer load
fbembed.dll with altered search path too. But our rules to determine
<root> is based on the application EXE directory.

I propose we change the root determination of the embedded engine to be
path of fbembed.dll. This is a change compatible with the current
documented way to use embedded, where fbembed.dll and the application
EXE should be in the same directory.


 All   Comments   Work Log   Change History   Version Control   Subversion Commits      Sort Order:
Vlad Khorsun - [03/Apr/08 08:31 AM ]
Currently fbserver is unable to load own ib_udf.dll as it depends on ib_util.dll which placed in \bin folder while ib_udf.dll is in \udf ;)
I offer or put ib_util.dll in \udf or, better as for me, add \bin folder into altered search paths too.

Dmitry Yemanov - [03/Apr/08 08:44 AM ]
Putting it into /udf is not a good option, as people may have 3rd party UDF libs in other locations and they may also depend on ib_util. I don't think we should tell them to copy ib_util everywhere.

Adriano dos Santos Fernandes - [03/Apr/08 11:27 AM ]
Loading ib_util.dll in the engine, it will be already be loaded and no problems happen latter.

I'm going to do this, but if it can't be loaded there will be no error or warning...

Do you see any problem?