Results 1 to 6 of 6

Thread: link error when Compile a static lib with icetouch 1.1.0

  1. #1
    cenlei1988 is offline Registered User
    Name: Lei Chen
    Organization: Tisson Regaltec Technologies Co.,Ltd.
    Project: Video Monitoring System, use ice to communicate
    Join Date
    Jun 2011
    Posts
    1

    Red face link error when Compile a static lib with icetouch 1.1.0

    hello all, I am developing a iPhone client that using icetouch to communicate with server.

    first,I complete a app demo, use ice,it works well. I need to offer a static lib to others,so Compile a static lib with icetouch 1.1.0. but there's link error like that:
    Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool failed with exit code 1

    Latest Results is that:

    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool: -dynamic not specified, -all_load invalid
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool: -dynamic not specified the following flags are invalid: -ObjC
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool: can't locate file for: -lstdc++
    /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool: file: -lstdc++ is not an object file (not allowed in a library)
    Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/libtool failed with exit code 1

    How can i fix it ? i am new to iPhone development,and my XCODE 3.2.3,iphone SDK 4
    I have try to Compile it with lastest Xcode yesterday,but there is same error.
    thinks.

  2. #2
    benoit's Avatar
    benoit is offline ZeroC Staff
    Name: Benoit Foucher
    Organization: ZeroC, Inc.
    Project: Ice
    Join Date
    Feb 2003
    Location
    Rennes, France
    Posts
    2,196
    Hi,

    Could you explain a little more what you are trying to build? The Xcode plugin sets up all the configuration to build Ice Touch applications, if you are trying to create a static library, you'll most likely need to specify those settings manually.

    Cheers,
    Benoit.

  3. #3
    ebetzler is offline Registered User
    Name: Eric Betzler
    Organization: St. Jude Medical
    Project: icetouch
    Join Date
    Dec 2011
    Posts
    2
    Quote Originally Posted by benoit View Post
    Hi,

    Could you explain a little more what you are trying to build? The Xcode plugin sets up all the configuration to build Ice Touch applications, if you are trying to create a static library, you'll most likely need to specify those settings manually.

    Cheers,
    Benoit.
    Could you expand on this? I have the same problem. What settings need to be set manually?
    What specifically does the Xcode plugin do that I need to recreate?

  4. #4
    benoit's Avatar
    benoit is offline ZeroC Staff
    Name: Benoit Foucher
    Organization: ZeroC, Inc.
    Project: Ice
    Join Date
    Feb 2003
    Location
    Rennes, France
    Posts
    2,196
    Hi Eric,

    Which Ice Touch version do you use?

    The Xcode plugin installed by the Ice Touch 1.2 installer is supposed to setup the correct settings for compiling your application with Ice Touch. You just need to specify the Ice Touch SDK path in the "Additional SDKs" setting of your project (for example set it to /Developer/SDKs/IceTouch-1.2/$(PLATFORM_NAME).sdk). See also the instructions from the Ice Touch Release Notes.

    Cheers,
    Benoit.

  5. #5
    benoit's Avatar
    benoit is offline ZeroC Staff
    Name: Benoit Foucher
    Organization: ZeroC, Inc.
    Project: Ice
    Join Date
    Feb 2003
    Location
    Rennes, France
    Posts
    2,196
    Note that if you are trying to build a static library, it's currently not supported by the Ice Touch Xcode plugin. You will need to manually setup the compiler flags with your Xcode project, so do not set "Additional SDKs" to disable the Xcode plugin and add /Developer/SDKs/IceTouch-1.2/$(PLATFORM_NAME)/usr/local/include to your include directories. You will also need to either manually compile the Slice files with slice2objc or write a script to do it. We will check whether or not we can add support for static library projects to the Ice Touch Xcode plugin.

    Cheers,
    Benoit.

  6. #6
    ebetzler is offline Registered User
    Name: Eric Betzler
    Organization: St. Jude Medical
    Project: icetouch
    Join Date
    Dec 2011
    Posts
    2

    That worked

    Quote Originally Posted by benoit View Post
    Note that if you are trying to build a static library, it's currently not supported by the Ice Touch Xcode plugin. You will need to manually setup the compiler flags with your Xcode project, so do not set "Additional SDKs" to disable the Xcode plugin and add /Developer/SDKs/IceTouch-1.2/$(PLATFORM_NAME)/usr/local/include to your include directories. You will also need to either manually compile the Slice files with slice2objc or write a script to do it. We will check whether or not we can add support for static library projects to the Ice Touch Xcode plugin.

    Cheers,
    Benoit.
    Benoit-
    Thanks! That worked. Only thing is I had to substitute $(PLATFORM_NAME) with 'iphoneos.sdk'.
    It would seem that static library support would be a big need by the community. Adding that to the next release would certainly be great from my point of view.

    I am trying to integrate ICE-touch with MonoDevelop/MonoTouch, and the only way I can think of doing that is by linking to a static library developed with Xcode.
    That brings to mind another question, any possibility for MonoTouch support in the future?

    Anyways- thanks again for the help.
    -Eric

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. IceTouch examples Linker error
    By SiegfriedHora in forum Help Center
    Replies: 2
    Last Post: 03-08-2010, 08:49 PM
  2. Replies: 1
    Last Post: 11-11-2009, 01:27 PM
  3. how to make the application static link to ICE
    By bowei in forum Help Center
    Replies: 2
    Last Post: 10-12-2007, 11:36 PM
  4. vc static lib
    By hellocyf in forum Help Center
    Replies: 2
    Last Post: 08-04-2004, 10:53 PM
  5. Replies: 2
    Last Post: 09-03-2003, 02:49 AM

Tags for this Thread

Posting Permissions

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