1 .TH LPLC "1" "2017-02-09" "lplc 0.1" "User Commands" 2 .SH NAME 3 lplc \- Lichen Python-like compiler 4 .SH SYNOPSIS 5 .B lplc 6 .RI [ options ] 7 .I file 8 .br 9 .B lplc 10 .I --help 11 .br 12 .B lplc 13 .I --version 14 .SH DESCRIPTION 15 .B lplc 16 compiles programs written in the Lichen language, taking the indicated 17 .I file 18 representing the principal source file of a program, compiling the program to an 19 intermediate representation, and then building the result using a C compiler and 20 .B make 21 to produce an executable. Other source files need not be specified: they will be 22 identified by the compiler and loaded as required. 23 .SH OPTIONS 24 The following options may be specified: 25 .PP 26 .TP 27 .BR \-c ", " \-\-compile 28 Only partially compile the program; do not build or link it 29 .TP 30 .BR \-E ", " \-\-no\-env 31 Ignore environment variables affecting the module search path 32 .TP 33 .BR \-g ", " \-\-debug 34 Generate debugging information for the built executable 35 .TP 36 .BR \-G ", " \-\-gc\-sections 37 Remove superfluous sections of the built executable by applying the 38 .B \-\-gc\-sections 39 linker option and associated compiler options 40 .TP 41 .BR \-P ", " \-\-show\-path 42 Show the module search path 43 .TP 44 .BR \-q ", " \-\-quiet 45 Silence messages produced when building an executable 46 .TP 47 .BR \-r ", " \-\-reset 48 Reset (discard) cached information; inspect the whole program again 49 .TP 50 .BR \-R ", " \-\-reset\-all 51 Reset (discard) all program details including translated code 52 .TP 53 .BR \-t ", " \-\-no\-timing 54 Silence timing messages 55 .TP 56 .BR \-tb ", " \-\-traceback 57 Provide a traceback for any internal errors (development only) 58 .TP 59 .BR \-v ", " \-\-verbose 60 Report compiler activities in a verbose fashion (development only) 61 .PP 62 Some options may be followed by values, either immediately after the option 63 (without any space between) or in the arguments that follow them: 64 .PP 65 .TP 66 .B \-o 67 Indicate the output executable name 68 .TP 69 .B \-W 70 Show warnings on the topics indicated 71 .PP 72 Currently, the following warnings are supported: 73 .TP 74 .B all 75 Show all possible warnings 76 .TP 77 .B args 78 Show invocations where a callable may be involved that cannot accept 79 the arguments provided 80 .PP 81 The following informational options can be specified to produce output instead 82 of compiling a program: 83 .PP 84 .TP 85 .BR \-h ", " \-? ", " \-\-help 86 Show a summary of the command syntax and options 87 .TP 88 .BR \-V ", " \-\-version 89 Show version information for this tool 90 .SH EXAMPLES 91 Compile the main program in 92 .BR hello.py , 93 including all source files that the program requires: 94 .IP 95 lplc -o hello hello.py 96 .PP 97 This produces an output executable called 98 .B hello 99 in the current directory, assuming that 100 .B hello.py 101 can be compiled without errors. 102 .SH FILES 103 .B lplc 104 produces an output executable file called 105 .B _main 106 unless the 107 .B \-o 108 option is given with a different name. Working data is stored in a directory 109 whose name is derived from the output executable name. Therefore, the working 110 data directory will be called 111 .B _main.lplc 112 unless otherwise specified. For example, an output executable called 113 .B hello 114 will have a working data directory called 115 .BR hello.lplc . 116 This is intended to allow work to proceed efficiently on multiple programs in 117 the same directory, although it can also create lots of unwanted directories. 118 .SH ENVIRONMENT 119 .TP 120 ARCH 121 Indicates a prefix to be used with tool names when building an executable. This 122 permits things like cross-compilation where tools have been provided with names 123 featuring architecture- and system-specific prefixes. For example, 124 .I mipsel-linux-gnu 125 may be used to indicate the use of tools for the MIPS architecture running 126 GNU/Linux in little-endian mode. 127 .TP 128 LICHENPATH 129 A collection of directories that are searched before those in the collection 130 comprising the default "module search path". This collection, if already defined 131 in the environment, may be excluded by specifying the 132 .BR \-E " (or " \-\-no\-env ) 133 option. 134 .SH AUTHOR 135 Paul Boddie <paul@boddie.org.uk> 136 .SH RESOURCES 137 The project Web site: http://projects.boddie.org.uk/Lichen 138 .SH COPYRIGHT 139 Copyright \(co 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 140 2014, 2015, 2016, 2017 Paul Boddie <paul@boddie.org.uk> 141 .PP 142 This program is free software; you may redistribute it under the terms of 143 the GNU General Public License version 3 or (at your option) a later version. 144 This program has absolutely no warranty. 145 .SH SEE ALSO 146 .BR cc (1), 147 .BR make (1).