This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Fully based on https://boxofcables.dev/accelerated-kvm-guests-on-wsl-2/ | |
if [ -z "$1" ] | |
then | |
echo "Must supply your Windows 10 username" | |
exit | |
fi | |
WIN_USERNAME=$1 | |
#package updates and installations |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* LD_PRELOAD를 사용하여 main()을 연결하세요. 왜 안되나요? | |
* 이 코드는 포터블하지 않다. 사용할때 리스크는 자신이 감당해라. | |
* | |
* Compile using 'gcc hax.c -o hax.so -fPIC -shared -ldl' | |
* Then run your program as 'LD_PRELOAD=$PWD/hax.so ./a.out' | |
*/ | |
#define _GNU_SOURCE | |
#include <stdio.h> |