glib2 3.1.8-x86-mingw32 → 3.1.9-x86-mingw32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (521) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +4 -4
  3. data/ext/glib2/rbglib.h +1 -1
  4. data/lib/2.2/glib2.so +0 -0
  5. data/lib/2.3/glib2.so +0 -0
  6. data/lib/2.4/glib2.so +0 -0
  7. data/lib/gnome2/rake/external-package.rb +5 -0
  8. data/lib/gnome2/rake/windows-binary-build-task.rb +82 -12
  9. data/test/run-test.rb +1 -1
  10. data/vendor/local/bin/asn1Coding.exe +0 -0
  11. data/vendor/local/bin/asn1Decoding.exe +0 -0
  12. data/vendor/local/bin/asn1Parser.exe +0 -0
  13. data/vendor/local/bin/envsubst.exe +0 -0
  14. data/vendor/local/bin/gdbus-codegen +10 -6
  15. data/vendor/local/bin/gdbus.exe +0 -0
  16. data/vendor/local/bin/gettext.exe +0 -0
  17. data/vendor/local/bin/gio-querymodules.exe +0 -0
  18. data/vendor/local/bin/gio.exe +0 -0
  19. data/vendor/local/bin/glib-compile-resources.exe +0 -0
  20. data/vendor/local/bin/glib-compile-schemas.exe +0 -0
  21. data/vendor/local/bin/glib-genmarshal +1056 -0
  22. data/vendor/local/bin/glib-gettextize +1 -1
  23. data/vendor/local/bin/glib-mkenums +694 -579
  24. data/vendor/local/bin/gobject-query.exe +0 -0
  25. data/vendor/local/bin/gresource.exe +0 -0
  26. data/vendor/local/bin/gsettings.exe +0 -0
  27. data/vendor/local/bin/gspawn-win32-helper-console.exe +0 -0
  28. data/vendor/local/bin/gspawn-win32-helper.exe +0 -0
  29. data/vendor/local/bin/iconv.exe +0 -0
  30. data/vendor/local/bin/idn.exe +0 -0
  31. data/vendor/local/bin/libasprintf-0.dll +0 -0
  32. data/vendor/local/bin/libcharset-1.dll +0 -0
  33. data/vendor/local/bin/libffi-6.dll +0 -0
  34. data/vendor/local/bin/libgio-2.0-0.dll +0 -0
  35. data/vendor/local/bin/libglib-2.0-0.dll +0 -0
  36. data/vendor/local/bin/libgmodule-2.0-0.dll +0 -0
  37. data/vendor/local/bin/libgmp-10.dll +0 -0
  38. data/vendor/local/bin/libgnutls-30.dll +0 -0
  39. data/vendor/local/bin/libgobject-2.0-0.dll +0 -0
  40. data/vendor/local/bin/libgthread-2.0-0.dll +0 -0
  41. data/vendor/local/bin/libhogweed-4-2.dll +0 -0
  42. data/vendor/local/bin/libiconv-2.dll +0 -0
  43. data/vendor/local/bin/libidn-11.dll +0 -0
  44. data/vendor/local/bin/libintl-8.dll +0 -0
  45. data/vendor/local/bin/libnettle-6-2.dll +0 -0
  46. data/vendor/local/bin/libp11-kit-0.dll +0 -0
  47. data/vendor/local/bin/libpcre-1.dll +0 -0
  48. data/vendor/local/bin/libpcrecpp-0.dll +0 -0
  49. data/vendor/local/bin/libpcreposix-0.dll +0 -0
  50. data/vendor/local/bin/libtasn1-6.dll +0 -0
  51. data/vendor/local/bin/nettle-hash.exe +0 -0
  52. data/vendor/local/bin/nettle-lfib-stream.exe +0 -0
  53. data/vendor/local/bin/nettle-pbkdf2.exe +0 -0
  54. data/vendor/local/bin/ngettext.exe +0 -0
  55. data/vendor/local/bin/p11-kit.exe +0 -0
  56. data/vendor/local/bin/pcregrep.exe +0 -0
  57. data/vendor/local/bin/pcretest.exe +0 -0
  58. data/vendor/local/bin/pkcs1-conv.exe +0 -0
  59. data/vendor/local/bin/sexp-conv.exe +0 -0
  60. data/vendor/local/bin/trust.exe +0 -0
  61. data/vendor/local/include/gio-win32-2.0/gio/gwin32inputstream.h +1 -1
  62. data/vendor/local/include/gio-win32-2.0/gio/gwin32outputstream.h +1 -1
  63. data/vendor/local/include/glib-2.0/gio/gaction.h +4 -4
  64. data/vendor/local/include/glib-2.0/gio/gactiongroup.h +4 -4
  65. data/vendor/local/include/glib-2.0/gio/gactiongroupexporter.h +4 -4
  66. data/vendor/local/include/glib-2.0/gio/gactionmap.h +4 -4
  67. data/vendor/local/include/glib-2.0/gio/gappinfo.h +1 -1
  68. data/vendor/local/include/glib-2.0/gio/gapplication.h +4 -4
  69. data/vendor/local/include/glib-2.0/gio/gapplicationcommandline.h +4 -4
  70. data/vendor/local/include/glib-2.0/gio/gasyncinitable.h +2 -2
  71. data/vendor/local/include/glib-2.0/gio/gasyncresult.h +1 -1
  72. data/vendor/local/include/glib-2.0/gio/gbufferedinputstream.h +1 -1
  73. data/vendor/local/include/glib-2.0/gio/gbufferedoutputstream.h +1 -1
  74. data/vendor/local/include/glib-2.0/gio/gbytesicon.h +1 -1
  75. data/vendor/local/include/glib-2.0/gio/gcancellable.h +1 -1
  76. data/vendor/local/include/glib-2.0/gio/gcharsetconverter.h +1 -1
  77. data/vendor/local/include/glib-2.0/gio/gcontenttype.h +1 -1
  78. data/vendor/local/include/glib-2.0/gio/gconverter.h +1 -1
  79. data/vendor/local/include/glib-2.0/gio/gconverterinputstream.h +1 -1
  80. data/vendor/local/include/glib-2.0/gio/gconverteroutputstream.h +1 -1
  81. data/vendor/local/include/glib-2.0/gio/gcredentials.h +1 -1
  82. data/vendor/local/include/glib-2.0/gio/gdatagrambased.h +1 -1
  83. data/vendor/local/include/glib-2.0/gio/gdatainputstream.h +1 -1
  84. data/vendor/local/include/glib-2.0/gio/gdataoutputstream.h +1 -1
  85. data/vendor/local/include/glib-2.0/gio/gdbusactiongroup.h +4 -4
  86. data/vendor/local/include/glib-2.0/gio/gdbusaddress.h +1 -1
  87. data/vendor/local/include/glib-2.0/gio/gdbusauthobserver.h +1 -1
  88. data/vendor/local/include/glib-2.0/gio/gdbusconnection.h +1 -1
  89. data/vendor/local/include/glib-2.0/gio/gdbuserror.h +1 -1
  90. data/vendor/local/include/glib-2.0/gio/gdbusinterface.h +1 -1
  91. data/vendor/local/include/glib-2.0/gio/gdbusinterfaceskeleton.h +1 -1
  92. data/vendor/local/include/glib-2.0/gio/gdbusintrospection.h +1 -1
  93. data/vendor/local/include/glib-2.0/gio/gdbusmenumodel.h +4 -4
  94. data/vendor/local/include/glib-2.0/gio/gdbusmessage.h +1 -1
  95. data/vendor/local/include/glib-2.0/gio/gdbusmethodinvocation.h +1 -1
  96. data/vendor/local/include/glib-2.0/gio/gdbusnameowning.h +1 -1
  97. data/vendor/local/include/glib-2.0/gio/gdbusnamewatching.h +1 -1
  98. data/vendor/local/include/glib-2.0/gio/gdbusobject.h +1 -1
  99. data/vendor/local/include/glib-2.0/gio/gdbusobjectmanager.h +1 -1
  100. data/vendor/local/include/glib-2.0/gio/gdbusobjectmanagerclient.h +1 -1
  101. data/vendor/local/include/glib-2.0/gio/gdbusobjectmanagerserver.h +1 -1
  102. data/vendor/local/include/glib-2.0/gio/gdbusobjectproxy.h +1 -1
  103. data/vendor/local/include/glib-2.0/gio/gdbusobjectskeleton.h +1 -1
  104. data/vendor/local/include/glib-2.0/gio/gdbusproxy.h +1 -1
  105. data/vendor/local/include/glib-2.0/gio/gdbusserver.h +1 -1
  106. data/vendor/local/include/glib-2.0/gio/gdbusutils.h +1 -1
  107. data/vendor/local/include/glib-2.0/gio/gdrive.h +1 -1
  108. data/vendor/local/include/glib-2.0/gio/gdtlsclientconnection.h +1 -1
  109. data/vendor/local/include/glib-2.0/gio/gdtlsconnection.h +1 -1
  110. data/vendor/local/include/glib-2.0/gio/gdtlsserverconnection.h +1 -1
  111. data/vendor/local/include/glib-2.0/gio/gemblem.h +1 -1
  112. data/vendor/local/include/glib-2.0/gio/gemblemedicon.h +1 -1
  113. data/vendor/local/include/glib-2.0/gio/gfile.h +1 -1
  114. data/vendor/local/include/glib-2.0/gio/gfileattribute.h +1 -1
  115. data/vendor/local/include/glib-2.0/gio/gfileenumerator.h +1 -1
  116. data/vendor/local/include/glib-2.0/gio/gfileicon.h +1 -1
  117. data/vendor/local/include/glib-2.0/gio/gfileinfo.h +1 -1
  118. data/vendor/local/include/glib-2.0/gio/gfileinputstream.h +1 -1
  119. data/vendor/local/include/glib-2.0/gio/gfileiostream.h +1 -1
  120. data/vendor/local/include/glib-2.0/gio/gfilemonitor.h +1 -1
  121. data/vendor/local/include/glib-2.0/gio/gfilenamecompleter.h +1 -1
  122. data/vendor/local/include/glib-2.0/gio/gfileoutputstream.h +1 -1
  123. data/vendor/local/include/glib-2.0/gio/gfilterinputstream.h +1 -1
  124. data/vendor/local/include/glib-2.0/gio/gfilteroutputstream.h +1 -1
  125. data/vendor/local/include/glib-2.0/gio/gicon.h +1 -1
  126. data/vendor/local/include/glib-2.0/gio/ginetaddress.h +1 -1
  127. data/vendor/local/include/glib-2.0/gio/ginetaddressmask.h +1 -1
  128. data/vendor/local/include/glib-2.0/gio/ginetsocketaddress.h +1 -1
  129. data/vendor/local/include/glib-2.0/gio/ginitable.h +3 -2
  130. data/vendor/local/include/glib-2.0/gio/ginputstream.h +1 -1
  131. data/vendor/local/include/glib-2.0/gio/gio-autocleanups.h +1 -1
  132. data/vendor/local/include/glib-2.0/gio/gio.h +1 -1
  133. data/vendor/local/include/glib-2.0/gio/gioenums.h +7 -2
  134. data/vendor/local/include/glib-2.0/gio/gioerror.h +1 -1
  135. data/vendor/local/include/glib-2.0/gio/giomodule.h +1 -1
  136. data/vendor/local/include/glib-2.0/gio/gioscheduler.h +1 -1
  137. data/vendor/local/include/glib-2.0/gio/giostream.h +4 -4
  138. data/vendor/local/include/glib-2.0/gio/giotypes.h +1 -1
  139. data/vendor/local/include/glib-2.0/gio/glistmodel.h +1 -1
  140. data/vendor/local/include/glib-2.0/gio/gliststore.h +1 -1
  141. data/vendor/local/include/glib-2.0/gio/gloadableicon.h +1 -1
  142. data/vendor/local/include/glib-2.0/gio/gmemoryinputstream.h +1 -1
  143. data/vendor/local/include/glib-2.0/gio/gmemoryoutputstream.h +1 -1
  144. data/vendor/local/include/glib-2.0/gio/gmenu.h +4 -4
  145. data/vendor/local/include/glib-2.0/gio/gmenuexporter.h +4 -4
  146. data/vendor/local/include/glib-2.0/gio/gmenumodel.h +4 -4
  147. data/vendor/local/include/glib-2.0/gio/gmount.h +1 -1
  148. data/vendor/local/include/glib-2.0/gio/gmountoperation.h +1 -1
  149. data/vendor/local/include/glib-2.0/gio/gnativevolumemonitor.h +1 -1
  150. data/vendor/local/include/glib-2.0/gio/gnetworkaddress.h +1 -1
  151. data/vendor/local/include/glib-2.0/gio/gnetworking.h +3 -3
  152. data/vendor/local/include/glib-2.0/gio/gnetworkmonitor.h +1 -1
  153. data/vendor/local/include/glib-2.0/gio/gnetworkservice.h +1 -1
  154. data/vendor/local/include/glib-2.0/gio/gnotification.h +1 -1
  155. data/vendor/local/include/glib-2.0/gio/goutputstream.h +1 -1
  156. data/vendor/local/include/glib-2.0/gio/gpermission.h +1 -1
  157. data/vendor/local/include/glib-2.0/gio/gpollableinputstream.h +1 -1
  158. data/vendor/local/include/glib-2.0/gio/gpollableoutputstream.h +1 -1
  159. data/vendor/local/include/glib-2.0/gio/gpollableutils.h +1 -1
  160. data/vendor/local/include/glib-2.0/gio/gpropertyaction.h +4 -4
  161. data/vendor/local/include/glib-2.0/gio/gproxy.h +1 -1
  162. data/vendor/local/include/glib-2.0/gio/gproxyaddress.h +1 -1
  163. data/vendor/local/include/glib-2.0/gio/gproxyaddressenumerator.h +1 -1
  164. data/vendor/local/include/glib-2.0/gio/gproxyresolver.h +1 -1
  165. data/vendor/local/include/glib-2.0/gio/gremoteactiongroup.h +4 -4
  166. data/vendor/local/include/glib-2.0/gio/gresolver.h +1 -1
  167. data/vendor/local/include/glib-2.0/gio/gresource.h +1 -1
  168. data/vendor/local/include/glib-2.0/gio/gseekable.h +1 -1
  169. data/vendor/local/include/glib-2.0/gio/gsettings.h +1 -1
  170. data/vendor/local/include/glib-2.0/gio/gsettingsbackend.h +1 -1
  171. data/vendor/local/include/glib-2.0/gio/gsettingsschema.h +1 -1
  172. data/vendor/local/include/glib-2.0/gio/gsimpleaction.h +4 -4
  173. data/vendor/local/include/glib-2.0/gio/gsimpleactiongroup.h +4 -4
  174. data/vendor/local/include/glib-2.0/gio/gsimpleasyncresult.h +1 -1
  175. data/vendor/local/include/glib-2.0/gio/gsimpleiostream.h +4 -4
  176. data/vendor/local/include/glib-2.0/gio/gsimplepermission.h +1 -1
  177. data/vendor/local/include/glib-2.0/gio/gsimpleproxyresolver.h +1 -1
  178. data/vendor/local/include/glib-2.0/gio/gsocket.h +1 -1
  179. data/vendor/local/include/glib-2.0/gio/gsocketaddress.h +1 -1
  180. data/vendor/local/include/glib-2.0/gio/gsocketaddressenumerator.h +1 -1
  181. data/vendor/local/include/glib-2.0/gio/gsocketclient.h +4 -4
  182. data/vendor/local/include/glib-2.0/gio/gsocketconnectable.h +1 -1
  183. data/vendor/local/include/glib-2.0/gio/gsocketconnection.h +4 -4
  184. data/vendor/local/include/glib-2.0/gio/gsocketcontrolmessage.h +4 -4
  185. data/vendor/local/include/glib-2.0/gio/gsocketlistener.h +4 -4
  186. data/vendor/local/include/glib-2.0/gio/gsocketservice.h +4 -4
  187. data/vendor/local/include/glib-2.0/gio/gsrvtarget.h +1 -1
  188. data/vendor/local/include/glib-2.0/gio/gsubprocess.h +1 -1
  189. data/vendor/local/include/glib-2.0/gio/gsubprocesslauncher.h +1 -1
  190. data/vendor/local/include/glib-2.0/gio/gtask.h +1 -1
  191. data/vendor/local/include/glib-2.0/gio/gtcpconnection.h +4 -4
  192. data/vendor/local/include/glib-2.0/gio/gtcpwrapperconnection.h +4 -4
  193. data/vendor/local/include/glib-2.0/gio/gtestdbus.h +1 -1
  194. data/vendor/local/include/glib-2.0/gio/gthemedicon.h +1 -1
  195. data/vendor/local/include/glib-2.0/gio/gthreadedsocketservice.h +4 -4
  196. data/vendor/local/include/glib-2.0/gio/gtlsbackend.h +1 -1
  197. data/vendor/local/include/glib-2.0/gio/gtlscertificate.h +1 -1
  198. data/vendor/local/include/glib-2.0/gio/gtlsclientconnection.h +1 -1
  199. data/vendor/local/include/glib-2.0/gio/gtlsconnection.h +1 -1
  200. data/vendor/local/include/glib-2.0/gio/gtlsdatabase.h +1 -1
  201. data/vendor/local/include/glib-2.0/gio/gtlsfiledatabase.h +4 -4
  202. data/vendor/local/include/glib-2.0/gio/gtlsinteraction.h +1 -1
  203. data/vendor/local/include/glib-2.0/gio/gtlspassword.h +1 -1
  204. data/vendor/local/include/glib-2.0/gio/gtlsserverconnection.h +1 -1
  205. data/vendor/local/include/glib-2.0/gio/gvfs.h +1 -1
  206. data/vendor/local/include/glib-2.0/gio/gvolume.h +1 -1
  207. data/vendor/local/include/glib-2.0/gio/gvolumemonitor.h +1 -1
  208. data/vendor/local/include/glib-2.0/gio/gzlibcompressor.h +1 -1
  209. data/vendor/local/include/glib-2.0/gio/gzlibdecompressor.h +1 -1
  210. data/vendor/local/include/glib-2.0/glib-object.h +1 -1
  211. data/vendor/local/include/glib-2.0/glib-unix.h +5 -5
  212. data/vendor/local/include/glib-2.0/glib.h +1 -1
  213. data/vendor/local/include/glib-2.0/glib/deprecated/gallocator.h +1 -1
  214. data/vendor/local/include/glib-2.0/glib/deprecated/gcache.h +1 -1
  215. data/vendor/local/include/glib-2.0/glib/deprecated/gcompletion.h +1 -1
  216. data/vendor/local/include/glib-2.0/glib/deprecated/gmain.h +1 -1
  217. data/vendor/local/include/glib-2.0/glib/deprecated/grel.h +1 -1
  218. data/vendor/local/include/glib-2.0/glib/deprecated/gthread.h +1 -1
  219. data/vendor/local/include/glib-2.0/glib/galloca.h +1 -1
  220. data/vendor/local/include/glib-2.0/glib/garray.h +10 -1
  221. data/vendor/local/include/glib-2.0/glib/gasyncqueue.h +1 -1
  222. data/vendor/local/include/glib-2.0/glib/gatomic.h +4 -4
  223. data/vendor/local/include/glib-2.0/glib/gbacktrace.h +1 -1
  224. data/vendor/local/include/glib-2.0/glib/gbase64.h +5 -5
  225. data/vendor/local/include/glib-2.0/glib/gbitlock.h +1 -1
  226. data/vendor/local/include/glib-2.0/glib/gbookmarkfile.h +4 -4
  227. data/vendor/local/include/glib-2.0/glib/gbytes.h +1 -1
  228. data/vendor/local/include/glib-2.0/glib/gcharset.h +1 -1
  229. data/vendor/local/include/glib-2.0/glib/gchecksum.h +5 -5
  230. data/vendor/local/include/glib-2.0/glib/gconvert.h +1 -31
  231. data/vendor/local/include/glib-2.0/glib/gdataset.h +1 -1
  232. data/vendor/local/include/glib-2.0/glib/gdate.h +1 -1
  233. data/vendor/local/include/glib-2.0/glib/gdir.h +1 -15
  234. data/vendor/local/include/glib-2.0/glib/genviron.h +1 -17
  235. data/vendor/local/include/glib-2.0/glib/gerror.h +1 -1
  236. data/vendor/local/include/glib-2.0/glib/gfileutils.h +1 -28
  237. data/vendor/local/include/glib-2.0/glib/ggettext.h +1 -1
  238. data/vendor/local/include/glib-2.0/glib/ghash.h +1 -1
  239. data/vendor/local/include/glib-2.0/glib/ghmac.h +5 -5
  240. data/vendor/local/include/glib-2.0/glib/ghook.h +1 -1
  241. data/vendor/local/include/glib-2.0/glib/ghostutils.h +1 -1
  242. data/vendor/local/include/glib-2.0/glib/gi18n-lib.h +1 -1
  243. data/vendor/local/include/glib-2.0/glib/gi18n.h +1 -1
  244. data/vendor/local/include/glib-2.0/glib/giochannel.h +1 -12
  245. data/vendor/local/include/glib-2.0/glib/gkeyfile.h +1 -1
  246. data/vendor/local/include/glib-2.0/glib/glib-autocleanups.h +1 -1
  247. data/vendor/local/include/glib-2.0/glib/glist.h +1 -1
  248. data/vendor/local/include/glib-2.0/glib/gmacros.h +1 -1
  249. data/vendor/local/include/glib-2.0/glib/gmain.h +5 -5
  250. data/vendor/local/include/glib-2.0/glib/gmappedfile.h +1 -1
  251. data/vendor/local/include/glib-2.0/glib/gmarkup.h +1 -1
  252. data/vendor/local/include/glib-2.0/glib/gmem.h +1 -1
  253. data/vendor/local/include/glib-2.0/glib/gmessages.h +8 -1
  254. data/vendor/local/include/glib-2.0/glib/gnode.h +1 -1
  255. data/vendor/local/include/glib-2.0/glib/goption.h +6 -6
  256. data/vendor/local/include/glib-2.0/glib/gpattern.h +1 -1
  257. data/vendor/local/include/glib-2.0/glib/gpoll.h +6 -6
  258. data/vendor/local/include/glib-2.0/glib/gprimes.h +1 -1
  259. data/vendor/local/include/glib-2.0/glib/gprintf.h +1 -1
  260. data/vendor/local/include/glib-2.0/glib/gqsort.h +1 -1
  261. data/vendor/local/include/glib-2.0/glib/gquark.h +1 -1
  262. data/vendor/local/include/glib-2.0/glib/gqueue.h +1 -1
  263. data/vendor/local/include/glib-2.0/glib/grand.h +1 -1
  264. data/vendor/local/include/glib-2.0/glib/gscanner.h +1 -1
  265. data/vendor/local/include/glib-2.0/glib/gsequence.h +1 -1
  266. data/vendor/local/include/glib-2.0/glib/gshell.h +1 -1
  267. data/vendor/local/include/glib-2.0/glib/gslice.h +1 -1
  268. data/vendor/local/include/glib-2.0/glib/gslist.h +1 -1
  269. data/vendor/local/include/glib-2.0/glib/gspawn.h +1 -54
  270. data/vendor/local/include/glib-2.0/glib/gstdio.h +1 -1
  271. data/vendor/local/include/glib-2.0/glib/gstrfuncs.h +48 -1
  272. data/vendor/local/include/glib-2.0/glib/gstring.h +1 -1
  273. data/vendor/local/include/glib-2.0/glib/gstringchunk.h +1 -1
  274. data/vendor/local/include/glib-2.0/glib/gtestutils.h +1 -1
  275. data/vendor/local/include/glib-2.0/glib/gthread.h +4 -4
  276. data/vendor/local/include/glib-2.0/glib/gthreadpool.h +1 -1
  277. data/vendor/local/include/glib-2.0/glib/gtimer.h +1 -1
  278. data/vendor/local/include/glib-2.0/glib/gtimezone.h +4 -4
  279. data/vendor/local/include/glib-2.0/glib/gtrashstack.h +1 -1
  280. data/vendor/local/include/glib-2.0/glib/gtree.h +1 -1
  281. data/vendor/local/include/glib-2.0/glib/gtypes.h +1 -1
  282. data/vendor/local/include/glib-2.0/glib/gunicode.h +12 -2
  283. data/vendor/local/include/glib-2.0/glib/gurifuncs.h +1 -1
  284. data/vendor/local/include/glib-2.0/glib/gutils.h +1 -1
  285. data/vendor/local/include/glib-2.0/glib/gvariant.h +1 -1
  286. data/vendor/local/include/glib-2.0/glib/gvarianttype.h +5 -4
  287. data/vendor/local/include/glib-2.0/glib/gversion.h +1 -1
  288. data/vendor/local/include/glib-2.0/glib/gversionmacros.h +25 -1
  289. data/vendor/local/include/glib-2.0/glib/gwin32.h +1 -20
  290. data/vendor/local/include/glib-2.0/gmodule.h +15 -15
  291. data/vendor/local/include/glib-2.0/gobject/gbinding.h +1 -1
  292. data/vendor/local/include/glib-2.0/gobject/gboxed.h +1 -1
  293. data/vendor/local/include/glib-2.0/gobject/gclosure.h +1 -1
  294. data/vendor/local/include/glib-2.0/gobject/genums.h +7 -1
  295. data/vendor/local/include/glib-2.0/gobject/glib-types.h +1 -1
  296. data/vendor/local/include/glib-2.0/gobject/gobject-autocleanups.h +2 -1
  297. data/vendor/local/include/glib-2.0/gobject/gobject.h +17 -2
  298. data/vendor/local/include/glib-2.0/gobject/gobjectnotifyqueue.c +1 -1
  299. data/vendor/local/include/glib-2.0/gobject/gparam.h +3 -1
  300. data/vendor/local/include/glib-2.0/gobject/gparamspecs.h +1 -1
  301. data/vendor/local/include/glib-2.0/gobject/gsignal.h +1 -1
  302. data/vendor/local/include/glib-2.0/gobject/gsourceclosure.h +1 -1
  303. data/vendor/local/include/glib-2.0/gobject/gtype.h +15 -3
  304. data/vendor/local/include/glib-2.0/gobject/gtypemodule.h +1 -1
  305. data/vendor/local/include/glib-2.0/gobject/gtypeplugin.h +1 -1
  306. data/vendor/local/include/glib-2.0/gobject/gvalue.h +1 -1
  307. data/vendor/local/include/glib-2.0/gobject/gvaluearray.h +1 -1
  308. data/vendor/local/include/glib-2.0/gobject/gvaluecollector.h +1 -1
  309. data/vendor/local/include/glib-2.0/gobject/gvaluetypes.h +1 -1
  310. data/vendor/local/lib/gio/modules/libgiognutls.a +0 -0
  311. data/vendor/local/lib/gio/modules/libgiognutls.dll +0 -0
  312. data/vendor/local/lib/gio/modules/libgiognutls.dll.a +0 -0
  313. data/vendor/local/lib/glib-2.0/include/glibconfig.h +2 -2
  314. data/vendor/local/lib/libasprintf.dll.a +0 -0
  315. data/vendor/local/lib/libcharset.dll.a +0 -0
  316. data/vendor/local/lib/libffi.dll.a +0 -0
  317. data/vendor/local/lib/libgio-2.0.dll.a +0 -0
  318. data/vendor/local/lib/libgio-2.0.la +3 -3
  319. data/vendor/local/lib/libglib-2.0.dll.a +0 -0
  320. data/vendor/local/lib/libglib-2.0.la +3 -3
  321. data/vendor/local/lib/libgmodule-2.0.dll.a +0 -0
  322. data/vendor/local/lib/libgmodule-2.0.la +3 -3
  323. data/vendor/local/lib/libgmp.dll.a +0 -0
  324. data/vendor/local/lib/libgnutls.dll.a +0 -0
  325. data/vendor/local/lib/libgobject-2.0.dll.a +0 -0
  326. data/vendor/local/lib/libgobject-2.0.la +3 -3
  327. data/vendor/local/lib/libgthread-2.0.dll.a +0 -0
  328. data/vendor/local/lib/libgthread-2.0.la +3 -3
  329. data/vendor/local/lib/libhogweed.dll.a +0 -0
  330. data/vendor/local/lib/libiconv.dll.a +0 -0
  331. data/vendor/local/lib/libidn.dll.a +0 -0
  332. data/vendor/local/lib/libintl.dll.a +0 -0
  333. data/vendor/local/lib/libnettle.dll.a +0 -0
  334. data/vendor/local/lib/libp11-kit.dll.a +0 -0
  335. data/vendor/local/lib/libpcre.dll.a +0 -0
  336. data/vendor/local/lib/libpcrecpp.dll.a +0 -0
  337. data/vendor/local/lib/libpcreposix.dll.a +0 -0
  338. data/vendor/local/lib/libtasn1.dll.a +0 -0
  339. data/vendor/local/lib/p11-kit/p11-kit-remote.exe +0 -0
  340. data/vendor/local/lib/pkcs11/p11-kit-trust.dll +0 -0
  341. data/vendor/local/lib/pkcs11/p11-kit-trust.dll.a +0 -0
  342. data/vendor/local/lib/pkgconfig/gio-2.0.pc +1 -1
  343. data/vendor/local/lib/pkgconfig/gio-windows-2.0.pc +1 -1
  344. data/vendor/local/lib/pkgconfig/glib-2.0.pc +1 -1
  345. data/vendor/local/lib/pkgconfig/gmodule-2.0.pc +1 -1
  346. data/vendor/local/lib/pkgconfig/gmodule-export-2.0.pc +1 -1
  347. data/vendor/local/lib/pkgconfig/gmodule-no-export-2.0.pc +1 -1
  348. data/vendor/local/lib/pkgconfig/gobject-2.0.pc +1 -1
  349. data/vendor/local/lib/pkgconfig/gthread-2.0.pc +1 -1
  350. data/vendor/local/share/gdb/auto-load/home/vagrant/ruby-gnome2.win32/glib2/vendor/local/lib/{libglib-2.0.so.0.5200.3-gdb.py → libglib-2.0.so.0.5400.1-gdb.py} +0 -0
  351. data/vendor/local/share/gdb/auto-load/home/vagrant/ruby-gnome2.win32/glib2/vendor/local/lib/{libgobject-2.0.so.0.5200.3-gdb.py → libgobject-2.0.so.0.5400.1-gdb.py} +0 -0
  352. data/vendor/local/share/glib-2.0/codegen/__init__.py +1 -1
  353. data/vendor/local/share/glib-2.0/codegen/__init__.pyc +0 -0
  354. data/vendor/local/share/glib-2.0/codegen/__init__.pyo +0 -0
  355. data/vendor/local/share/glib-2.0/codegen/codegen.py +11 -11
  356. data/vendor/local/share/glib-2.0/codegen/codegen.pyc +0 -0
  357. data/vendor/local/share/glib-2.0/codegen/codegen.pyo +0 -0
  358. data/vendor/local/share/glib-2.0/codegen/codegen_docbook.py +1 -1
  359. data/vendor/local/share/glib-2.0/codegen/codegen_docbook.pyc +0 -0
  360. data/vendor/local/share/glib-2.0/codegen/codegen_docbook.pyo +0 -0
  361. data/vendor/local/share/glib-2.0/codegen/codegen_main.py +1 -1
  362. data/vendor/local/share/glib-2.0/codegen/codegen_main.pyc +0 -0
  363. data/vendor/local/share/glib-2.0/codegen/codegen_main.pyo +0 -0
  364. data/vendor/local/share/glib-2.0/codegen/config.py +2 -5
  365. data/vendor/local/share/glib-2.0/codegen/config.pyc +0 -0
  366. data/vendor/local/share/glib-2.0/codegen/config.pyo +0 -0
  367. data/vendor/local/share/glib-2.0/codegen/dbustypes.py +1 -1
  368. data/vendor/local/share/glib-2.0/codegen/dbustypes.pyc +0 -0
  369. data/vendor/local/share/glib-2.0/codegen/dbustypes.pyo +0 -0
  370. data/vendor/local/share/glib-2.0/codegen/parser.py +1 -1
  371. data/vendor/local/share/glib-2.0/codegen/parser.pyc +0 -0
  372. data/vendor/local/share/glib-2.0/codegen/parser.pyo +0 -0
  373. data/vendor/local/share/glib-2.0/codegen/utils.py +1 -1
  374. data/vendor/local/share/glib-2.0/codegen/utils.pyc +0 -0
  375. data/vendor/local/share/glib-2.0/codegen/utils.pyo +0 -0
  376. data/vendor/local/share/glib-2.0/schemas/gschemas.compiled +0 -0
  377. data/vendor/local/share/glib-2.0/valgrind/glib.supp +10 -0
  378. data/vendor/local/share/gtk-doc/html/gio/GApplication.html +1 -1
  379. data/vendor/local/share/gtk-doc/html/gio/GAsyncInitable.html +12 -5
  380. data/vendor/local/share/gtk-doc/html/gio/GDBusInterfaceSkeleton.html +1 -1
  381. data/vendor/local/share/gtk-doc/html/gio/GDBusObject.html +3 -2
  382. data/vendor/local/share/gtk-doc/html/gio/GDataInputStream.html +8 -8
  383. data/vendor/local/share/gtk-doc/html/gio/GFile.html +9 -7
  384. data/vendor/local/share/gtk-doc/html/gio/GInitable.html +23 -5
  385. data/vendor/local/share/gtk-doc/html/gio/GInputStream.html +6 -4
  386. data/vendor/local/share/gtk-doc/html/gio/GMount.html +2 -2
  387. data/vendor/local/share/gtk-doc/html/gio/GNetworkMonitor.html +4 -2
  388. data/vendor/local/share/gtk-doc/html/gio/GProxyResolver.html +3 -0
  389. data/vendor/local/share/gtk-doc/html/gio/GResource.html +23 -11
  390. data/vendor/local/share/gtk-doc/html/gio/GSettings.html +1 -2
  391. data/vendor/local/share/gtk-doc/html/gio/GSocket.html +3 -3
  392. data/vendor/local/share/gtk-doc/html/gio/GSocketListener.html +4 -4
  393. data/vendor/local/share/gtk-doc/html/gio/GSubprocessLauncher.html +6 -2
  394. data/vendor/local/share/gtk-doc/html/gio/GTlsInteraction.html +1 -1
  395. data/vendor/local/share/gtk-doc/html/gio/api-index-full.html +10 -2
  396. data/vendor/local/share/gtk-doc/html/gio/gdbus.html +38 -0
  397. data/vendor/local/share/gtk-doc/html/gio/gio-D-Bus-Introspection-Data.html +4 -4
  398. data/vendor/local/share/gtk-doc/html/gio/gio-D-Bus-Utilities.html +5 -1
  399. data/vendor/local/share/gtk-doc/html/gio/gio-Extension-Points.html +1 -1
  400. data/vendor/local/share/gtk-doc/html/gio/gio-GIOError.html +2 -0
  401. data/vendor/local/share/gtk-doc/html/gio/gio-GWin32RegistryKey.html +4 -4
  402. data/vendor/local/share/gtk-doc/html/gio/gio-Owning-Bus-Names.html +8 -0
  403. data/vendor/local/share/gtk-doc/html/gio/gio-Unix-Mounts.html +138 -64
  404. data/vendor/local/share/gtk-doc/html/gio/gio-hierarchy.html +3 -1
  405. data/vendor/local/share/gtk-doc/html/gio/gio.devhelp2 +7 -4
  406. data/vendor/local/share/gtk-doc/html/gio/gresource-tool.html +1 -1
  407. data/vendor/local/share/gtk-doc/html/gio/index.html +1 -1
  408. data/vendor/local/share/gtk-doc/html/glib/annotation-glossary.html +2 -2
  409. data/vendor/local/share/gtk-doc/html/glib/api-index-full.html +24 -0
  410. data/vendor/local/share/gtk-doc/html/glib/glib-Arrays.html +5 -2
  411. data/vendor/local/share/gtk-doc/html/glib/glib-Date-and-Time-Functions.html +10 -1
  412. data/vendor/local/share/gtk-doc/html/glib/glib-Doubly-Linked-Lists.html +1 -1
  413. data/vendor/local/share/gtk-doc/html/glib/glib-Error-Reporting.html +7 -3
  414. data/vendor/local/share/gtk-doc/html/glib/glib-GVariant.html +11 -10
  415. data/vendor/local/share/gtk-doc/html/glib/glib-GVariantType.html +5 -4
  416. data/vendor/local/share/gtk-doc/html/glib/glib-Hash-Tables.html +5 -2
  417. data/vendor/local/share/gtk-doc/html/glib/glib-IO-Channels.html +9 -7
  418. data/vendor/local/share/gtk-doc/html/glib/glib-Message-Logging.html +30 -5
  419. data/vendor/local/share/gtk-doc/html/glib/glib-Miscellaneous-Utility-Functions.html +43 -29
  420. data/vendor/local/share/gtk-doc/html/glib/glib-Pointer-Arrays.html +146 -1
  421. data/vendor/local/share/gtk-doc/html/glib/glib-Sequences.html +38 -19
  422. data/vendor/local/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html +4 -1
  423. data/vendor/local/share/gtk-doc/html/glib/glib-Spawning-Processes.html +103 -13
  424. data/vendor/local/share/gtk-doc/html/glib/glib-String-Utility-Functions.html +254 -1
  425. data/vendor/local/share/gtk-doc/html/glib/glib-UNIX-specific-utilities-and-integration.html +1 -1
  426. data/vendor/local/share/gtk-doc/html/glib/glib-URI-Functions.html +1 -1
  427. data/vendor/local/share/gtk-doc/html/glib/glib-Unicode-Manipulation.html +34 -1
  428. data/vendor/local/share/gtk-doc/html/glib/glib-Version-Information.html +2 -2
  429. data/vendor/local/share/gtk-doc/html/glib/glib-running.html +6 -7
  430. data/vendor/local/share/gtk-doc/html/glib/glib.devhelp2 +13 -0
  431. data/vendor/local/share/gtk-doc/html/glib/glib.html +1 -1
  432. data/vendor/local/share/gtk-doc/html/glib/gvariant-format-strings.html +94 -39
  433. data/vendor/local/share/gtk-doc/html/glib/index.html +1 -1
  434. data/vendor/local/share/gtk-doc/html/gobject/api-index-full.html +20 -0
  435. data/vendor/local/share/gtk-doc/html/gobject/glib-genmarshal.html +81 -14
  436. data/vendor/local/share/gtk-doc/html/gobject/gobject-Enumeration-and-Flag-Types.html +95 -0
  437. data/vendor/local/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html +191 -3
  438. data/vendor/local/share/gtk-doc/html/gobject/gobject.devhelp2 +7 -2
  439. data/vendor/local/share/gtk-doc/html/gobject/gtype-non-instantiable-classed.html +2 -2
  440. data/vendor/local/share/gtk-doc/html/gobject/howto-interface-prerequisite.html +1 -1
  441. data/vendor/local/share/gtk-doc/html/gobject/howto-interface.html +1 -1
  442. data/vendor/local/share/gtk-doc/html/gobject/index.html +1 -1
  443. data/vendor/local/share/gtk-doc/html/gobject/signal.html +1 -1
  444. data/vendor/local/share/license/glib/COPYING +118 -98
  445. data/vendor/local/share/locale/be/LC_MESSAGES/glib-networking.mo +0 -0
  446. data/vendor/local/share/locale/bg/LC_MESSAGES/glib-networking.mo +0 -0
  447. data/vendor/local/share/locale/ca/LC_MESSAGES/glib-networking.mo +0 -0
  448. data/vendor/local/share/locale/ca/LC_MESSAGES/glib20.mo +0 -0
  449. data/vendor/local/share/locale/cs/LC_MESSAGES/glib-networking.mo +0 -0
  450. data/vendor/local/share/locale/cs/LC_MESSAGES/glib20.mo +0 -0
  451. data/vendor/local/share/locale/da/LC_MESSAGES/glib-networking.mo +0 -0
  452. data/vendor/local/share/locale/da/LC_MESSAGES/glib20.mo +0 -0
  453. data/vendor/local/share/locale/de/LC_MESSAGES/glib-networking.mo +0 -0
  454. data/vendor/local/share/locale/de/LC_MESSAGES/glib20.mo +0 -0
  455. data/vendor/local/share/locale/eo/LC_MESSAGES/glib-networking.mo +0 -0
  456. data/vendor/local/share/locale/eo/LC_MESSAGES/glib20.mo +0 -0
  457. data/vendor/local/share/locale/es/LC_MESSAGES/glib-networking.mo +0 -0
  458. data/vendor/local/share/locale/es/LC_MESSAGES/glib20.mo +0 -0
  459. data/vendor/local/share/locale/eu/LC_MESSAGES/glib-networking.mo +0 -0
  460. data/vendor/local/share/locale/eu/LC_MESSAGES/glib20.mo +0 -0
  461. data/vendor/local/share/locale/fi/LC_MESSAGES/glib20.mo +0 -0
  462. data/vendor/local/share/locale/fr/LC_MESSAGES/glib-networking.mo +0 -0
  463. data/vendor/local/share/locale/fr/LC_MESSAGES/glib20.mo +0 -0
  464. data/vendor/local/share/locale/fur/LC_MESSAGES/glib-networking.mo +0 -0
  465. data/vendor/local/share/locale/fur/LC_MESSAGES/glib20.mo +0 -0
  466. data/vendor/local/share/locale/gl/LC_MESSAGES/glib-networking.mo +0 -0
  467. data/vendor/local/share/locale/gl/LC_MESSAGES/glib20.mo +0 -0
  468. data/vendor/local/share/locale/he/LC_MESSAGES/glib20.mo +0 -0
  469. data/vendor/local/share/locale/hr/LC_MESSAGES/glib-networking.mo +0 -0
  470. data/vendor/local/share/locale/hu/LC_MESSAGES/glib-networking.mo +0 -0
  471. data/vendor/local/share/locale/hu/LC_MESSAGES/glib20.mo +0 -0
  472. data/vendor/local/share/locale/id/LC_MESSAGES/glib-networking.mo +0 -0
  473. data/vendor/local/share/locale/id/LC_MESSAGES/glib20.mo +0 -0
  474. data/vendor/local/share/locale/it/LC_MESSAGES/glib-networking.mo +0 -0
  475. data/vendor/local/share/locale/it/LC_MESSAGES/glib20.mo +0 -0
  476. data/vendor/local/share/locale/kk/LC_MESSAGES/glib-networking.mo +0 -0
  477. data/vendor/local/share/locale/kk/LC_MESSAGES/glib20.mo +0 -0
  478. data/vendor/local/share/locale/ko/LC_MESSAGES/glib-networking.mo +0 -0
  479. data/vendor/local/share/locale/ko/LC_MESSAGES/glib20.mo +0 -0
  480. data/vendor/local/share/locale/lt/LC_MESSAGES/glib-networking.mo +0 -0
  481. data/vendor/local/share/locale/lt/LC_MESSAGES/glib20.mo +0 -0
  482. data/vendor/local/share/locale/lv/LC_MESSAGES/glib-networking.mo +0 -0
  483. data/vendor/local/share/locale/lv/LC_MESSAGES/glib20.mo +0 -0
  484. data/vendor/local/share/locale/ml/LC_MESSAGES/glib-networking.mo +0 -0
  485. data/vendor/local/share/locale/ne/LC_MESSAGES/glib-networking.mo +0 -0
  486. data/vendor/local/share/locale/ne/LC_MESSAGES/glib20.mo +0 -0
  487. data/vendor/local/share/locale/nl/LC_MESSAGES/glib-networking.mo +0 -0
  488. data/vendor/local/share/locale/pl/LC_MESSAGES/glib-networking.mo +0 -0
  489. data/vendor/local/share/locale/pl/LC_MESSAGES/glib20.mo +0 -0
  490. data/vendor/local/share/locale/pt_BR/LC_MESSAGES/glib-networking.mo +0 -0
  491. data/vendor/local/share/locale/pt_BR/LC_MESSAGES/glib20.mo +0 -0
  492. data/vendor/local/share/locale/ro/LC_MESSAGES/glib20.mo +0 -0
  493. data/vendor/local/share/locale/sk/LC_MESSAGES/glib-networking.mo +0 -0
  494. data/vendor/local/share/locale/sl/LC_MESSAGES/glib-networking.mo +0 -0
  495. data/vendor/local/share/locale/sl/LC_MESSAGES/glib20.mo +0 -0
  496. data/vendor/local/share/locale/sr/LC_MESSAGES/glib-networking.mo +0 -0
  497. data/vendor/local/share/locale/sr/LC_MESSAGES/glib20.mo +0 -0
  498. data/vendor/local/share/locale/sr@latin/LC_MESSAGES/glib-networking.mo +0 -0
  499. data/vendor/local/share/locale/sr@latin/LC_MESSAGES/glib20.mo +0 -0
  500. data/vendor/local/share/locale/sv/LC_MESSAGES/glib-networking.mo +0 -0
  501. data/vendor/local/share/locale/sv/LC_MESSAGES/glib20.mo +0 -0
  502. data/vendor/local/share/locale/tr/LC_MESSAGES/glib-networking.mo +0 -0
  503. data/vendor/local/share/locale/tr/LC_MESSAGES/glib20.mo +0 -0
  504. data/vendor/local/share/locale/zh_TW/LC_MESSAGES/glib-networking.mo +0 -0
  505. data/vendor/local/share/man/man1/gapplication.1 +1 -1
  506. data/vendor/local/share/man/man1/gdbus-codegen.1 +1 -1
  507. data/vendor/local/share/man/man1/gdbus.1 +66 -1
  508. data/vendor/local/share/man/man1/gio-querymodules.1 +1 -1
  509. data/vendor/local/share/man/man1/gio.1 +1 -1
  510. data/vendor/local/share/man/man1/glib-compile-resources.1 +1 -1
  511. data/vendor/local/share/man/man1/glib-compile-schemas.1 +1 -1
  512. data/vendor/local/share/man/man1/glib-genmarshal.1 +99 -19
  513. data/vendor/local/share/man/man1/glib-gettextize.1 +1 -1
  514. data/vendor/local/share/man/man1/glib-mkenums.1 +1 -1
  515. data/vendor/local/share/man/man1/gobject-query.1 +1 -1
  516. data/vendor/local/share/man/man1/gresource.1 +2 -2
  517. data/vendor/local/share/man/man1/gsettings.1 +1 -1
  518. data/vendor/local/share/man/man1/gtester-report.1 +1 -1
  519. data/vendor/local/share/man/man1/gtester.1 +1 -1
  520. metadata +9 -7
  521. data/vendor/local/bin/glib-genmarshal.exe +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9671e4ca4ee91e3ef9fd84e9bd523c0e69afcbe2
