Comments (7)
Unfortunately we never expect the xcode
backend to work because we don't have any proficient knowledge on xcode development.
from unicorn.
In my case I got:
ERROR: "/Applications/Xcode-15.1.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc" cannot build an executable (is your linker broken?)
I found that this by commenting this line it will success!
Line 314 in d4b9248
Could anyone tell why is it here? (coming from Unicorn 2)
from unicorn.
This is from qemu. Commenting this line will give you inconsistent setup.
As far as I know about Xcode toolchain, it's probably your cc
settings problem.
from unicorn.
After I investigated, the qemu/cofigure
missing -isysroot
flags that needed by apple clang if only invoked outside /usr/bin
.
So there are two places for clang: /usr/bin/cc
and /Applications/Xcode-15.1.0.app/.../usr/bin/cc
. The 1st seems only a shim with "proper" search path, it being used when --cc
flags omitted.
But, CMake the using 2nd ver which require -isysroot
being passed to external script. CMake implicitly added these flags with value from CMAKE_OSX_SYSROOT
on its generator.
I'm suggesting to add following lines, before calling qemu/cofigure
:
if (CMAKE_OSX_SYSROOT)
set (EXTRA_CFLAGS "${EXTRA_CFLAGS} -isysroot ${CMAKE_OSX_SYSROOT} ")
endif()
from unicorn.
After I investigated, the
qemu/cofigure
missing-isysroot
flags that needed by apple clang if only invoked outside/usr/bin
.So there are two places for clang:
/usr/bin/cc
and/Applications/Xcode-15.1.0.app/.../usr/bin/cc
. The 1st seems only a shim with "proper" search path, it being used when--cc
flags omitted.But, CMake the using 2nd ver which require
-isysroot
being passed to external script. CMake implicitly added these flags with value fromCMAKE_OSX_SYSROOT
on its generator.I'm suggesting to add following lines, before calling
qemu/cofigure
:if (CMAKE_OSX_SYSROOT) set (EXTRA_CFLAGS "${EXTRA_CFLAGS} -isysroot ${CMAKE_OSX_SYSROOT} ") endif()
Great, thanks for investigating this. -isysroot
was once there but removed because breaking when using /usr/bin/cc
. I will have a look.
from unicorn.
link to #1924
from unicorn.
Fixed in a9a54ae
from unicorn.
Related Issues (20)
- v2.1.0 Plan HOT 9
- Re-align Unicorn register enum values with updated Capstone register enum values HOT 2
- Question and maybe even suggestion : ) HOT 3
- unicorn for cygwin HOT 1
- RISC-V64 incorrectly returns error when calling `emu_start` with `count` = 1 at end of page
- Memory hooks cause incorrect emulation of the carry flag for the SAR instrution on x86_64 HOT 2
- ctl_set_cpu_model issues HOT 2
- Difference between memory and block hooks HOT 5
- mips 3 issues HOT 2
- When running x86 simulation in unrestricted mode, there's an EFLAGS error upon exiting HOT 3
- distutils deprecation
- UC_HOOK_INTR not observed HOT 1
- Changing x86 32 bit execution to x86 64 bit and vice versa HOT 3
- glib_compat breaks Qt Widgets with glib backend HOT 11
- page_collection_lock causing a crash HOT 3
- Does memory need to be mapped aligned to page boundaries? HOT 1
- Ignoring a Branchs/Handling Invalid Memory Access Handling Gracefully HOT 4
- Setting RIP inside callback doesn't change execution flow HOT 2
- Paging doesn't work on x86, is that by design? HOT 4
- ARM32 Cortex A9 MRRC instruction UC_ERR_INSN_INVALID HOT 5
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 unicorn.