mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-02-07 06:53:33 +00:00
With these addtions, I could build and run a [sokol](https://github.com/floooh/sokol) application (using OpenGL) on both Linux and Windows.
20 lines
315 B
ArmAsm
20 lines
315 B
ArmAsm
#include "libc/nt/codegen.h"
|
|
.imp kernel32,__imp_GlobalLock,GlobalLock
|
|
|
|
.text.windows
|
|
.ftrace1
|
|
GlobalLock:
|
|
.ftrace2
|
|
#ifdef __x86_64__
|
|
push %rbp
|
|
mov %rsp,%rbp
|
|
mov %rdi,%rcx
|
|
sub $32,%rsp
|
|
call *__imp_GlobalLock(%rip)
|
|
leave
|
|
#elif defined(__aarch64__)
|
|
mov x0,#0
|
|
#endif
|
|
ret
|
|
.endfn GlobalLock,globl
|
|
.previous
|