mathematical 1.5.12 → 1.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (254) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +11 -30
  3. data/Rakefile +1 -0
  4. data/ext/mathematical/CMakeLists.txt +4 -1
  5. data/ext/mathematical/extconf.rb +4 -1
  6. data/ext/mathematical/lasem/NEWS +17 -0
  7. data/ext/mathematical/lasem/autogen.sh +5 -2
  8. data/ext/mathematical/lasem/configure.ac +3 -3
  9. data/ext/mathematical/lasem/po/cs.po +50 -18
  10. data/ext/mathematical/lasem/po/de.po +62 -26
  11. data/ext/mathematical/lasem/po/es.po +27 -18
  12. data/ext/mathematical/lasem/po/hu.po +50 -21
  13. data/ext/mathematical/lasem/po/id.po +49 -16
  14. data/ext/mathematical/lasem/po/lt.po +47 -18
  15. data/ext/mathematical/lasem/po/pl.po +53 -24
  16. data/ext/mathematical/lasem/po/pt_BR.po +70 -29
  17. data/ext/mathematical/lasem/po/sl.po +43 -29
  18. data/ext/mathematical/lasem/po/sr.po +67 -27
  19. data/ext/mathematical/lasem/po/sr@latin.po +67 -27
  20. data/ext/mathematical/lasem/po/sv.po +51 -18
  21. data/ext/mathematical/lasem/src/lasemrender.c +107 -14
  22. data/ext/mathematical/lasem/src/lsmitex.c +1 -0
  23. data/ext/mathematical/lasem/src/lsmsvgelement.c +0 -2
  24. data/ext/mathematical/lasem/src/lsmsvglength.c +2 -2
  25. data/ext/mathematical/lasem/src/lsmsvgmatrix.c +16 -0
  26. data/ext/mathematical/lasem/src/lsmsvgmatrix.h +2 -1
  27. data/ext/mathematical/lasem/src/lsmsvgsvgelement.c +8 -2
  28. data/ext/mathematical/lasem_overrides.c +3 -3
  29. data/ext/mathematical/lib/liblasem.dylib +0 -0
  30. data/ext/mathematical/lib/libmtex2MML.a +0 -0
  31. data/ext/mathematical/mathematical.c +1 -1
  32. data/ext/mathematical/mtex2MML/CMakeLists.txt +5 -0
  33. data/ext/mathematical/mtex2MML/README.md +3 -3
  34. data/ext/mathematical/mtex2MML/SUPPORTED.md +2 -0
  35. data/ext/mathematical/mtex2MML/appveyor.yml +15 -5
  36. data/ext/mathematical/mtex2MML/build/CMakeCache.txt +181 -116
  37. data/ext/mathematical/mtex2MML/build/CMakeFiles/3.6.1/CMakeCCompiler.cmake +67 -0
  38. data/ext/mathematical/mtex2MML/build/CMakeFiles/3.6.1/CMakeCXXCompiler.cmake +68 -0
  39. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1 → 3.6.1}/CMakeDetermineCompilerABI_C.bin +0 -0
  40. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1 → 3.6.1}/CMakeDetermineCompilerABI_CXX.bin +0 -0
  41. data/ext/mathematical/mtex2MML/build/CMakeFiles/3.6.1/CMakeSystem.cmake +15 -0
  42. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1 → 3.6.1}/CompilerIdC/CMakeCCompilerId.c +223 -55
  43. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1/CompilerIdCXX → 3.6.1/CompilerIdC}/a.out +0 -0
  44. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1 → 3.6.1}/CompilerIdCXX/CMakeCXXCompilerId.cpp +202 -44
  45. data/ext/mathematical/mtex2MML/build/CMakeFiles/{2.8.10.1/CompilerIdC → 3.6.1/CompilerIdCXX}/a.out +0 -0
  46. data/ext/mathematical/mtex2MML/build/CMakeFiles/CMakeDirectoryInformation.cmake +8 -8
  47. data/ext/mathematical/mtex2MML/build/CMakeFiles/CMakeOutput.log +405 -109
  48. data/ext/mathematical/mtex2MML/build/CMakeFiles/CMakeRuleHashes.txt +29 -29
  49. data/ext/mathematical/mtex2MML/build/CMakeFiles/Continuous.dir/DependInfo.cmake +4 -20
  50. data/ext/mathematical/mtex2MML/build/CMakeFiles/Continuous.dir/build.make +14 -7
  51. data/ext/mathematical/mtex2MML/build/CMakeFiles/Continuous.dir/cmake_clean.cmake +4 -4
  52. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousBuild.dir/DependInfo.cmake +4 -20
  53. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousBuild.dir/build.make +14 -7
  54. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousBuild.dir/cmake_clean.cmake +4 -4
  55. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousConfigure.dir/DependInfo.cmake +4 -20
  56. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousConfigure.dir/build.make +14 -7
  57. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousConfigure.dir/cmake_clean.cmake +4 -4
  58. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousCoverage.dir/DependInfo.cmake +4 -20
  59. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousCoverage.dir/build.make +14 -7
  60. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousCoverage.dir/cmake_clean.cmake +4 -4
  61. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousMemCheck.dir/DependInfo.cmake +4 -20
  62. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousMemCheck.dir/build.make +14 -7
  63. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousMemCheck.dir/cmake_clean.cmake +4 -4
  64. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousStart.dir/DependInfo.cmake +4 -20
  65. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousStart.dir/build.make +14 -7
  66. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousStart.dir/cmake_clean.cmake +4 -4
  67. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousSubmit.dir/DependInfo.cmake +4 -20
  68. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousSubmit.dir/build.make +14 -7
  69. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousSubmit.dir/cmake_clean.cmake +4 -4
  70. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousTest.dir/DependInfo.cmake +4 -20
  71. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousTest.dir/build.make +14 -7
  72. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousTest.dir/cmake_clean.cmake +4 -4
  73. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousUpdate.dir/DependInfo.cmake +4 -20
  74. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousUpdate.dir/build.make +14 -7
  75. data/ext/mathematical/mtex2MML/build/CMakeFiles/ContinuousUpdate.dir/cmake_clean.cmake +4 -4
  76. data/ext/mathematical/mtex2MML/build/CMakeFiles/Experimental.dir/DependInfo.cmake +4 -20
  77. data/ext/mathematical/mtex2MML/build/CMakeFiles/Experimental.dir/build.make +14 -7
  78. data/ext/mathematical/mtex2MML/build/CMakeFiles/Experimental.dir/cmake_clean.cmake +4 -4
  79. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalBuild.dir/DependInfo.cmake +4 -20
  80. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalBuild.dir/build.make +14 -7
  81. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalBuild.dir/cmake_clean.cmake +4 -4
  82. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalConfigure.dir/DependInfo.cmake +4 -20
  83. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalConfigure.dir/build.make +14 -7
  84. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalConfigure.dir/cmake_clean.cmake +4 -4
  85. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalCoverage.dir/DependInfo.cmake +4 -20
  86. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalCoverage.dir/build.make +14 -7
  87. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalCoverage.dir/cmake_clean.cmake +4 -4
  88. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalMemCheck.dir/DependInfo.cmake +4 -20
  89. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalMemCheck.dir/build.make +14 -7
  90. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalMemCheck.dir/cmake_clean.cmake +4 -4
  91. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalStart.dir/DependInfo.cmake +4 -20
  92. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalStart.dir/build.make +14 -7
  93. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalStart.dir/cmake_clean.cmake +4 -4
  94. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalSubmit.dir/DependInfo.cmake +4 -20
  95. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalSubmit.dir/build.make +14 -7
  96. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalSubmit.dir/cmake_clean.cmake +4 -4
  97. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalTest.dir/DependInfo.cmake +4 -20
  98. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalTest.dir/build.make +14 -7
  99. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalTest.dir/cmake_clean.cmake +4 -4
  100. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalUpdate.dir/DependInfo.cmake +4 -20
  101. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalUpdate.dir/build.make +14 -7
  102. data/ext/mathematical/mtex2MML/build/CMakeFiles/ExperimentalUpdate.dir/cmake_clean.cmake +4 -4
  103. data/ext/mathematical/mtex2MML/build/CMakeFiles/Makefile.cmake +68 -60
  104. data/ext/mathematical/mtex2MML/build/CMakeFiles/Makefile2 +564 -522
  105. data/ext/mathematical/mtex2MML/build/CMakeFiles/Nightly.dir/DependInfo.cmake +4 -20
  106. data/ext/mathematical/mtex2MML/build/CMakeFiles/Nightly.dir/build.make +14 -7
  107. data/ext/mathematical/mtex2MML/build/CMakeFiles/Nightly.dir/cmake_clean.cmake +4 -4
  108. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyBuild.dir/DependInfo.cmake +4 -20
  109. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyBuild.dir/build.make +14 -7
  110. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyBuild.dir/cmake_clean.cmake +4 -4
  111. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyConfigure.dir/DependInfo.cmake +4 -20
  112. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyConfigure.dir/build.make +14 -7
  113. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyConfigure.dir/cmake_clean.cmake +4 -4
  114. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyCoverage.dir/DependInfo.cmake +4 -20
  115. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyCoverage.dir/build.make +14 -7
  116. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyCoverage.dir/cmake_clean.cmake +4 -4
  117. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemCheck.dir/DependInfo.cmake +4 -20
  118. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemCheck.dir/build.make +14 -7
  119. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemCheck.dir/cmake_clean.cmake +4 -4
  120. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemoryCheck.dir/DependInfo.cmake +4 -20
  121. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemoryCheck.dir/build.make +14 -7
  122. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyMemoryCheck.dir/cmake_clean.cmake +4 -4
  123. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyStart.dir/DependInfo.cmake +4 -20
  124. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyStart.dir/build.make +14 -7
  125. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyStart.dir/cmake_clean.cmake +4 -4
  126. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlySubmit.dir/DependInfo.cmake +4 -20
  127. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlySubmit.dir/build.make +14 -7
  128. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlySubmit.dir/cmake_clean.cmake +4 -4
  129. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyTest.dir/DependInfo.cmake +4 -20
  130. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyTest.dir/build.make +14 -7
  131. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyTest.dir/cmake_clean.cmake +4 -4
  132. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyUpdate.dir/DependInfo.cmake +4 -20
  133. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyUpdate.dir/build.make +14 -7
  134. data/ext/mathematical/mtex2MML/build/CMakeFiles/NightlyUpdate.dir/cmake_clean.cmake +4 -4
  135. data/ext/mathematical/mtex2MML/build/CMakeFiles/TargetDirectories.txt +28 -21
  136. data/ext/mathematical/mtex2MML/build/CMakeFiles/feature_tests.bin +0 -0
  137. data/ext/mathematical/mtex2MML/build/CMakeFiles/feature_tests.c +34 -0
  138. data/ext/mathematical/mtex2MML/build/CMakeFiles/feature_tests.cxx +405 -0
  139. data/ext/mathematical/mtex2MML/build/CMakeFiles/format.dir/DependInfo.cmake +4 -20
  140. data/ext/mathematical/mtex2MML/build/CMakeFiles/format.dir/build.make +13 -6
  141. data/ext/mathematical/mtex2MML/build/CMakeFiles/format.dir/cmake_clean.cmake +4 -4
  142. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/DependInfo.cmake +16 -18
  143. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/build.make +55 -42
  144. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/cmake_clean.cmake +4 -4
  145. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/flags.make +5 -3
  146. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/link.txt +1 -1
  147. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML.dir/progress.make +1 -0
  148. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/C.includecache +115 -27
  149. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/DependInfo.cmake +16 -18
  150. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/build.make +54 -42
  151. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/cmake_clean.cmake +4 -4
  152. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/cmake_clean_target.cmake +1 -1
  153. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/depend.internal +19 -20
  154. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/depend.make +18 -19
  155. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/flags.make +5 -3
  156. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/link.txt +2 -2
  157. data/ext/mathematical/mtex2MML/build/CMakeFiles/libmtex2MML_static.dir/progress.make +9 -8
  158. data/ext/mathematical/mtex2MML/build/CMakeFiles/memcheck.dir/DependInfo.cmake +4 -20
  159. data/ext/mathematical/mtex2MML/build/CMakeFiles/memcheck.dir/build.make +13 -6
  160. data/ext/mathematical/mtex2MML/build/CMakeFiles/memcheck.dir/cmake_clean.cmake +4 -4
  161. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/DependInfo.cmake +16 -18
  162. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/build.make +60 -47
  163. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/cmake_clean.cmake +4 -4
  164. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/flags.make +5 -3
  165. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/link.txt +1 -1
  166. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML.dir/progress.make +10 -9
  167. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/DependInfo.cmake +17 -18
  168. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/build.make +178 -124
  169. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/cmake_clean.cmake +5 -4
  170. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/flags.make +5 -3
  171. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/link.txt +1 -1
  172. data/ext/mathematical/mtex2MML/build/CMakeFiles/mtex2MML_clar.dir/progress.make +27 -25
  173. data/ext/mathematical/mtex2MML/build/CMakeFiles/progress.marks +1 -1
  174. data/ext/mathematical/mtex2MML/build/CTestTestfile.cmake +2 -2
  175. data/ext/mathematical/mtex2MML/build/DartConfiguration.tcl +25 -7
  176. data/ext/mathematical/mtex2MML/build/Makefile +419 -307
  177. data/ext/mathematical/mtex2MML/build/cmake_install.cmake +32 -32
  178. data/ext/mathematical/mtex2MML/build/lexer.c +4317 -4379
  179. data/ext/mathematical/mtex2MML/build/libmtex2MML.a +0 -0
  180. data/ext/mathematical/mtex2MML/build/mtex2mml_export.h +12 -5
  181. data/ext/mathematical/mtex2MML/build/parser.c +5549 -5473
  182. data/ext/mathematical/mtex2MML/build/parser.h +499 -490
  183. data/ext/mathematical/mtex2MML/build/parser.output +93361 -92735
  184. data/ext/mathematical/mtex2MML/deps/strdup/package.json +2 -2
  185. data/ext/mathematical/mtex2MML/deps/strdup/strdup.c +2 -0
  186. data/ext/mathematical/mtex2MML/deps/strdup/strdup.h +2 -0
  187. data/ext/mathematical/mtex2MML/deps/uthash/package.json +2 -1
  188. data/ext/mathematical/mtex2MML/deps/uthash/utarray.h +42 -36
  189. data/ext/mathematical/mtex2MML/deps/uthash/uthash.h +334 -218
  190. data/ext/mathematical/mtex2MML/deps/uthash/utlist.h +282 -144
  191. data/ext/mathematical/mtex2MML/deps/uthash/utringbuffer.h +108 -0
  192. data/ext/mathematical/mtex2MML/deps/uthash/utstring.h +15 -10
  193. data/ext/mathematical/mtex2MML/script/bootstrap +6 -12
  194. data/ext/mathematical/mtex2MML/script/cibuild +47 -1
  195. data/ext/mathematical/mtex2MML/script/{release → tag} +1 -1
  196. data/ext/mathematical/mtex2MML/src/environment.c +73 -13
  197. data/ext/mathematical/mtex2MML/src/environment.h +1 -1
  198. data/ext/mathematical/mtex2MML/src/lexer.l +75 -53
  199. data/ext/mathematical/mtex2MML/src/main.c +65 -36
  200. data/ext/mathematical/mtex2MML/src/mtex2MML.h +5 -1
  201. data/ext/mathematical/mtex2MML/src/parser.y +67 -16
  202. data/ext/mathematical/mtex2MML/tests/basic.c +10 -0
  203. data/ext/mathematical/mtex2MML/tests/delimiters.c +95 -0
  204. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/layout/strut-1.html +1 -1
  205. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/cal-1.html +1 -1
  206. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/frak-1.html +1 -1
  207. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/mathcal-1.html +1 -1
  208. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/mathfrak-1.html +1 -1
  209. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/mathrm-1.html +1 -1
  210. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/mathscr-1.html +1 -1
  211. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/rm-1.html +1 -1
  212. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/scr-1.html +1 -1
  213. data/ext/mathematical/mtex2MML/tests/fixtures/MathJax/LaTeXToMathML-out/mathvariant/textrm-1.html +1 -1
  214. data/ext/mathematical/mtex2MML/tests/fixtures/array/strip_excess_whitespace_in_array_attributes.html +1 -1
  215. data/ext/mathematical/mtex2MML/tests/fixtures/basic/text_rendering.html +23 -0
  216. data/ext/mathematical/mtex2MML/tests/fixtures/basic/text_rendering.txt +23 -0
  217. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/align.html +1 -0
  218. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/align.txt +3 -0
  219. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/alignat-1a.html +1 -0
  220. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/alignat-1a.txt +4 -0
  221. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/aligned_ex_spacing.html +1 -0
  222. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/aligned_ex_spacing.txt +4 -0
  223. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/basic_array.html +1 -0
  224. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/basic_array.txt +3 -0
  225. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/mixed_env.html +8 -0
  226. data/ext/mathematical/mtex2MML/tests/fixtures/delimiters/mixed_env.txt +11 -0
  227. data/ext/mathematical/mtex2MML/tests/fixtures/performance/big_file.html +6 -6
  228. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/gt.html +1 -0
  229. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/gt.txt +1 -0
  230. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/lt.html +1 -0
  231. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/lt.txt +1 -0
  232. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/textgreater.html +1 -0
  233. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/textgreater.txt +1 -0
  234. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/textless.html +1 -0
  235. data/ext/mathematical/mtex2MML/tests/fixtures/symbols/textless.txt +1 -0
  236. data/ext/mathematical/mtex2MML/tests/symbols.c +69 -0
  237. data/lib/mathematical.rb +19 -1
  238. data/lib/mathematical/version.rb +1 -1
  239. data/mathematical.gemspec +2 -1
  240. data/test/mathematical/basic_test.rb +16 -3
  241. data/test/mathematical/fixtures/png/numeric_test_1.png +0 -0
  242. data/test/mathematical/fixtures/png/numeric_test_3.png +0 -0
  243. data/test/mathematical/fixtures/png/pmatrix.png +0 -0
  244. data/test/mathematical/maliciousness_test.rb +0 -1
  245. data/test/mathematical/multiples_test.rb +3 -0
  246. data/test/mathematical/png_test.rb +4 -1
  247. data/test/test_helper.rb +2 -0
  248. metadata +54 -18
  249. data/ext/mathematical/FindNewerRubies.cmake +0 -292
  250. data/ext/mathematical/mtex2MML/build.ps1 +0 -2
  251. data/ext/mathematical/mtex2MML/build/CMakeFiles/2.8.10.1/CMakeCCompiler.cmake +0 -55
  252. data/ext/mathematical/mtex2MML/build/CMakeFiles/2.8.10.1/CMakeCXXCompiler.cmake +0 -56
  253. data/ext/mathematical/mtex2MML/build/CMakeFiles/2.8.10.1/CMakeSystem.cmake +0 -15
  254. data/ext/mathematical/mtex2MML/src/y.output +0 -117655
