Comments (3)
I'm using macOS 10.14.6(Mojave) / CLion 2019.3 / This compiler is in Downloads directory.
from osx-arm-linux-toolchains.
Looks like your code includes a Mac OS X SDK header file. This header file is designed to be used only with code that runs on macOS. Hence, the header file has a check for the target architecture, and throws the error because these toolchains are cross-compilers -- the host is macOS, but the target is ARM/Linux, not macOS.
from osx-arm-linux-toolchains.
I found out the solution.
Mac users using cmake have to add this below.
I put arm-linux compiler to /usr/local.
Someone who doesn't put arm compiler to /usr/local, modify the first set(ARM_LINUX_TOOLCHAIN_DIR [your arm compiler path])
set(ARM_LINUX_TOOLCHAIN_DIR /usr/local/arm-unknown-linux-gnueabi)
set(CMAKE_C_COMPILER ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-gcc)
set(CMAKE_LINKER ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-ld)
set(CMAKE_NM ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-nm)
set(CMAKE_OBJCOPY ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-objcopy)
set(CMAKE_OBJDUMP ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-objdump)
set(CMAKE_RANLIB ${ARM_LINUX_TOOLCHAIN_DIR}/bin/arm-unknown-linux-gnueabi-ranlib)
include_directories(${ARM_LINUX_TOOLCHAIN_DIR}/arm-unknown-linux-gnueabi/sysroot/usr/include)
from osx-arm-linux-toolchains.
Related Issues (12)
- arm-unknown-linux-gnueabihf/bin/ld.bfd: cannot find crt1.o: No such file or directory HOT 1
- Issue with build on Monterey 12.2.1
- What machine arch were these compiled on x86_64 or arm (M1)? HOT 3
- Add cmake support
- Toolchains for x86_64 osx HOT 1
- arm-linux-gnueabihf-gcc for ArmV7 HOT 4
- Musl support HOT 3
- missing libpthread_nonshared.a
- code signing recipe HOT 1
- Automatic building HOT 3
- hello,can you send me the .config file HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from osx-arm-linux-toolchains.