But I have different structure. According to documentation I should be in linux-build/, then cd bin/cpp-tests/. So I should be in linux-build/bin/cpp-tests/. I don’t have cpp-tests/ in there.
Is it me having something wrong or documentation ?
This is what I’ve found:
$ find ./ -name cpp-tests
./tests/cpp-tests
./build/linux-build/engine/tests/cpp-tests
$ cd ./build/linux-build/engine/tests/cpp-tests
joe@PC:~/cocos2d-x/build/linux-build/engine/tests/cpp-tests$ ls
CMakeFiles cmake_install.cmake Makefile
Update:
I had problems with running android test project, but after I did what you can see below I was able to run it on android. But there still no cpp-tests/cpp-tests. Should I redownload cocos again and compile it again ?
joe@PC:~/cocos2d-x$ git submodule update --init
Submodule ‘tests/cpp-tests/Resources/ccs-res’ (git://github.com/dumganhar/ccs-res.git) registered for path ‘tests/cpp-tests/Resources/ccs-res’
Submodule ‘tools/bindings-generator’ (git://github.com/cocos2d/bindings-generator.git) registered for path ‘tools/bindings-generator’
Submodule ‘tools/cocos2d-console’ (git://github.com/cocos2d/cocos2d-console.git) registered for path ‘tools/cocos2d-console’
Submodule ‘web’ (git://github.com/cocos2d/cocos2d-html5.git) registered for path ‘web’
Cloning into ‘/home/joe/cocos2d-x/tests/cpp-tests/Resources/ccs-res’…
Cloning into ‘/home/joe/cocos2d-x/tools/bindings-generator’…
Cloning into ‘/home/joe/cocos2d-x/tools/cocos2d-console’…
Cloning into ‘/home/joe/cocos2d-x/web’…
Submodule path ‘tests/cpp-tests/Resources/ccs-res’: checked out ‘5d65db4c5f18c0df1305ff32b076425ab228cc4a’
Submodule path ‘tools/bindings-generator’: checked out ‘2aa9b21f11bf514ca80f243b21750e8c7c28f05e’
Submodule path ‘tools/cocos2d-console’: checked out ‘03d1f8d291ed63439918fa4b180c7b9d698a2bfd’
Submodule path ‘web’: checked out ‘15704c33421bbd236299b6b965e63eb2a6b7172c’
You told me in another thread that you followed the Linux docs completely and you were running. You made it through make ok then?
git submodule update --init and ./download-deps.py are part of that process. Have you done both of these?
cpp-tests is here ~/cocos2d-x/build/linux-build/engine/tests/cpp-tests. Do you have it there? Your screenshot suggests that you do. The Linux process has changed a bit with master in GitHub so I think we should correct the Linux doc for this too.
In ~/cocos2d-x_prev/build/linux-build/engine/tests/cpp-tests/ I have this:
I tried to compile again, but downloaded it from site (not using git) and there was again errors during make. Are those archives different ?
It’s better to put checksums for archive on web-site.
git submodule update --init
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
But I did it after make. And as I remember it was successful.
sudo apt-get install git
cd <to where you want to clone this repo>
git clone https://github.com/cocos2d/cocos2d-x.git
git submodule update --init
git submodule update
./download-deps.py
you cd the second step, that puts you in cocos2d-x root and you never cd … so you are in your root the whole time.
Yes, what you clone from GitHub doesn’t contain everything you need without running the steps mentioned. Downloading the .zip from our website is self contained, except in the case of Linux where you need the steps mentioned in the documentation.
cd build
mkdir linux-build
cd linux-build
cmake ../..
Technically you should be still in your cocos2d-x root because the instructions never told you to cd… but I can add a line just to make sure the user is there.