@@ -0,0 +1,67 @@
1
+ set(CMAKE_C_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc")
2
+ set(CMAKE_C_COMPILER_ARG1 "")
3
+ set(CMAKE_C_COMPILER_ID "AppleClang")
4
+ set(CMAKE_C_COMPILER_VERSION "7.3.0.7030029")
5
+ set(CMAKE_C_COMPILER_WRAPPER "")
6
+ set(CMAKE_C_STANDARD_COMPUTED_DEFAULT "11")
7
+ set(CMAKE_C_COMPILE_FEATURES "c_function_prototypes;c_restrict;c_variadic_macros;c_static_assert")
8
+ set(CMAKE_C90_COMPILE_FEATURES "c_function_prototypes")
9
+ set(CMAKE_C99_COMPILE_FEATURES "c_restrict;c_variadic_macros")
10
+ set(CMAKE_C11_COMPILE_FEATURES "c_static_assert")
11
+
12
+ set(CMAKE_C_PLATFORM_ID "Darwin")
13
+ set(CMAKE_C_SIMULATE_ID "")
14
+ set(CMAKE_C_SIMULATE_VERSION "")
15
+
16
+ set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17
+ set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18
+ set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19
+ set(CMAKE_COMPILER_IS_GNUCC )
20
+ set(CMAKE_C_COMPILER_LOADED 1)
21
+ set(CMAKE_C_COMPILER_WORKS TRUE)
22
+ set(CMAKE_C_ABI_COMPILED TRUE)
23
+ set(CMAKE_COMPILER_IS_MINGW )
24
+ set(CMAKE_COMPILER_IS_CYGWIN )
25
+ if(CMAKE_COMPILER_IS_CYGWIN)
26
+ set(CYGWIN 1)
27
+ set(UNIX 1)
28
+ endif()
29
+
30
+ set(CMAKE_C_COMPILER_ENV_VAR "CC")
31
+
32
+ if(CMAKE_COMPILER_IS_MINGW)
33
+ set(MINGW 1)
34
+ endif()
35
+ set(CMAKE_C_COMPILER_ID_RUN 1)
36
+ set(CMAKE_C_SOURCE_FILE_EXTENSIONS c;m)
37
+ set(CMAKE_C_IGNORE_EXTENSIONS h;H;o;O;obj;OBJ;def;DEF;rc;RC)
38
+ set(CMAKE_C_LINKER_PREFERENCE 10)
39
+
40
+ # Save compiler ABI information.
41
+ set(CMAKE_C_SIZEOF_DATA_PTR "8")
42
+ set(CMAKE_C_COMPILER_ABI "")
43
+ set(CMAKE_C_LIBRARY_ARCHITECTURE "")
44
+
45
+ if(CMAKE_C_SIZEOF_DATA_PTR)
46
+ set(CMAKE_SIZEOF_VOID_P "${CMAKE_C_SIZEOF_DATA_PTR}")
47
+ endif()
48
+
49
+ if(CMAKE_C_COMPILER_ABI)
50
+ set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_C_COMPILER_ABI}")
51
+ endif()
52
+
53
+ if(CMAKE_C_LIBRARY_ARCHITECTURE)
54
+ set(CMAKE_LIBRARY_ARCHITECTURE "")
55
+ endif()
56
+
57
+ set(CMAKE_C_CL_SHOWINCLUDES_PREFIX "")
58
+ if(CMAKE_C_CL_SHOWINCLUDES_PREFIX)
59
+ set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_C_CL_SHOWINCLUDES_PREFIX}")
60
+ endif()
61
+
62
+
63
+
64
+
65
+ set(CMAKE_C_IMPLICIT_LINK_LIBRARIES "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/7.3.0/lib/darwin/libclang_rt.osx.a")
66
+ set(CMAKE_C_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
67
+ set(CMAKE_C_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
@@ -0,0 +1,68 @@
1
+ set(CMAKE_CXX_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++")
2
+ set(CMAKE_CXX_COMPILER_ARG1 "")
3
+ set(CMAKE_CXX_COMPILER_ID "AppleClang")
4
+ set(CMAKE_CXX_COMPILER_VERSION "7.3.0.7030029")
5
+ set(CMAKE_CXX_COMPILER_WRAPPER "")
6
+ set(CMAKE_CXX_STANDARD_COMPUTED_DEFAULT "98")
7
+ set(CMAKE_CXX_COMPILE_FEATURES "cxx_template_template_parameters;cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates;cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
8
+ set(CMAKE_CXX98_COMPILE_FEATURES "cxx_template_template_parameters")
9
+ set(CMAKE_CXX11_COMPILE_FEATURES "cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates")
10
+ set(CMAKE_CXX14_COMPILE_FEATURES "cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
11
+
12
+ set(CMAKE_CXX_PLATFORM_ID "Darwin")
13
+ set(CMAKE_CXX_SIMULATE_ID "")
14
+ set(CMAKE_CXX_SIMULATE_VERSION "")
15
+
16
+ set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17
+ set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18
+ set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19
+ set(CMAKE_COMPILER_IS_GNUCXX )
20
+ set(CMAKE_CXX_COMPILER_LOADED 1)
21
+ set(CMAKE_CXX_COMPILER_WORKS TRUE)
22
+ set(CMAKE_CXX_ABI_COMPILED TRUE)
23
+ set(CMAKE_COMPILER_IS_MINGW )
24
+ set(CMAKE_COMPILER_IS_CYGWIN )
25
+ if(CMAKE_COMPILER_IS_CYGWIN)
26
+ set(CYGWIN 1)
27
+ set(UNIX 1)
28
+ endif()
29
+
30
+ set(CMAKE_CXX_COMPILER_ENV_VAR "CXX")
31
+
32
+ if(CMAKE_COMPILER_IS_MINGW)
33
+ set(MINGW 1)
34
+ endif()
35
+ set(CMAKE_CXX_COMPILER_ID_RUN 1)
36
+ set(CMAKE_CXX_IGNORE_EXTENSIONS inl;h;hpp;HPP;H;o;O;obj;OBJ;def;DEF;rc;RC)
37
+ set(CMAKE_CXX_SOURCE_FILE_EXTENSIONS C;M;c++;cc;cpp;cxx;mm;CPP)
38
+ set(CMAKE_CXX_LINKER_PREFERENCE 30)
39
+ set(CMAKE_CXX_LINKER_PREFERENCE_PROPAGATES 1)
40
+
41
+ # Save compiler ABI information.
42
+ set(CMAKE_CXX_SIZEOF_DATA_PTR "8")
43
+ set(CMAKE_CXX_COMPILER_ABI "")
44
+ set(CMAKE_CXX_LIBRARY_ARCHITECTURE "")
45
+
46
+ if(CMAKE_CXX_SIZEOF_DATA_PTR)
47
+ set(CMAKE_SIZEOF_VOID_P "${CMAKE_CXX_SIZEOF_DATA_PTR}")
48
+ endif()
49
+
50
+ if(CMAKE_CXX_COMPILER_ABI)
51
+ set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_CXX_COMPILER_ABI}")
52
+ endif()
53
+
54
+ if(CMAKE_CXX_LIBRARY_ARCHITECTURE)
55
+ set(CMAKE_LIBRARY_ARCHITECTURE "")
56
+ endif()
57
+
58
+ set(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX "")
59
+ if(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX)
60
+ set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_CXX_CL_SHOWINCLUDES_PREFIX}")
61
+ endif()
62
+
63
+
64
+
65
+
66
+ set(CMAKE_CXX_IMPLICIT_LINK_LIBRARIES "c++;/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/7.3.0/lib/darwin/libclang_rt.osx.a")
67
+ set(CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
68
+ set(CMAKE_CXX_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
@@ -0,0 +1,15 @@
1
+ set(CMAKE_HOST_SYSTEM "Darwin-15.6.0")
2
+ set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3
+ set(CMAKE_HOST_SYSTEM_VERSION "15.6.0")
4
+ set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5
+
6
+
7
+
8
+ set(CMAKE_SYSTEM "Darwin-15.6.0")
9
+ set(CMAKE_SYSTEM_NAME "Darwin")
10
+ set(CMAKE_SYSTEM_VERSION "15.6.0")
11
+ set(CMAKE_SYSTEM_PROCESSOR "x86_64")
12
+
13
+ set(CMAKE_CROSSCOMPILING "FALSE")
14
+
15
+ set(CMAKE_SYSTEM_LOADED 1)
@@ -2,23 +2,41 @@
2
2
  # error "A C++ compiler has been selected for C."
3
3
  #endif
4
4
 
5
- /* Version number components: V=Version, R=Revision, P=Patch
6
- Version date components: YYYY=Year, MM=Month, DD=Day */
7
-
8
5
  #if defined(__18CXX)
9
6
  # define ID_VOID_MAIN
10
7
  #endif
8
+ #if defined(__CLASSIC_C__)
9
+ /* cv-qualifiers did not exist in K&R C */
10
+ # define const
11
+ # define volatile
12
+ #endif
13
+
14
+
15
+ /* Version number components: V=Version, R=Revision, P=Patch
16
+ Version date components: YYYY=Year, MM=Month, DD=Day */
11
17
 
12
18
  #if defined(__INTEL_COMPILER) || defined(__ICC)
13
19
  # define COMPILER_ID "Intel"
20
+ # if defined(_MSC_VER)
21
+ # define SIMULATE_ID "MSVC"
22
+ # endif
14
23
  /* __INTEL_COMPILER = VRP */
15
24
  # define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
16
25
  # define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
17
- # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
26
+ # if defined(__INTEL_COMPILER_UPDATE)
27
+ # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
28
+ # else
29
+ # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
30
+ # endif
18
31
  # if defined(__INTEL_COMPILER_BUILD_DATE)
19
32
  /* __INTEL_COMPILER_BUILD_DATE = YYYYMMDD */
20
33
  # define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
21
34
  # endif
35
+ # if defined(_MSC_VER)
36
+ /* _MSC_VER = VVRR */
37
+ # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
38
+ # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
39
+ # endif
22
40
 
23
41
  #elif defined(__PATHCC__)
24
42
  # define COMPILER_ID "PathScale"
@@ -28,17 +46,11 @@
28
46
  # define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
29
47
  # endif
30
48
 
31
- #elif defined(__clang__)
32
- # define COMPILER_ID "Clang"
33
- # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
34
- # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
35
- # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
36
-
37
49
  #elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
38
50
  # define COMPILER_ID "Embarcadero"
39
51
  # define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
40
52
  # define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
41
- # define COMPILER_VERSION_PATCH HEX(__CODEGEARC_VERSION__ & 0xFFFF)
53
+ # define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
42
54
 
43
55
  #elif defined(__BORLANDC__)
44
56
  # define COMPILER_ID "Borland"
@@ -46,11 +58,23 @@
46
58
  # define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
47
59
  # define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
48
60
 
49
- #elif defined(__WATCOMC__)
61
+ #elif defined(__WATCOMC__) && __WATCOMC__ < 1200
50
62
  # define COMPILER_ID "Watcom"
51
- /* __WATCOMC__ = VVRR */
63
+ /* __WATCOMC__ = VVRR */
52
64
  # define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
53
- # define COMPILER_VERSION_MINOR DEC(__WATCOMC__ % 100)
65
+ # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
66
+ # if (__WATCOMC__ % 10) > 0
67
+ # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
68
+ # endif
69
+
70
+ #elif defined(__WATCOMC__)
71
+ # define COMPILER_ID "OpenWatcom"
72
+ /* __WATCOMC__ = VVRP + 1100 */
73
+ # define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
74
+ # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
75
+ # if (__WATCOMC__ % 10) > 0
76
+ # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
77
+ # endif
54
78
 
55
79
  #elif defined(__SUNPRO_C)
56
80
  # define COMPILER_ID "SunPro"
@@ -60,7 +84,7 @@
60
84
  # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xFF)
61
85
  # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
62
86
  # else
63
- /* __SUNPRO_C = 0xVRP */
87
+ /* __SUNPRO_CC = 0xVRP */
64
88
  # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>8)
65
89
  # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xF)
66
90
  # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
@@ -80,20 +104,26 @@
80
104
  # define COMPILER_VERSION_MINOR DEC(__DECC_VER/100000 % 100)
81
105
  # define COMPILER_VERSION_PATCH DEC(__DECC_VER % 10000)
82
106
 
83
- #elif defined(__IBMC__)
84
- # if defined(__COMPILER_VER__)
85
- # define COMPILER_ID "zOS"
86
- # else
87
- # if __IBMC__ >= 800
88
- # define COMPILER_ID "XL"
89
- # else
90
- # define COMPILER_ID "VisualAge"
91
- # endif
92
- /* __IBMC__ = VRP */
93
- # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
94
- # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
95
- # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
96
- # endif
107
+ #elif defined(__IBMC__) && defined(__COMPILER_VER__)
108
+ # define COMPILER_ID "zOS"
109
+ /* __IBMC__ = VRP */
110
+ # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
111
+ # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
112
+ # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
113
+
114
+ #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ >= 800
115
+ # define COMPILER_ID "XL"
116
+ /* __IBMC__ = VRP */
117
+ # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
118
+ # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
119
+ # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
120
+
121
+ #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ < 800
122
+ # define COMPILER_ID "VisualAge"
123
+ /* __IBMC__ = VRP */
124
+ # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
125
+ # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
126
+ # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
97
127
 
98
128
  #elif defined(__PGI)
99
129
  # define COMPILER_ID "PGI"
@@ -105,26 +135,63 @@
105
135
 
106
136
  #elif defined(_CRAYC)
107
137
  # define COMPILER_ID "Cray"
108
- # define COMPILER_VERSION_MAJOR DEC(_RELEASE)
138
+ # define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
109
139
  # define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
110
140
 
111
141
  #elif defined(__TI_COMPILER_VERSION__)
112
- # define COMPILER_ID "TI_DSP"
142
+ # define COMPILER_ID "TI"
113
143
  /* __TI_COMPILER_VERSION__ = VVVRRRPPP */
114
144
  # define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
115
145
  # define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
116
146
  # define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
117
147
 
148
+ #elif defined(__FUJITSU) || defined(__FCC_VERSION) || defined(__fcc_version)
149
+ # define COMPILER_ID "Fujitsu"
150
+
118
151
  #elif defined(__TINYC__)
119
152
  # define COMPILER_ID "TinyCC"
120
153
 
154
+ #elif defined(__BCC__)
155
+ # define COMPILER_ID "Bruce"
156
+
121
157
  #elif defined(__SCO_VERSION__)
122
158
  # define COMPILER_ID "SCO"
123
159
 
160
+ #elif defined(__clang__) && defined(__apple_build_version__)
161
+ # define COMPILER_ID "AppleClang"
162
+ # if defined(_MSC_VER)
163
+ # define SIMULATE_ID "MSVC"
164
+ # endif
165
+ # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
166
+ # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
167
+ # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
168
+ # if defined(_MSC_VER)
169
+ /* _MSC_VER = VVRR */
170
+ # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
171
+ # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
172
+ # endif
173
+ # define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
174
+
175
+ #elif defined(__clang__)
176
+ # define COMPILER_ID "Clang"
177
+ # if defined(_MSC_VER)
178
+ # define SIMULATE_ID "MSVC"
179
+ # endif
180
+ # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
181
+ # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
182
+ # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
183
+ # if defined(_MSC_VER)
184
+ /* _MSC_VER = VVRR */
185
+ # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
186
+ # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
187
+ # endif
188
+
124
189
  #elif defined(__GNUC__)
125
190
  # define COMPILER_ID "GNU"
126
191
  # define COMPILER_VERSION_MAJOR DEC(__GNUC__)
127
- # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
192
+ # if defined(__GNUC_MINOR__)
193
+ # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
194
+ # endif
128
195
  # if defined(__GNUC_PATCHLEVEL__)
129
196
  # define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
130
197
  # endif
@@ -147,26 +214,33 @@
147
214
  # define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
148
215
  # endif
149
216
 
150
- /* Analog VisualDSP++ >= 4.5.6 */
151
- #elif defined(__VISUALDSPVERSION__)
217
+ #elif defined(__VISUALDSPVERSION__) || defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
152
218
  # define COMPILER_ID "ADSP"
219
+ #if defined(__VISUALDSPVERSION__)
153
220
  /* __VISUALDSPVERSION__ = 0xVVRRPP00 */
154
221
  # define COMPILER_VERSION_MAJOR HEX(__VISUALDSPVERSION__>>24)
155
222
  # define COMPILER_VERSION_MINOR HEX(__VISUALDSPVERSION__>>16 & 0xFF)
156
223
  # define COMPILER_VERSION_PATCH HEX(__VISUALDSPVERSION__>>8 & 0xFF)
224
+ #endif
157
225
 
158
- /* Analog VisualDSP++ < 4.5.6 */
159
- #elif defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
160
- # define COMPILER_ID "ADSP"
226
+ #elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC)
227
+ # define COMPILER_ID "IAR"
228
+
229
+ #elif defined(__ARMCC_VERSION)
230
+ # define COMPILER_ID "ARMCC"
231
+ #if __ARMCC_VERSION >= 1000000
232
+ /* __ARMCC_VERSION = VRRPPPP */
233
+ # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
234
+ # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
235
+ # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
236
+ #else
237
+ /* __ARMCC_VERSION = VRPPPP */
238
+ # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
239
+ # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
240
+ # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
241
+ #endif
161
242
 
162
- /* IAR Systems compiler for embedded systems.
163
- http://www.iar.com
164
- Not supported yet by CMake
165
- #elif defined(__IAR_SYSTEMS_ICC__)
166
- # define COMPILER_ID "IAR" */
167
243
 
168
- /* sdcc, the small devices C compiler for embedded systems,
169
- http://sdcc.sourceforge.net */
170
244
  #elif defined(SDCC)
171
245
  # define COMPILER_ID "SDCC"
172
246
  /* SDCC = VRP */
@@ -188,9 +262,10 @@
188
262
  # define COMPILER_VERSION_PATCH DEC(_COMPILER_VERSION % 10)
189
263
  # endif
190
264
 
191
- /* This compiler is either not known or is too old to define an
192
- identification macro. Try to identify the platform and guess that
193
- it is the native compiler. */
265
+
266
+ /* These compilers are either not known or too old to define an
267
+ identification macro. Try to identify the platform and guess that
268
+ it is the native compiler. */
194
269
  #elif defined(__sgi)
195
270
  # define COMPILER_ID "MIPSpro"
196
271
 
@@ -199,7 +274,6 @@
199
274
 
200
275
  #else /* unknown compiler */
201
276
  # define COMPILER_ID ""
202
-
203
277
  #endif
204
278
 
205
279
  /* Construct the string literal in pieces to prevent the source from
@@ -207,6 +281,20 @@
207
281
  because some compilers will just produce instructions to fill the
208
282
  array rather than assigning a pointer to a static array. */
209
283
  char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
284
+ #ifdef SIMULATE_ID
285
+ char const* info_simulate = "INFO" ":" "simulate[" SIMULATE_ID "]";
286
+ #endif
287
+
288
+ #ifdef __QNXNTO__
289
+ char const* qnxnto = "INFO" ":" "qnxnto[]";
290
+ #endif
291
+
292
+ #if defined(__CRAYXE) || defined(__CRAYXC)
293
+ char const *info_cray = "INFO" ":" "compiler_wrapper[CrayPrgEnv]";
294
+ #endif
295
+
296
+ #define STRINGIFY_HELPER(X) #X
297
+ #define STRINGIFY(X) STRINGIFY_HELPER(X)
210
298
 
211
299
  /* Identify known platforms by name. */
212
300
  #if defined(__linux) || defined(__linux__) || defined(linux)
@@ -245,11 +333,8 @@ char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
245
333
  #elif defined(__hpux) || defined(__hpux__)
246
334
  # define PLATFORM_ID "HP-UX"
247
335
 
248
- #elif defined(__HAIKU) || defined(__HAIKU__) || defined(_HAIKU)
336
+ #elif defined(__HAIKU__)
249
337
  # define PLATFORM_ID "Haiku"
250
- /* Haiku also defines __BEOS__ so we must
251
- put it prior to the check for __BEOS__
252
- */
253
338
 
254
339
  #elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
255
340
  # define PLATFORM_ID "BeOS"
@@ -287,8 +372,25 @@ char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
287
372
  #elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
288
373
  # define PLATFORM_ID "Xenix"
289
374
 
375
+ #elif defined(__WATCOMC__)
376
+ # if defined(__LINUX__)
377
+ # define PLATFORM_ID "Linux"
378
+
379
+ # elif defined(__DOS__)
380
+ # define PLATFORM_ID "DOS"
381
+
382
+ # elif defined(__OS2__)
383
+ # define PLATFORM_ID "OS2"
384
+
385
+ # elif defined(__WINDOWS__)
386
+ # define PLATFORM_ID "Windows3x"
387
+
388
+ # else /* unknown platform */
389
+ # define PLATFORM_ID
390
+ # endif
391
+
290
392
  #else /* unknown platform */
291
- # define PLATFORM_ID ""
393
+ # define PLATFORM_ID
292
394
 
293
395
  #endif
294
396
 
@@ -308,7 +410,13 @@ char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
308
410
  # define ARCHITECTURE_ID "X86"
309
411
 
310
412
  # elif defined(_M_ARM)
311
- # define ARCHITECTURE_ID "ARM"
413
+ # if _M_ARM == 4
414
+ # define ARCHITECTURE_ID "ARMV4I"
415
+ # elif _M_ARM == 5
416
+ # define ARCHITECTURE_ID "ARMV5I"
417
+ # else
418
+ # define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
419
+ # endif
312
420
 
313
421
  # elif defined(_M_MIPS)
314
422
  # define ARCHITECTURE_ID "MIPS"
@@ -320,8 +428,19 @@ char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
320
428
  # define ARCHITECTURE_ID ""
321
429
  # endif
322
430
 
323
- #else
431
+ #elif defined(__WATCOMC__)
432
+ # if defined(_M_I86)
433
+ # define ARCHITECTURE_ID "I86"
434
+
435
+ # elif defined(_M_IX86)
436
+ # define ARCHITECTURE_ID "X86"
437
+
438
+ # else /* unknown architecture */
324
439
  # define ARCHITECTURE_ID ""
440
+ # endif
441
+
442
+ #else
443
+ # define ARCHITECTURE_ID
325
444
  #endif
326
445
 
327
446
  /* Convert integer to decimal digit literals. */
@@ -364,6 +483,24 @@ char const info_version[] = {
364
483
  ']','\0'};
365
484
  #endif
366
485
 
486
+ /* Construct a string literal encoding the version number components. */
487
+ #ifdef SIMULATE_VERSION_MAJOR
488
+ char const info_simulate_version[] = {
489
+ 'I', 'N', 'F', 'O', ':',
490
+ 's','i','m','u','l','a','t','e','_','v','e','r','s','i','o','n','[',
491
+ SIMULATE_VERSION_MAJOR,
492
+ # ifdef SIMULATE_VERSION_MINOR
493
+ '.', SIMULATE_VERSION_MINOR,
494
+ # ifdef SIMULATE_VERSION_PATCH
495
+ '.', SIMULATE_VERSION_PATCH,
496
+ # ifdef SIMULATE_VERSION_TWEAK
497
+ '.', SIMULATE_VERSION_TWEAK,
498
+ # endif
499
+ # endif
500
+ # endif
501
+ ']','\0'};
502
+ #endif
503
+
367
504
  /* Construct the string literal in pieces to prevent the source from
368
505
  getting matched. Store it in a pointer rather than an array
369
506
  because some compilers will just produce instructions to fill the
@@ -373,12 +510,33 @@ char const* info_arch = "INFO" ":" "arch[" ARCHITECTURE_ID "]";
373
510
 
374
511
 
375
512
 
513
+
514
+ #if !defined(__STDC__)
515
+ # if defined(_MSC_VER) && !defined(__clang__)
516
+ # define C_DIALECT "90"
517
+ # else
518
+ # define C_DIALECT
519
+ # endif
520
+ #elif __STDC_VERSION__ >= 201000L
521
+ # define C_DIALECT "11"
522
+ #elif __STDC_VERSION__ >= 199901L
523
+ # define C_DIALECT "99"
524
+ #else
525
+ # define C_DIALECT "90"
526
+ #endif
527
+ const char* info_language_dialect_default =
528
+ "INFO" ":" "dialect_default[" C_DIALECT "]";
529
+
376
530
  /*--------------------------------------------------------------------------*/
377
531
 
378
532
  #ifdef ID_VOID_MAIN
379
533
  void main() {}
380
534
  #else
535
+ # if defined(__CLASSIC_C__)
536
+ int main(argc, argv) int argc; char *argv[];
537
+ # else
381
538
  int main(int argc, char* argv[])
539
+ # endif
382
540
  {
383
541
  int require = 0;
384
542
  require += info_compiler[argc];
@@ -387,6 +545,16 @@ int main(int argc, char* argv[])
387
545
  #ifdef COMPILER_VERSION_MAJOR
388
546
  require += info_version[argc];
389
547
  #endif
548
+ #ifdef SIMULATE_ID
549
+ require += info_simulate[argc];
550
+ #endif
551
+ #ifdef SIMULATE_VERSION_MAJOR
552
+ require += info_simulate_version[argc];
553
+ #endif
554
+ #if defined(__CRAYXE) || defined(__CRAYXC)
555
+ require += info_cray[argc];
556
+ #endif
557
+ require += info_language_dialect_default[argc];
390
558
  (void)argv;
391
559
  return require;
392
560
  }