Blame src/ldso/nt32/dlsym.s

8b6d8f
############################################################################
8b6d8f
##  mmglue: midipix architecture- and target-specific bits for musl libc  ##
8b6d8f
##  Copyright (C) 2013--2025  SysDeer Technologies, LLC                   ##
8b6d8f
##  Released under GPLv2 and GPLv3; see COPYING.MMGLUE.                   ##
8b6d8f
############################################################################
8b6d8f
8b6d8f
.text
8b6d8f
.global _dlsym
8b6d8f
8b6d8f
.def _dlsym; .scl 2; .type 32; .endef
8b6d8f
8b6d8f
_dlsym:
8b6d8f
	movl  %esp,%ecx  # save stack pointer
8b6d8f
	push  (%ecx)     # original return address
8b6d8f
	push  12(%ecx)   # original second argument
8b6d8f
	push  12(%ecx)   # original first argument
8b6d8f
	call  ___dlsym
8b6d8f
	movl  %ecx,%esp  # restore stack pointer
8b6d8f
8b6d8f
	.section .got$_dlsym,"r"
8b6d8f
	.global __imp__dlsym
8b6d8f
__imp__dlsym:
8b6d8f
	.long     _dlsym
8b6d8f
	.linkonce discard