Gd-tools, programs to enhance goldendict

还不懂加强了啥子…

When I tried building it on my Apple Silicon macOS, it gave the following error:

[ 55%] Linking CXX shared library libcpr.dylib
ld: library 'stdc++fs' not found
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [_deps/cpr-build/cpr/libcpr.1.10.5.dylib] Error 1
make[1]: *** [_deps/cpr-build/cpr/CMakeFiles/cpr.dir/all] Error 2
make: *** [all] Error 2

This is how I was trying to build:

cmake -S . -B build \
    -DCMAKE_C_COMPILER=/opt/homebrew/opt/llvm/bin/clang \
    -DCMAKE_CXX_COMPILER=/opt/homebrew/opt/llvm/bin/clang++ \
    -DCMAKE_BUILD_TYPE=Release

cmake --build build

Do I need to copy the gd-tools folder into the GoldenDict-ng root folder and then build it?

Is there a macOS version of Gd-tools available? I can’t pass the build process.

unfortunately since i dont have a mac, i cant provide a mac version

OK. I hope someone who has a mac could try the build process and hopefully provide a macOS version afterward. :pray::face_with_head_bandage:

as i said above, i cant test it on my own, but the error seems to be here:

and the solution would be:
to add this:

stdc++fs

hence , with the modification that line would look like this:

#Apple and other
if (NOT ${GUIX})
  target_link_libraries(gd-tools_exe PRIVATE marisa cpr::cpr nlohmann_json::nlohmann_json rdricpp stdc++fs)
endif()

if someone has a mac, and has some experience with c++ development, please test it.

I added that stdc++fs, but still the same error: 'stdc++fs' not found

then i really dont know what can be done about this.

this is meant to be called within goldendict-ng
please READ the what the repository says

added a link with a tutorial (english only)

spoonfeeding is such a bad thing, but since a small percentage of users are lazy enough to refuse reading the documentation, i had to add a the tutorial.

now the only thing i can think of is “oh yeah, the same people will come back and say that the tutorial was confusing (aka they didnt bothered watching it as well)”

It doesn’t support compiling on an Apple Silicon mac device, right? (I have failed to compile it many times anyway.)

Any agenda for that? :smiley: (I really look forward to getting my hands on the mac version, to really trying out this Gd-tools on Apple Silicon mac.)

hello!
as i said before, the only reason i cant give Mac support is because i dont own a Mac…
but someone said that it fails to compile in the ARM architecture, which probably is the one used by M1 Mac’s

again, sorry that i cant provide Mac support.

1 个赞