×

Discussion Board

Results 1 to 7 of 7
  1. #1
    Registered User
    Join Date
    Jul 2003
    Posts
    28

    What is the replacement for E32Dll and TDllReason?

    So I read that TDllReason is not defined anymore
    and DLL entry point is not needed.

    But what if I need an entry point and Reason
    to initialize/uninitialize some stuff?

    What is the alternative to the old and trusted
    E32Dll(TDllReason), which is used in too many DLLs?

    Thank you
    John

  2. #2
    Super Contributor
    Join Date
    Mar 2004
    Location
    Czech Republic
    Posts
    2,037

    Re: What is the replacement for E32Dll and TDllReason?

    Hi,
    I don't know if you had the same problem as me, but try look here
    http://discussion.forum.nokia.com/fo...ad.php?t=80742
    Bye
    STeN

  3. #3
    Registered User
    Join Date
    Jul 2003
    Posts
    28

    Re: What is the replacement for E32Dll and TDllReason?

    No, I don't think EPOCCALLDLLENTRYPOINTS
    is applicable because the whole E32Dll along with TDllReason
    was removed from EKA2 (S60 3rd ed).

    And it is not clear what it should be replaced with.

  4. #4
    Super Contributor
    Join Date
    Nov 2005
    Location
    London
    Posts
    584

    Re: What is the replacement for E32Dll and TDllReason?

    You don't need to replace it, but can just remove it.

  5. #5
    Registered User
    Join Date
    Jul 2003
    Posts
    28

    Re: What is the replacement for E32Dll and TDllReason?

    > You don't need to replace it, but can just remove it.

    Thank you, but this is not an answer, sorry.

    DLLs often need to initialize certain per-process data
    when loaded or unloaded and most OS provide
    a mean to do that. Symbian used to have E32Dll(TDllReason), but now it is removed without
    any alternative given.

  6. #6
    Super Contributor
    Join Date
    Nov 2005
    Location
    London
    Posts
    584

    Re: What is the replacement for E32Dll and TDllReason?

    Sorry, I didn't read your first post properly - I understand now that you want an alternative to the entry point for initialization.

    I think lack of an equivalent probably reflects the view that initialization should be owned by something (ie there should be a top-level object responsible which must be created to perform initialization before other classes and methods exported from the class are used. If there isn't an owning class, initialization is pretty limited to global data anyway.

    However, if it's a polymorphic (interface) dll, you do have the "gate" function to do perform initialization.

  7. #7
    Registered User
    Join Date
    Jul 2003
    Posts
    28

    Re: What is the replacement for E32Dll and TDllReason?

    Thank you for your answer.

    >However, if it's a polymorphic (interface) dll,
    >you do have the "gate" function to do perform initialization.

    In this trivial case I wouldn't have had the problem
    and wouldn't have posted this question.

    I really appreciate your answers,
    but, please, don't waste your time posting obvious
    suggestions, such as to redesign the code to have
    clients explicitly call the DLL to initialize
    and uninitialize.

    The purpose of this post was to confirm whether
    Symbian, indeed, eliminated DLL entry point
    and there is no alternatives provided by the OS.

    The documentation for S60 3rd ed is a total mess:
    it was only partially updated. You can still see such
    statements as "The E32Dll() function is required by all DLLs;"

    So, I thought I would ask the forum to double check.

Similar Threads

  1. Problem: Error: undefined identifier 'TDllReason'
    By ice_nadin in forum Carbide.c++ IDE and plug-ins (Closed)
    Replies: 14
    Last Post: 2008-12-30, 07:45
  2. TDllReason - Symbian v9.1
    By jainygaurav in forum Symbian
    Replies: 2
    Last Post: 2005-06-01, 23:32

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×