Code:/usr/bin/ld: errno: TLS definition in /lib/x86_64-linux-gnu/libc.so.6 section .tbss mismatches non-TLS reference in purebasic.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libc.so.6: Fehler beim Hinzufügen von Symbolen: bad value
collect2: error: ld returned 1 exit status
Code: Select all
;-TOP
; By mk-soft, v1.01.1, 08.01.2023
; Not work with ASM (Bug version)
CompilerIf Not Defined(PB_Compiler_Backend, #PB_Constant)
#PB_Backend_Asm = 0
#PB_Backend_C = 1
#PB_Compiler_Backend = 0
CompilerEndIf
CompilerIf #PB_Compiler_OS = #PB_OS_Windows
Macro GetLastError()
GetLastError_()
EndMacro
CompilerElse
CompilerIf #PB_Compiler_Backend = #PB_Backend_C
Procedure GetLastError()
!#include "errno.h"
!extern int errno;
Protected r1
!v_r1=errno;
ProcedureReturn r1
EndProcedure
CompilerElse
ImportC ""
errno
EndImport
Procedure GetLastError()
Protected r1
r1 = errno
ProcedureReturn r1
EndProcedure
CompilerEndIf
CompilerEndIf
; ----
CompilerIf #PB_Compiler_IsMainFile
err = GetLastError()
Debug "LastError = " + GetLastError()
CompilerEndIf