-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
236 additions
and
17 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
TODO | ||
.*.d |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
0.8 - raised version number to be above perlpp | ||
- added -d to generate Makefile dependencies lists | ||
0.1 - rewritten simplified preprocessor | ||
|
||
perlpp | ||
|
||
0.7 - dosomething-if now working also inside {} | ||
- syntax change: in {} act.comments they should be last, not first, but before next,exit,etc. | ||
0.6 - don't include commented out active comments | ||
- added block syntax for .pl.debug code | ||
- added debug line style "dosomething if condition;" | ||
- another duplicate includes bug fix | ||
0.5 - fixed duplicate includes bug | ||
- added debug labels support | ||
0.4 - added #eval directive | ||
- added -x overwrite switch | ||
0.3 - simplified and renamed to perlpp | ||
|
||
perlkit | ||
|
||
0.2 - added make list | ||
- added more advanced perlpp (instead of plpp.pl) | ||
- improved make install | ||
0.1 - the start |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
### NAME | ||
pcpp - simple Perl/Python/C/C++ preprocessor | ||
|
||
### USAGE | ||
pcpp [OPTIONS] file file ... | ||
|
||
### DESCRIPTION | ||
Simple Perl/Python/C/C++ preprocessor for in-comment directives. | ||
* process include directives, | ||
* removes triple-comments. | ||
|
||
### OPTIONS | ||
-h This help. | ||
-v Verbose, -vv for more verbose. | ||
-l Just list files to include, -l1/lp for level1 or paths. | ||
-dd Print a list of dependencies (input file plus included ones). | ||
-d TGT Generate dependencies list for Makefile for the TGT target. | ||
-e DIR Exclude directory from a search, multiple -e possible. | ||
-nt No triple comments removal. | ||
-nw No watermarking of included parts (by #included). | ||
-ni No indentation propagation. | ||
|
||
### INCLUDE DIRECTIVE | ||
Only lines with the "include" directive are recognized. | ||
Whitespace after the hash is optional, quotes optional. | ||
Whitespace before the hash is used to indent the included content. | ||
|
||
Include files can be defined by the filename, by the path, or by | ||
a partial incomplete path. The path resolving procedure is: | ||
|
||
1. look for direct path from CWD, | ||
2. look for relative path from file to which we include, | ||
3. find filename recursively in the depth order from CWD, | ||
4. strip directory part from include and serch by filename. | ||
Double includes are avoided. Missing includes are ignored. | ||
Any text after include files is a comment. | ||
|
||
# include "abc.pl" # Perl, Python | ||
// include "abc.h" // C, C++ | ||
#include abc.pl xyz.pl # multiple files in one include possible | ||
## include abc.pl # not an include due to two hashes | ||
# include abc.pl # indented include of abc.pl | ||
# include "abc.pl" # comment | ||
# include abc.pl xyz.pl comment | ||
|
||
### TRIPLE COMMENTS | ||
Triple comments are removed, together with preceding empty lines. | ||
All other comments are propagated to the output. | ||
|
||
### this line will be removed from the Perl/Python code by pcpp | ||
/// this line will be removed from the C/C++ code by pcpp | ||
#### but this will be kept | ||
|
||
### EXAMPLES | ||
pcpp -v pcpp.pl > pcpp | ||
pcpp -d pcpp pcpp.pl > .pcpp.d | ||
|
||
### VERSION | ||
pcpp-0.5 R.Jaksa 2008,2024 GPLv3 | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
### NAME | ||
uninclude - remove included parts from pcpp generated files | ||
|
||
### USAGE | ||
uninclude [OPTIONS] file | ||
|
||
### DESCRIPTION | ||
Removes all included parts from a pcpp generated file. Depends | ||
on pcpp watermarking. Can return back the #include statements, | ||
but they are flattened to a single level direct includes. | ||
|
||
### OPTIONS | ||
-h This help. | ||
-v Verbose. | ||
-l Just list all includes, indentation by the include level. | ||
-ni Don't return back #include statements. | ||
|
||
### VERSION | ||
pcpp-0.5 R.Jaksa 2008,2024 GPLv3 | ||
|
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.