GithubHelp home page GithubHelp logo

wilson1068 / android-prng Goto Github PK

View Code? Open in Web Editor NEW

This project forked from noloader/android-prng

0.0 1.0 0.0 77 KB

Sample Android shared object which depends on Crypto++ library shared object.

Shell 30.72% Makefile 4.57% C++ 53.62% Java 11.08%

android-prng's Introduction

Android-PRNG is a sample Android NDK project to demonstrate two topics. First, it shows you how to compile a real shared object using the Crypto++ library on Android. Second, it shows you how to sample sensors to accumulate seed data to use with a software based random number generator.


The project requires the Crypto++ library built for Android with architectures armeabi, x86, mips, armeabi-v7a and x86_64. The project looks for them in the following locations based on architecture:

  • /usr/local/cryptopp/android-armeabi
  • /usr/local/cryptopp/android-armeabi-v7a
  • /usr/local/cryptopp/android-mips
  • /usr/local/cryptopp/android-x86
  • /usr/local/cryptopp/android-x86_64

You can do it by repeatedly building and installing the Crypto++ library. For that task, see "Android (Command Line)" on the Crypto++ wiki at http://www.cryptopp.com/wiki/Android_(Command_Line) .

The executive summary from "Android (Command Line)" is:

git clone https://github.com/weidai11/cryptopp.git
cd cryptopp
wget https://www.cryptopp.com/w/images/0/0a/Setenv-android.sh.zip
unzip -aoq Setenv-android.sh.zip
. ./setenv-android.sh armeabi stlport

make -f GNUmakefile-cross distclean
make -f GNUmakefile-cross static dynamic
sudo make install PREFIX=/usr/local/cryptopp/android-armeabi

Lather, rinse, repeat for each architecture.


Once you have the libraries installed, use ndk-build to build the library:

cd Android-PRNG
ndk-build

After the native libraries are built, use ant to build the APK and install it on a device:

ant debug install

Once installed, you should find it in the App Launcher.

android-prng's People

Contributors

noloader avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.