mirror of
https://github.com/ziglang/zig.git
synced 2026-02-15 22:09:49 +00:00
more helpful message when testTlsOffsetAlignment fails
This commit is contained in:
parent
504ad56815
commit
2530d638d6
@ -3757,11 +3757,15 @@ fn testTlsOffsetAlignment(b: *Build, opts: Options) *Step {
|
||||
\\#include <pthread.h>
|
||||
\\#include <dlfcn.h>
|
||||
\\#include <assert.h>
|
||||
\\#include <stdio.h>
|
||||
\\void *(*verify)(void *);
|
||||
\\
|
||||
\\int main() {
|
||||
\\ void *handle = dlopen("liba.so", RTLD_NOW);
|
||||
\\ assert(handle);
|
||||
\\ if (!handle) {
|
||||
\\ fprintf(stderr, "dlopen failed: %s\n", dlerror());
|
||||
\\ return 1;
|
||||
\\ }
|
||||
\\ *(void**)(&verify) = dlsym(handle, "verify");
|
||||
\\ assert(verify);
|
||||
\\
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user