Problems building on linux

Could you describe it more detail? What step 4 is?

Minggo Zhang wrote:

  1. On win32, you should do the following:
    a. install the template
    b. open cocos2d-win32.vc2008.sln or cocos2d-win32.vc2010.sln, and create a new project by the template. The project should under the root of cocos2d-x, such as HelloWorld.
    c. run build-win32.bat
    d. run the new project
    >
    >

step d.

running the new project causes this error.
EDIT:
This is weird, turns out building the thing with bat errors the same way. Though it didn’t before… Will resetup one more time.

Hi!
I have a problem with build-linux.sh execution on Ubuntu 11.10 64bit
(I’ve read http://www.cocos2d-x.org/boards/14/topics/5817 topic)
All SDK, NDK and other tools are presented
then i launch build-linux.sh:
sudo
bash build-linux.sh

the reaction is:

alexey@alexey-System-Product-Name:/app-dev/cocos2dx$\ bash\ build-linux.sh
building\ cocos2dx*****
make:\ `libcocos2d.so’\ is\ up\ to\ date.
building\ cocosdenshion*
g++\ Wallg\ O2fPIC\ ~~I…~~I…/include\ I…/third_party/fmod/lib64/api/incDLINUX\ …/Linux/FmodAudioPlayer.o\ …/Linux/SimpleAudioEngine.o\ sharedo\ libcocosdenshion.so\ L…/third_party/fmod/lib64/api/liblfmodex64\
/usr/bin/ld:\ cannot\ find\ -lfmodex64
collect2:\ ld\ returned\ 1\ exit\ status
make:
*\ Error\ 1
cp:\ cannot\ stat\ `libcocosdenshion.so’:\ No\ such\ file\ or\ directory
building\ Box2D
*****
make:\ `libbox2d.a’\ is\ up\ to\ date.
building\ chipmunk*******
make:\ `libchipmunk.a’\ is\ up\ to\ date.
alexey@alexey-System-Product-Name:
/app-dev/cocos2dx$

what to do? please i have no windows on my machine. Is there any chance to build on Ubuntu 64 machine? If I switch to 32bit will this help?

Is “CocosDenshion/third_party/fmod/lib64/api/lib/libfmodex64.so” exists?

Minggo Zhang wrote:

Is “CocosDenshion/third_party/fmod/lib64/api/lib/libfmodex64.so” exists?

yes, it is. CocosDenshion/third_party/fmod/lib64/api/lib/ contains two files:
libfmodex64-4.38.00.so
libfmodexL64-4.38.00.so

I’ve tried to install libs and then ran build-linux.sh again:

alexey@alexey-System-Product-Name:~/app-dev/cocos2dx/CocosDenshion/third_party/fmod/lib64$ make install
Installing FMOD Ex libraries and headers…
cp -f api/lib/libfmodex64-4.38.00.so /usr/local/lib
cp: cannot create regular file `/usr/local/lib/libfmodex64-4.38.00.so’: Permission denied
make: * Error 1
alexey@alexey-System-Product-Name:/app-dev/cocos2dx/CocosDenshion/third_party/fmod/lib64$\ sudo\ make\ install
\ password\ for\ alexey:\
Installing\ FMOD\ Ex\ libraries\ and\ headers…
cp\ f\ api/lib/libfmodex64-4.38.00.so\ /usr/local/lib
cp
f\ api/lib/libfmodexL64-4.38.00.so\ /usr/local/lib
ldconfig\ n\ /usr/local/lib
mkdir
p\ /usr/local/include/fmodex
cp\ -f\ api/inc/
.h**\ /usr/local/include/fmodex
done.
alexey@alexey-System-Product-Name:/app-dev/cocos2dx/CocosDenshion/third_party/fmod/lib64$ cd …/…/…/
alexey@alexey-System-Product-Name:/app-dev/cocos2dx/CocosDenshion$\ cd\ …/
alexey@alexey-System-Product-Name:
/app-dev/cocos2dx$ bash build-linux.sh
building cocos2dx*****
make: `libcocos2d.so’ is up to date.
building cocosdenshion*
g++ Wallg O2fPIC ~~I…~~I…/include I…/third_party/fmod/lib64/api/incDLINUX …/Linux/FmodAudioPlayer.o …/Linux/SimpleAudioEngine.o sharedo libcocosdenshion.so L…/third_party/fmod/lib64/api/liblfmodex64
/usr/bin/ld: cannot find -lfmodex64
collect2: ld returned 1 exit status
make:
** [libcocosdenshion.so] Error 1
cp: cannot stat `libcocosdenshion.so’: No such file or directory
building Box2D*********
make: `libbox2d.a’ is up to date.
****building chipmunk******
make: `libchipmunk.a’ is up to date.

some part was solved with theese steps:

alexey@alexey-System-Product-Name:
/usr/bin$ sudo ld lfmodex64
ld: cannot find
lfmodex64
:/usr/bin$ sudo ln s /usr/local/lib/libfmodex64-4.38.06.so /usr/lib/libfmodex64.so
:/usr/bin$ sudo ld
lfmodex64ld: warning: cannot find entry symbol _start; not setting start address

then
alexey@alexey-System-Product-Name:~/app-dev/cocos2dx$ bash build-linux.sh

building cocos2dx*****
make: `libcocos2d.so’ is up to date.
building cocosdenshion*
g++ Wallg O2fPIC ~~I…~~I…/include I…/third_party/fmod/lib64/api/incDLINUX …/Linux/FmodAudioPlayer.o …/Linux/SimpleAudioEngine.o sharedo libcocosdenshion.so L…/third_party/fmod/lib64/api/liblfmodex64
building Box2D
*****
make: `libbox2d.a’ is up to date.
building chipmunk*****
make: `libchipmunk.a’ is up to date.
test:
alexey@alexey-System-Product-Name:~/app-dev/cocos2dx$ bash build-linux.sh
building cocos2dx*****
make: `libcocos2d.so’ is up to date.
building cocosdenshion*
make: `libcocosdenshion.so’ is up to date.
building Box2D
*****
make: `libbox2d.a’ is up to date.
building chipmunk***
make: `libchipmunk.a’ is up to date.

There should be 4 files in CocosDenshion/third_party/fmod/lib64/api/lib:
libfmodex64.so
libfmodex64-4.38.00.so
libfmodexL64.so
libfmodexL64-4.38.00.so

There are only 2 of them libfmodex64-4.38.00.so and libfmodexL64-4.38.00.so in cocos2d-1.0.1-x-0.11.0.Zip/CocosDenshion/third_party/fmod/lib64/api/lib/ taken from http://www.cocos2d-x.org/projects/cocos2d-x/wiki/Download
And there are all 4 in /CocosDenshion/third_party/fmod/api/lib/

I don’t know what’s the error.
I paste the two files here.

After I’ve made soft link as I described in http://www.cocos2d-x.org/boards/14/topics/4526?r=7367#message-7367 the problem has been solved. Now I’m figuring out how to write c++ part in Eclipse with help of Marcio Andrey Oliveira but that’s an other story :slight_smile:

I’ll hope, I’ll give c2d-x one last shot this weekend.