Linux System Call Table in JSON
One-liner to generate a JSON object mapping syscall names to their numbers:
|
|
Optionally, minify the JSON by piping it through tr -d' \n'
:
|
|
A reverse mapping can be made by swapping the columns in the awk expression:
|
|
One-liner to generate a JSON object mapping syscall names to their numbers:
|
|
Optionally, minify the JSON by piping it through tr -d' \n'
:
|
|
A reverse mapping can be made by swapping the columns in the awk expression:
|
|
You can use gcc -M
to print all the dependencies of a C source file. For example:
|
|
To see the resulting file after all those includes, you can cat
them together:
|
|
Then, to print all the preprocessor #define
s, excluding the predefined ones:
|
|