tylerchesley / libgphoto2android

📸 Android Wrapper around libgphoto2 to connect and remote control digital cameras via usb.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

libgphoto2android

Android Wrapper around libgphoto2 to connect and remote control digital cameras via usb.

CC-BY license Build Status

This project is an android wrapper around the gphoto2 library (libgphoto2) which main purpose is to connect and remote control digital cameras.

Installation

run docker image with android ndk

docker run --rm -it -v ${PWD}:/root android-build-environment:0.0.6

create a standalone toolchain into my-toolchain

$ANDROID_NDK_HOME/build/tools/make-standalone-toolchain.sh --arch=arm --install-dir=my-toolchain --force
python3 /usr/local/android-sdk/ndk/20.0.5594570/build/tools/make_standalone_toolchain.py --arch arm --install-dir my-toolchain --force

add created toolchain to path

export PATH=$PATH:`pwd`/my-toolchain/bin

download and unzip libgphoto2

tar -xvf ../libgphoto2-latest.tar.bz2 

set environment vars for cross-compile

target_host=arm-linux-androideabi
export AR=$target_host-ar
export AS=$target_host-clang
export CC=$target_host-clang
export CXX=$target_host-clang++
export LD=$target_host-ld
export STRIP=$target_host-strip
export CFLAGS="-fPIE -fPIC"
export LDFLAGS="-pie"

change into libgphoto2 directory and run configure command

./configure --host=arm-linux-androideabi --prefix=/root/libgphoto2-2.5.23/output --with-sysroot="/usr/local/android-sdk/ndk/20.0.5594570/sysroot/usr/lib/arm-linux-androideabi/"

build library

make install

Release History

  • 0.1.0
    • ADD: Add getLibraryVersion and create()
  • 0.0.1
    • First draft

Meta

Benjamin Stürmer – @benjaminstrmer – webmaster@stuermer-benjamin.de

Distributed under the Attribution 4.0 International (CC BY 4.0) license. See LICENSE for more information.

https://github.com/yourname/github-link

Contributing

  1. Fork it (https://github.com/thebino/libgphoto2android/fork>)
  2. Create your feature branch (git checkout -b feature/fooBar)
  3. Commit your changes (git commit -am 'Add some fooBar')
  4. Push to the branch (git push origin feature/fooBar)
  5. Create a new Pull Request

About

📸 Android Wrapper around libgphoto2 to connect and remote control digital cameras via usb.


Languages

Language:C 68.0%Language:Shell 12.7%Language:Makefile 11.7%Language:M4 6.0%Language:Perl 0.4%Language:Python 0.4%Language:HTML 0.3%Language:Objective-C 0.1%Language:Yacc 0.1%Language:C++ 0.1%Language:CMake 0.1%Language:Roff 0.0%Language:Kotlin 0.0%Language:Lex 0.0%Language:sed 0.0%