83 lines
2.3 KiB
Markdown
83 lines
2.3 KiB
Markdown
# PawletOS-Build
|
|
|
|
Scripts and helpers to build PawletOS.
|
|
|
|
## Usage
|
|
|
|
### Setup Environment
|
|
|
|
```bash
|
|
# Install dependencies
|
|
pip3 install -r requirements.txt
|
|
|
|
# Setup and sync source code
|
|
python3 environ.py --applyPatches
|
|
|
|
# Or with custom source directory
|
|
python3 environ.py --sourceDir my-source --applyPatches
|
|
```
|
|
|
|
### Configuration
|
|
|
|
Create `repo.yml`:
|
|
```yaml
|
|
repo:
|
|
url: "https://android.googlesource.com/platform/manifest"
|
|
branch: "android-14.0.0_r1"
|
|
options:
|
|
- "--depth=1"
|
|
- "--no-clone-bundle"
|
|
local_manifests:
|
|
device_manifest: "https://raw.githubusercontent.com/example/device-manifest/main/manifest.xml"
|
|
vendor_manifest: "https://raw.githubusercontent.com/example/vendor-manifest/main/manifest.xml"
|
|
```
|
|
|
|
### Command Line Options
|
|
|
|
| Option | Description |
|
|
|--------|-------------|
|
|
| `--noSync` | Skip repo sync (sync is enabled by default) |
|
|
| `--forceResync` | Force sync source code with repo sync --force-sync |
|
|
| `--applyPatches` | Apply patches from patches directory |
|
|
| `--forceApplyPatches` | Force apply patches even if some fail |
|
|
| `--patchLevel <n>` | Patch level for -p option (default: 1) |
|
|
| `--sourceDir <path>` | Source directory (default: AOSP-source) |
|
|
| `--patchDir <dirs>` | Patch directories (default: patches). Can specify multiple. |
|
|
| `--syncJobs <n>` | Number of parallel jobs for repo sync |
|
|
| `--ignorePatches <files>` | List of patches to ignore |
|
|
| `--useLegacyPatch` | Use legacy patch command instead of robust handler |
|
|
| `--verbosePatches` | Verbose output for patch application |
|
|
| `--config <file>` | Path to repo configuration file (default: repo.yml) |
|
|
| `--no-git-lfs` | Disable Git LFS setup (enabled by default) |
|
|
|
|
### Raspberry Pi Setup
|
|
|
|
```bash
|
|
chmod +x rpivanilla-ensetup.sh
|
|
./rpivanilla-ensetup.sh
|
|
```
|
|
|
|
## Files
|
|
|
|
- `environ.py` - Main setup script
|
|
- `rpivanilla-ensetup.sh` - Raspberry Pi environment setup
|
|
- `repo.yml` - Repository configuration
|
|
- `scripts/better-patch.py` - Patch management
|
|
- `patches/` - Patch files
|
|
|
|
## Requirements
|
|
|
|
- Python 3.6+
|
|
- Git (recommended for advanced patch features)
|
|
- Git LFS (optional, for large file support)
|
|
- Android build tools (repo, patch)
|
|
- Bash shell for setup scripts
|
|
- Python packages:
|
|
- `PyYAML` (for YAML configuration support)
|
|
- `requests` (for downloading local manifests)
|
|
|
|
### Installing Python Dependencies
|
|
|
|
```bash
|
|
pip3 install PyYAML requests
|
|
``` |