Skip to content

Instantly share code, notes, and snippets.

@ittat
ittat / patch_and_build.sh
Created May 13, 2020 23:41 — forked from EricRahm/patch_and_build.sh
x86_64 emulator build
#!/usr/bin/env bash
export LOCAL_NDK_BASE_URL='ftp://ftp.kaiostech.com/ndk/android-ndk'
mkdir patches
# Apply open PR for B2G repo
wget https://github.com/kaiostech/B2G/pull/4.patch -O patches/b2g.patch && patch -p1 < patches/b2g.patch
# Init
@ittat
ittat / note
Last active May 18, 2020 06:48
brew reinstall nasm yasm
brew install autoconf@2.13
ccache sccache
brew postinstall watchman
subprocess.CalledProcessError: Command '['/usr/local/opt/python/bin/python3.7', '/Volumes/android/B2G/gecko/mach', 'artifact', 'toolchain', '--from-build', 'macosx64-minidump-stackwalk']' returned non-zero exit status 1.
Could not find artifacts for a toolchain build named `macosx64-minidump-stackwalk`. Local commits, dirty/stale files, and other changes in your checkout may cause this error. Make sure you are on a fresh, current checkout
of mozilla-central. If you are already, you may be able to avoid this error by running `mach clobber python`. Beware that commands like `mach bootstrap` and `mach artifact` are unlikely to work on any versions of the code
在 ImageNet 上预训练过的用于图像分类的模型:
Xception
VGG16
VGG19
ResNet, ResNetV2, ResNeXt
InceptionV3
InceptionResNetV2
MobileNet
MobileNetV2
DenseNet
新b2g
https://github.com/kaiostech/gecko-b2g/tree/3699cef0e5611cba4ecdcdfa4b59fa37e825caa3/dom/b2g/tethering
https://github.com/kaiostech/gecko-b2g/commit/46b34c77149823e339f78c959e9efc155dd0d27c#diff-255ac02ce991ec5b067e127483bac18c
旧 b2g idl
https://github.com/ittat/quic_lf_b2g_mozilla_gecko/commit/9ff955b12d2555ef78773c0f0b065b8a8337a415#diff-6589d35e15b2b6aba772fab9f6f7ca37
Note: 在gecko 层 jsm可以直接使用,默认jsm打包resource://gre/modules/ 或者XPCOMUtils.defineLazyServiceGetter(...)
在gaia 这需要api实现
资料:
lxc:
https://github.com/clondroid
lxc-android https://github.com/ppoffice/lxc-android
https://github.com/hybris-mobian/lxc-android
区别在Android上运行lxc 和 利用lxc运行Android
anbox:
!!!!!!!!!!!!!!!!
@ittat
ittat / Build Android Go Edition
Created September 29, 2020 00:44
This device does have 2GB RAM (above the recommended <=1GB for Go) however we could probably save some battery and make the device feel much faster by causing it to be a Go target.
+ $(call inherit-product, $(SRC_TARGET_DIR)/product/go_defaults.mk)
@ittat
ittat / gist:0e2a444e285482179ff808d53fe9953f
Last active February 4, 2021 07:32
Porting B2G to your device
# Porting to your device
if your device support AOSP-10,you can try to port B2G using the following method:
1. Fork kernel and device tree form aosp10 sources.
For example, the `aosp10_manifest.xml` file of onyx device. like: [onyx's aosp10_manifest](https://github.com/OnePlus-onyx/android/blob/master/onyx/aosp-10.0/default.xml#L714-L716)
2. Modify device tree
Add apply patches to your deviecs mainly, like: https://github.com/OnePlus-onyx/device_oneplus_onyx/commit/df19ecd958db26ddc301a29c94d108720e8fdd59
@ittat
ittat / 0001_gecko.patch
Last active August 9, 2022 09:07
for daviepeng
From 8c69882de236eddee83520d7d9dc1f636d86a319 Mon Sep 17 00:00:00 2001
From: ittat <ittat@live.com>
Date: Sun, 21 Feb 2021 14:48:51 +0800
Subject: [PATCH] Display work for onyx part1
---
widget/gonk/libdisplay/GonkDisplay.cpp | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/widget/gonk/libdisplay/GonkDisplay.cpp b/widget/gonk/libdisplay/GonkDisplay.cpp