geohot / freethedsp Goto Github PK
View Code? Open in Web Editor NEWFor winners only. Are you a winner?
For winners only. Are you a winner?
Hello.
I try to compile freethedsp.c with './clang -shared freethedsp.c -o freethedsp.so'.
Therefor I use clang with NDK-14 (also tryed 16).
I used "python make_standalone_toolchain.py --arch arm --api 24 --install-dir tmp" for generating the Clang toolchain.
But when trying to compile I get following error:
freethedsp.c:70:5: error: conflicting types for 'ioctl' int ioctl(int fd, unsigned long request, void *arg) { ^ ./../sysroot/usr/include/unistd.h:145:12: note: previous declaration is here extern int ioctl(int, int, ...); ^ freethedsp.c:91:17: warning: implicit declaration of function 'open' is invalid in C99 [-Wimplicit-function-declaration] int ionfd = open("/dev/ion", O_RDONLY); ^ freethedsp.c:91:34: error: use of undeclared identifier 'O_RDONLY' int ionfd = open("/dev/ion", O_RDONLY); ^ 1 warning and 2 errors generated.
Can anybody help me how to fix?
I compiled the .so file successfully. However that doesn't seem work. I think maybe the wrong parameter for patching the fastrpc_shell_0. Would you please tell me how to determine patching parameter? Thanks~~
original code listed:
#define PATCH_ADDR 0x5200c
#define PATCH_OLD "\x40\x3f\x20\x50"
#define PATCH_NEW "\x40\x3f\x00\x5a"
#define PATCH_LEN (sizeof(PATCH_OLD)-1)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.