I downloaded a source code for an iOS coloring book from github :
When I try to compile I get these errors, and I don't understand what they mean:
0 clang 0x0000000100c57bb2 main + 12932498
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal (use -v to see invocation)
Apple LLVM version 4.2 (clang-425.0.28) (based on LLVM 3.2svn)
Target: i386-apple-darwin11.4.2
Thread model: posix
clang: note: diagnostic msg: PLEASE submit a bug report to http://developer.apple.com/bugreporter/ and include the crash backtrace, preprocessed source, and associated run script.
clang: error: unable to execute command: Segmentation fault: 11
clang: note: diagnostic msg: Error generating preprocessed source(s).
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 254
Did you follow the instructions? I tried to build it after just cloning the primary directory, got lots of problems, then re-read the Instructions and found this:
INSTRUCTIONS
Clone the coloring-book-ios repository, or alternatively, clone
your fork of the coloring-book-ios repository, along with its
submodules.
For git version 1.6.5 or higher, run:
git clone --recursive https://github.com/byronsanchez/coloring-book-ios.git
cd coloring-book-ios
Assets/Scripts/build.sh all
For other versions of git, run:
git clone https://github.com/byronsanchez/coloring-book-ios.git
cd coloring-book-ios
git submodule update --init
Assets/Scripts/build.sh all
Once I followed the 1.6.5 or higher (and ignored the build.sh warning as it instructions you to do in that file) everything built just fine using Xcode 4.6.3.
It's because the project references Toast+UIView.h but doesn't contain that category at the root level. NIBs, Raw, and Vendor are submodules of the main project.
Related
I am using Visual Studio Code and added the PlatformIO IDE extension along with c/c++ to code for my board, which is a uPesy ESP32 Wrovoer DevKit with a Espressif IoT Developement framework. Everything matches my but when I click finish I get an error message:
The current working directory C:\Users\brownme1\Documents\PlatformIO\Projects\my_project will be used for the project.
The next files/directories have been created in C:\Users\brownme1\Documents\PlatformIO\Projects\my_project
include - Put project header files here
lib - Put here project specific (private) libraries
src - Put project source files here
platformio.ini - Project Configuration File
Resolving upesy_wrover dependencies...
Already up-to-date.
Updating metadata for the vscode IDE...
Error: Processing upesy_wrover (platform: espressif32; board: upesy_wrover; framework: espidf)
--------------------------------------------------------------------------------
Verbose mode can be enabled via -v, --verbose option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/upesy_wrover.html
PLATFORM: Espressif 32 (6.0.0) > uPesy ESP32 Wrover DevKit
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-espidf # 3.50000.0 (5.0.0)
- tool-cmake # 3.16.4
- tool-esptoolpy # 1.40400.0 (4.4.0)
- tool-idf # 1.0.1
- tool-mconf # 1.4060000.20190628 (406.0.0)
- tool-ninja # 1.9.0
- toolchain-esp32ulp # 1.23500.220830 (2.35.0)
- toolchain-xtensa-esp32 # 11.2.0+2022r1
Reading CMake configuration...
-- Could NOT find Git (missing: GIT_EXECUTABLE)
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
-- The ASM compiler identification is GNU
-- Found assembler: C:/Users/brownme1/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/brownme1/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/brownme1/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe -- broken
-- Configuring incomplete, errors occurred!
See also "C:/Users/brownme1/Documents/PlatformIO/Projects/my_project/.pio/build/upesy_wrover/CMakeFiles/CMakeOutput.log".
See also "C:/Users/brownme1/Documents/PlatformIO/Projects/my_project/.pio/build/upesy_wrover/CMakeFiles/CMakeError.log".
CMake Warning at C:/Users/brownme1/.platformio/packages/framework-espidf/tools/cmake/git_submodules.cmake:4 (message):
Git executable was not found. Git submodule checks will not be executed.
If you have any build issues at all, start by adding git executable to the
PATH and rerun cmake to not see this warning again.
Call Stack (most recent call first):
C:/Users/brownme1/.platformio/packages/framework-espidf/tools/cmake/idf.cmake:41 (include)
C:/Users/brownme1/.platformio/packages/framework-espidf/tools/cmake/project.cmake:12 (include)
CMakeLists.txt:2 (include)
CMake Error at C:/Users/brownme1/.platformio/packages/tool-cmake/share/cmake-3.16/Modules/CMakeTestCCompiler.cmake:60 (message):
The C compiler
"C:/Users/brownme1/.platformio/packages/toolchain-xtensa-esp32/bin/xtensa-esp32-elf-gcc.exe"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: C:/Users/brownme1/Documents/PlatformIO/Projects/my_project/.pio/build/upesy_wrover/CMakeFiles/CMakeTmp
Run Build Command(s):C:/Users/brownme1/.platformio/packages/tool-ninja/ninja.exe cmTC_0ae29 && [1/2] Building C object CMakeFiles\cmTC_0ae29.dir\testCCompiler.c.obj
FAILED: CMakeFiles/cmTC_0ae29.dir/testCCompiler.c.obj
C:\Users\brownme1\.platformio\packages\toolchain-xtensa-esp32\bin\xtensa-esp32-elf-gcc.exe -mlongcalls -Wno-frame-address -o CMakeFiles\cmTC_0ae29.dir\testCCompiler.c.obj -c testCCompiler.c
xtensa-esp32-elf-gcc.exe: fatal error: cannot execute 'c:/users/brownme1/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/11.2.0/../../../../xtensa-esp32-elf/bin/as.exe': CreateProcess: No such file or directory
compilation terminated.
ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
C:/Users/brownme1/.platformio/packages/framework-espidf/tools/cmake/project.cmake:342 (__project)
CMakeLists.txt:3 (project)
========================== [FAILED] Took 4.21 seconds ==========================
Please try to read the error carefully. It says you're missing git.
Git executable was not found. Git submodule checks will not be executed.
If you have any build issues at all, start by adding git executable to the
PATH and rerun cmake to not see this warning again.
I am trying to install spritebuilder but since it is no longer on the app store I have to do it through github. I ran the following code from the readme file on github.
git clone https://github.com/apportable/SpriteBuilder
cd SpriteBuilder
git submodule update --init --recursive
cd scripts
./build_distribution.py --version 1.x
but it keeps returning the error:
Testing failed:
Error: There is no SDK with the name or path '/Users/username/SpriteBuilder/scripts/SpriteBuilder/SpriteBuilder/macosx10.9'
** TEST FAILED **
The following build commands failed:
Check dependencies
(1 failure)
Am I doing something wrong? I went into the build folder despite the error and the .app is not able to be opened, saying it may be incomplete or corrupt.
I found a workaround by downloading Spritebuilder from a mirror hosting site.
I was wondering if you could help me with some issues and questions I have for developing for the i.MX6 SoloX in bare-metal. I was looking at this link https://community.nxp.com/docs/DOC-106253 and downloaded the files there to use as an example of how to develop bare-metal c code for the i.MX6.
Then I setup my eclipse environment according to this tutorial https://community.nxp.com/docs/DOC-103736 but just the toolchain because I'm not interested in processor expert.
Since I'm working on Linux I didn't installed the Code Sourcery thing, instead I'm working with the gcc-arm-none-eabi which I installed using:
$ sudo apt-get install gcc-arm-none-eabi
And therefore I had to change the cs-rm and cs-make for rm and make respectively.
And I was able to create an eclipse project with the downloaded code and configure the project to make it work, nevertheless, I had the first error:
main.c:8:19: fatal error: stdio.h: No such file or directory
#include <stdio.h>
^
compilation terminated.
make: *** [cortex_A9/main.o] Error 1
cortex_A9/subdir.mk:24: recipe for target 'cortex_A9/main.o' failed
And I was able to solve it adding "/usr/include" in the include directories at project > properties. But I'm not sure if this is a correct way of solving this error.
After fixing this error I got a new one:
syscalls.c:168:1: error: unknown type name 'caddr_t'
caddr_t _sbrk(int incr)
And for solving that I had to include explicitly the file "/usr/include/x86_64-linux-gnu/sys/types.h" and also I don't know if that is the correct way to solve it.
Now having eliminated those two errors I have the following one:
Building target: imx6-A9.elf
Invoking: Cross ARM C Linker
arm-none-eabi-gcc -mcpu=cortex-a9 -march=armv7-a -marm -mlittle-endian -mfloat-abi=softfp -mfpu=neon -mno-unaligned-access -fno-zero-initialized-in-bss -O0 -g -T "/home/mmalagon/iMX6/MX6SX_hello_MFG/cortex_A9/mx6slx.ld" -nostartfiles -Wl,-Map,"imx6-A9.map" -o "imx6-A9.elf" ./cortex_A9/main.o ./cortex_A9/syscalls.o ./cortex_A9/uart.o
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: cannot find -lg
makefile:42: recipe for target 'imx6-A9.elf' failed
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status
make: *** [imx6-A9.elf] Error 1
Which I haven't been able to resolve.
I don't know if this error is a consequence of the way I solved the two previous errors.
Does anybody know how to properly setup eclipse for i.MX6 bare-metal development?
Thank you very much for helping!!
If you want to develop bare-metal code for the i.MX6SoloX without using CodeSourcery then you need to execute this:
sudo apt-get install gcc-arm-none-eabi libnewlib-arm-none-eabi -y
And then choose "Custom (arm-none-eabi-gcc)" at Project>Settings>C/C++ Build in the 'Toolchains' tab.
I've been following the "Getting Started" tutorial on http://swift.org. Upon creating new Swift "Hello World" project, I ran shell command:
$ swift build
and got the following output:
Compiling Swift Module 'MyProject' (1 sources)
Linking MyProject
ld: library not found for -lobjc
<unknown>:0: error: build had 1 command failures
error: exit(1): /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-02-25-a.xctoolchain/usr/bin/swift-build-tool -f /Users/petrmanek/Projekty/MyProject/.build/debug.yaml default
I'm assuming that ld: library not found for -lobjc means that the linker can't find the Objective-C standard library, however I find that hard to believe as both files /usr/lib/libobjc.A.dylib and /usr/lib/libobjc.dylib are present on my file system.
What do I do now?
My configuration is:
Hardware: Mac mini (Late 2012)
OS: Mac OS 10.11 El Capitan
uname -a
Darwin tywin 15.3.0 Darwin Kernel Version 15.3.0: Thu Dec 10 18:40:58 PST 2015; root:xnu-3248.30.4~1/RELEASE_X86_64 x86_64
swift --version
Apple Swift version 3.0-dev (LLVM b361b0fc05, Clang 11493b0f62, Swift fc261045a5)
Target: x86_64-apple-macosx10.9
I think I have solved it. Here's my solution if anyone's interested.
Looking at the swift-build --help option list, I have discovered the option -Xlinker which allows me to specify flags directly for ld. I used this option to tell it to be more verbose with command:
$ swift build -Xlinker -v
The output was:
Linking MyProject
#(#)PROGRAM:ld PROJECT:ld64-242
configured to support archs: i386 x86_64 x86_64h armv6 armv7 armv7s armv7m armv7k arm64
Library search paths:
/Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-02-25-a.xctoolchain/usr/lib/swift/macosx
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/lib
Framework search paths:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/System/Library/Frameworks/
ld: library not found for -lobjc
<unknown>:0: error: build had 1 command failures
error: exit(1): /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-02-25-a.xctoolchain/usr/bin/swift-build-tool -f /Users/petrmanek/Projekty/MyProject/.build/debug.yaml default
This was quite messy but we can see that /usr/lib is not among the library search paths. I had two options:
add /usr/lib as a search path - that didn't work because ld strives to add /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/ prefix in front of every search path I add using the -L flag
link `libobjc.dylib - that worked
Here are the shell commands I used (I did the same thing for libSystem because it required the same treatment):
$ cd /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-02-25-a.xctoolchain/usr/lib/swift/macosx
$ sudo ln -s /usr/lib/libobjc.dylib
$ sudo ln -s /usr/lib/libSystem.dylib
The swift build command is working now and the product runs correctly. However, I don't believe that is user-friendly installation process, Apple.
I'm trying to compile VLC player for iOS.
I've cloned git from repo, a tried to run "buildMobileVLC.sh" (using this wiki documentation)
$ git clone git://git.videolan.org/MobileVLC.git
$ cd MobileVLC
$ ./buildMobileVLC.sh
But as the result I have in terminal next:
SDKROOT not specified, assuming /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk
*** /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk does not exist, please install required SDK, or set SDKROOT manually. ***
Even this
./buildMobileVLC.sh -k iphoneos5.0
can't help to solve the problem
P.S. When I try:
./buildMobileVLC.sh -h
It says
-k Specify which sdk to use (see 'xcodebuild -showsdks', current: iphoneos5.0)
What am I doing wrong? And should I install iPhone SDK 5.1, if "yes", then how?
UPD:
I changed
SDK_VERSION=5.0
in file "build.sh" in /Users//MobileVLC/ImportedSources/vlc/extras/package/ios
The error disappeared but the new error in Terminal is:
./libavutil/arm/asm.S:180:cannot use register index with PC-relative addressing -- `ldr r4,[pc,r4]'
./libavutil/arm/asm.S:180:cannot use register index with PC-relative addressing -- `ldr lr,[pc,lr]'
clang: error: assembler command failed with exit code 1 (use -v to see invocation)
make[1]: *** [libavcodec/arm/ac3dsp_armv6.o] Error 1
make: *** [.ffmpeg] Error 2
Yes you should install the iOS SDK, you can get it by installing Xcode from the Appstore.
Error is telling you that the SDK can not be found, after you install Xcode the SDK will be installed.
With the new Xcode the SDK is in the Xcode bundle, /Applications/Xcode.app/Contents/Developer
As suggest you could set the SDKROOT to this path if it can't find the SDK.
It appears that the mobile build for VLC is broken: http://forum.videolan.org/viewtopic.php?f=12&t=103322