Access network file shares directly from the Android Downloads/Files app
b16d629dc5
* Consolidate ShareManager into the unified init process. * Remove misc.xml * Expose smb.conf to external storage. Some clean-up on initialization code. Fix a bug that doesn't restart SMB client after configuration is updated. * Use the right TAG. * Guard a log behind debug flag. |
||
---|---|---|
.idea | ||
app | ||
gradle/wrapper | ||
.gitignore | ||
build.gradle | ||
CONTRIBUTING.md | ||
gradle.properties | ||
gradlew | ||
gradlew.bat | ||
groups | ||
LICENSE | ||
project.config | ||
README.md | ||
sambapatch.diff | ||
settings.gradle |
Samba Documents Provider
Overview
This is an Android app that extends the built in File Manager to support connecting to SMB file shares.
This app is built on top of Samba 4.5.1.
Setup
Prerequisite
Android SDK and NDK r15b or above are required to build this app. Android Studio is highly recommended.
Build Steps
- Download and unarchive Samba 4.5.1 source code.
- Change directory to the root of Samba source code.
- Create a git repository.
- Run
git apply <path_to_samba_documents_provider_source>/sambapatch.diff
. - Modify configure.sh to change $NDK to point to your NDK folder.
- Uncomment corresponding flags in configure.sh to compile for different architecture. Uncomment flags for ARMv7 in addition to 32-bit ARM to compile it for ARMv7.
- Run
configure.sh
to configure Samba project. - Run
compile.sh
to compile libsmbclient.so. - Run
install.sh <path_to_samba_documents_provider_source>/app/src/main/jniLibs/<ABI>
. - Change directory to SambaDocumentsProvider source code.
- Run
mv app/src/main/jniLibs/<ABI>/includes app/src/main/cpp/samba_includes
. - Change directory to the root of Samba source code and run
make distclean
. - Repeat step 6-12 for all desired ABI's.
- Make sure to change app's
build.gradle
to include only ABI's that Samba was built for in previous steps. - Compile SambaDocumentsProvider.
Discussion
Please go to our Google group to discuss any issues.