Closed wargio closed 9 years ago
Until this gets resolved, try appending "-I${path to xnu-deps-linux}/headers/include/foreign" to CFLAGS in /SETUP/setsegname/Makefile. This should fix your issue.
good :D my advice is to add it in the readme: make TARGET_CONFIGS="debug arm armpba8" MAKEJOBS= SDKVERSION=10.7 HOST_CC=clang HOST_YACC=yacc \ HOST_BISON=bison HOST_FLEX=flex HOST_CODESIGN=/bin/true BUILD_NO_DEBUG=1 DEPLOYMENT_TARGET_FLAGS= \ RC_CFLAGS="-Darm -DARM -I${path to xnu-deps-linux}/headers/include/foreign" MIG=/usr/bin/mig CC=clang CXX=clang++ RC_CFLAGS="-target arm-apple-darwin11" \ VERBOSE=YES RC_LDFLAGS="-target arm-apple-darwin11 /usr/lib/libclang_rt.cc_kext.a" \ STRIP="arm-apple-darwin11-strip" then add an extra "value" inside the makefile for LINUX builing. something like: $(LINUX_CFLAGS) in that way if the value is not set, it will simply not read it, then if the value is set, it will fix that problems under linux
Well, it fails again because there is no swap.h under mach-o folder
I don't think RC_CFLAGS is for host utilities.
Sent from my iPhone
On Sep 22, 2013, at 5:02 AM, Giovanni notifications@github.com wrote:
Well, it fails again because there is no swap.h under mach-o folder
— Reply to this email directly or view it on GitHub.
no. it's a wrong use for that, i've just added the correct path to that makefile and it worked, but it fails since there is no swap.h under mach-o then i have thousand of other problems like double definitions or similar
Usually, I just stick it into /usr/include.
Sent from my iPhone
On Sep 22, 2013, at 10:28 AM, Giovanni notifications@github.com wrote:
no. it's a wrong use for that, i've just added the correct path to that makefile and it worked, but it fails since there is no swap.h under mach-o then i have thousand of other problems like double definitions or similar
— Reply to this email directly or view it on GitHub.
well, i've created a $XNUDEV folder with the exports, then i have put all the XNU stuff (elfs and the includes) there to not messed up the os. but i have lots of multiple definitions -_-
To help avoid this issue, I've made xnu-deps-linux build setsegname as a separate tool instead. (setsegname was originally a part of kext_tools, but apple decided to include it as part of xnu's source tree for some reason)
Until xnu's build system is changed to be more linux-aware, you'll need to modify SEG_HACK in makedefs/MakeInc.cmd in xnu to reflect this change.
And also remove setsegname under SETUP_SUBDIRS in SETUP/Makefile to exclude it from xnu build.
ok, seems that in that way i can build it, but now its stops again xD seems that it fails to generate the DEBUG folders inside the BUILD dir. an example: there is no /BUILD/obj//DEBUG_ARM_ARMPBA8/iokit/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/osfmk/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/bsd/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/pexpert/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/libkern/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/libsa/DEBUG /BUILD/obj//DEBUG_ARM_ARMPBA8/security/DEBUG and doconf fails on these folders by saying: /bin/sh: 7: [xnu path]/SETUP/config/doconf: not found then it completely stops by saying: make[2]: *\ no rule to make target "/media/ps3dev/xnu-rms/BUILD/obj//DEBUG_ARM_ARMPBA8/./osfmk/DEBUG/osfmk.filelist", needed by "/media/ps3dev/xnu-rms/BUILD/obj//DEBUG_ARM_ARMPBA8/./mach_kernel". Stop.
am i the only one that is building xnu under linux? xD
Use this chroot tarball: http://winocmbox.cloudapp.net/linux_x86_64_ubuntu_1304_xnu_chroot.tar.bz2
It's x86_64 only, source is in /home/rms
.
it works :D :D :D
ok
@winocm Could you possibly link that tarball again? Or is it not relevant anymore?
after patching the printf inside the MakeInc.def, it works till failing here: http://pastie.org/private/zg3pjzftx12urvufkfdbjw