Skip to content

Instantly share code, notes, and snippets.

View natsumerinchan's full-sized avatar
⚒️

Celica Sylphil natsumerinchan

⚒️
View GitHub Profile
@natsumerinchan
natsumerinchan / enable_nativebridge
Created April 13, 2022 10:10 — forked from uzxmx/enable_nativebridge
android x86 /system/bin/enable_nativebridge
#!/system/bin/sh
PATH=/system/bin:/system/xbin
houdini_bin=0
dest_dir=/system/lib$1/arm$1
binfmt_misc_dir=/proc/sys/fs/binfmt_misc
if [ -z "$1" ]; then
if [ "`uname -m`" = "x86_64" ]; then
@natsumerinchan
natsumerinchan / WSA_Houdini_Extracter.bat
Last active September 19, 2024 04:16
Extract libhoudini from WSA.
@echo off
@rem Set variables
set "TMP_PATH=/data/local/tmp"
set "WSA_PORT=127.0.0.1:58526"
@rem Check whether platform-tools is exist or not
adb devices >nul
if not %errorlevel% == 0 (
cls
echo [ERROR] It seems that adb is not exist!
@natsumerinchan
natsumerinchan / Modify_Android-x86.md
Last active December 21, 2023 04:42 — forked from jhorstmann/gist:1579903
How to modify Android-x86 system.img

Extract the iso image and the contained squashfs image

$ mkdir android-image
$ bsdtar -C android-image -xf xxx.iso
$ cd android-image
$ unsquashfs system.sfs

Modify system.img size.

$ sudo e2fsck -f ./squashfs-root/system.img

@natsumerinchan
natsumerinchan / lahaina-arch.sh
Last active February 22, 2023 08:29
Compile kernel for Oneplus 9RT on Arch Linux
#! /bin/bash
set -eux
setup_export() {
export KERNEL_PATH=$PWD
export CLANG_PATH=~/toolchains/neutron-clang
export PATH=${CLANG_PATH}/bin:${PATH}
export CLANG_TRIPLE=aarch64-linux-gnu-
export ARCH=arm64
@natsumerinchan
natsumerinchan / vangogh-arch.sh
Last active February 22, 2023 08:29
Compile kernel for Mi 10 Lite Zoom on Arch Linux
#! /bin/bash
set -x
setup_export() {
export KERNEL_PATH=$PWD
export KERNEL_DEFCONFIG=vendor/vangogh_user_defconfig
export KERNEL_FILE=Image
export CLANG_VERSION=r416183b
export BUILD_EXTRA_COMMAND='LLVM=1'
@natsumerinchan
natsumerinchan / 40_custom.md
Last active February 24, 2023 09:38
Boot BlissOS on Intel GPU && NVIDIA GPU devices

Modify /etc/grub.d/40_custom

sudo nano /etc/grub.d/40_custom 

Add these lines.

menuentry 'Bliss OS' {
set android=/bliss
@natsumerinchan
natsumerinchan / trash-cli
Last active February 25, 2023 16:34
trash-cli helper
#!/usr/bin/bash
if [ ! "$1" ] || [ "$1" == "help" ]; then
if [ "$2" == "" ]; then
echo "Get command help: trash-cli help <put/empty/list/restore/rm>"
echo "help 获取帮助"
echo "put 把文件或目录移动到回收站"
echo "empty 清空回收站"
echo "list 列出回收站文件"
echo "restore 恢复回收站文件"
@natsumerinchan
natsumerinchan / eva-arch-build.sh
Last active July 18, 2024 07:54
Compile eva kernel for Oneplus 9 Series(9/9PRO/9RT) or Realme GT Master Edition on Arch Linux.(Just need to run this script in an empty folder.)
#!/bin/bash
clear
set -eux
setup_export() {
export LC_ALL=C
export SOURCE_PATH=$PWD
export CLANG_PATH=$SOURCE_PATH/prebuilts-master/clang/host/linux-x86/clang-r450784d/
@natsumerinchan
natsumerinchan / 0001-kallsyms-strip-LTO-suffixes-from-static-functions.patch
Created March 21, 2023 12:07
0001-kallsyms-strip-LTO-suffixes-from-static-functions.patch
From 2a710a626354016cd0344b848adeedb6e31ae643 Mon Sep 17 00:00:00 2001
From: Nathan Chancellor <[email protected]>
Date: Tue, 21 Mar 2023 15:04:24 +0800
Subject: [PATCH] kallsyms: strip LTO suffixes from static functions
https://lore.kernel.org/all/[email protected]/#r
---
kernel/kallsyms.c | 47 ++++++++++++++++++++++++++++++++++-------------
1 file changed, 34 insertions(+), 13 deletions(-)
From 2cea5094c6104dba89e2e759b7984a65357c5d2d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E3=82=BB=E3=83=AA=E3=82=AB=E3=83=BB=E3=82=B7=E3=83=AB?=
=?UTF-8?q?=E3=83=95=E3=82=A3=E3=83=AB?=
<[email protected]>
Date: Sat, 25 Mar 2023 18:13:53 +0800
Subject: [PATCH] kernel: Show the real /proc/config.gz
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit