美文网首页
strace交叉编译 strace5.5

strace交叉编译 strace5.5

作者: o从心出发o | 来源:发表于2020-04-05 11:06 被阅读0次

    下载

    https://github.com/strace/strace/releases/download/v5.5/strace-5.5.tar.xz

    Please ignore so called "Source code" links provided by github, they are useless.
    请忽略github提供的所谓“源代码”链接,它们是无用的。

    配置

    默认已经有configure文件

    ./configure CC=/tool/gcc_linaro/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-gcc CXX=/tool/gcc_linaro/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-g++ LD=/tool/gcc_linaro/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-ld RANLIB=/tool/gcc_linaro/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-ranlib --host=aarch64-linux --target=aarch64-linux --prefix=/workspace/xxx/thirdparty/strace/install --enable-mpers=no
    
    或者
    
    ./configure CC=aarch64-linux-gnu-gcc CXX=aarch64-linux-gnu-cpp LD=aarch64-linux-gnu-ld RANLIB=aarch64-linux-gnu-ranlib --host=aarch64-linux --target=aarch64-linux --enable-mpers=no
    

    注意:发现出现configure: error: Cannot enable m32 personality support 错误提示时:
    添加:--enable-mpers=no

    编译

    make LDFLAGS+='-static -pthread'
    

    安装

    make installt
    或者
    make install exec_prefix=/mnt/d/wsl_ubuntu/workspace/d_thirdparty/strace-5.5/out
    

    使用

    https://www.linuxidc.com/Linux/2018-01/150654.htm

    参考

    https://blog.csdn.net/lile777/article/details/103611243/

    https://blog.csdn.net/aalace/article/details/103176287

    相关文章

      网友评论

          本文标题:strace交叉编译 strace5.5

          本文链接:https://www.haomeiwen.com/subject/msayphtx.html