sustrik / libdill

Structured concurrency in C
MIT License
1.68k stars 156 forks source link

build for Android/x86 failed #211

Open leleliu008 opened 2 years ago

leleliu008 commented 2 years ago
/home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=i686-none-linux-android24 --sysroot=/home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot -DDILL_THREADS -DHAVE_MPROTECT -DHAVE_POSIX_MEMALIGN -Ddill_EXPORTS -I/tmp/tmp.ynVAr3y0UK -I/tmp/tmp.ynVAr3y0UK/dns --sysroot /home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot -Qunused-arguments -fpic -Wl,--dynamic-linker=/system/bin/linker -Wl,--strip-debug -Os -DNDEBUG -fno-asynchronous-unwind-tables -I/home/fpliu/.ndk-pkg/install.d/openssl/x86/include --sysroot /home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot -Qunused-arguments -I/home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/include/i686-linux-android -include /tmp/tmp.ynVAr3y0UK/1640588455/include.h -L/home/fpliu/.ndk-pkg/install.d/openssl/x86/lib --sysroot /home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot -L/tmp/tmp.ynVAr3y0UK/1640588455 -L/home/fpliu/.ndk-pkg/android-ndk-r23b/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/i686-linux-android/24 -Wl,--dynamic-linker=/system/bin/linker -Wl,--strip-debug -O3 -DNDEBUG -fPIC -MD -MT CMakeFiles/dill.dir/cr.c.o -MF CMakeFiles/dill.dir/cr.c.o.d -o CMakeFiles/dill.dir/cr.c.o -c /tmp/tmp.ynVAr3y0UK/cr.c
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:196:35: note: expanded from macro 'dill_longjmp'
        "movl   20(%%edx), %%ecx\n\t"\
                                  ^
<inline asm>:7:2: note: instantiated into assembly here
        .cfi_def_cfa %edx, 0
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:197:34: note: expanded from macro 'dill_longjmp'
        ".cfi_def_cfa %%edx, 0 \n\t"\
                                 ^
<inline asm>:8:2: note: instantiated into assembly here
        .cfi_offset %ebx, 0
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:198:33: note: expanded from macro 'dill_longjmp'
        ".cfi_offset %%ebx, 0 \n\t"\
                                ^
<inline asm>:9:2: note: instantiated into assembly here
        .cfi_offset %esi, 4
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:199:33: note: expanded from macro 'dill_longjmp'
        ".cfi_offset %%esi, 4 \n\t"\
                                ^
<inline asm>:10:2: note: instantiated into assembly here
        .cfi_offset %edi, 8
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:200:33: note: expanded from macro 'dill_longjmp'
        ".cfi_offset %%edi, 8 \n\t"\
                                ^
<inline asm>:11:2: note: instantiated into assembly here
        .cfi_offset %ebp, 12
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:201:34: note: expanded from macro 'dill_longjmp'
        ".cfi_offset %%ebp, 12 \n\t"\
                                 ^
<inline asm>:12:2: note: instantiated into assembly here
        .cfi_offset %esp, 16
        ^
/tmp/tmp.ynVAr3y0UK/cr.c:504:5: error: this directive must appear between .cfi_startproc and .cfi_endproc directives
    dill_longjmp(ctx->r->ctx);
    ^
/tmp/tmp.ynVAr3y0UK/libdill.h:202:34: note: expanded from macro 'dill_longjmp'
        ".cfi_offset %%esp, 16 \n\t"\
                                 ^
<inline asm>:13:2: note: instantiated into assembly here
        .cfi_offset %eip, 20
        ^
7 errors generated.

It seems that clang do not recognize this inline ASM syntax.

Android NDK: 23.1.7779620

https://github.com/sustrik/libdill/archive/2.14.tar.gz