-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tips for Termux installation #950
Comments
😍😭❤️ you're a genius I was about to give up , please please please can you explain this in more detail I am using tarfile to install this and I cannot find the python/ directory 😢 and I am a little bit confused about where I've to make that edit is that line number specific in that file ? |
@FindingMeaning : Re your question - it requires
first, obviously, then changing these tidbits ( in .../sentencepiece/CMakeLists.txt, as I wrote) that you will see, and maybe paying attention to the missing libraries that In short - just paste these errors to a live session with any LLM/AI and explain to it politely what you are after, assuming it is also a blind man seeing (your) elephant, that is the system errors. |
Another tip for Termux lovers (like me)
or
(e.g. for MALLOC error) is what is needed to compile, the termux equivalents thereof Anyhow, use that syntax to find the Termux precompiled equivalents of most anything: numpy (needed for numba), scikit, torch, etc. Another trick that (may, a big may) work out of the box
|
FYI, I know it should not be here, as it is not a bug, but I wrote a quick script that runs it in Termux etc, with cute statistics. |
Thankyou very very much 😌 I've successfully installed sentence-transformers because of you, for me you'll always be a genius and a person who helped me when I was loosing hope 😭 Thank you very very very much once again |
Which version of sentencepiece are you using? |
Just add this line at top of CMakeLists.txt |
This had to be added, when compiling it in Termux:
.../sentencepiece/CMakeLists.txt
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -llog")
: This line is setting a CMake variable calledCMAKE_SHARED_LINKER_FLAGS
, which specifies the flags to be used by the linker when creating shared libraries⁵. The-llog
flag tells the linker to link againstliblog.so
, which provides the__android_log_write
function that was causing the undefined reference error in your initial build attempt⁶.Compile:
cmake .. -DCMAKE_INSTALL_PREFIX=$PREFIX
: Here, you're invoking CMake and passing it a command-line argument to set theCMAKE_INSTALL_PREFIX
variable. This variable determines the directory where the project will be installed[^10^]¹¹. By setting it to$PREFIX
, you're telling CMake to install the project in the directory specified by thePREFIX
environment variable, which in Termux is typically/data/data/com.termux/files/usr
.After applying these fixes and successfully building the project:
The text was updated successfully, but these errors were encountered: