-
-
Notifications
You must be signed in to change notification settings - Fork 414
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
libmysofa: add package #6076
base: dev
Are you sure you want to change the base?
libmysofa: add package #6076
Conversation
I don't know you mean, you can try table.insert(configs, "-DBUILD_STATIC_LIBS=" .. (package:config("shared") and "OFF" or "ON"))
table.insert(configs, "-DBUILD_SHARED_LIBS=" .. (package:config("shared") and "ON" or "OFF"))
Yes, We can reference https://archlinux.org/packages/extra/x86_64/libmysofa
C:\PROGRA~1\MICROS~2\2022\COMMUN~1\VC\Tools\MSVC\1442~1.344\bin\Hostx64\x64\cl.exe /nologo -IC:\Users\star\AppData\Local\.xmake\cache\packages\2412\l\libmysofa\v1.3.2\source\build_7ef28615\src -IC:\Users\star\AppData\Local\.xmake\cache\packages\2412\l\libmysofa\v1.3.2\source\windows\third-party\zlib-1.2.11\include -IC:\Users\star\AppData\Local\.xmake\cache\packages\2412\l\libmysofa\v1.3.2\source\src\hrtf /DWIN32 /D_WINDOWS /W3 -Wall /DWIN32 /D_WINDOWS /W3 /Zi /Ob0 /Od /RTC1 -MD -DDEBUG -DVDEBUG /showIncludes /Fosrc\CMakeFiles\mysofa-static.dir\hdf\gcol.c.obj /Fdpdb\ /FS -c C:\Users\star\AppData\Local\.xmake\cache\packages\2412\l\libmysofa\v1.3.2\source\src\hdf\gcol.c Try to patch cmake to use xrepo zlib for unbundle deps. |
We can apply this patch to improve shared library build. |
IDK maybe we should limit BSD & Wasm here, because xmake-repo/packages/l/libkmod/xmake.lua Lines 14 to 19 in aa72d47
Could be related https://github.com/linux-sunxi/sunxi-tools/pull/59/files https://gist.github.com/panzi/6856583?permalink_comment_id=2382595#gistcomment-2382595 https://gist.github.com/panzi/6856583?permalink_comment_id=2372628#gistcomment-2372628 https://github.com/xmake-io/xmake-repo/blob/aa72d472b106727cf9cd823f1ce675e0c4c19ff5/packages/l/libkmod/port/endian-darwin.h is same as https://github.com/hoene/libmysofa/blob/main/src/hrtf/portable_endian.h |
#endif | ||
|
||
-#if defined(__linux__) || defined(__CYGWIN__) | ||
+#if defined(__linux__) || defined(__CYGWIN__) || defined(__illumos__) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should it be there || defined(__EMSCRIPTEN__)
or its better limit wasm build ? https://github.com/hobuinc/laz-perf/blob/2b68700d33bf981d257d6101d96714620c64019c/cpp/lazperf/portable_endian.hpp#L15
if is_plat("linux", "bsd") then | ||
add_syslinks("m", "pthread") | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this more preferable https://github.com/hoene/libmysofa/blob/main/src/CMakeLists.txt#L211-L215
if is_plat("linux", "bsd") then
add_syslinks("pthread")
end
on_load("linux", "bsd", function (package)
if package:config("shared") then
package:add("syslinks", "m")
end
end)
wasm:
feel free to change & merge.