/docroot/pgadmin/lang/Makefile

https://github.com/Knight-Mozilla/FollowThis · Makefile · 257 lines · 199 code · 34 blank · 24 comment · 6 complexity · 62a7b2e639cebb276ffbe8052811eb48 MD5 · raw file

  1. # This Makefile recodes source lang files into XML Unicode.
  2. # You should add your encodings to this file. You need to have GNU Recode
  3. # installed.
  4. #
  5. # It is important to:
  6. # - fix the delimiters of php code: <?php and ?>
  7. # - convert CRLF -> LF
  8. # - remove all text before first <?php
  9. # - remove all text after last ?>
  10. # - convert "&apos;" -> "'"
  11. # using 'convert.awk'
  12. #
  13. # Modifications by Dave Smith, 2003-11-10:
  14. # Added TARGETS variable for easy listing of all lang files.
  15. # Added 'prepare' target to check that 'recode' is installed.
  16. # Added 'clean' target to nuke recoded files.
  17. # Surpressed verbose command line dumpage with '@'.
  18. # Added dependency checking for incremental recoding.
  19. # Added pretty "Recoding ..." messages.
  20. # Added 'chmod 644' to 'all' target for correct file permissions.
  21. # Modifications by Rafal Slubowski, 2003-12-12:
  22. # All conversions of recoded text moved to convert.awk script
  23. #
  24. # $Id: Makefile,v 1.48 2007/02/10 03:48:35 xzilla Exp $
  25. DESTDIR=./recoded
  26. TARGETS=polish \
  27. english \
  28. chinese-sim \
  29. chinese-tr \
  30. chinese-utf8-zh_TW \
  31. chinese-utf8-zh_CN \
  32. danish \
  33. dutch \
  34. german \
  35. spanish \
  36. italian \
  37. french \
  38. russian \
  39. russian-utf8 \
  40. japanese \
  41. slovak \
  42. turkish \
  43. czech \
  44. portuguese-br \
  45. portuguese-pt \
  46. swedish \
  47. afrikaans \
  48. arabic \
  49. mongol \
  50. ukrainian \
  51. hungarian \
  52. hebrew \
  53. catalan \
  54. romanian \
  55. greek \
  56. galician
  57. all: prepare ${TARGETS}
  58. @for p in ${TARGETS} ; do chmod 644 ${DESTDIR}/$$p.php ; done
  59. prepare:
  60. @which recode >/dev/null 2>&1 || ( echo "You must have GNU 'recode' installed to use this Makefile,\
  61. but I could not find it in your path!" && exit 1 )
  62. @which sed >/dev/null 2>&1 || ( echo "You must have sed installed to use this Makefile,\
  63. but I could not find it in your path!" && exit 1 )
  64. @which awk >/dev/null 2>&1 || ( echo "You must have awk installed to use this Makefile,\
  65. but I could not find it in your path!" && exit 1 )
  66. clean:
  67. @echo "Nuking recoded lang files..."
  68. @for p in ${TARGETS} ; do rm -fv ${DESTDIR}/$$p.php ; done
  69. catalan: catalan.php
  70. @echo "Recoding catalan..."
  71. @cat catalan.php | recode utf-8..xml | ./convert.awk \
  72. > ${DESTDIR}/catalan.php
  73. @chmod 644 catalan.php ${DESTDIR}/catalan.php
  74. polish: polish.php
  75. @echo "Recoding polish..."
  76. @cat polish.php | recode utf-8..xml | ./convert.awk \
  77. > ${DESTDIR}/polish.php
  78. @chmod 644 polish.php ${DESTDIR}/polish.php
  79. english: english.php
  80. @echo "Recoding english..."
  81. @cat english.php | recode latin1..xml | ./convert.awk \
  82. > ${DESTDIR}/english.php
  83. @chmod 644 english.php ${DESTDIR}/english.php
  84. dutch: dutch.php
  85. @echo "Recoding dutch..."
  86. @cat dutch.php | recode latin1..xml | ./convert.awk \
  87. > ${DESTDIR}/dutch.php
  88. @chmod 644 dutch.php ${DESTDIR}/dutch.php
  89. danish: danish.php
  90. @echo "Recoding danish..."
  91. @cat danish.php | recode latin1..xml | ./convert.awk \
  92. > ${DESTDIR}/danish.php
  93. @chmod 644 danish.php ${DESTDIR}/danish.php
  94. german: german.php
  95. @echo "Recoding german..."
  96. @cat german.php | recode utf-8..xml | ./convert.awk \
  97. > ${DESTDIR}/german.php
  98. @chmod 644 german.php ${DESTDIR}/german.php
  99. spanish: spanish.php
  100. @echo "Recoding spanish..."
  101. @cat spanish.php | recode iso-8859-1..xml | ./convert.awk \
  102. > ${DESTDIR}/spanish.php
  103. @chmod 644 spanish.php ${DESTDIR}/spanish.php
  104. italian: italian.php
  105. @echo "Recoding italian..."
  106. @cat italian.php | recode iso-8859-1..xml | ./convert.awk \
  107. > ${DESTDIR}/italian.php
  108. @chmod 644 italian.php ${DESTDIR}/italian.php
  109. chinese-sim: chinese-sim.php
  110. @echo "Recoding chinese-sim..."
  111. @cat chinese-sim.php | recode gb2312..xml | ./convert.awk \
  112. > ${DESTDIR}/chinese-sim.php
  113. @chmod 644 chinese-sim.php ${DESTDIR}/chinese-sim.php
  114. chinese-tr: chinese-tr.php
  115. @echo "Recoding chinese-tr..."
  116. @cat chinese-tr.php | recode big5..xml | ./convert.awk \
  117. > ${DESTDIR}/chinese-tr.php
  118. @chmod 644 chinese-tr.php ${DESTDIR}/chinese-tr.php
  119. chinese-utf8-zh_CN: chinese-utf8-zh_CN.php
  120. @echo "Recoding chinese-utf8-zh_CN..."
  121. @cat chinese-utf8-zh_CN.php | recode utf-8..xml | ./convert.awk \
  122. > ${DESTDIR}/chinese-utf8-zh_CN.php
  123. @chmod 644 chinese-utf8-zh_CN.php ${DESTDIR}/chinese-utf8-zh_CN.php
  124. chinese-utf8-zh_TW: chinese-utf8-zh_TW.php
  125. @echo "Recoding chinese-utf8-zh_TW..."
  126. @cat chinese-utf8-zh_TW.php | recode utf-8..xml | ./convert.awk \
  127. > ${DESTDIR}/chinese-utf8-zh_TW.php
  128. @chmod 644 chinese-utf8-zh_TW.php ${DESTDIR}/chinese-utf8-zh_TW.php
  129. french: french.php
  130. @echo "Recoding french..."
  131. @cat french.php | recode latin1..xml | ./convert.awk \
  132. > ${DESTDIR}/french.php
  133. @chmod 644 french.php ${DESTDIR}/french.php
  134. japanese: japanese.php
  135. @echo "Recoding japanese..."
  136. @cat japanese.php | recode euc-jp..xml | ./convert.awk \
  137. > ${DESTDIR}/japanese.php
  138. @chmod 644 japanese.php ${DESTDIR}/japanese.php
  139. russian: russian.php
  140. @echo "Recoding russian..."
  141. @cat russian.php | recode koi8..xml | ./convert.awk \
  142. > ${DESTDIR}/russian.php
  143. @chmod 644 russian.php ${DESTDIR}/russian.php
  144. russian-utf8: russian-utf8.php
  145. @echo "Recoding russian-utf8..."
  146. @cat russian-utf8.php | recode utf-8..xml | ./convert.awk \
  147. > ${DESTDIR}/russian-utf8.php
  148. @chmod 644 russian-utf8.php ${DESTDIR}/russian-utf8.php
  149. slovak: slovak.php
  150. @echo "Recoding slovak..."
  151. @cat slovak.php | recode utf-8..xml | ./convert.awk \
  152. > ${DESTDIR}/slovak.php
  153. @chmod 644 slovak.php ${DESTDIR}/slovak.php
  154. czech: czech.php
  155. @echo "Recoding czech..."
  156. @cat czech.php | recode utf-8..xml | ./convert.awk \
  157. > ${DESTDIR}/czech.php
  158. @chmod 644 czech.php ${DESTDIR}/czech.php
  159. turkish: turkish.php
  160. @echo "Recoding turkish..."
  161. @cat turkish.php | recode iso-8859-9..xml | ./convert.awk \
  162. > ${DESTDIR}/turkish.php
  163. @chmod 644 turkish.php ${DESTDIR}/turkish.php
  164. portuguese-br: portuguese-br.php
  165. @echo "Recoding portuguese-br..."
  166. @cat portuguese-br.php | recode iso-8859-1..xml | ./convert.awk \
  167. > ${DESTDIR}/portuguese-br.php
  168. @chmod 644 portuguese-br.php ${DESTDIR}/portuguese-br.php
  169. portuguese-pt: portuguese-pt.php
  170. @echo "Recoding portuguese-pt..."
  171. @cat portuguese-pt.php | recode iso-8859-15..xml | ./convert.awk \
  172. > ${DESTDIR}/portuguese-pt.php
  173. @chmod 644 portuguese-pt.php ${DESTDIR}/portuguese-pt.php
  174. swedish: swedish.php
  175. @echo "Recoding swedish..."
  176. @cat swedish.php | recode iso-8859-1..xml | ./convert.awk \
  177. > ${DESTDIR}/swedish.php
  178. @chmod 644 swedish.php ${DESTDIR}/swedish.php
  179. afrikaans: afrikaans.php
  180. @echo "Recoding afrikaans..."
  181. @cat afrikaans.php | recode iso-8859-1..xml | ./convert.awk \
  182. > ${DESTDIR}/afrikaans.php
  183. @chmod 644 afrikaans.php ${DESTDIR}/afrikaans.php
  184. hungarian: hungarian.php
  185. @echo "Recoding hungarian..."
  186. @cat hungarian.php | recode utf-8..xml | ./convert.awk \
  187. > ${DESTDIR}/hungarian.php
  188. @chmod 644 hungarian.php ${DESTDIR}/hungarian.php
  189. arabic: arabic.php
  190. @echo "Recoding arabic..."
  191. @cat arabic.php | recode utf-8..xml | ./convert.awk \
  192. > ${DESTDIR}/arabic.php
  193. @chmod 644 arabic.php ${DESTDIR}/arabic.php
  194. mongol: mongol.php
  195. @echo "Recoding mongol..."
  196. @cat mongol.php | recode iso-8859-5..xml | ./convert.awk \
  197. > ${DESTDIR}/mongol.php
  198. @chmod 644 mongol.php ${DESTDIR}/mongol.php
  199. ukrainian: ukrainian.php
  200. @echo "Recoding ukrainian..."
  201. @cat ukrainian.php | recode koi8-r..xml | ./convert.awk \
  202. > ${DESTDIR}/ukrainian.php
  203. @chmod 644 ukrainian.php ${DESTDIR}/ukrainian.php
  204. hebrew: hebrew.php
  205. @echo "Recoding hebrew..."
  206. @cat hebrew.php | recode utf-8..xml | ./convert.awk \
  207. > ${DESTDIR}/hebrew.php
  208. @chmod 644 hebrew.php ${DESTDIR}/hebrew.php
  209. romanian: romanian.php
  210. @echo "Recoding romanian..."
  211. @cat romanian.php | recode utf-8..xml | ./convert.awk \
  212. > ${DESTDIR}/romanian.php
  213. @chmod 644 romanian.php ${DESTDIR}/romanian.php
  214. greek: greek.php
  215. @echo "Recoding greek..."
  216. @cat greek.php | recode iso-8859-7..xml | ./convert.awk \
  217. > ${DESTDIR}/greek.php
  218. @chmod 644 greek.php ${DESTDIR}/greek.php
  219. galician: galician.php
  220. @echo "Recoding galician..."
  221. @cat galician.php | recode utf-8..xml | ./convert.awk \
  222. > ${DESTDIR}/galician.php
  223. @chmod 644 galician.php ${DESTDIR}/galician.php