4
- data.tar.gz: ee78397512a043e99c104ca75e15e8f307b6517d
3
+ metadata.gz: 2208ebf97c755370e7f676a2e6014e8fcbd12ebc
4
+ data.tar.gz: 4e653ec74d150ecee242487239de232c4dede483
5
5
  SHA512:
6
- metadata.gz: 707570c6789a124aaaa7e97c99168d0c53348bae41675bc3ca62d10174292304daeabf2d9f796055a62dc15c2af7cfb015978a76d3b20c8b319e891177453c82
7
- data.tar.gz: ee48de49bc231f5184629ca709a2fdb950df43f3b223bddb17572d6d15efe3080def8a46ce0e2eaa34667e00b1bb12d7458e17fbd70ee0d238ff8ee15abca47e
6
+ metadata.gz: 5c50207d0eff0d61bc6f8947b4245efaad49d431857878cdde74ade782fc24ed7c535d3eff58e98c9511f0649f78100b97dbfc5d2ce10d371263d11d951ef00c
7
+ data.tar.gz: 80db6e85623b6240ee2688a78f0fc2ec098a4b49709f5b1d92c0cc4f7fc7fe461bacb1bd4ee66decb9fbf44a565311d4ba0be3bbf4d15cde5486e9257fd5ee51
data/Rakefile CHANGED
@@ -88,12 +88,12 @@ package_task = GNOME2::Rake::PackageTask.new do |package|
88
88
  :name => "glib",
