Problem FiveMac and Maverick OSX 10.9

Post Reply
User avatar
vensanto
Posts: 54
Joined: Thu Oct 13, 2005 1:26 pm
Location: ITALIA
Contact:

Problem FiveMac and Maverick OSX 10.9

Post by vensanto »

Dear Antonio
i have installed fivemac of FTDN 13.06 on MAC OSX 10.9 with xcode 5.1
when i compile tutor01.prg
i get this error message

Undefined symbols for architecture x86_64:
"_HB_FUN_ERRORLINK", referenced from:
_symbols_table in ....

Please help me
Best regards
Santo Venezia
User avatar
mastintin
Posts: 1502
Joined: Thu May 27, 2010 2:06 pm

Re: Problem FiveMac and Maverick OSX 10.9

Post by mastintin »

please , show build.sh code ..
User avatar
vensanto
Posts: 54
Joined: Thu Oct 13, 2005 1:26 pm
Location: ITALIA
Contact:

Re: Problem FiveMac and Maverick OSX 10.9

Post by vensanto »

# ./build.sh - (c) FiveTech Software 2007-2010

clear

if [ $# = 0 ]; then
echo syntax: ./build.sh file [options...]
exit
fi

echo compiling...
./../../harbour/bin/harbour $1 -n -w -I./../include:./../../harbour/include $2
if [ $? = 1 ]; then
exit
fi

echo compiling C module...
SDKPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk
HEADERS=$SDKPATH/usr/include
# add -arch ppc -arch i386 for universal binaries
gcc $1.c -c -I./../include -I./../../harbour/include -I$HEADERS

if [ ! -d $1.app ]; then
mkdir $1.app
fi
if [ ! -d $1.app/Contents ]; then
mkdir $1.app/Contents
echo '<?xml version="1.0" encoding="UTF-8"?>' > $1.app/Contents/Info.plist
echo '<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">' >> $1.app/Contents/Info.plist
echo '<plist version="1.0">' >> $1.app/Contents/Info.plist
echo '<dict>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundleExecutable</key>' >> $1.app/Contents/Info.plist
echo ' <string>'$1'</string>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundleName</key>' >> $1.app/Contents/Info.plist
echo ' <string>'$1'</string>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundleIdentifier</key>' >> $1.app/Contents/Info.plist
echo ' <string>com.fivetech.'$1'</string>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundlePackageType</key>' >> $1.app/Contents/Info.plist
echo ' <string>APPL</string>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundleInfoDictionaryVersion</key>' >> $1.app/Contents/Info.plist
echo ' <string>6.0</string>' >> $1.app/Contents/Info.plist
echo ' <key>CFBundleIconFile</key>' >> $1.app/Contents/Info.plist
echo ' <string>fivetech.icns</string>' >> $1.app/Contents/Info.plist
echo '</dict>' >> $1.app/Contents/Info.plist
echo '</plist>' >> $1.app/Contents/Info.plist
fi
if [ ! -d $1.app/Contents/MacOS ]; then
mkdir $1.app/Contents/MacOS
fi
if [ ! -d $1.app/Contents/Resources ]; then
mkdir $1.app/Contents/Resources
cp ./../icons/fivetech.icns $1.app/Contents/Resources/
fi
if [ ! -d $1.app/Contents/frameworks ]; then
mkdir $1.app/Contents/frameworks
cp -r ./../frameworks/* $1.app/Contents/frameworks/
fi

echo linking...
CRTLIB=$SDKPATH/usr/lib
HRBLIBS='-lhbdebug -lhbvm -lhbrtl -lhblang -lhbrdd -lhbrtl -lgttrm -lhbvm -lhbmacro -lhbpp -lrddntx -lrddcdx -lrddfpt -lhbsix -lhbcommon -lhbcplr'
FRAMEWORKS='-framework Cocoa -framework WebKit -framework QTkit -framework Quartz'
# add -arch ppc -arch i386 for universal binaries
gcc $1.o -o ./$1.app/Contents/MacOS/$1 -L$CRTLIB -L./../lib -lfive -lfivec -L./../../harbour/lib $HRBLIBS $FRAMEWORKS -F./../frameworks -framework Scintilla

rm $1.c
rm $1.o

echo done!
./$1.app/Contents/MacOS/$1
# reset
User avatar
mastintin
Posts: 1502
Joined: Thu May 27, 2010 2:06 pm

Re: Problem FiveMac and Maverick OSX 10.9

Post by mastintin »

Change :
SDKPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk
for :
SDKPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk

or donwload MacOSX10.7.sdk from apple . http://adcdownload.apple.com/Developer_ ... e_2012.dmg
User avatar
vensanto
Posts: 54
Joined: Thu Oct 13, 2005 1:26 pm
Location: ITALIA
Contact:

Re: Problem FiveMac and Maverick OSX 10.9

Post by vensanto »

Thank you very much
mastintin

now it is ok

Best Regard
Santo
Post Reply