darlinghq / darling

Darwin/macOS emulation layer for Linux
http://www.darlinghq.org
GNU General Public License v3.0
11.45k stars 445 forks source link

Building on Debian 10 #979

Closed JJTech0130 closed 3 years ago

JJTech0130 commented 3 years ago

Build Log What is the build error? Same as https://github.com/darlinghq/darling/issues/964, https://github.com/darlinghq/darling/issues/939 and possibly others:

/home/jjtech/darling/src/external/objc4/runtime/NSObject.mm:2000:2: error: prefix attribute must be followed by an
      interface or protocol
@implementation NSObject
 ^

System Information What system are you building with?

Software Version
Clang 6.0.1-10
CMake 3.13.4
Linux Kernel 5.10.16.3-microsoft-standard-WSL2+
Darling 4fd969bf1e6bc8fcd1830229394f35676246e827

Your build instructions for Debian 10 include clang-6.0 as a build dependency, while previously stating that Darling will not build without Clang 9 or higher. clang-11 appears to be available on Debian 10 (at least the WSL version) so it appears to be a documentation issue.

HinTak commented 3 years ago

clang too old. I think the doc mentions that clang 10+(?) is required...

JJTech0130 commented 3 years ago

I know. But the build instructions specifically install clang-6.0

Debian 10


 $ sudo apt install cmake clang-6.0 bison flex xz-utils libfuse-dev libudev-dev pkg-config \
 libc6-dev-i386 linux-headers-amd64 libcap2-bin git python2 libglu1-mesa-dev libcairo2-dev \
 libgl1-mesa-dev libtiff5-dev libfreetype6-dev libxml2-dev libegl1-mesa-dev libfontconfig1-dev \
 libbsd-dev libxrandr-dev libxcursor-dev libgif-dev libpulse-dev libavformat-dev libavcodec-dev \
 libavresample-dev libdbus-1-dev libxkbfile-dev libssl-dev
`clang-6.0` specifically requests clang 6.
~~Oh, and the CMakeList ignores Clang 11, so you have to use 10~~ They skipped 9 and 10 in the backports. Grr. Will try to build with 11
HinTak commented 3 years ago

You can check when that line was written at https://github.com/darlinghq/darling-docs - likely very old... And you can create pull / edit / update to the docs there yourself too, btw. If you are simply complaining about the doc being out of date, filing and fixing it over there may be more appropriate... (yes, you can just click the edit button on the top right to create a pull there..)

HinTak commented 3 years ago

Disclaimer: I am just another user (and not a happy one at that...).

JJTech0130 commented 3 years ago

Yah, is there any reason Clang 11 wouldn't work? I'm building now but it's going to take awhile. I'm going to create a pull request to change the docs, and edit the CMake list to remove the old, unsupported versions of clang.

JJTech0130 commented 3 years ago

https://github.com/darlinghq/darling-docs/pull/25

HinTak commented 3 years ago

There were some problems with Clang 12, but has since been fixed: https://github.com/darlinghq/darling/issues/856

JJTech0130 commented 3 years ago

https://github.com/darlinghq/darling/pull/980

JJTech0130 commented 3 years ago

I'm going to close this issue, I've added all of the pull req. necessary to fix it.