89
89
  :download_site => :gnome,
90
90
  :label => "GLib",
91
- :version => "2.52.3",
91
+ :version => "2.54.1",
92
92
  :compression_method => "xz",
93
93
  :windows => {
94
94
  :need_autoreconf => true,
95
95
  :patches => [
96
- "glib-2.48.0-add-missing-exeext.diff",
96
+ "glib-2.54.1-add-missing-exeext.diff",
97
97
  ],
98
98
  :built_file => "bin/libglib-2.0-0.dll",
99
99
  },
@@ -171,7 +171,7 @@ package_task = GNOME2::Rake::PackageTask.new do |package|
171
171
  :name => "glib-networking",
172
172
  :download_site => :gnome,
173
173
  :label => "glib-networking",
174
- :version => "2.50.0",
174
+ :version => "2.54.0",
175
175
  :compression_method => "xz",
176
176
  :windows => {
177
177
  :configure_args => [
@@ -185,7 +185,7 @@ package_task = GNOME2::Rake::PackageTask.new do |package|
185
185
  ]
186
186
  package.cross_compiling do |spec|
187
187
  if /mingw|mswin/ =~ spec.platform.to_s
188
- spec.add_runtime_dependency("cairo", ">= 1.12.8")
188
+ spec.add_runtime_dependency("cairo", ">= 1.15.9")
189
189
  end
190
190
  end
191
191
  end
data/ext/glib2/rbglib.h CHANGED
@@ -36,7 +36,7 @@ extern "C" {
36
36
 
37
37
  #define RBGLIB_MAJOR_VERSION 3
38
38
  #define RBGLIB_MINOR_VERSION 1
39
- #define RBGLIB_MICRO_VERSION 8
39
+ #define RBGLIB_MICRO_VERSION 9
40
40
 
41
41
  #ifndef RB_ZALLOC
42
42
  # ifdef ZALLOC
data/lib/2.2/glib2.so CHANGED
Binary file
data/lib/2.3/glib2.so CHANGED
Binary file
data/lib/2.4/glib2.so CHANGED
Binary file
@@ -305,6 +305,7 @@ module GNOME2
305
305
  :include_paths,
306
306
  :library_paths,
307
307
  :configure_args,
308
+ :meson_args,
308
309
  :cmake_args,
309
310
  :cc_args,
310
311
  :patches,
@@ -338,6 +339,10 @@ module GNOME2
338
339
  super || []
339
340
  end
340
341
 
342
+ def meson_args
343
+ super || []
344
+ end
345
+
341
346
  def cmake_args
342
347
  super || []
343
348
  end
@@ -4,6 +4,8 @@
4
4
 
5
5
  require "open-uri"
6
6
  require "pathname"
7
+ require "tempfile"
8
+ require "tmpdir"
7
9
 
8
10
  module GNOME2
9
11
  module Rake
@@ -122,11 +124,6 @@ module GNOME2
122
124
  package.windows.patches.each do |patch|
123
125
  sh("patch -p1 < #{@package.patches_dir}/#{patch}")
124
126
  end
125
- if File.exist?("configure")
126
- configure(package)
127
- else
128
- cmake(package)
129
- end
130
127
  common_make_args = []
131
128
  common_make_args << "MAKE=make"
132
129
  common_make_args << "GLIB_COMPILE_SCHEMAS=glib-compile-schemas"
@@ -142,11 +139,29 @@ module GNOME2
142
139
  end
143
140
  ENV["GREP_OPTIONS"] = "--text"
144
141
  # ENV["GI_SCANNER_DEBUG"] = "save-temps"
145
- # build_make_args << "--debug"
146
- # build_make_args << "V=1"
147
- # build_make_args << "VERBOSE=1"
148
- sh("nice", "make", *build_make_args) or exit(false)
149
- sh("make", "install", *install_make_args) or exit(false)
142
+ if File.exist?("meson.build") and not File.exist?("Makefile.am")
143
+ source_dir = Dir.pwd
144
+ build_dir = "build"
145
+ mkdir_p(build_dir)
146
+ Dir.chdir(build_dir) do
147
+ meson(package, source_dir)
148
+ sh(make_args_to_env(build_make_args),
149
+ "nice", "ninja") or exit(false)
150
+ sh(make_args_to_env(install_make_args),
151
+ "ninja", "install") or exit(false)
152
+ end
153
+ else
154
+ if File.exist?("Makefile.in")
155
+ configure(package)
156
+ else
157
+ cmake(package)
158
+ end
159
+ # build_make_args << "--debug"
160
+ # build_make_args << "V=1"
161
+ # build_make_args << "VERBOSE=1"
162
+ sh("nice", "make", *build_make_args) or exit(false)
163
+ sh("make", "install", *install_make_args) or exit(false)
164
+ end
150
165
 
151
166
  package_license_dir = license_dir + package.name
152
167
  mkdir_p(package_license_dir)
@@ -180,6 +195,37 @@ module GNOME2
180
195
  *package.windows.configure_args) or exit(false)
181
196
  end
182
197
 
198
+ def meson(package, source_dir)
199
+ cross_file = Tempfile.new("meson-cross-file")
200
+ cross_file.puts(<<-CROSS_FILE)
201
+ [host_machine]
202
+ system = 'windows'
203
+ cpu_family = 'x86_64'
204
+ cpu = 'x86_64'
205
+ endian = 'littel'
206
+
207
+ [binaries]
208
+ c = '/usr/bin/#{cc(package)}'
209
+ cpp = '/usr/bin/#{cxx(package)}'
210
+ ar = '/usr/bin/#{ar}'
211
+ strip = '/usr/bin/#{strip}'
212
+ dlltool = '/usr/bin/#{dlltool}'
213
+ pkgconfig = '/usr/bin/pkg-config'
214
+ CROSS_FILE
215
+ cross_file.close
216
+ sh({
217
+ "PATH" => "#{g_ir_scanner_bin_dir}:#{ENV["PATH"]}",
218
+ "CPPFLAGS" => cppflags(package),
219
+ "LDFLAGS" => ldflags(package),
220
+ },
221
+ "meson",
222
+ source_dir,
223
+ ".",
224
+ "--prefix=#{dist_dir}",
225
+ "--cross-file=#{cross_file.path}",
226
+ *package.windows.meson_args) or exit(false)
227
+ end
228
+
183
229
  def cmake(package)
184
230
  sh("cmake",
185
231
  ".",
@@ -255,10 +301,27 @@ module GNOME2
255
301
  cxx_command_line.compact.join(" ")
256
302
  end
257
303
 
304
+ def ar
305
+ "#{@package.windows.build_host}-ar"
306
+ end
307
+
308
+ def strip
309
+ "#{@package.windows.build_host}-strip"
310
+ end
311
+
258
312
  def dlltool
259
313
  "#{@package.windows.build_host}-dlltool"
260
314
  end
261
315
 
316
+ def g_ir_scanner_bin_dir
317
+ "#{@package.project_root_dir}/gobject-introspection/" +
318
+ "#{@package.native.relative_binary_dir}/bin"
319
+ end
320
+
321
+ def g_ir_scanner
322
+ "#{g_ir_scanner_bin_dir}/g-ir-scanner"
323
+ end
324
+
262
325
  def cppflags(package)
263
326
  include_paths = package.windows.include_paths
264
327
  if @package.windows.build_dependencies.include?("glib2")
@@ -300,11 +363,18 @@ module GNOME2
300
363
  paths
301
364
  end
302
365
 
366
+ def make_args_to_env(make_args)
367
+ env = {}
368
+ make_args.each do |arg|
369
+ key, value = arg.split("=", 2)
370
+ env[key] = value
371
+ end
372
+ env
373
+ end
374
+
303
375
  def add_gobject_introspection_make_args(package, common_make_args)
304
376
  return unless use_gobject_introspection?(package)
305
377
 
306
- g_ir_scanner = "#{@package.project_root_dir}/gobject-introspection/"
307
- g_ir_scanner << "#{@package.native.relative_binary_dir}/bin/g-ir-scanner"
308
378
  introspection_scanner = "INTROSPECTION_SCANNER=#{g_ir_scanner}"
309
379
  common_make_args << introspection_scanner
310
380
 
data/test/run-test.rb CHANGED
@@ -22,7 +22,7 @@ top = File.expand_path(File.join(base, ".."))
22
22
  $LOAD_PATH.unshift(top)
23
23
  require 'test/glib-test-init'
24
24
 
25
- if system("which make > /dev/null")
25
+ if File.exist?("#{top}/Makefile") and system("which make > /dev/null")
26
26
  system("cd #{top.dump} && make > /dev/null") or exit(1)
27
27
  end
28
28
 
Binary file
Binary file
Binary file
Binary file
@@ -1,4 +1,4 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env /usr/bin/python
2
2
 
3
3
  # GDBus - GLib D-Bus Library
4
4
  #
@@ -7,7 +7,7 @@
7
7
  # This library is free software; you can redistribute it and/or
8
8
  # modify it under the terms of the GNU Lesser General Public
9
9
  # License as published by the Free Software Foundation; either
10
- # version 2 of the License, or (at your option) any later version.
10
+ # version 2.1 of the License, or (at your option) any later version.
11
11
  #
12
12
  # This library is distributed in the hope that it will be useful,
13
13
  # but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -24,14 +24,18 @@ import os
24
24
  import sys
25
25
 
26
26
  srcdir = os.getenv('UNINSTALLED_GLIB_SRCDIR', None)
27
+ filedir = os.path.dirname(__file__)
27
28
 
28
29
  if srcdir is not None:
29
30
  path = os.path.join(srcdir, 'gio', 'gdbus-2.0')
30
- elif os.name == 'nt':
31
- # Makes gdbus-codegen 'relocatable' at runtime on Windows.
32
- path = os.path.join(os.path.dirname(__file__), '..', 'share', 'glib-2.0')
31
+ elif os.path.basename(filedir) == 'bin':
32
+ # Make the prefix containing gdbus-codegen 'relocatable' at runtime by
33
+ # adding /some/prefix/bin/../share/glib-2.0 to the python path
34
+ path = os.path.join(filedir, '..', 'share', 'glib-2.0')
33
35
  else:
34
- path = os.path.join('/home/vagrant/ruby-gnome2.win32/glib2/vendor/local/share', 'glib-2.0')
36
+ # Assume that the modules we need are in the current directory and add the
37
+ # parent directory to the python path.
38
+ path = os.path.join(filedir, '..')
35
39
 
36
40
  sys.path.insert(0, os.path.abspath(path))
37
41
  from codegen import codegen_main
Binary file
Binary file
Binary file
Binary file
@@ -0,0 +1,1056 @@
1
+ #!/usr/bin/env /usr/bin/python
2
+
3
+ # pylint: disable=too-many-lines, missing-docstring, invalid-name
4
+
5
+ # This file is part of GLib
6
+ #
7
+ # This library is free software; you can redistribute it and/or
8
+ # modify it under the terms of the GNU Lesser General Public
9
+ # License as published by the Free Software Foundation; either
10
+ # version 2.1 of the License, or (at your option) any later version.
11
+ #
12
+ # This library is distributed in the hope that it will be useful,
13
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15
+ # Lesser General Public License for more details.
16
+ #
17
+ # You should have received a copy of the GNU Lesser General Public
18
+ # License along with this library; if not, see <http://www.gnu.org/licenses/>.
19
+
20
+ import argparse
21
+ import os
22
+ import re
23
+ import sys
24
+
25
+ VERSION_STR = '''glib-genmarshal version 2.54.1
26
+ glib-genmarshal comes with ABSOLUTELY NO WARRANTY.
27
+ You may redistribute copies of glib-genmarshal under the terms of
28
+ the GNU General Public License which can be found in the
29
+ GLib source package. Sources, examples and contact
30
+ information are available at http://www.gtk.org'''
31
+
32
+ GETTERS_STR = '''#ifdef G_ENABLE_DEBUG
33
+ #define g_marshal_value_peek_boolean(v) g_value_get_boolean (v)
34
+ #define g_marshal_value_peek_char(v) g_value_get_schar (v)
35
+ #define g_marshal_value_peek_uchar(v) g_value_get_uchar (v)
36
+ #define g_marshal_value_peek_int(v) g_value_get_int (v)
37
+ #define g_marshal_value_peek_uint(v) g_value_get_uint (v)
38
+ #define g_marshal_value_peek_long(v) g_value_get_long (v)
39
+ #define g_marshal_value_peek_ulong(v) g_value_get_ulong (v)
40
+ #define g_marshal_value_peek_int64(v) g_value_get_int64 (v)
41
+ #define g_marshal_value_peek_uint64(v) g_value_get_uint64 (v)
42
+ #define g_marshal_value_peek_enum(v) g_value_get_enum (v)
43
+ #define g_marshal_value_peek_flags(v) g_value_get_flags (v)
44
+ #define g_marshal_value_peek_float(v) g_value_get_float (v)
45
+ #define g_marshal_value_peek_double(v) g_value_get_double (v)
46
+ #define g_marshal_value_peek_string(v) (char*) g_value_get_string (v)
47
+ #define g_marshal_value_peek_param(v) g_value_get_param (v)
48
+ #define g_marshal_value_peek_boxed(v) g_value_get_boxed (v)
49
+ #define g_marshal_value_peek_pointer(v) g_value_get_pointer (v)
50
+ #define g_marshal_value_peek_object(v) g_value_get_object (v)
51
+ #define g_marshal_value_peek_variant(v) g_value_get_variant (v)
52
+ #else /* !G_ENABLE_DEBUG */
53
+ /* WARNING: This code accesses GValues directly, which is UNSUPPORTED API.
54
+ * Do not access GValues directly in your code. Instead, use the
55
+ * g_value_get_*() functions
56
+ */
57
+ #define g_marshal_value_peek_boolean(v) (v)->data[0].v_int
58
+ #define g_marshal_value_peek_char(v) (v)->data[0].v_int
59
+ #define g_marshal_value_peek_uchar(v) (v)->data[0].v_uint
60
+ #define g_marshal_value_peek_int(v) (v)->data[0].v_int
61
+ #define g_marshal_value_peek_uint(v) (v)->data[0].v_uint
62
+ #define g_marshal_value_peek_long(v) (v)->data[0].v_long
63
+ #define g_marshal_value_peek_ulong(v) (v)->data[0].v_ulong
64
+ #define g_marshal_value_peek_int64(v) (v)->data[0].v_int64
65
+ #define g_marshal_value_peek_uint64(v) (v)->data[0].v_uint64
66
+ #define g_marshal_value_peek_enum(v) (v)->data[0].v_long
67
+ #define g_marshal_value_peek_flags(v) (v)->data[0].v_ulong
68
+ #define g_marshal_value_peek_float(v) (v)->data[0].v_float
69
+ #define g_marshal_value_peek_double(v) (v)->data[0].v_double
70
+ #define g_marshal_value_peek_string(v) (v)->data[0].v_pointer
71
+ #define g_marshal_value_peek_param(v) (v)->data[0].v_pointer
72
+ #define g_marshal_value_peek_boxed(v) (v)->data[0].v_pointer
73
+ #define g_marshal_value_peek_pointer(v) (v)->data[0].v_pointer
74
+ #define g_marshal_value_peek_object(v) (v)->data[0].v_pointer
75
+ #define g_marshal_value_peek_variant(v) (v)->data[0].v_pointer
76
+ #endif /* !G_ENABLE_DEBUG */'''
77
+
78
+ DEPRECATED_MSG_STR = 'The token "{}" is deprecated; use "{}" instead'
79
+
80
+ VA_ARG_STR = \
81
+ ' arg{:d} = ({:s}) va_arg (args_copy, {:s});'
82
+ STATIC_CHECK_STR = \
83
+ '(param_types[{:d}] & G_SIGNAL_TYPE_STATIC_SCOPE) == 0 && '
84
+ BOX_TYPED_STR = \
85
+ ' arg{idx:d} = {box_func} (param_types[{idx:d}] & ~G_SIGNAL_TYPE_STATIC_SCOPE, arg{idx:d});'
86
+ BOX_UNTYPED_STR = \
87
+ ' arg{idx:d} = {box_func} (arg{idx:d});'
88
+ UNBOX_TYPED_STR = \
89
+ ' {unbox_func} (param_types[{idx:d}] & ~G_SIGNAL_TYPE_STATIC_SCOPE, arg{idx:d});'
90
+ UNBOX_UNTYPED_STR = \
91
+ ' {unbox_func} (arg{idx:d});'
92
+
93
+ STD_PREFIX = 'g_cclosure_marshal'
94
+
95
+ # These are part of our ABI; keep this in sync with gmarshal.h
96
+ GOBJECT_MARSHALLERS = {
97
+ 'g_cclosure_marshal_VOID__VOID',
98
+ 'g_cclosure_marshal_VOID__BOOLEAN',
99
+ 'g_cclosure_marshal_VOID__CHAR',
100
+ 'g_cclosure_marshal_VOID__UCHAR',
101
+ 'g_cclosure_marshal_VOID__INT',
102
+ 'g_cclosure_marshal_VOID__UINT',
103
+ 'g_cclosure_marshal_VOID__LONG',
104
+ 'g_cclosure_marshal_VOID__ULONG',
105
+ 'g_cclosure_marshal_VOID__ENUM',
106
+ 'g_cclosure_marshal_VOID__FLAGS',
107
+ 'g_cclosure_marshal_VOID__FLOAT',
108
+ 'g_cclosure_marshal_VOID__DOUBLE',
109
+ 'g_cclosure_marshal_VOID__STRING',
110
+ 'g_cclosure_marshal_VOID__PARAM',
111
+ 'g_cclosure_marshal_VOID__BOXED',
112
+ 'g_cclosure_marshal_VOID__POINTER',
113
+ 'g_cclosure_marshal_VOID__OBJECT',
114
+ 'g_cclosure_marshal_VOID__VARIANT',
115
+ 'g_cclosure_marshal_VOID__UINT_POINTER',
116
+ 'g_cclosure_marshal_BOOLEAN__FLAGS',
117
+ 'g_cclosure_marshal_STRING__OBJECT_POINTER',
118
+ 'g_cclosure_marshal_BOOLEAN__BOXED_BOXED',
119
+ }
120
+
121
+
122
+ # pylint: disable=too-few-public-methods
123
+ class Color:
124
+ '''ANSI Terminal colors'''
125
+ GREEN = '\033[1;32m'
126
+ BLUE = '\033[1;34m'
127
+ YELLOW = '\033[1;33m'
128
+ RED = '\033[1;31m'
129
+ END = '\033[0m'
130
+
131
+
132
+ def print_color(msg, color=Color.END, prefix='MESSAGE'):
133
+ '''Print a string with a color prefix'''
134
+ if os.isatty(sys.stderr.fileno()):
135
+ real_prefix = '{start}{prefix}{end}'.format(start=color, prefix=prefix, end=Color.END)
136
+ else:
137
+ real_prefix = prefix
138
+ sys.stderr.write('{prefix}: {msg}\n'.format(prefix=real_prefix, msg=msg))
139
+
140
+
141
+ def print_error(msg):
142
+ '''Print an error, and terminate'''
143
+ print_color(msg, color=Color.RED, prefix='ERROR')
144
+ sys.exit(1)
145
+
146
+
147
+ def print_warning(msg, fatal=False):
148
+ '''Print a warning, and optionally terminate'''
149
+ if fatal:
150
+ color = Color.RED
151
+ prefix = 'ERROR'
152
+ else:
153
+ color = Color.YELLOW
154
+ prefix = 'WARNING'
155
+ print_color(msg, color, prefix)
156
+ if fatal:
157
+ sys.exit(1)
158
+
159
+
160
+ def print_info(msg):
161
+ '''Print a message'''
162
+ print_color(msg, color=Color.GREEN, prefix='INFO')
163
+
164
+
165
+ def generate_header_preamble(outfile, prefix='', std_includes=True, use_pragma=False):
166
+ '''Generate the preamble for the marshallers header file'''
167
+ outfile.write('/* This file is generated, all changes will be lost */\n')
168
+ if use_pragma:
169
+ outfile.write('#pragma once\n')
170
+ outfile.write('\n')
171
+ else:
172
+ outfile.write('#ifndef __{}_MARSHAL_H__\n'.format(prefix.upper()))
173
+ outfile.write('#define __{}_MARSHAL_H__\n'.format(prefix.upper()))
174
+ outfile.write('\n')
175
+ # Maintain compatibility with the old C-based tool
176
+ if std_includes:
177
+ outfile.write('#include <glib-object.h>\n')
178
+ outfile.write('\n')
179
+
180
+ outfile.write('G_BEGIN_DECLS\n')
181
+ outfile.write('\n')
182
+
183
+
184
+ def generate_header_postamble(outfile, prefix='', use_pragma=False):
185
+ '''Generate the postamble for the marshallers header file'''
186
+ outfile.write('\n')
187
+ outfile.write('G_END_DECLS\n')
188
+
189
+ if not use_pragma:
190
+ outfile.write('\n')
191
+ outfile.write('#endif /* __{}_MARSHAL_H__ */\n'.format(prefix.upper()))
192
+
193
+
194
+ def generate_body_preamble(outfile, std_includes=True, include_headers=None, cpp_defines=None, cpp_undefines=None):
195
+ '''Generate the preamble for the marshallers source file'''
196
+ for header in (include_headers or []):
197
+ outfile.write('#include "{}"\n'.format(header))
198
+ if include_headers:
199
+ outfile.write('\n')
200
+
201
+ for define in (cpp_defines or []):
202
+ s = define.split('=')
203
+ symbol = s[0]
204
+ value = s[1] if len(s) > 1 else '1'
205
+ outfile.write('#define {} {}\n'.format(symbol, value))
206
+ if cpp_defines:
207
+ outfile.write('\n')
208
+
209
+ for undefine in (cpp_undefines or []):
210
+ outfile.write('#undef {}\n'.format(undefine))
211
+ if cpp_undefines:
212
+ outfile.write('\n')
213
+
214
+ if std_includes:
215
+ outfile.write('#include <glib-object.h>\n')
216
+ outfile.write('\n')
217
+
218
+ outfile.write(GETTERS_STR)
219
+ outfile.write('\n\n')
220
+
221
+
222
+ # Marshaller arguments, as a dictionary where the key is the token used in
223
+ # the source file, and the value is another dictionary with the following
224
+ # keys:
225
+ #
226
+ # - signal: the token used in the marshaller prototype (mandatory)
227
+ # - ctype: the C type for the marshaller argument (mandatory)
228
+ # - getter: the function used to retrieve the argument from the GValue
229
+ # array when invoking the callback (optional)
230
+ # - promoted: the C type used by va_arg() to retrieve the argument from
231
+ # the va_list when invoking the callback (optional, only used when
232
+ # generating va_list marshallers)
233
+ # - box: an array of two elements, containing the boxing and unboxing
234
+ # functions for the given type (optional, only used when generating
235
+ # va_list marshallers)
236
+ # - static-check: a boolean value, if the given type should perform
237
+ # a static type check before boxing or unboxing the argument (optional,
238
+ # only used when generating va_list marshallers)
239
+ # - takes-type: a boolean value, if the boxing and unboxing functions
240
+ # for the given type require the type (optional, only used when
241
+ # generating va_list marshallers)
242
+ # - deprecated: whether the token has been deprecated (optional)
243
+ # - replaced-by: the token used to replace a deprecated token (optional,
244
+ # only used if deprecated is True)
245
+ IN_ARGS = {
246
+ 'VOID': {
247
+ 'signal': 'VOID',
248
+ 'ctype': 'void',
249
+ },
250
+ 'BOOLEAN': {
251
+ 'signal': 'BOOLEAN',
252
+ 'ctype': 'gboolean',
253
+ 'getter': 'g_marshal_value_peek_boolean',
254
+ },
255
+ 'CHAR': {
256
+ 'signal': 'CHAR',
257
+ 'ctype': 'gchar',
258
+ 'promoted': 'gint',
259
+ 'getter': 'g_marshal_value_peek_char',
260
+ },
261
+ 'UCHAR': {
262
+ 'signal': 'UCHAR',
263
+ 'ctype': 'guchar',
264
+ 'promoted': 'guint',
265
+ 'getter': 'g_marshal_value_peek_uchar',
266
+ },
267
+ 'INT': {
268
+ 'signal': 'INT',
269
+ 'ctype': 'gint',
270
+ 'getter': 'g_marshal_value_peek_int',
271
+ },
272
+ 'UINT': {
273
+ 'signal': 'UINT',
274
+ 'ctype': 'guint',
275
+ 'getter': 'g_marshal_value_peek_uint',
276
+ },
277
+ 'LONG': {
278
+ 'signal': 'LONG',
279
+ 'ctype': 'glong',
280
+ 'getter': 'g_marshal_value_peek_long',
281
+ },
282
+ 'ULONG': {
283
+ 'signal': 'ULONG',
284
+ 'ctype': 'gulong',
285
+ 'getter': 'g_marshal_value_peek_ulong',
286
+ },
287
+ 'INT64': {
288
+ 'signal': 'INT64',
289
+ 'ctype': 'gint64',
290
+ 'getter': 'g_marshal_value_peek_int64',
291
+ },
292
+ 'UINT64': {
293
+ 'signal': 'UINT64',
294
+ 'ctype': 'guint64',
295
+ 'getter': 'g_marshal_value_peek_uint64',
296
+ },
297
+ 'ENUM': {
298
+ 'signal': 'ENUM',
299
+ 'ctype': 'gint',
300
+ 'getter': 'g_marshal_value_peek_enum',
301
+ },
302
+ 'FLAGS': {
303
+ 'signal': 'FLAGS',
304
+ 'ctype': 'guint',
305
+ 'getter': 'g_marshal_value_peek_flags',
306
+ },
307
+ 'FLOAT': {
308
+ 'signal': 'FLOAT',
309
+ 'ctype': 'gfloat',
310
+ 'promoted': 'gdouble',
311
+ 'getter': 'g_marshal_value_peek_float',
312
+ },
313
+ 'DOUBLE': {
314
+ 'signal': 'DOUBLE',
315
+ 'ctype': 'gdouble',
316
+ 'getter': 'g_marshal_value_peek_double',
317
+ },
318
+ 'STRING': {
319
+ 'signal': 'STRING',
320
+ 'ctype': 'gpointer',
321
+ 'getter': 'g_marshal_value_peek_string',
322
+ 'box': ['g_strdup', 'g_free'],
323
+ },
324
+ 'PARAM': {
325
+ 'signal': 'PARAM',
326
+ 'ctype': 'gpointer',
327
+ 'getter': 'g_marshal_value_peek_param',
328
+ 'box': ['g_param_spec_ref', 'g_param_spec_unref'],
329
+ },
330
+ 'BOXED': {
331
+ 'signal': 'BOXED',
332
+ 'ctype': 'gpointer',
333
+ 'getter': 'g_marshal_value_peek_boxed',
334
+ 'box': ['g_boxed_copy', 'g_boxed_free'],
335
+ 'static-check': True,
336
+ 'takes-type': True,
337
+ },
338
+ 'POINTER': {
339
+ 'signal': 'POINTER',
340
+ 'ctype': 'gpointer',
341
+ 'getter': 'g_marshal_value_peek_pointer',
342
+ },
343
+ 'OBJECT': {
344
+ 'signal': 'OBJECT',
345
+ 'ctype': 'gpointer',
346
+ 'getter': 'g_marshal_value_peek_object',
347
+ 'box': ['g_object_ref', 'g_object_unref'],
348
+ },
349
+ 'VARIANT': {
350
+ 'signal': 'VARIANT',
351
+ 'ctype': 'gpointer',
352
+ 'getter': 'g_marshal_value_peek_variant',
353
+ 'box': ['g_variant_ref', 'g_variant_unref'],
354
+ 'static-check': True,
355
+ 'takes-type': False,
356
+ },
357
+
358
+ # Deprecated tokens
359
+ 'NONE': {
360
+ 'signal': 'VOID',
361
+ 'ctype': 'void',
362
+ 'deprecated': True,
363
+ 'replaced_by': 'VOID'
364
+ },
365
+ 'BOOL': {
366
+ 'signal': 'BOOLEAN',
367
+ 'ctype': 'gboolean',
368
+ 'getter': 'g_marshal_value_peek_boolean',
369
+ 'deprecated': True,
370
+ 'replaced_by': 'BOOLEAN'
371
+ }
372
+ }
373
+
374
+
375
+ # Marshaller return values, as a dictionary where the key is the token used
376
+ # in the source file, and the value is another dictionary with the following
377
+ # keys:
378
+ #
379
+ # - signal: the token used in the marshaller prototype (mandatory)
380
+ # - ctype: the C type for the marshaller argument (mandatory)
381
+ # - setter: the function used to set the return value of the callback
382
+ # into a GValue (optional)
383
+ # - deprecated: whether the token has been deprecated (optional)
384
+ # - replaced-by: the token used to replace a deprecated token (optional,
385
+ # only used if deprecated is True)
386
+ OUT_ARGS = {
387
+ 'VOID': {
388
+ 'signal': 'VOID',
389
+ 'ctype': 'void',
390
+ },
391
+ 'BOOLEAN': {
392
+ 'signal': 'BOOLEAN',
393
+ 'ctype': 'gboolean',
394
+ 'setter': 'g_value_set_boolean',
395
+ },
396
+ 'CHAR': {
397
+ 'signal': 'CHAR',
398
+ 'ctype': 'gchar',
399
+ 'setter': 'g_value_set_char',
400
+ },
401
+ 'UCHAR': {
402
+ 'signal': 'UCHAR',
403
+ 'ctype': 'guchar',
404
+ 'setter': 'g_value_set_uchar',
405
+ },
406
+ 'INT': {
407
+ 'signal': 'INT',
408
+ 'ctype': 'gint',
409
+ 'setter': 'g_value_set_int',
410
+ },
411
+ 'UINT': {
412
+ 'signal': 'UINT',
413
+ 'ctype': 'guint',
414
+ 'setter': 'g_value_set_uint',
415
+ },
416
+ 'LONG': {
417
+ 'signal': 'LONG',
418
+ 'ctype': 'glong',
419
+ 'setter': 'g_value_set_long',
420
+ },
421
+ 'ULONG': {
422
+ 'signal': 'ULONG',
423
+ 'ctype': 'gulong',
424
+ 'setter': 'g_value_set_ulong',
425
+ },
426
+ 'INT64': {
427
+ 'signal': 'INT64',
428
+ 'ctype': 'gint64',
429
+ 'setter': 'g_value_set_int64',
430
+ },
431
+ 'UINT64': {
432
+ 'signal': 'UINT64',
433
+ 'ctype': 'guint64',
434
+ 'setter': 'g_value_set_uint64',
435
+ },
436
+ 'ENUM': {
437
+ 'signal': 'ENUM',
438
+ 'ctype': 'gint',
439
+ 'setter': 'g_value_set_enum',
440
+ },
441
+ 'FLAGS': {
442
+ 'signal': 'FLAGS',
443
+ 'ctype': 'guint',
444
+ 'setter': 'g_value_set_flags',
445
+ },
446
+ 'FLOAT': {
447
+ 'signal': 'FLOAT',
448
+ 'ctype': 'gfloat',
449
+ 'setter': 'g_value_set_float',
450
+ },
451
+ 'DOUBLE': {
452
+ 'signal': 'DOUBLE',
453
+ 'ctype': 'gdouble',
454
+ 'setter': 'g_value_set_double',
455
+ },
456
+ 'STRING': {
457
+ 'signal': 'STRING',
458
+ 'ctype': 'gchar*',
459
+ 'setter': 'g_value_take_string',
460
+ },
461
+ 'PARAM': {
462
+ 'signal': 'PARAM',
463
+ 'ctype': 'GParamSpec*',
464
+ 'setter': 'g_value_take_param',
465
+ },
466
+ 'BOXED': {
467
+ 'signal': 'BOXED',
468
+ 'ctype': 'gpointer',
469
+ 'setter': 'g_value_take_boxed',
470
+ },
471
+ 'POINTER': {
472
+ 'signal': 'POINTER',
473
+ 'ctype': 'gpointer',
474
+ 'setter': 'g_value_set_pointer',
475
+ },
476
+ 'OBJECT': {
477
+ 'signal': 'OBJECT',
478
+ 'ctype': 'GObject*',
479
+ 'setter': 'g_value_take_object',
480
+ },
481
+ 'VARIANT': {
482
+ 'signal': 'VARIANT',
483
+ 'ctype': 'GVariant*',
484
+ 'setter': 'g_value_take_variant',
485
+ },
486
+
487
+ # Deprecated tokens
488
+ 'NONE': {
489
+ 'signal': 'VOID',
490
+ 'ctype': 'void',
491
+ 'setter': None,
492
+ 'deprecated': True,
493
+ 'replaced_by': 'VOID',
494
+ },
495
+ 'BOOL': {
496
+ 'signal': 'BOOLEAN',
497
+ 'ctype': 'gboolean',
498
+ 'setter': 'g_value_set_boolean',
499
+ 'deprecated': True,
500
+ 'replaced_by': 'BOOLEAN',
501
+ },
502
+ }
503
+
504
+
505
+ def check_args(retval, params, fatal_warnings=False):
506
+ '''Check the @retval and @params tokens for invalid and deprecated symbols.'''
507
+ if retval not in OUT_ARGS:
508
+ print_error('Unknown return value type "{}"'.format(retval))
509
+
510
+ if OUT_ARGS[retval].get('deprecated', False):
511
+ replaced_by = OUT_ARGS[retval]['replaced_by']
512
+ print_warning(DEPRECATED_MSG_STR.format(retval, replaced_by), fatal_warnings)
513
+
514
+ for param in params:
515
+ if param not in IN_ARGS:
516
+ print_error('Unknown parameter type "{}"'.format(param))
517
+ else:
518
+ if IN_ARGS[param].get('deprecated', False):
519
+ replaced_by = IN_ARGS[param]['replaced_by']
520
+ print_warning(DEPRECATED_MSG_STR.format(param, replaced_by), fatal_warnings)
521
+
522
+
523
+ def indent(text, level=0, fill=' '):
524
+ '''Indent @text by @level columns, using the @fill character'''
525
+ return ''.join([fill for x in range(level)]) + text
526
+
527
+
528
+ # pylint: disable=too-few-public-methods
529
+ class Visibility:
530
+ '''Symbol visibility options'''
531
+ NONE = 0
532
+ INTERNAL = 1
533
+ EXTERN = 2
534
+
535
+
536
+ def generate_marshaller_name(prefix, retval, params, replace_deprecated=True):
537
+ '''Generate a marshaller name for the given @prefix, @retval, and @params.
538
+ If @replace_deprecated is True, the generated name will replace deprecated
539
+ tokens.'''
540
+ if replace_deprecated:
541
+ real_retval = OUT_ARGS[retval]['signal']
542
+ real_params = []
543
+ for param in params:
544
+ real_params.append(IN_ARGS[param]['signal'])
545
+ else:
546
+ real_retval = retval
547
+ real_params = params
548
+ return '{prefix}_{retval}__{args}'.format(prefix=prefix,
549
+ retval=real_retval,
550
+ args='_'.join(real_params))
551
+
552
+
553
+ def generate_prototype(retval, params,
554
+ prefix='g_cclosure_user_marshal',
555
+ visibility=Visibility.NONE,
556
+ va_marshal=False):
557
+ '''Generate a marshaller declaration with the given @visibility. If @va_marshal
558
+ is True, the marshaller will use variadic arguments in place of a GValue array.'''
559
+ signature = []
560
+
561
+ if visibility == Visibility.INTERNAL:
562
+ signature += ['G_GNUC_INTERNAL']
563
+ elif visibility == Visibility.EXTERN:
564
+ signature += ['extern']
565
+
566
+ function_name = generate_marshaller_name(prefix, retval, params)
567
+
568
+ if not va_marshal:
569
+ signature += ['void ' + function_name + ' (GClosure *closure,']
570
+ width = len('void ') + len(function_name) + 2
571
+
572
+ signature += [indent('GValue *return_value,', level=width, fill=' ')]
573
+ signature += [indent('guint n_param_values,', level=width, fill=' ')]
574
+ signature += [indent('const GValue *param_values,', level=width, fill=' ')]
575
+ signature += [indent('gpointer invocation_hint,', level=width, fill=' ')]
576
+ signature += [indent('gpointer marshal_data);', level=width, fill=' ')]
577
+ else:
578
+ signature += ['void ' + function_name + 'v (GClosure *closure,']
579
+ width = len('void ') + len(function_name) + 3
580
+
581
+ signature += [indent('GValue *return_value,', level=width, fill=' ')]
582
+ signature += [indent('gpointer instance,', level=width, fill=' ')]
583
+ signature += [indent('va_list args,', level=width, fill=' ')]
584
+ signature += [indent('gpointer marshal_data,', level=width, fill=' ')]
585
+ signature += [indent('int n_params,', level=width, fill=' ')]
586
+ signature += [indent('GType *param_types);', level=width, fill=' ')]
587
+
588
+ return signature
589
+
590
+
591
+ # pylint: disable=too-many-statements, too-many-locals, too-many-branches
592
+ def generate_body(retval, params, prefix, va_marshal=False):
593
+ '''Generate a marshaller definition. If @va_marshal is True, the marshaller
594
+ will use va_list and variadic arguments in place of a GValue array.'''
595
+ retval_setter = OUT_ARGS[retval].get('setter', None)
596
+ # If there's no return value then we can mark the retval argument as unused
597
+ # and get a minor optimisation, as well as avoid a compiler warning
598
+ if not retval_setter:
599
+ unused = ' G_GNUC_UNUSED'
600
+ else:
601
+ unused = ''
602
+
603
+ body = ['void']
604
+
605
+ function_name = generate_marshaller_name(prefix, retval, params)
606
+
607
+ if not va_marshal:
608
+ body += [function_name + ' (GClosure *closure,']
609
+ width = len(function_name) + 2
610
+
611
+ body += [indent('GValue *return_value{},'.format(unused), level=width, fill=' ')]
612
+ body += [indent('guint n_param_values,', level=width, fill=' ')]
613
+ body += [indent('const GValue *param_values,', level=width, fill=' ')]
614
+ body += [indent('gpointer invocation_hint G_GNUC_UNUSED,', level=width, fill=' ')]
615
+ body += [indent('gpointer marshal_data)', level=width, fill=' ')]
616
+ else:
617
+ body += [function_name + 'v (GClosure *closure,']
618
+ width = len(function_name) + 3
619
+
620
+ body += [indent('GValue *return_value{},'.format(unused), level=width, fill=' ')]
621
+ body += [indent('gpointer instance,', level=width, fill=' ')]
622
+ body += [indent('va_list args,', level=width, fill=' ')]
623
+ body += [indent('gpointer marshal_data,', level=width, fill=' ')]
624
+ body += [indent('int n_params,', level=width, fill=' ')]
625
+ body += [indent('GType *param_types)', level=width, fill=' ')]
626
+
627
+ # Filter the arguments that have a getter
628
+ get_args = [x for x in params if IN_ARGS[x].get('getter', None) is not None]
629
+
630
+ body += ['{']
631
+
632
+ # Generate the type of the marshaller function
633
+ typedef_marshal = generate_marshaller_name('GMarshalFunc', retval, params)
634
+
635
+ typedef = ' typedef {ctype} (*{func_name}) ('.format(ctype=OUT_ARGS[retval]['ctype'],
636
+ func_name=typedef_marshal)
637
+ pad = len(typedef)
638
+ typedef += 'gpointer data1,'
639
+ body += [typedef]
640
+
641
+ for idx, in_arg in enumerate(get_args):
642
+ body += [indent('{} arg{:d},'.format(IN_ARGS[in_arg]['ctype'], idx + 1), level=pad)]
643
+
644
+ body += [indent('gpointer data2);', level=pad)]
645
+
646
+ # Variable declarations
647
+ body += [' GCClosure *cc = (GCClosure *) closure;']
648
+ body += [' gpointer data1, data2;']
649
+ body += [' {} callback;'.format(typedef_marshal)]
650
+
651
+ if retval_setter:
652
+ body += [' {} v_return;'.format(OUT_ARGS[retval]['ctype'])]
653
+
654
+ if va_marshal:
655
+ for idx, arg in enumerate(get_args):
656
+ body += [' {} arg{:d};'.format(IN_ARGS[arg]['ctype'], idx)]
657
+
658
+ if get_args:
659
+ body += [' va_list args_copy;']
660
+ body += ['']
661
+
662
+ body += [' G_VA_COPY (args_copy, args);']
663
+
664
+ for idx, arg in enumerate(get_args):
665
+ ctype = IN_ARGS[arg]['ctype']
666
+ promoted_ctype = IN_ARGS[arg].get('promoted', ctype)
667
+ body += [VA_ARG_STR.format(idx, ctype, promoted_ctype)]
668
+ if IN_ARGS[arg].get('box', None):
669
+ box_func = IN_ARGS[arg]['box'][0]
670
+ if IN_ARGS[arg].get('static-check', False):
671
+ static_check = STATIC_CHECK_STR.format(idx)
672
+ else:
673
+ static_check = ''
674
+ arg_check = 'arg{:d} != NULL'.format(idx)
675
+ body += [' if ({}{})'.format(static_check, arg_check)]
676
+ if IN_ARGS[arg].get('takes-type', False):
677
+ body += [BOX_TYPED_STR.format(idx=idx, box_func=box_func)]
678
+ else:
679
+ body += [BOX_UNTYPED_STR.format(idx=idx, box_func=box_func)]
680
+
681
+ body += [' va_end (args_copy);']
682
+
683
+ body += ['']
684
+
685
+ # Preconditions check
686
+ if retval_setter:
687
+ body += [' g_return_if_fail (return_value != NULL);']
688
+
689
+ if not va_marshal:
690
+ body += [' g_return_if_fail (n_param_values == {:d});'.format(len(get_args) + 1)]
691
+
692
+ body += ['']
693
+
694
+ # Marshal instance, data, and callback set up
695
+ body += [' if (G_CCLOSURE_SWAP_DATA (closure))']
696
+ body += [' {']
697
+ body += [' data1 = closure->data;']
698
+ if va_marshal:
699
+ body += [' data2 = instance;']
700
+ else:
701
+ body += [' data2 = g_value_peek_pointer (param_values + 0);']
702
+ body += [' }']
703
+ body += [' else']
704
+ body += [' {']
705
+ if va_marshal:
706
+ body += [' data1 = instance;']
707
+ else:
708
+ body += [' data1 = g_value_peek_pointer (param_values + 0);']
709
+ body += [' data2 = closure->data;']
710
+ body += [' }']
711
+ # pylint: disable=line-too-long
712
+ body += [' callback = ({}) (marshal_data ? marshal_data : cc->callback);'.format(typedef_marshal)]
713
+ body += ['']
714
+
715
+ # Marshal callback action
716
+ if retval_setter:
717
+ callback = ' {} callback ('.format(' v_return =')
718
+ else:
719
+ callback = ' callback ('
720
+
721
+ pad = len(callback)
722
+ body += [callback + 'data1,']
723
+
724
+ if va_marshal:
725
+ for idx, arg in enumerate(get_args):
726
+ body += [indent('arg{:d},'.format(idx), level=pad)]
727
+ else:
728
+ for idx, arg in enumerate(get_args):
729
+ arg_getter = IN_ARGS[arg]['getter']
730
+ body += [indent('{} (param_values + {:d}),'.format(arg_getter, idx + 1), level=pad)]
731
+
732
+ body += [indent('data2);', level=pad)]
733
+
734
+ if va_marshal:
735
+ boxed_args = [x for x in get_args if IN_ARGS[x].get('box', None) is not None]
736
+ if not boxed_args:
737
+ body += ['']
738
+ else:
739
+ for idx, arg in enumerate(get_args):
740
+ if not IN_ARGS[arg].get('box', None):
741
+ continue
742
+ unbox_func = IN_ARGS[arg]['box'][1]
743
+ if IN_ARGS[arg].get('static-check', False):
744
+ static_check = STATIC_CHECK_STR.format(idx)
745
+ else:
746
+ static_check = ''
747
+ arg_check = 'arg{:d} != NULL'.format(idx)
748
+ body += [' if ({}{})'.format(static_check, arg_check)]
749
+ if IN_ARGS[arg].get('takes-type', False):
750
+ body += [UNBOX_TYPED_STR.format(idx=idx, unbox_func=unbox_func)]
751
+ else:
752
+ body += [UNBOX_UNTYPED_STR.format(idx=idx, unbox_func=unbox_func)]
753
+
754
+ if retval_setter:
755
+ body += ['']
756
+ body += [' {} (return_value, v_return);'.format(retval_setter)]
757
+
758
+ body += ['}']
759
+
760
+ return body
761
+
762
+
763
+ def generate_marshaller_alias(outfile, marshaller, real_marshaller,
764
+ include_va=False,
765
+ source_location=None):
766
+ '''Generate an alias between @marshaller and @real_marshaller, including
767
+ an optional alias for va_list marshallers'''
768
+ if source_location:
769
+ outfile.write('/* {} */\n'.format(source_location))
770
+
771
+ outfile.write('#define {}\t{}\n'.format(marshaller, real_marshaller))
772
+
773
+ if include_va:
774
+ outfile.write('#define {}v\t{}v\n'.format(marshaller, real_marshaller))
775
+
776
+ outfile.write('\n')
777
+
778
+
779
+ def generate_marshallers_header(outfile, retval, params,
780
+ prefix='g_cclosure_user_marshal',
781
+ internal=False,
782
+ include_va=False, source_location=None):
783
+ '''Generate a declaration for a marshaller function, to be used in the header,
784
+ with the given @retval, @params, and @prefix. An optional va_list marshaller
785
+ for the same arguments is also generated. The generated buffer is written to
786
+ the @outfile stream object.'''
787
+ if source_location:
788
+ outfile.write('/* {} */\n'.format(source_location))
789
+
790
+ if internal:
791
+ visibility = Visibility.INTERNAL
792
+ else:
793
+ visibility = Visibility.EXTERN
794
+
795
+ signature = generate_prototype(retval, params, prefix, visibility, False)
796
+ if include_va:
797
+ signature += generate_prototype(retval, params, prefix, visibility, True)
798
+ signature += ['']
799
+
800
+ outfile.write('\n'.join(signature))
801
+ outfile.write('\n')
802
+
803
+
804
+ def generate_marshallers_body(outfile, retval, params,
805
+ prefix='g_cclosure_user_marshal',
806
+ include_prototype=True,
807
+ internal=False,
808
+ include_va=False, source_location=None):
809
+ '''Generate a definition for a marshaller function, to be used in the source,
810
+ with the given @retval, @params, and @prefix. An optional va_list marshaller
811
+ for the same arguments is also generated. The generated buffer is written to
812
+ the @outfile stream object.'''
813
+ if source_location:
814
+ outfile.write('/* {} */\n'.format(source_location))
815
+
816
+ if include_prototype:
817
+ # Declaration visibility
818
+ if internal:
819
+ decl_visibility = Visibility.INTERNAL
820
+ else:
821
+ decl_visibility = Visibility.EXTERN
822
+ proto = ['/* Prototype for -Wmissing-prototypes */']
823
+ # Add C++ guards in case somebody compiles the generated code
824
+ # with a C++ compiler
825
+ proto += ['G_BEGIN_DECLS']
826
+ proto += generate_prototype(retval, params, prefix, decl_visibility, False)
827
+ proto += ['G_END_DECLS']
828
+ outfile.write('\n'.join(proto))
829
+ outfile.write('\n')
830
+
831
+ body = generate_body(retval, params, prefix, False)
832
+ outfile.write('\n'.join(body))
833
+ outfile.write('\n\n')
834
+
835
+ if include_va:
836
+ if include_prototype:
837
+ # Declaration visibility
838
+ if internal:
839
+ decl_visibility = Visibility.INTERNAL
840
+ else:
841
+ decl_visibility = Visibility.EXTERN
842
+ proto = ['/* Prototype for -Wmissing-prototypes */']
843
+ # Add C++ guards here as well
844
+ proto += ['G_BEGIN_DECLS']
845
+ proto += generate_prototype(retval, params, prefix, decl_visibility, True)
846
+ proto += ['G_END_DECLS']
847
+ outfile.write('\n'.join(proto))
848
+ outfile.write('\n')
849
+
850
+ body = generate_body(retval, params, prefix, True)
851
+ outfile.write('\n'.join(body))
852
+ outfile.write('\n\n')
853
+
854
+
855
+ if __name__ == '__main__':
856
+ arg_parser = argparse.ArgumentParser(description='Generate signal marshallers for GObject')
857
+ arg_parser.add_argument('--prefix', metavar='STRING',
858
+ default='g_cclosure_user_marshal',
859
+ help='Specify marshaller prefix')
860
+ arg_parser.add_argument('--output', metavar='FILE',
861
+ type=argparse.FileType('w'),
862
+ default=sys.stdout,
863
+ help='Write output into the specified file')
864
+ arg_parser.add_argument('--skip-source',
865
+ action='store_true',
866
+ help='Skip source location comments')
867
+ arg_parser.add_argument('--internal',
868
+ action='store_true',
869
+ help='Mark generated functions as internal')
870
+ arg_parser.add_argument('--valist-marshallers',
871
+ action='store_true',
872
+ help='Generate va_list marshallers')
873
+ arg_parser.add_argument('-v', '--version',
874
+ action='store_true',
875
+ dest='show_version',
876
+ help='Print version information, and exit')
877
+ arg_parser.add_argument('--g-fatal-warnings',
878
+ action='store_true',
879
+ dest='fatal_warnings',
880
+ help='Make warnings fatal')
881
+ arg_parser.add_argument('--include-header', metavar='HEADER', nargs='?',
882
+ action='append',
883
+ dest='include_headers',
884
+ help='Include the specified header in the body')
885
+ arg_parser.add_argument('--pragma-once',
886
+ action='store_true',
887
+ help='Use "pragma once" as the inclusion guard')
888
+ arg_parser.add_argument('-D',
889
+ action='append',
890
+ dest='cpp_defines',
891
+ default=[],
892
+ help='Pre-processor define')
893
+ arg_parser.add_argument('-U',
894
+ action='append',
895
+ dest='cpp_undefines',
896
+ default=[],
897
+ help='Pre-processor undefine')
898
+ arg_parser.add_argument('files', metavar='FILE', nargs='*',
899
+ type=argparse.FileType('r'),
900
+ help='Files with lists of marshallers to generate, ' +
901
+ 'or "-" for standard input')
902
+ arg_parser.add_argument('--prototypes',
903
+ action='store_true',
904
+ help='Generate the marshallers prototype in the C code')
905
+ arg_parser.add_argument('--header',
906
+ action='store_true',
907
+ help='Generate C headers')
908
+ arg_parser.add_argument('--body',
909
+ action='store_true',
910
+ help='Generate C code')
911
+
912
+ group = arg_parser.add_mutually_exclusive_group()
913
+ group.add_argument('--stdinc',
914
+ action='store_true',
915
+ dest='stdinc', default=True,
916
+ help='Include standard marshallers')
917
+ group.add_argument('--nostdinc',
918
+ action='store_false',
919
+ dest='stdinc', default=True,
920
+ help='Use standard marshallers')
921
+
922
+ group = arg_parser.add_mutually_exclusive_group()
923
+ group.add_argument('--quiet',
924
+ action='store_true',
925
+ help='Only print warnings and errors')
926
+ group.add_argument('--verbose',
927
+ action='store_true',
928
+ help='Be verbose, and include debugging information')
929
+
930
+ args = arg_parser.parse_args()
931
+
932
+ if args.show_version:
933
+ print(VERSION_STR)
934
+ sys.exit(0)
935
+
936
+ # Backward compatibility hack; some projects use both arguments to
937
+ # generate the marshallers prototype in the C source, even though
938
+ # it's not really a supported use case. We keep this behaviour by
939
+ # forcing the --prototypes and --body arguments instead. We make this
940
+ # warning non-fatal even with --g-fatal-warnings, as it's a deprecation
941
+ compatibility_mode = False
942
+ if args.header and args.body:
943
+ print_warning('Using --header and --body at the same time time is deprecated; ' +
944
+ 'use --body --prototypes instead', False)
945
+ args.prototypes = True
946
+ args.header = False
947
+ compatibility_mode = True
948
+
949
+ if args.header:
950
+ generate_header_preamble(args.output,
951
+ prefix=args.prefix,
952
+ std_includes=args.stdinc,
953
+ use_pragma=args.pragma_once)
954
+ elif args.body:
955
+ generate_body_preamble(args.output,
956
+ std_includes=args.stdinc,
957
+ include_headers=args.include_headers,
958
+ cpp_defines=args.cpp_defines,
959
+ cpp_undefines=args.cpp_undefines)
960
+
961
+ seen_marshallers = set()
962
+
963
+ for infile in args.files:
964
+ if not args.quiet:
965
+ print_info('Reading {}...'.format(infile.name))
966
+
967
+ line_count = 0
968
+ for line in infile:
969
+ line_count += 1
970
+
971
+ if line == '\n' or line.startswith('#'):
972
+ continue
973
+
974
+ matches = re.match(r'^([A-Z0-9]+)\s?:\s?([A-Z0-9,\s]+)$', line.strip())
975
+ if not matches or len(matches.groups()) != 2:
976
+ print_warning('Invalid entry: "{}"'.format(line.strip()), args.fatal_warnings)
977
+ continue
978
+
979
+ if not args.skip_source:
980
+ location = '{} ({}:{:d})'.format(line.strip(), infile.name, line_count)
981
+ else:
982
+ location = None
983
+
984
+ retval = matches.group(1).strip()
985
+ params = [x.strip() for x in matches.group(2).split(',')]
986
+ check_args(retval, params, args.fatal_warnings)
987
+
988
+ raw_marshaller = generate_marshaller_name(args.prefix, retval, params, False)
989
+ if raw_marshaller in seen_marshallers:
990
+ if args.verbose:
991
+ print_info('Skipping repeated marshaller {}'.format(line.strip()))
992
+ continue
993
+
994
+ if args.header:
995
+ if args.verbose:
996
+ print_info('Generating declaration for {}'.format(line.strip()))
997
+ generate_std_alias = False
998
+ if args.stdinc:
999
+ std_marshaller = generate_marshaller_name(STD_PREFIX, retval, params)
1000
+ if std_marshaller in GOBJECT_MARSHALLERS:
1001
+ if args.verbose:
1002
+ print_info('Skipping default marshaller {}'.format(line.strip()))
1003
+ generate_std_alias = True
1004
+
1005
+ marshaller = generate_marshaller_name(args.prefix, retval, params)
1006
+ if generate_std_alias:
1007
+ generate_marshaller_alias(args.output, marshaller, std_marshaller,
1008
+ source_location=location,
1009
+ include_va=args.valist_marshallers)
1010
+ else:
1011
+ generate_marshallers_header(args.output, retval, params,
1012
+ prefix=args.prefix,
1013
+ internal=args.internal,
1014
+ include_va=args.valist_marshallers,
1015
+ source_location=location)
1016
+ # If the marshaller is defined using a deprecated token, we want to maintain
1017
+ # compatibility and generate an alias for the old name pointing to the new
1018
+ # one
1019
+ if marshaller != raw_marshaller:
1020
+ if args.verbose:
1021
+ print_info('Generating alias for deprecated tokens')
1022
+ generate_marshaller_alias(args.output, raw_marshaller, marshaller,
1023
+ include_va=args.valist_marshallers)
1024
+ elif args.body:
1025
+ if args.verbose:
1026
+ print_info('Generating definition for {}'.format(line.strip()))
1027
+ if compatibility_mode:
1028
+ generate_std_alias = False
1029
+ if args.stdinc:
1030
+ std_marshaller = generate_marshaller_name(STD_PREFIX, retval, params)
1031
+ if std_marshaller in GOBJECT_MARSHALLERS:
1032
+ if args.verbose:
1033
+ print_info('Skipping default marshaller {}'.format(line.strip()))
1034
+ generate_std_alias = True
1035
+ marshaller = generate_marshaller_name(args.prefix, retval, params)
1036
+ if compatibility_mode and generate_std_alias:
1037
+ generate_marshaller_alias(args.output, marshaller, std_marshaller,
1038
+ source_location=location,
1039
+ include_va=args.valist_marshallers)
1040
+ else:
1041
+ generate_marshallers_body(args.output, retval, params,
1042
+ prefix=args.prefix,
1043
+ internal=args.internal,
1044
+ include_prototype=args.prototypes,
1045
+ include_va=args.valist_marshallers,
1046
+ source_location=location)
1047
+ if compatibility_mode and marshaller != raw_marshaller:
1048
+ if args.verbose:
1049
+ print_info('Generating alias for deprecated tokens')
1050
+ generate_marshaller_alias(args.output, raw_marshaller, marshaller,
1051
+ include_va=args.valist_marshallers)
1052
+
1053
+ seen_marshallers.add(raw_marshaller)
1054
+
1055
+ if args.header:
1056
+ generate_header_postamble(args.output, prefix=args.prefix, use_pragma=args.pragma_once)