pcc 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. .TH PCC 1
  2. .SH NAME
  3. pcc \- APE C compiler driver
  4. .SH SYNOPSIS
  5. .B pcc
  6. [
  7. .I option ...
  8. ]
  9. [
  10. .I name ...
  11. ]
  12. .SH DESCRIPTION
  13. .I Pcc
  14. compiles and loads C programs,
  15. using APE (ANSI C/POSIX) include files and libraries.
  16. Named files ending with
  17. .B .c
  18. are preprocessed with
  19. .IR cpp (1),
  20. then compiled with one of the compilers described in
  21. .IR 8c (1),
  22. as specified by the environment variable
  23. .BR $objtype .
  24. The object files are then loaded using one of the loaders described in
  25. .IR 8l (1).
  26. The options are:
  27. .TP \w'\fL-D\ \fIname\ 'u
  28. .B "-+
  29. Accept C++
  30. .B //
  31. comments.
  32. .TP
  33. .BI -o " out"
  34. Place loader output in file
  35. .I out
  36. instead of the default
  37. .BR 8.out ,
  38. .BR v.out ,
  39. etc.
  40. .TP
  41. .B -P
  42. Omit the compilation and loading phases;
  43. leave the result of preprocessing
  44. .IB name .c
  45. in
  46. .IB name .i\f1.
  47. .TP
  48. .B -E
  49. Like
  50. .BR -P ,
  51. but send the result to standard output.
  52. .TP
  53. .B -c
  54. Omit the loading phase.
  55. .TP
  56. .B -p
  57. Insert profiling code into the executable output.
  58. .TP
  59. .B -w
  60. Print compiler warning messages.
  61. .TP
  62. .BI -l lib
  63. Include
  64. .BI / $objtype /lib/ape/lib lib .a
  65. as a library during the linking phase.
  66. .TP
  67. .B -B
  68. Don't complain about functions used without
  69. ANSI function prototypes.
  70. .TP
  71. .B -V
  72. Enable
  73. .B void*
  74. conversion warnings, as in
  75. .IR 8c (1).
  76. .TP
  77. .B -v
  78. Echo the preprocessing, compiling, and loading commands
  79. before they are executed.
  80. .TP
  81. .BI -D name=def
  82. .br
  83. .ns
  84. .TP
  85. .BI -D name
  86. Define the
  87. .I name
  88. to the preprocessor,
  89. as if by
  90. .LR #define .
  91. If no definition is given, the name is defined as
  92. .LR 1 .
  93. .TP
  94. .BI -U name
  95. Undefine the
  96. .I name
  97. to the preprocessor,
  98. as if by
  99. .LR #undef .
  100. .TP
  101. .BI -I dir
  102. .L #include
  103. files whose names do not begin with
  104. .L /
  105. are always
  106. sought first in the directory
  107. of the
  108. .I file
  109. argument,
  110. then in directories named in
  111. .B -I
  112. options,
  113. then in
  114. .BR /$objtype/include/ape .
  115. .TP
  116. .B -N
  117. Don't optimize compiled code.
  118. .TP
  119. .B -S
  120. Print an assembly language version of the object code
  121. on standard output.
  122. .TP
  123. .B -a
  124. Instead of compiling, print on standard output acid functions (see
  125. .IR acid (1))
  126. for examining structures declared in the source files.
  127. .TP
  128. .B -aa
  129. Like
  130. .B -a
  131. except that functions for structures declared in included header files
  132. are omitted.
  133. .TP
  134. .B -F
  135. Enable vararg type checking as described in
  136. .IR 8c (1).
  137. This is of limited use without the appropriate
  138. .B #pragma
  139. definitions.
  140. .TP
  141. .B -f
  142. (ARM only) Generate VFP hardware floating point instructions.
  143. .PP
  144. The APE environment contains all of the include
  145. files and library routines specified in the ANSI C standard
  146. (X3.159-1989), as well as those specified in the IEEE Portable
  147. Operating System Interface standard (POSIX, 1003.1-1990, ISO 9945-1).
  148. In order to access the POSIX routines, source programs should
  149. define the preprocessor constant
  150. .BR _POSIX_SOURCE .
  151. .SH FILES
  152. .TF /$objtype/lib/ape/libap.a
  153. .TP
  154. .B /sys/include/ape
  155. directory for machine-independent
  156. .B #include
  157. files.
  158. .TP
  159. .B /$objtype/include/ape
  160. directory for machine-dependent
  161. .B #include
  162. files.
  163. .TP
  164. .B /$objtype/lib/ape/libap.a
  165. ANSI C/POSIX library.
  166. .SH "SEE ALSO"
  167. .IR cpp (1),
  168. .IR 8c (1),
  169. .IR 8a (1),
  170. .IR 8l (1),
  171. .IR mk (1),
  172. .IR nm (1),
  173. .IR acid (1),
  174. .IR db (1),
  175. .IR prof (1)
  176. .br
  177. Howard Trickey,
  178. ``APE \(em The ANSI/POSIX Environment''
  179. .SH SOURCE
  180. .B /sys/src/cmd/pcc.c
  181. .SH BUGS
  182. The locale manipulation functions are minimal.
  183. Signal functions and terminal characteristic
  184. handlers are only minimally implemented.
  185. .IR Link
  186. always fails, because Plan 9 doesn't support multiple links to a file.
  187. The functions related to setting effective user and group ids
  188. cannot be implemented because the concept doesn't exist in Plan 9.