• (OK) cross_compile_readline_for_android-x86_64-6.0


    cross_compile_readline_for_android-x86_64-6.0.txt

    download readline: ftp://ftp.cwru.edu/pub/bash/readline-6.3.tar.gz


    [root@localhost readline-6.3]# pwd
    /opt/android-on-linux/readline-6.3
    [root@localhost readline-6.3]#

    -----
    Note: no use
    -----
    // update the config.sub and config.guess files (the ones in the libreadline source are very old and don't have arm-linux-androideabi)

    cp /usr/share/automake-1.15/config.{sub,guess} support/
    -----



    -----
    Note: first, execute autoconf:  it looks like a stale `configure', can regenerate it using autoconf.
    -----

    autoconf

    make clean

    export NDK_ROOT="/opt/android-on-linux/android-ndk-r12"
    export SYSROOT="$NDK_ROOT/platforms/android-23/arch-x86_64"
    export CFLAGS="-g --pipe --sysroot=$SYSROOT -fPIC -fpic -I$NDK_ROOT/toolchains/x86_64-4.9/prebuilt/linux-x86_64/lib/gcc/x86_64-linux-android/4.9.x/include-fixed/ -I$NDK_ROOT/platforms/android-23/arch-x86_64/usr/include -I$NDK_ROOT/sources/cxx-stl/llvm-libc++/libcxx/include/ -I$NDK_ROOT/sources/android/support/include/"
    export CPPFLAGS="$CFLAGS"
    export CXXFLAGS="$CFLAGS"
    export LDFLAGS="--sysroot=$SYSROOT -fPIE -fpie -L$NDK_ROOT/platforms/android-23/arch-x86_64/usr/lib/ -L$NDK_ROOT/sources/cxx-stl/stlport/libs/x86_64 -L$NDK_ROOT/sources/cxx-stl/llvm-libc++/libs/x86_64 -L$NDK_ROOT/sources/cxx-stl/gnu-libstdc++/4.9/libs/x86_64 -shared -lstlport_shared -lm -lc++ -lc"
    export CPATH="/opt/android-on-linux/android-ndk-r12/toolchains/x86_64-4.9/prebuilt/linux-x86_64/bin"
    export CPP="$CPATH/x86_64-linux-android-cpp"
    export CXX="$CPATH/x86_64-linux-android-g++"
    export CC="$CPATH/x86_64-linux-android-gcc"
    export LD="$CPATH/x86_64-linux-android-ld"
    export AR="$CPATH/x86_64-linux-android-ar"
    export STRIP="$CPATH/x86_64-linux-android-strip"
    export OBJDUMP="$CPATH/x86_64-linux-android-objdump"
    export RANLIB="$CPATH/x86_64-linux-android-ranlib"

    ./configure --host=x86_64-android-linux
     --prefix=/opt/android-on-linux/readline-6.3/out
     --exec-prefix=/opt/android-on-linux/readline-6.3/out


    make -j4

    make install

    // $STRIP /opt/android-on-linux/quagga/out/sbin/*

    ll -h out/lib


    [root@localhost readline-6.3]# ll -h out/lib
    总用量 1.8M
    -rw-r--r--. 1 root root 121K 7月   5 14:34 libhistory.a
    lrwxrwxrwx. 1 root root   15 7月   5 14:34 libhistory.so -> libhistory.so.6
    lrwxrwxrwx. 1 root root   17 7月   5 14:34 libhistory.so.6 -> libhistory.so.6.3
    -r-xr-xr-x. 1 root root  72K 7月   5 14:34 libhistory.so.6.3
    -rw-r--r--. 1 root root 983K 7月   5 14:34 libreadline.a
    lrwxrwxrwx. 1 root root   16 7月   5 14:34 libreadline.so -> libreadline.so.6
    lrwxrwxrwx. 1 root root   18 7月   5 14:34 libreadline.so.6 -> libreadline.so.6.3
    -r-xr-xr-x. 1 root root 536K 7月   5 14:34 libreadline.so.6.3


  • 相关阅读:
    猜数字小游戏的设计
    实验三 敏捷开发与XP实践 实验报告
    实验二Java面向对象程序设计
    课程总结报告
    Android实践项目汇报总结(下)
    Android实践项目汇报总结(上)修改
    Android项目开发四
    Android项目开发三
    Android项目开发二
    Android项目开发一
  • 原文地址:https://www.cnblogs.com/ztguang/p/12646216.html
Copyright © 2020-2023  润新知