Run LG on ARM-Win10VM

I want to run LG on ARM-Win10VM, but I can’t find a tool to cross-compile, I tried to compile 32-bit x86 program, the following error occurred, can anyone give me some advice

[ 90%] Generating version.c, include/version.h, _version.c
[ 92%] Building RC object CMakeFiles/looking-glass-host.dir/platform/Windows/resource.rc.res
[ 95%] Building C object CMakeFiles/looking-glass-host.dir/version.c.obj
[ 97%] Linking C executable looking-glass-host.exe
/usr/bin/i686-w64-mingw32-ld: platform/Windows/libplatform_Windows.a(platform.c.obj):platform.c:(.text$boostPriority+0x1c): undefined reference to `[email protected]'
/usr/bin/i686-w64-mingw32-ld: platform/Windows/libplatform_Windows.a(platform.c.obj):platform.c:(.text$os_blockScreensaver+0x94): undefined reference to `[email protected]'
/usr/bin/i686-w64-mingw32-ld: common/src/platform/windows/liblg_common_platform_code.a(time.c.obj):time.c:(.text$windowsSetTimerResolution+0x20): undefined reference to `[email protected]'
/usr/bin/i686-w64-mingw32-ld: CMakeFiles/looking-glass-host.dir/objects.a(app.c.obj):app.c:(.text$nsleep+0x50): undefined reference to `[email protected]'
/usr/bin/i686-w64-mingw32-ld: common/src/platform/windows/liblg_common_platform_code.a(cpuinfo.c.obj):cpuinfo.c:(.text$getCoreCount+0x40): undefined reference to `[email protected]'
/usr/bin/i686-w64-mingw32-ld: common/src/platform/windows/liblg_common_platform_code.a(cpuinfo.c.obj):cpuinfo.c:(.text$getCoreCount+0x256): undefined reference to `[email protected]'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/looking-glass-host.dir/build.make:133:looking-glass-host.exe] 错误 1
make[1]: *** [CMakeFiles/Makefile2:78:CMakeFiles/looking-glass-host.dir/all] 错误 2
make: *** [Makefile:130:all] 错误 2

client has problem…here is log:

