Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Jan 2006

    Question related to DLL

    Greetings All,
    I have some global data in one of the project for symbian earlier everything was fine because no one was using it as or for the DLL.
    Now the problem is that my project is a DLL but i have to use the project which is having global data and symbain is not allowing to build it with the obvious reason that few of my files have global data. I cant change the code having global data.

    So can any one give me a way out so that i can make my dll work with global data. If yes please explain.


  2. #2
    Regular Contributor
    Join Date
    May 2005
    Brasov, Romania

    Re: Question related to DLL

    Use Dll::Tls() and Dll::StTls() to pack your "global static" data into the main thread and use it further.

    Search for this in Symbian documentation.

  3. #3
    Nokia Developer Champion
    Join Date
    Jul 2004

    Re: Question related to DLL

    Global data is allowed as long as its not writable, is your data readable only? If so maybe you can make it const. If its writable then you can use TLS as mentioned or turn your dll into an exe or use 9.x.

  4. #4
    Super Contributor
    Join Date
    Nov 2005

    Re: Question related to DLL

    or, another alternative to those mentioned by hotcheese, would be to remove the readable global data, if possible.

    Maybe it's too much effort to re-factor the code, but you can often remove the need for global data by doing so.

Similar Threads

  1. A slightly different DLL question
    By jonofrio in forum Symbian
    Replies: 3
    Last Post: 2007-02-27, 07:17
  2. Linking Static DLL with another Static DLL
    By symbianfresher in forum Symbian
    Replies: 6
    Last Post: 2006-01-09, 04:23
  3. Replies: 0
    Last Post: 2003-04-27, 21:38
  4. Question about DLL size limited.
    By kangtk in forum Symbian
    Replies: 1
    Last Post: 1970-01-01, 02:00
  5. Question related to Message Type ?
    By naoriya in forum General Messaging
    Replies: 2
    Last Post: 1970-01-01, 02:00

Posting Permissions

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