Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7193273
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T20:08:10+00:00 2026-05-28T20:08:10+00:00

I’ve been using CodeRunner to collect little chunks of code that are frequently used

  • 0

I’ve been using CodeRunner to collect little chunks of code that are frequently used while developing but don’t necessarily belong in the codebase for a project. It’s a great tool for summarizing in Objective-C and Cocoa because I can include frameworks that are installed on my machine.

However, sometimes I want to include functionality from external sources that aren’t frameworks, such as ASIHTTPRequest. If I place the ASIHTTPRequest files in a folder nearby and #include them, I get errors about "Undefined symbols for architecture x86_64: _OBJC_CLASS_$_ASIHTTPRequest" which I’m assuming means that the ASI files simply aren’t being compiled and linked with the CodeRunner doc – this is a single file being compiled, not a project. In Xcode I would add the ASIHTTPRequest files to the project and they would automatically be compiled and linked with the rest of the code, what is the equivalent when I’m not using Xcode?

I can include custom arguments and compilation flags (the latter contains -std=c99 -framework Foundation by default) and I suspect I have to tweak these somehow but I haven’t been able to find out how.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T20:08:11+00:00Added an answer on May 28, 2026 at 8:08 pm

    I got it to work. gcc requires some additional parameters to link to the ASIHTTP modules, of course. Here’s what I ended up with:

    -std=c99 -framework SystemConfiguration -framework CoreServices -framework Foundation -lz -I/path/to/asi-header-files -filelist /path/to/list-of-asi-compiled-modules
    

    I imagine your code was just including paths to the ASIHTTPRequest.h, etc. header files… if you’re using explicit paths there, you don’t need the -I switch above. gcc does need to have a compiled version of the code from ASIHTTPRequest.m and friends to link with it. One way to do that is to compile the “Mac” project that comes with the library. That will produce .o files in one of those deeply-buried “DerivedData” directories Xcode likes to make. The one it made for me is:

    ~/Library/Developer/Xcode/DerivedData/Mac-flsjygxmngizhzfwnfgcakejmwkx/Build/Intermediates/Mac.build/Debug/Mac.build/Objects-normal/x86_64
    

    (The “Mac-flsjygxmngizhzfwnfgcakejmwkx” bit will differ for you, I imagine.) In that directory, there are a bunch of .o files and a ‘Mac.LinkFileList’ file. This file is the one you’d give for the -filelist parameter to gcc. You’ll need to remove references to the main.o, AppDelegate.o and ASIWebPageRequest.o files so you don’t get duplicate symbol errors during the link step.

    In addition to the ASIHTTPRequest header and .o files, gcc will expect to link with the SystemConfiguration, CoreServices frameworks and the zlib library, since ASIHTTPRequest has those dependencies.

    If you’re doing lots of tests with this library, I would recommend duplicating the “Objective-C” language definition (under Preferences) as “Objective-C with ASIHTTPRequest” or something. Then you can customize the compilation flags for running against ASIHTTPRequest without making it do that for all Objective-C code you run.

    You may also want to copy the .o files and the “LinkFileList” file to a more permanent place, just in case Xcode cleans that build tree away or something.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have a jquery bug and I've been looking for hours now, I can't
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
I used javascript for loading a picture on my website depending on which small
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I've got a string that has curly quotes in it. I'd like to replace
I am reading a book about Javascript and jQuery and using one of the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.