{"id":13643870,"url":"https://github.com/termux/termux-exec","last_synced_at":"2025-02-28T08:29:13.267Z","repository":{"id":25368154,"uuid":"103826397","full_name":"termux/termux-exec","owner":"termux","description":"A execve() wrapper to fix problem with shebangs.","archived":false,"fork":false,"pushed_at":"2024-06-20T01:36:48.000Z","size":22,"stargazers_count":183,"open_issues_count":4,"forks_count":57,"subscribers_count":16,"default_branch":"master","last_synced_at":"2024-10-29T20:56:22.960Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/termux.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-09-17T12:18:10.000Z","updated_at":"2024-10-25T00:50:38.000Z","dependencies_parsed_at":"2023-12-15T02:17:42.098Z","dependency_job_id":"b05137a2-f70f-440b-a801-2c14f145b120","html_url":"https://github.com/termux/termux-exec","commit_stats":{"total_commits":18,"total_committers":5,"mean_commits":3.6,"dds":0.4444444444444444,"last_synced_commit":"f3ae554e7c890b72c91bdc44ae2dfc8d141285a4"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/termux%2Ftermux-exec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/termux%2Ftermux-exec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/termux%2Ftermux-exec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/termux%2Ftermux-exec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/termux","download_url":"https://codeload.github.com/termux/termux-exec/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241124273,"owners_count":19913831,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T01:01:54.069Z","updated_at":"2025-02-28T08:29:13.229Z","avatar_url":"https://github.com/termux.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"# termux-exec\nA `execve()` wrapper to fix problem with shebangs when running in Termux.\n\n# Problem\nA lot of Linux software is written with the assumption that `/bin/sh`, `/usr/bin/env`\nand similar file exists. This is not the case on Android where neither `/bin/` nor `/usr/`\nexists.\n\nWhen building packages for Termux those hard-coded assumptions are patched away - but this\ndoes not help with installing scripts and programs from other sources than Termux packages.\n\n# Solution\nCreate an `execve()` wrapper that rewrites calls to execute files under `/bin/` and `/usr/bin`\ninto the matching Termux executables under `$PREFIX/bin/` and inject that into processes\nusing `LD_PRELOAD`.\n\n# How to install\n1. Install with `pkg install termux-exec`.\n2. Exit your current session and start a new one.\n3. From now on shebangs such as `/bin/sh` and `/usr/bin/env python` should work.\n\n# Where is LD_PRELOAD set?\nThe `$PREFIX/bin/login` program which is used to create new Termux sessions checks for\n`$PREFIX/lib/libtermux-exec.so` and if so sets up `LD_PRELOAD` before launching the login shell.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftermux%2Ftermux-exec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftermux%2Ftermux-exec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftermux%2Ftermux-exec/lists"}