[I] 283982670588              main.c:1304 | main                           | Looking Glass (B5.0.1)
[I] 283982670673              main.c:1305 | main                           | Locking Method: Atomic
[I] 283982670853           cpuinfo.c:36   | lgDebugCPU                     | CPU Model: �Jݞ
[I] 283982670877           cpuinfo.c:37   | lgDebugCPU                     | CPU: 0 cores, 8 threads
[I] 283982698383              main.c:866  | lg_run                         | Using font: /usr/share/fonts/truetype/dejavu/DejaVuSansMono.ttf
[I] 283982698578           ivshmem.c:128  | ivshmemOpenDev                 | KVMFR Device     : /dev/shm/looking-glass
[I] 283982808232               egl.c:261  | egl_initialize                 | Double buffering is off
[I] 283982808259              main.c:833  | tryRenderer                    | Using Renderer: EGL
[W] 283982946616             input.c:402  | waylandInputInit               | zwp_keyboard_shortcuts_inhibit_manager_v1 not exported by compositor, keyboard will not be grabbed                                                                                                                             
[I] 283982947984                gl.c:65   | waylandGetEGLDisplay           | Using eglGetPlatformDisplayEXT
[I] 283982959545               egl.c:773  | egl_renderStartup              | Single buffer mode
[I] 283982960000               egl.c:789  | egl_renderStartup              | EGL     : 1.4
[I] 283982960036               egl.c:790  | egl_renderStartup              | Vendor  : ARM
[I] 283982960044               egl.c:791  | egl_renderStartup              | Renderer: Mali-G52
[I] 283982960052               egl.c:792  | egl_renderStartup              | Version : OpenGL ES 3.2 v1.r29p0-01eac0.c718f9084c8f6428c3bf6442822e2361
[I] 283982960068               egl.c:793  | egl_renderStartup              | EGL APIs: OpenGL_ES
[I] 283982960076               egl.c:794  | egl_renderStartup              | EGL Exts: EGL_WL_bind_wayland_display EGL_NV_context_priority_realtime EGL_KHR_partial_update EGL_EXT_swap_buffers_with_damage EGL_KHR_swap_buffers_with_damage EGL_ANDROID_native_fence_sync EGL_KHR_config_attribs EGL_KHR_image EGL_KHR_image_base EGL_KHR_fence_sync EGL_KHR_wait_sync EGL_KHR_gl_colorspace EGL_KHR_get_all_proc_addresses EGL_IMG_context_priority EGL_KHR_no_config_context EGL_EXT_image_dma_buf_import EGL_EXT_image_dma_buf_import_modifiers EGL_EXT_yuv_surface EGL_EXT_pixel_format_float EGL_ARM_pixmap_multisample_discard EGL_ARM_implicit_external_sync EGL_KHR_gl_texture_2D_image EGL_KHR_gl_renderbuffer_image EGL_KHR_create_context EGL_KHR_surfaceless_context EGL_KHR_gl_texture_cubemap_image EGL_EXT_image_gl_colorspace EGL_EXT_create_context_robustness
[I] 283982960091               egl.c:795  | egl_renderStartup              | GL Exts : GL_ARM_rgba8 GL_ARM_mali_shader_binary GL_OES_depth24 GL_OES_depth_texture GL_OES_depth_texture_cube_map GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_EXT_read_format_bgra GL_OES_compressed_paletted_texture GL_OES_compressed_ETC1_RGB8_texture GL_OES_standard_derivatives GL_OES_EGL_image GL_OES_EGL_image_external GL_OES_EGL_image_external_essl3 GL_OES_EGL_sync GL_OES_texture_npot GL_OES_vertex_half_float GL_OES_required_internalformat GL_OES_vertex_array_object GL_OES_mapbuffer GL_EXT_texture_format_BGRA8888 GL_EXT_texture_rg GL_EXT_texture_type_2_10_10_10_REV GL_OES_fbo_render_mipmap GL_OES_element_index_uint GL_EXT_shadow_samplers GL_OES_texture_compression_astc GL_KHR_texture_compression_astc_ldr GL_KHR_texture_compression_astc_hdr GL_KHR_texture_compression_astc_sliced_3d GL_EXT_texture_compression_astc_decode_mode GL_EXT_texture_compression_astc_decode_mode_rgb9e5 GL_KHR_debug GL_EXT_occlusion_query_boolean GL_EXT_disjoint_timer_query GL_EXT_blend_minmax GL_EXT_discard_framebuffer GL_OES_get_program_binary GL_OES_texture_3D GL_EXT_texture_storage GL_EXT_multisampled_render_to_texture GL_EXT_multisampled_render_to_texture2 GL_OES_surfaceless_context GL_OES_texture_stencil8 GL_EXT_shader_pixel_local_storage GL_ARM_shader_framebuffer_fetch GL_ARM_shader_framebuffer_fetch_depth_stencil GL_ARM_mali_program_binary GL_EXT_sRGB GL_EXT_sRGB_write_control GL_EXT_texture_sRGB_decode GL_EXT_texture_sRGB_R8 GL_EXT_texture_sRGB_RG8 GL_KHR_blend_equation_advanced GL_KHR_blend_equation_advanced_coherent GL_OES_texture_storage_multisample_2d_array GL_OES_shader_image_atomic GL_EXT_robustness GL_EXT_draw_buffers_indexed GL_OES_draw_buffers_indexed GL_EXT_texture_border_clamp GL_OES_texture_border_clamp GL_EXT_texture_cube_map_array GL_OES_texture_cube_map_array GL_OES_sample_variables GL_OES_sample_shading GL_OES_shader_multisample_interpolation GL_EXT_shader_io_blocks GL_OES_shader_io_blocks GL_EXT_tessellation_shader GL_OES_tessellation_shader GL_EXT_primitive_bounding_box GL_OES_primitive_bounding_box GL_EXT_geometry_shader GL_OES_geometry_shader GL_ANDROID_extension_pack_es31a GL_EXT_gpu_shader5 GL_OES_gpu_shader5 GL_EXT_texture_buffer GL_OES_texture_buffer GL_EXT_copy_image GL_OES_copy_image GL_EXT_shader_non_constant_global_initializers GL_EXT_color_buffer_half_float GL_EXT_color_buffer_float GL_EXT_YUV_target GL_OVR_multiview GL_OVR_multiview2 GL_OVR_multiview_multisampled_render_to_texture GL_KHR_robustness GL_KHR_robust_buffer_access_behavior GL_EXT_draw_elements_base_vertex GL_OES_draw_elements_base_vertex GL_EXT_buffer_storage GL_EXT_texture_filter_anisotropic GL_ARM_texture_unnormalized_coordinates GL_EXT_shader_framebuffer_fetch 
[W] 283982960137               egl.c:809  | egl_renderStartup              | GL_EXT_buffer_age is not supported, will not perform as well.
[I] 283982960183               egl.c:858  | egl_renderStartup              | Debug messages disabled, enable with egl:debug=true
[E] 283982992195            shader.c:141  | egl_shaderCompile              | Failed to compile fragment shader
[E] 283982992256            shader.c:150  | egl_shaderCompile              | 0:7: S0022: Symbol 'texture' redeclared
0:16: L0001: Symbol 'texture' can't be referenced as a variable                                                                                       
0:25: L0001: Symbol 'texture' can't be referenced as a variable                                                                                       
[E] 283982992289  filter_downscale.c:171  | egl_filterDownscaleInit        | Failed to compile the shader
[E] 283983022040            shader.c:141  | egl_shaderCompile              | Failed to compile fragment shader
[E] 283983022080            shader.c:150  | egl_shaderCompile              | 0:40: S0022: Symbol 'texture' redeclared
0:2705: L0001: Symbol 'texture' can't be referenced as a variable                                                                                     
0:4163: L0001: Symbol 'texture' can't be referenced as a variable                                                                                     
[E] 283983022113    filter_ffx_cas.c:120  | egl_filterFFXCASInit           | Failed to compile the shader
[E] 283983051053            shader.c:141  | egl_shaderCompile              | Failed to compile fragment shader
[E] 283983051123            shader.c:150  | egl_shaderCompile              | 0:40: S0022: Symbol 'texture' redeclared
0:2718: L0001: Symbol 'texture' can't be referenced as a variable                                                                                     
0:2719: L0001: Symbol 'texture' can't be referenced as a variable                                                                                     
0:2720: L0001: Symbol 'texture' can't be referenced as a variable                                                                                     
[E] 283983051159   filter_ffx_fsr1.c:129  | egl_filterFFXFSR1Init          | Failed to compile the Easu shader
[I] 283983160566              main.c:1176 | lg_run                         | Host ready, reported version: B5.0.1
[I] 283983160608              main.c:1177 | lg_run                         | Starting session
[I] 283983244717              main.c:641  | main_frameThread               | Format: FRAME_TYPE_BGRA 800x600 stride:800 pitch:3200 rotation:0
^C[I] 283987638699              main.c:789  | intHandler                     | Caught signal, shutting down...

How did you get a GPU inside the ARM KVM VM? That’s a prerequisite for this.

Although probably most certainly not supported, what’s your host distro?

i modified some code to make it work,like:

  status = D3D11CreateDevice(
    tmp,
    D3D_DRIVER_TYPE_UNKNOWN,
    NULL,
    //D3D11_CREATE_DEVICE_VIDEO_SUPPORT,
    0,
    featureLevels, featureLevelCount,
    D3D11_SDK_VERSION,
    &this->device,
    &this->featureLevel,
    &this->deviceContext);

Now I have fixed all the above problems, the host and client logs look fine, but when I use the client to connect to a host, the connection screen only appears at the beginning, and then freezes. I found that the heartbeat of the host disappeared after that. “Hq ->count” becomes negative and then goes into an infinite loop

The above occurs in host.c:lampHostProcess

Only x86_64 is supported, LGMP makes heavy usage of atomics in an architecture specific way which is why you’re having issues.

That seems to be the case. What changes can I make to LG to support ARM64?

No idea, ARM64 is not our target.