2

I am facing these errors when i execute this command "./make.sh" To build ldid utility for jailbreak tweaks development

    Bilals-Mac:ldid billy$ ./make.sh
+ g++ -arch i386 -arch x86_64 -arch ppc -arch armv6 -o ldid ldid.cpp -I. -x c lookup2.c sha1.c
Undefined symbols for architecture i386:
  "SHA1Result(SHA1Context*, unsigned char*)", referenced from:
      sha1(unsigned char*, unsigned char*, unsigned long) in ldid-6MHU04.o
  "SHA1Input(SHA1Context*, unsigned char const*, unsigned int)", referenced from:
      sha1(unsigned char*, unsigned char*, unsigned long) in ldid-6MHU04.o
  "SHA1Reset(SHA1Context*)", referenced from:
      sha1(unsigned char*, unsigned char*, unsigned long) in ldid-6MHU04.o
ld: symbol(s) not found for architecture i386
In file included from ldid.cpp:22:
./minimal/stdlib.h:123:10: fatal error: 'errno.h' file not found
#include <errno.h>
         ^
1 error generated.
lookup2.c:9:10: fatal error: 'stdio.h' file not found
#include <stdio.h>
         ^
1 error generated.
error: unable to create target: 'No available targets are compatible with this
      triple, see -version for the available targets.'
1 error generated.
clang: error: linker command failed with exit code 1 (use -v to see invocation)**strong text**
Billy Q
  • 71
  • 1
  • 7

3 Answers3

3

Whosever having problem building ldid, he can get prebuild ldid from here http://joedj.net/ldid

Just download and place it in Theos/bin folder

Billy Q
  • 71
  • 1
  • 7
2

First download Apple's "Command Line Tools" for Xcode if you haven't already.

/usr/bin/xcode-select --install

Change into the appropriate ldid directory.

cd $THEOS/bin/

Download this already compiled version of Theos.

sudo wget http://ac3xx.com/ldid && sudo chmod +x $THEOS/bin/ldid

Apparently it seems to be an issue with Xcode 5.

Information from http://iphonedevwiki.net/index.php/Updating_extensions_for_iOS_7#Theos_and_ldid_errors .

Hope this helps.

anoadragon453
  • 43
  • 1
  • 6
  • ldid is a binary and not a directory, so the second command should read `cd $THEOS/bin/`. Plus the third command will most likely require `sudo`. (Unfortunately my attempt to edit was rejected, thanks most likely to mods who have no idea what ldid is!) – newenglander Jul 28 '14 at 16:29
  • Fixed. Old answer though :P – anoadragon453 Jul 28 '14 at 22:45
1

I am assuming you are using OSX Mavericks and have the latest XCode installed. If yes, then this issue is occurring because the OSX upgrade Apple wipes out many of the core Posix libraries that were earlier present. Not sure why. Previously you could rectify this by installing "Command Line Tools" from Xcode. Unfortunately with the latest release of xcode there is no option to install command line tools from Xcode UI directly. You have to use a little hidden utility called xcode-select

Type the following command in terminal as an administrator to get things working again:

/usr/bin/xcode-select --install

Hope this helps.

iansari
  • 354
  • 3
  • 12