Skip to content
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

fail to run on macOS, possibly because lack of 32bit support #55

Open
Willian-Zhang opened this issue Feb 13, 2021 · 0 comments
Open

fail to run on macOS, possibly because lack of 32bit support #55

Willian-Zhang opened this issue Feb 13, 2021 · 0 comments

Comments

@Willian-Zhang
Copy link

Willian-Zhang commented Feb 13, 2021

build info

[ 86%] Linking C static library libopenhmd.a
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libopenhmd.a(platform-win32.c.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libopenhmd.a(platform-win32.c.o) has no symbols
[ 86%] Built target openhmd
[ 89%] Building CXX object CMakeFiles/driver_openhmd.dir/driverlog.cpp.o
[ 91%] Building CXX object CMakeFiles/driver_openhmd.dir/driver_openhmd.cpp.o
[ 94%] Linking CXX shared library bin/osx64/driver_openhmd.dylib
[ 94%] Built target driver_openhmd
[ 97%] Building C object subprojects/openhmd/examples/simple/CMakeFiles/simple.dir/simple.c.o
[100%] Linking C executable simple
[100%] Built target simple
# In ~/Library/Application Support/Steam/steamapps/common/SteamVR
❯ find . -name "vrpathreg"
./SteamVR.app/Contents/MacOS/runtime/bin/osx32/vrpathreg

❯ ./SteamVR.app/Contents/MacOS/runtime/bin/osx32/vrpathreg
Runtime path = /Users/macuser/Library/Application Support/Steam/steamapps/common/SteamVR/SteamVR.app/Contents/MacOS/runtime/
Config path = /Users/macuser/Library/Application Support/Steam/config
Log path = /Users/macuser/Library/Application Support/Steam/logs
External Drivers:
	/Users/macuser/Github/other/SteamVR-OpenHMD/build

from vrserver.txt

Sun Feb 14 2021 02:24:32.100611 - Unable to load driver openhmd from /Users/macuser/Github/other/SteamVR-OpenHMD/build/bin/osx32/driver_openhmd.dylib.
Sun Feb 14 2021 02:24:32.100651 - Unable to load driver openhmd because of error VRInitError_Init_FileNotFound(103). Skipping.

FTR osx32 does not exist in /Users/macuser/Github/other/SteamVR-OpenHMD/build/bin

if ln -s osx64 osx32

from vrserver.txt

Sun Feb 14 2021 01:47:10.429747 - error VRInitError_Init_InterfaceNotFound when initing driver openhmd from /Users/macuser/Github/other/SteamVR-OpenHMD/build/bin/osx32/driver_openhmd.dylib.
if add Compile flags

Neither openhmd nor this project was familiar to me, just tried the following with random guessing:

set(CMAKE_C_FLAGS -m32)
set(CMAKE_CXX_FLAGS -m32)
set_target_properties(openhmd PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
set_target_properties(driver_openhmd PROPERTIES COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
build info
[ 86%] Linking C static library libopenhmd.a
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libopenhmd.a(platform-win32.c.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libopenhmd.a(platform-win32.c.o) has no symbols
[ 86%] Built target openhmd
[ 89%] Building CXX object CMakeFiles/driver_openhmd.dir/driverlog.cpp.o
[ 91%] Building CXX object CMakeFiles/driver_openhmd.dir/driver_openhmd.cpp.o
[ 94%] Linking CXX shared library bin/osx64/driver_openhmd.dylib
... (large chunks of c lines)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [bin/osx64/driver_openhmd.dylib] Error 1
make[1]: *** [CMakeFiles/driver_openhmd.dir/all] Error 2
make: *** [all] Error 2
@Willian-Zhang Willian-Zhang changed the title fail to run on macOS, possibly because lack of fail to run on macOS, possibly because lack of 323bit support Feb 13, 2021
@Willian-Zhang Willian-Zhang changed the title fail to run on macOS, possibly because lack of 323bit support fail to run on macOS, possibly because lack of 32bit support Feb 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant