termux / termux-packages

A package build system for Termux.
https://termux.dev
Other
12.89k stars 2.97k forks source link

[Bug]: Error while installing libandroid-spawn #17503

Open anishdevtech opened 1 year ago

anishdevtech commented 1 year ago

Problem description

I was trying to install libandroid-spawn but it was not installing I don't know why I have seen a old message in which there is a guide how to install Ninja using some commands I follow that commands but install libandroid-spawn command didn't work and give the output

~ $ pkg install libandroid-spawn
Checking availability of current mirror:                               [*] https://packages-cf.termux.dev/apt/termux-main: ok
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libandroid-spawn is already the newest version (0.3).
The following package was automatically installed and is no longer required:                                                                    libgfortran5
Use 'apt autoremove' to remove it.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.         ~ $ install libandroid-spawn
install: missing destination file operand after 'libandroid-spawn'     Try 'install --help' for more information.
~ $

What steps will reproduce the bug?

I have I have full load this Link commands but this produce this error

What is the expected behavior?

Expected behaviour is to successfully install it

System information

termux-info:

Termux Variables:
TERMUX_API_VERSION=0.50.1
TERMUX_APK_RELEASE=F_DROID
TERMUX_APP_PACKAGE_MANAGER=apt
TERMUX_APP_PID=29429
TERMUX_IS_DEBUGGABLE_BUILD=0
TERMUX_MAIN_PACKAGE_FORMAT=debian
TERMUX_VERSION=0.118.0
Packages CPU architecture:
arm
Subscribed repositories:
# sources.list
deb https://packages-cf.termux.dev/apt/termux-main stable main
# root-repo (sources.list.d/root.list)
deb https://packages-cf.termux.dev/apt/termux-root root stable
Updatable packages:
All packages up to date
termux-tools version:
1.38.3
Android version:
11
Kernel build information:
Linux localhost 4.4.177-21848546 #1 SMP PREEMPT Wed Jul 13 14:26:29 KST 2022 armv8l Android
Device manufacturer:
samsung
Device model:
SM-A105F
LD Variables:
LD_LIBRARY_PATH=/data/data/com.termux/files/home/.local/lib:
LD_PRELOAD=/data/data/com.termux/files/usr/lib/libtermux-exec.so
Installed termux plugins:
com.termux.api versionCode:51
com.termux.styling versionCode:30
licy183 commented 1 year ago

I don't think this is a bug. As shown, you've installed libandroid-spawn.

anishdevtech commented 1 year ago

I don't think this is a bug. As shown, you've installed libandroid-spawn.

It is installed kind but not in working condition

licy183 commented 1 year ago

What does not in working condition mean? If you can find it in $PREFIX/lib, this package has been already successfully installed, and I don't think there is any error in installing libandroid-spawn.

licy183 commented 1 year ago

Installing ninja from pip has many bugs, because ninja from pip always tries to compile from source. Anyway, you should try export LDFLAGS="-landroid-spawn" && pip install ninja -vv and share the output to see what is the root cause.

anishdevtech commented 1 year ago

make[2]: [CMakeFiles/build_ninja.dir/build.make:120: build_ninja-prefix/src/build_ninja-stamp/build_ninja-run_ninja_test_suite] Error 1 make[1]: [CMakeFiles/Makefile2:111: CMakeFiles/build_ninja.dir/all] Error 2 make: *** [Makefile:136: all] Error 2 Traceback (most recent call last): File "/data/data/com.termux/files/usr/tmp/pip-build-env-ke2e5_8g/overlay/lib/python3.11/site-packages/skbuild/setuptools_wrap.py", line 674, in setup cmkr.make(make_args, install_target=cmake_install_target, env=env) File "/data/data/com.termux/files/usr/tmp/pip-build-env-ke2e5_8g/overlay/lib/python3.11/site-packages/skbuild/cmaker.py", line 697, in make self.make_impl(clargs=clargs, config=config, source_dir=source_dir, install_target=install_target, env=env) File "/data/data/com.termux/files/usr/tmp/pip-build-env-ke2e5_8g/overlay/lib/python3.11/site-packages/skbuild/cmaker.py", line 742, in make_impl raise SKBuildError(msg)
An error occurred while building with CMake. Command: /data/data/com.termux/files/usr/bin/cmake --build . --target install --config Release -- Install target: install Source directory: /data/data/com.termux/files/usr/tmp/pip-install-v5nzp_am/ninja_10399d4c447c461cb38fd2529ab2f53a Working directory: /data/data/com.termux/files/usr/tmp/pip-install-v5nzp_am/ninja_10399d4c447c461cb38fd2529ab2f53a/_skbuild/linux-armv8l-3.11/cmake-build Please check the install target is valid and see CMake's output for more information.

cybercruz commented 1 year ago

Screenshot_20230815-021505 Someone should help me with this

anishdevtech commented 1 year ago

Create a new issue pls