* [gentoo-commits] repo/user/ssnb:master commit in: app-emulation/opennebula/files/openrc/, app-emulation/opennebula/, ...
@ 2021-02-08 10:19 Samuel Bernardo
0 siblings, 0 replies; only message in thread
From: Samuel Bernardo @ 2021-02-08 10:19 UTC (permalink / raw
To: gentoo-commits
commit: 1fcf88bab1fc5efe907660e30cb88a02cd13be5e
Author: Samuel Bernardo <samuelbernardo.mail <AT> gmail <DOT> com>
AuthorDate: Mon Feb 8 10:19:05 2021 +0000
Commit: Samuel Bernardo <samuelbernardo.mail <AT> gmail <DOT> com>
CommitDate: Mon Feb 8 10:19:05 2021 +0000
URL: https://gitweb.gentoo.org/repo/user/ssnb.git/commit/?id=1fcf88ba
Temporary removing opennebula until I have the time to review it for new versions
Signed-off-by: Samuel Bernardo <samuelbernardo.mail <AT> gmail.com>
app-emulation/opennebula/Manifest | 74 -
.../opennebula/files/logrotate/opennebula | 13 -
.../opennebula/files/logrotate/opennebula-econe | 13 -
.../opennebula/files/logrotate/opennebula-flow | 13 -
.../opennebula/files/logrotate/opennebula-gate | 13 -
.../opennebula/files/logrotate/opennebula-hem | 13 -
.../opennebula/files/logrotate/opennebula-novnc | 13 -
.../files/logrotate/opennebula-scheduler | 13 -
.../opennebula/files/logrotate/opennebula-sunstone | 13 -
app-emulation/opennebula/files/one_auth | 1 -
.../files/opennebula-5.10.1/parsers/SConstruct | 74 -
.../files/opennebula-5.10.1/parsers/expr_arith.cc | 1732 --------------
.../files/opennebula-5.10.1/parsers/expr_arith.h | 117 -
.../files/opennebula-5.10.1/parsers/expr_arith.y | 141 --
.../files/opennebula-5.10.1/parsers/expr_bool.cc | 1902 ----------------
.../files/opennebula-5.10.1/parsers/expr_bool.h | 118 -
.../files/opennebula-5.10.1/parsers/expr_bool.y | 271 ---
.../files/opennebula-5.10.1/parsers/expr_parser.cc | 2260 -------------------
.../files/opennebula-5.10.1/parsers/expr_parser.h | 717 ------
.../files/opennebula-5.10.1/parsers/expr_parser.l | 77 -
.../opennebula-5.10.1/parsers/mem_collector.cc | 90 -
.../opennebula-5.10.1/parsers/template_parser.cc | 2363 --------------------
.../opennebula-5.10.1/parsers/template_parser.h | 718 ------
.../opennebula-5.10.1/parsers/template_parser.l | 107 -
.../opennebula-5.10.1/parsers/template_syntax.cc | 1779 ---------------
.../opennebula-5.10.1/parsers/template_syntax.h | 119 -
.../opennebula-5.10.1/parsers/template_syntax.y | 215 --
.../parsers/vm_file_var_syntax.cc | 1843 ---------------
.../opennebula-5.10.1/parsers/vm_file_var_syntax.h | 125 --
.../opennebula-5.10.1/parsers/vm_file_var_syntax.y | 301 ---
.../opennebula-5.10.1/parsers/vm_var_parser.cc | 2319 -------------------
.../opennebula-5.10.1/parsers/vm_var_parser.h | 719 ------
.../opennebula-5.10.1/parsers/vm_var_parser.l | 100 -
.../opennebula-5.10.1/parsers/vm_var_syntax.cc | 2089 -----------------
.../opennebula-5.10.1/parsers/vm_var_syntax.h | 124 -
.../opennebula-5.10.1/parsers/vm_var_syntax.y | 538 -----
app-emulation/opennebula/files/openrc/99one | 1 -
.../opennebula/files/openrc/oneflow-server.confd | 10 -
.../opennebula/files/openrc/oneflow-server.initd | 34 -
.../opennebula/files/openrc/opennebula.confd | 12 -
.../opennebula/files/openrc/opennebula.initd | 40 -
.../opennebula/files/openrc/sunstone-server.confd | 10 -
.../opennebula/files/openrc/sunstone-server.initd | 34 -
.../files/patches/fix_kvm_emulator.5.12.0.1.patch | 11 -
.../files/patches/fix_kvm_emulator.patch | 12 -
.../files/patches/install.sh.5.12.0.1.patch | 14 -
.../opennebula/files/patches/install.sh.patch | 25 -
.../files/patches/node-sass.5.12.0.1.patch | 20 -
.../files/patches/package.js.5.12.0.1.patch | 20 -
app-emulation/opennebula/files/sudoers/opennebula | 14 -
.../opennebula/files/sudoers/opennebula-node | 1 -
.../opennebula/files/sudoers/opennebula-node-lxd | 1 -
.../opennebula/files/sudoers/opennebula-server | 1 -
.../files/systemd/opennebula-econe.service | 19 -
.../files/systemd/opennebula-flow.service | 19 -
.../files/systemd/opennebula-gate.service | 19 -
.../files/systemd/opennebula-hem.service | 18 -
.../files/systemd/opennebula-novnc.service | 18 -
.../files/systemd/opennebula-scheduler.service | 19 -
.../files/systemd/opennebula-sunstone.service | 20 -
.../opennebula/files/systemd/opennebula.service | 21 -
.../files/tmpfiles.d/opennebula-flow.conf | 2 -
.../files/tmpfiles.d/opennebula-gate.conf | 2 -
.../files/tmpfiles.d/opennebula-node.conf | 1 -
.../files/tmpfiles.d/opennebula-sunstone.conf | 2 -
.../opennebula/files/tmpfiles.d/opennebula.conf | 2 -
app-emulation/opennebula/metadata.xml | 33 -
app-emulation/opennebula/opennebula-5.10.1.ebuild | 292 ---
app-emulation/opennebula/opennebula-5.10.4.ebuild | 306 ---
app-emulation/opennebula/opennebula-5.10.5.ebuild | 314 ---
.../opennebula/opennebula-5.12.0.1.ebuild | 315 ---
71 files changed, 22819 deletions(-)
diff --git a/app-emulation/opennebula/Manifest b/app-emulation/opennebula/Manifest
deleted file mode 100644
index 0ee60ac..0000000
--- a/app-emulation/opennebula/Manifest
+++ /dev/null
@@ -1,74 +0,0 @@
-AUX logrotate/opennebula 172 BLAKE2B 18c2f029cf9b5579ad77e2ccb87de842b49566e4b3086a39c1332d17238ff4e21aae4cf2b9c774c8d48f5a86ae492b187253a1485d4a9e20fb6d8e743c56c18d SHA512 f85c652667edb120e3fbdea7a23a7e61ec7bc1cf19f27d1b7d58417f61081af715c0ed70803cc42904ae4281296be7cafdd131ec305bea242bd99298fd7f4c79
-AUX logrotate/opennebula-econe 149 BLAKE2B a736cc6174f215ef44cb42dabc077818a453724d662b310b2599dd2e95eccd844df0cf014a6d97910d9b06299fcb051ab5a07f1f546c9381418d6528a6ac6686 SHA512 222b29dae4ea16b127f3526083cadcec3b7de7bd97636ff2565e7e9802bb313262955ec23dbf3ef3ec066a793fd4cacedd0bcac3af6afa20222faa183fefbd34
-AUX logrotate/opennebula-flow 144 BLAKE2B 93bac175f8bffc75728936b30e198e57009226c357e6bf639869d5fb4a4eaa4933682a3db0badc319e6710130a5461c27aa1bad0364b926d519db9bdcb5b7bd6 SHA512 cc8123c0153d57ba1209f8c130cbf7e85452bfaf58e848cf0f0dd2c27ebf057f774ce1f33ce238ba0c34fce0eef2b7e32b72cd103a09a6d12f9e79019d9159a2
-AUX logrotate/opennebula-gate 144 BLAKE2B e7bd2782b32a58ad87a54953f36b5c4e6eae9d624ae399010ac20e3fc323d4e6fafd531a3015bd81abf590a05fbd62b6bf5ee09febf0834396cf79f27b4ade00 SHA512 46a9169260e2e5f8ca5f6e2b37537f09a1cffd5aa2bcf0f92e316a5e2442bc519e1d653a27bb1b4cef957e1090568646ecb5c6dbc0c89e7445317b7598b29eab
-AUX logrotate/opennebula-hem 143 BLAKE2B 0c8813f5559ab784c97c6dbdb5d6972b1287c1258202f2603b279f684431dac1be0d8cce43a60b60e7886b664af24c6996c2c464eab2fefcabc5da305f1f135b SHA512 e8d654e6e49f22cfc0324c942b8e62d22606747f0fa54541e0e0d5f33f851d36e806026857537fdf54517e5b775c4fe96e62e4892aa0c7bf76742736d4c6dd23
-AUX logrotate/opennebula-novnc 142 BLAKE2B 77000cb2ad091d7699b34c21a1978c8a1b815c8b817cdd3040a4efa6d33ea4f59ffe9277675a55611474b3777b79f6241473e7237edb4e12f28e8423af3e2015 SHA512 b3bde016333c76a85e282ea98a72c1bef09ea1fa0aa92e588ea22a8aa2ccd8575f530142fdda2d897e0f98e5db2c617bfefbc730d7a8a4278097e67dab3e240f
-AUX logrotate/opennebula-scheduler 142 BLAKE2B bd15c5c89ba2d3ccdcbb36b0d4502daf4e7e151bbb81dc8ec031519a532adfba38aa77ee08ed8133aee77936b3c9a64354dce78e78dc821aeae05bfd1addaf10 SHA512 ae6c14585cb94f0f7151ef9f5162208eff41fe2293fef197afa5bd9ecd7cd5fe1958551bfb08055273b06293fc6bffbed29a6f67d3a23e3aa2899c7108a9aa7d
-AUX logrotate/opennebula-sunstone 145 BLAKE2B 78ac4a223870b83f1f85338c405e1a5f8adde850ba941a7ead70bc4f8759ba26171a689835ab524c83ba52c78046140b7725c64ba0a41af8550033cea0b873c5 SHA512 9c99d33754a4ac67d698b9e5c0db01531b86516645256273c83205805b60c7b3dda75f9400ee620745ac0cb440fba34e25a77acecec561074e20758f55a989ce
-AUX one_auth 18 BLAKE2B d716be15da2ec04170be79dfd807b383aad1e98b01063aeb94a91ee8f22d3d6063fd7e9a98ff43d6eaf8ed8fb7aac5ee96ecb84b173b20dec55c0ef5d852d726 SHA512 c4cc94b521013fffbaba6c0949e753e3239b5e5555734b783dc9f5929d212a8530215fddd311424cee51228ebfdb61d622bbdfaa768dc08603341ac70b010c14
-AUX opennebula-5.10.1/parsers/SConstruct 2142 BLAKE2B ab92b55806a898b200a73042554a6d880583fdba710f30a44641bbd27d09cf56d4a5927c57d744305817be88e7369bd29ab6f10683af8c8763296901b2ea27f1 SHA512 4f603471183d186fb493a6fd487e4bd99fb7453701bdec1af7498001cb9b54cb46fba9a046531c0a4966a875b3110a1257da4e323040bd5e0db6ff431dced9ad
-AUX opennebula-5.10.1/parsers/expr_arith.cc 53125 BLAKE2B ba4bde2e70d356e72ec58d15c8de4016d311890c261ef8dc4f468f5309dbaabcc85c1abb5fc45426d36a40af0d8695e523e7088b458c9f55867d92087ca133a9 SHA512 811c7a22ccbb50f8fe2a753c01b1a53c0dd60f101f37db5c6b9125af575602410a82dcc65c858289373e138a23021675cce3dac0b805b34c6691f6b715998bbf
-AUX opennebula-5.10.1/parsers/expr_arith.h 3185 BLAKE2B 0e811efaacf1f5c4ec85e38a148045783de510409d52c9676e74f64e69dd8dfa0714f87f7294d49e164ea10c09f535251e5065a5207aef2a5f7521841906e44c SHA512 d37180cd76043b4957ed8bcff512d710703715f7e4820b91af27cd207b23fa04937988e5cd292dc631ee5a75ead512110e85c8c7402305b77a699ca040c7ef0c
-AUX opennebula-5.10.1/parsers/expr_arith.y 3912 BLAKE2B f1a7d35743f5fccdea396f8c20d4786635ea6f70b2093f1e48c34d8c4ed93e271fbec460537cd496e9b630efb4c940f77734cbe464846f1eeb861ac435cc431a SHA512 a77cde752f0a83c6cac764f61353664efd76a6fe2989ec7004209e98054e4f51cefd67a3240a6ad1f50ebf4ba471101770d19d2bd856085fea69a394908fdde6
-AUX opennebula-5.10.1/parsers/expr_bool.cc 57312 BLAKE2B 67bc02b1ca1649f699173b7c23e759d20ec61c71fbdaac049b0ea4130311b6d9818c5aa7f1b56371b9589b0a990b5a3ec3b6c023c61cf140e63a01a2035c2fef SHA512 9992a2430d55de7689611914dbc682411ac6aa8c1c37eda7167f1b598ca0473bf46e507be89669af579d4a53a2f78a0953d8b1f9482b76e9f39dabdf7c7c7572
-AUX opennebula-5.10.1/parsers/expr_bool.h 3175 BLAKE2B 1764e64cfe7d495c334c4e5afc5423d978cea9a2988e99e96808280ca53847ab83bfe286c41b56d4f2aa97b388584c60c6d2b6232f550555f682698bbd05ef0f SHA512 b84c2f0037c9f94a30bcd167b06cc5bfa838ff02183392756fd8b0f360be5635e7f440786bd23fc27d7c9d5e68ad60d69e12deaad55becbbfd933e606d6fe4df
-AUX opennebula-5.10.1/parsers/expr_bool.y 6574 BLAKE2B 36a9ed206fa6b29c560298ae46574f11cc478083124368313f4c594f39eb1cbd5ede9b847d7b336f585fab2b9ba0cd7b76565a088e00a7af8f5977ebf82d7fe5 SHA512 6095ca4b0b7b10e95da272d5ba650501b77a2ac75f671cdc2f3b0e671651aa47cabc82ad77d07a3b1fa4aaf7b42ea1b0efbeaaa7173b1863b99a90ad50bb07ee
-AUX opennebula-5.10.1/parsers/expr_parser.cc 61455 BLAKE2B fbd4170dbe8b2ab14daed1071741d2608b9a5741c1b0c780fb0e205d864a1f86ff0feb8592790804d9d993a09cbab60a71f1c3259a9a46adb33db5e8a0428b11 SHA512 4fabe7c15faf6d7fca5056a6fff51d9bd9fef4c4bf1db11264095cbdfebcddd83ab40534957a5bfd7b4e4e30272220c2540f4f74f2d453540fe1fc39163f7844
-AUX opennebula-5.10.1/parsers/expr_parser.h 15948 BLAKE2B 7e14defd80847b3c6a180ef1849853e1a93471a5283a3b60c6a42a2b785aba2a3f698269c595cf8ec8c6a999f3c725bf19f693366c6805c69cbcf45692f060c8 SHA512 e80640f32c7362c9f11d0d144e85a5fe237ab5e8f9fa2f7e88e2930b6182e3b3fbdfc860072a64bd9322e3a7803ae608a4ed9ed92529d85cd841a3da0721114b
-AUX opennebula-5.10.1/parsers/expr_parser.l 2610 BLAKE2B 3a9c97b2d05524ad83d7d5c2ccf0b2611a5ea9715a9c82c86e26bc6353da3eaf3d89a66aa67ffc358d9c3c4c2988c2edf18effee0da936f10082b4ca22702b44 SHA512 1dd0f923a32edb437556c026dc133b87fb53e6151d19691dc568cc8161b1c2c56cbcfb667572c79611fba9d04432391ff2693787418c6a6db6de9dbb15d5936a
-AUX opennebula-5.10.1/parsers/mem_collector.cc 3097 BLAKE2B 942b9faa03a9c3f6f4d7d5a7bdb21b5f3cfa3a66dcc91676bae0ad641b6ac62ecd3767e223707e52c27e11811c1798f38c3228d3f304ce01ddf216bb8b26e985 SHA512 f6031ab2c568c7b39b067e5d121681261756a4cb966a75a0d1fc16017f92a67b825d52549c53990f9da6b7046826fba531acec04a7c152791ea8d5b3948ef414
-AUX opennebula-5.10.1/parsers/template_parser.cc 66893 BLAKE2B e7718e151856399b67461c86445bbeda43fe6a5f1a6ec1a76b151d3fd5acc2e70b8ea94ff01b0288e3208ab3819daff0f6a2cef8503fbf2f7f8c5b786e1c7575 SHA512 4e4a9f54067a32ed29b91860b508b0bfd0f496d0d098ba18cf0ba40850cd6a5eb41ab8fe4393efd96471d108d95b4dac029f4d1abdcbd0c7f0d704980df1f9a2
-AUX opennebula-5.10.1/parsers/template_parser.h 16489 BLAKE2B a31a0a2f60ce8ac7b098da5f5365597e78d4cd2effd0fb731e4d30745b86825c467086637e874c4678070b624dce76550a82196f73c331dc746499a597225ff2 SHA512 61300b2f6ec15c476f10cd9969fa8f2bfe469ff7b673930a21e85a5ded992d3d7ab2051b7c992d838b9bba308444b3b602f4fbb1c17765c876134d91ce04a418
-AUX opennebula-5.10.1/parsers/template_parser.l 4151 BLAKE2B 9e58a4a32de774cb82212747d386fd51759cabe578e61af4c40b02328ceaa5954342ce59dda3c16a4402edb2d03928d886c8a324867ef8025ea8b91baa57774b SHA512 0d31062deec5a192dbced842623835ee4a72b556d6bf7c758e8659aa14306b9e70bf728ea7a19ccd3d146b482657170a85fe6e2f8a554549769372c0b315c0c8
-AUX opennebula-5.10.1/parsers/template_syntax.cc 54201 BLAKE2B 6b8117b47a52fb9ab422ec542f8ae6c59c266ffacf2fd7e7915ace4a9f88d24fdd298c4e45624ff89d4ce8af3d875a727a03760e972924771d5a79b905bdd2ea SHA512 af0e23335aa75648576edc1ec094dc52ef40464ce27f747850d9b20e13ffa6c2c0ba7a57b82d7db6d68edc273e84a8f1a964a59ce9c203ed537fa6d59803c466
-AUX opennebula-5.10.1/parsers/template_syntax.h 3213 BLAKE2B fd734fab48df0053385f61e21a4c274a8293b2c8879075c18a472a3215b7bfda20b5c1fa3dc0e5cf015605c69adde6ddac995fdd6a04dbb9da408a295c9b0d47 SHA512 90677e4ca6ee2914cb67b64b5cd22144dd9dbc85cb690e27d8d347cbfaea8d9b2abbff24f46faad9784e770155d9534e6932409833c9a945a1622704db8cfd0a
-AUX opennebula-5.10.1/parsers/template_syntax.y 5600 BLAKE2B 0f1416693d1dfb81d08e3a3463361dd46fff3e338ac611ce0883a00e2aa9b402a3701d65fe231f5d59faf00dcf88653b7df05fd901068917554623674a15313e SHA512 a1a4e85163cd40a67e77c74772fc67f300bb7a7da76605e9fd56ad30668daea409acfd601d6c73bcd79de8d0c7726eed29e8c10e686272554b5ca7d7fa4d9796
-AUX opennebula-5.10.1/parsers/vm_file_var_syntax.cc 55759 BLAKE2B 7fc094c838e2a66ef2a3c2ed70c5514ae50697126c2dd63da2c62e18036d4a4881d42a76ac3037669f609bc44e82bb1bce0e78f8c2f946f4d1884d8df8d89d44 SHA512 f487d61cade883faf722b76b362668e0f9812cd6c213ac21b4fd3763fc8d7748fbaca23010f7f8579b7b44be8b500f237ec732b5d9899a85370e2573e4accfad
-AUX opennebula-5.10.1/parsers/vm_file_var_syntax.h 3417 BLAKE2B 837994320d0f6531dc7eb9eded9655b7832d7f793223df82b5a076c97f27cb0a0cd35837180a0a70d3040c40e0d52c9bc575c0bee66aa7061f97c881cdb80df7 SHA512 74fcc37b0ee532e20187a3e7e3aa7b81d5c9b797c1f2a57e7e7df9a97de9f50f70bbaeeb93541997952a00aec3788eb3b261e1aae410192086bb40a9e7d25deb
-AUX opennebula-5.10.1/parsers/vm_file_var_syntax.y 7467 BLAKE2B be35f732d76e15fcfb304845397988b0cfd704000af137240e4166deeda3c1c53d150d683afa394eb5b93befad4ee93fe1f711133183af2ce99178bad18227bd SHA512 8dd4bb7d9e7474e377a46fdf4c06e1a17bb6672b2c20c04185b360ff8f1002a6baf44e79bf1d03512746a9f9f8fb080dd1f5c67998d672dae9ef06d77432dc3b
-AUX opennebula-5.10.1/parsers/vm_var_parser.cc 64310 BLAKE2B b6eec8077eaf2ccab8cf5766b18e8515a9490a8c2e2c78dce69c78bbfb2a9dca1a3f4461a3818001ba8cdbcd781998346516206e66cd8e664f1ff70d49c91042 SHA512 68082a1698d673fba5c18f3f1aaaafb8e3b8cf644d2cc3547193c6b4f07ffe08b53f44d41641f30433fe660ef13b6ad0028ed1ada26ef68dcca5020d536389f9
-AUX opennebula-5.10.1/parsers/vm_var_parser.h 16240 BLAKE2B e8a0c217ffa07bbc174b6aad9d283077167222fffff54b6af37a24d13138663fa8e9f207f4689dc9a143646bd80f0b1aa63253d576cf25a7807cca8f023c5044 SHA512 bc041ac5eb68b23714a5a711e528def4b74ebafaa4ec8d3b3429e517cc4b8d5615b56032ce59b1944024aeefedec59605ed4e3152391fef1b8e6d6385d28c2a0
-AUX opennebula-5.10.1/parsers/vm_var_parser.l 4280 BLAKE2B f2c7fa858c8e7ab7778561aeb84f9d00090336c307249a648e73951a7208df17ec369d85cf53303ed17f64e42ec17a2e779e1135155923931c9547ee5f23006b SHA512 02cb7b4c08b8498a28113e3a5824270b48d9c625fba68b7cf0afc4054b7662481b309a57c4d89ef3869aa1435d647034d1c458797ba46d01942649dcd73fbbaf
-AUX opennebula-5.10.1/parsers/vm_var_syntax.cc 61095 BLAKE2B aefa4b7352037775b4d91b0a6893418664668ed9aca901a8ef269eee843bfe6a47b3823fd05beb622870e9fb4148badad0ef5e3fdfc42f92cae597f93430e424 SHA512 425585a510b8c4e2ed17ffe6e32da201b10ab35632ef4889a2ef049452f310f2e39c86929e06fc765bea96547c5592e66ee6e75b02ce842565b3e7dd39176beb
-AUX opennebula-5.10.1/parsers/vm_var_syntax.h 3336 BLAKE2B 4d35978e90e844f8a98cc8a54306164f79100650389ad0ec44ab84467effab9ffe9543e1f812f0ef1ef30cb1728beeac1c4aa53e5795eedb0bcc1c235e187464 SHA512 56541802079b91316a2c3c1f45e642311f4a09ebf18820efe3a452a15cefeda0086d274320d0fd2d2abd7304d9dc83c7b648af338a83e7ead877b5c74f69b287
-AUX opennebula-5.10.1/parsers/vm_var_syntax.y 12623 BLAKE2B 111e013eabb9107532431de767a5237d19ba8f27a83504d571022e90e864b30b2152290e5c16e968ac6281dadec57269106ce495793257541c8105969b53f55c SHA512 ca7bc208c697720827df1fba5b459e8683086e7d45be07050f5d8604ad2aba9b103f26e071d203d7e7faf953aed5045cf9c2b9c5a1a23dee5a5f9f6391ad4b79
-AUX openrc/99one 29 BLAKE2B faf301bd63b3dd997552e5dc48b139201b86384adf96d75e91315d7325e9a593ecc5701898f388a47213d074c3c8c9c9615590fe33dfe85e8338a4337249abbc SHA512 6a8287ff68a6489a65ead46a9e456c4f985874ed3a307fae0c623d070383c663f3748124c48d3fb05df6511e0388278d8afe00fb7427e6674903d079ee611f2d
-AUX openrc/oneflow-server.confd 162 BLAKE2B cc2a106d94608a0d90ca8c0135ab09303b962f8599c2c839afbe0637f048b0af26fc13607d3f64fd10fc785e553d29bece784f396003470ad05934a627d9a5e3 SHA512 0b9ac8968731b1da1e66725b18491014949d7225e38ca8ad7c0cfedf44d055dd9c170298b5ead6b10dcc13a2d60c30013288d9b818f09ff05f3c8905924e9532
-AUX openrc/oneflow-server.initd 780 BLAKE2B 74b75d674c26d0e03adc129add97cac49c0883b0ad7dc9dc4a0db929a0b7ad42863e1594ba743ef4d016813da251de110bd767e8bfdff0c95066f87e137877e0 SHA512 4fa3c5339c8baadaeb48e6bf1beab1a25c2bd3af3c389414e4456fafa6582e80abcdafd46e6f497ac950316b8859a673cf2f2012e840c5ac2edcf95cc3fb7eb1
-AUX openrc/opennebula.confd 189 BLAKE2B 1c2899def707c77fc5abff2538fc3d106a20d8ccb7d4f5240814dbe7f00cf046934350c825187b0194b2215b5dfde4e3812dd43b6ab8258cbcb554fee4a40cf3 SHA512 78378b3046cb2d267502349250155f1f805f86465219cf8644064cf3227323b270777f73637fe5e2136691e8564c99b47a61aae47dda9d6c1177bf50b551d746
-AUX openrc/opennebula.initd 913 BLAKE2B 3ab4d3c1d1d8644e909422b89526f23e168c8b0f4d08495b0844df366438292bc6bccfc4030b51bbcd93d0b60df10b48faaa142ee2ded285b9772a285cc805a2 SHA512 74fb19970136d6d1b4a7b9d6279249c47ca7cbb6e4e9f90555a6ffd93963957fbc9ccb1b97c9355211057d715fb947aea968db40f7d89d61fff34c3b1331879e
-AUX openrc/sunstone-server.confd 166 BLAKE2B 88409cce348709fa0dc1794dadefef623245ca838ce4e4cffea3f99deebf93f969b12761ec3761e12c5677a937e4cb3ccf112ad5b1811c1f986fff4d87b11ec4 SHA512 fe70685cd1aad949c8f46c85764ff62f67b55477879b5d125f2f5ed176d13171762e9ef953b6d5cd6e27d4fb9f503b9fe7ac4ef0fa1f9790f86f9698d3b82079
-AUX openrc/sunstone-server.initd 788 BLAKE2B e49f736213f0575d9a040058eff5accd36b00070ed767bb0de39fb0e8e9ae05ed5b34ddf2ae224530b04fd506e7b1f2a4c73ec69ac608b4a5d231bc07653ae6b SHA512 fa2d6ee6e86e2497adc7792e67140810761c7403ffec3a9def57e7568180c99f17561381462648c8cbe43b12e4b36a146e48973de979b321002c1a566beb727e
-AUX patches/fix_kvm_emulator.5.12.0.1.patch 417 BLAKE2B f3c800b37095ff95a2887bdb260d2de40c731cf09011b61086c66f6a43e379a0f6be437a35246787f0889d80aeb08054293c5a00caec0ed9148453a160cae129 SHA512 cf85539fd6ee57b6d6ec843c1d3b717052d9e22973f4bbac7d210a1b5a30408bc7274d56fb818cbde2cc35caf9ac1bf9982cc97d7e4cb926e04785f7fc9f651f
-AUX patches/fix_kvm_emulator.patch 362 BLAKE2B 704aa77b28d337922c2b0dbfa1865127dc1c2b3e2e4c6995bcf4cfaaffa3a7c4f4c2becc7c982954fb24c1849044828ddc43881d045a344ff788b8126e546c24 SHA512 18b1964cb4e3fc2eaa93a7ef79e4b9b185584d33ad4f7fa33cd33a74516334136d9cf0ee25921c189250420b751c753cb0142227e8de39e14f8d110e97cd8e30
-AUX patches/install.sh.5.12.0.1.patch 560 BLAKE2B aa9ed2bc271f029f9e8f2a53c79ff07176f34df43d807c21fd49d4d82f39c54a057aac338bd7ab0c91495bf678481cc7f1f3621c1c47801bdfcc10520fcda3b1 SHA512 6d178d5f904cccf4c7dd324e7dbda367c9d7aeaa04c5e901f9c4ebeb2c68d2d68b49618a21043c4c0640f659806a5b7c74a7e0dd4ea402636f10dd6a9a37297e
-AUX patches/install.sh.patch 987 BLAKE2B ed9682609aa7867087ecad73f117738f494eefa740053b73a25cb703a58b24630afd7dac5b463b0e938fa212ceb2555c90b10c05d2cf6adeb572ea2361bbfd3c SHA512 ea2aac1d9df1ae976f96be119813b366e3b7eae2d14ba75352ed975fb337f1ecfb7a0fc22628b16fc6b0498e46ff8d1c1415ccc569559c3cbb45b414dd9be540
-AUX patches/node-sass.5.12.0.1.patch 669 BLAKE2B 02518ca6cf66d249e0ab24afeab6294423a64ba183fae292709c06a921bbcf49cddbef5b6f05686d2b3785b1fbdc73109814d0425e9d77c870bf5e4d17ffcd23 SHA512 83b297d1c5394ed7e1074f00cb7ed2447427fd4dc3410a7324ecab5ef06f37a656d1027d3c672e37d1c224566f4b0009420fda3c61a54a71bdcc0fe02ef7b0fe
-AUX patches/package.js.5.12.0.1.patch 681 BLAKE2B 6efa8e29b3ac1ca16092abaff01e6d0c7f7e10b41cbf333cbd13710ca7bbf12189b2313071bc6038af097179175a1630c7a48860e9e62a37691d5868ffd49573 SHA512 54de87611112ba4e3841867488b0de160c7fee321a3a0f95003750c2a31858c0bfb5a2546eef11f571fe2c303c62630877d17d2315245e25e306a7a7241c95e8
-AUX sudoers/opennebula 1456 BLAKE2B f25ac0f3c1b9f44644e3edddbe578d611204bdc683990a359ff51eb8d540870fda53eb5d0816bac22327369e59d7acf783adbc3a19c127e76985c7578733c8e1 SHA512 5eabdc11b16be8b34c12094ba108012916a6d2a4b06ecc421a5a0d6b7e720bcbdc698ace8b003726acc3b9d637a558540d0630bfc59335104ffed3006e13e0fa
-AUX sudoers/opennebula-node 69 BLAKE2B 7292f9aeb4b2599190cda6148700fbedc4c1d00e7295df6f2033baa4189b5b1abd74f76a5ac7ca6dc7c587176e10b2b7f58f7d81019d7b73a74b64cf265210e6 SHA512 f3e7a39d1c5533e8ac4338326a48b49fd2ab73f0a20bbe23280f64d05f1312663c616ce2ad6e5fed2c09bdbef0243f5a8a9f4ec361aac6aa57d1bdf008508846
-AUX sudoers/opennebula-node-lxd 41 BLAKE2B b0533db80686c1075a89df5b38b7b199a7d3dd022ad675405d021c5dadd76ca784c3ae1962cc273ebea2686f060a2ac9e8f9e088846cbdbea6e325a16b3d96c8 SHA512 86043f606d9fcbfb0288ac286fe0f31db11aba3b39164ec92cdaf23e4ece3d0a9909f8d8b26533cd7801eb79b342dc5f55487a2bd06ac058d46d66c410b37ff1
-AUX sudoers/opennebula-server 58 BLAKE2B 4d0ab8d64ce6feaaf7fba94db4fba2df1c4400c6f4ef4eb827d953405a1ef719eecd572a935435a5d7bb6199d60f0e0c0f8aad8b0b0d93d2a4759e55f0861729 SHA512 c9789eed479933fb9f772ace9f9a76cfaad36188be61920f86c5aec072f6df1f04a233e605c2828fb4ac7664930b27fbed79614d2bba28fc81dfff431fa51c74
-AUX systemd/opennebula-econe.service 487 BLAKE2B f5754051cf87791b2a1a3b9fa7fdfe0793e15a6d86187b186a6f3a96d36d49e9bc0fcd59a65034ee999ad7e7f2f5678280aff0ccb5a6603a789a87b21c655481 SHA512 7bc53b4510c03587c64ec9b95064bd812678bca0a8ea1e9cf38aea96284a25ca5bcd5dd71d0e30d8eab2fc15dc280aeacb74dc974ab3c9c45d01843f47bdbd23
-AUX systemd/opennebula-flow.service 483 BLAKE2B 983df1a7ee139b462c79f81f6eeda5c5617e7f5f44c1325e020f7b35ac5698283f2f6652e02f3eefc0209d6eee5d9499e2188cd5312aee93c644af1a05dc2ad1 SHA512 978233139935def2795138b78aa2233cc7f621ede63d4c58e1d95b82ed224c72b4a7d247fcc3ae8451dd7ab7ef4d4d4901def97c7ae6980a397fce8925b216df
-AUX systemd/opennebula-gate.service 483 BLAKE2B 387d749c5d1aa8a2c4f245b27c98d09b11ef7593f2cbb6fa317fc67892967df48e4d55208c2436dbf313a5f69be03864f6ab12aa0e05cf775bd1df28a2ad2228 SHA512 18855bc6a0e6092635753da95104fb395ad1210cbf98ff6e846f80a58f602762f109ca82cb9b791e52f24ce2d265bf9ffe68a79b3d03f967049061d70ccf5a53
-AUX systemd/opennebula-hem.service 440 BLAKE2B 4f9ed62dd4b686c9ee4ce52d02c7224eb18273a156af0892d35ec089df5c8081fdfd40870308ae5685f990743cc7b93dda870617331d448a49cbc53d26b229ea SHA512 6b38ffbab96fe7826cde90130f67ba5ba09bc1c4e0a8f35cfc634187ee770491dbd4a3cdc9ca6056189823ae42ee3a28406c838e1d6308ca6b44bb3f890a195a
-AUX systemd/opennebula-novnc.service 417 BLAKE2B eeebdc36940f8c6c3fa1f880b57dad33465da573f47289e316edb724ba36c208fdd246d8acf706148a7025d2ec4b7f335bae8c1f1d7377b77824328bef111985 SHA512 5c833c35f0fefba1e1bc10b60a575c86b2eff2d39bb1a43f52c073364d6fea8c06859506cce3466e755b0617a15f693e4102af2bcd4e4fe38f2b30b1c4c1ba70
-AUX systemd/opennebula-scheduler.service 474 BLAKE2B 2804efb94bc8bda7b407792008a64437f34643f06ddf10d371388228f62057196158e6f74cc51bc2b227a7dc41c35809264cac39381fc077e7dfed7005f0c18c SHA512 af75c0a59540aecbb7879cc15ae6d1d4e2230ea2be444a5749f9b840aef17f4cba679fab9a34b974bbe336b2011e74c32551391e1d2fbb29b73274e7b1ffca62
-AUX systemd/opennebula-sunstone.service 522 BLAKE2B b07146bd735496d8a866afdd5cd8dc91bf0bfd420e3df9ba8510f8ddd8173ec11c75a1809087de61742b66cb5d788ab7ac69f67f5f933ef3ae258152a225bd64 SHA512 50f759bd801e753866163595faace9895064cebb7fb79a3d12d14a4e982dfe2c3dccc1a0e5b8591f48f7f4b149534a8df109e7eb1ff6c36ac04a0d4472ea1c1a
-AUX systemd/opennebula.service 559 BLAKE2B b189c255a0a32fe470b15f8bc6a526efb43c33161a0ca44d9139a69ec2c2433c58bc708ee683c4f422d17fb1a67f683c5c16b2b32250b41f89bbb623a808e0ca SHA512 60acfec60a51d9e9d3a77b111cb8727df36a71ca26a61916606ee59ba1c3c77acd6c2f14b55adf899a7cec677949a5e7ae168a97bb2d3ea6d829be746acc8279
-AUX tmpfiles.d/opennebula-flow.conf 77 BLAKE2B 9988562b0e36bf74fc67af5a1777eca18b24e0a1bcfc78735f360f1aceca4602e32f7b6cfbe3b731a13725a9cd14a4dc49b71c12bb7576a29aa00112b37cd2be SHA512 c13210255ebb0f34d464e2799858d6ac2a79afac287ead639821ef5e939b7666a960ebb1ee96bc7098a111ddd6765e72d8a5e53e0647b9a866d0826e02cbd2a1
-AUX tmpfiles.d/opennebula-gate.conf 77 BLAKE2B 9988562b0e36bf74fc67af5a1777eca18b24e0a1bcfc78735f360f1aceca4602e32f7b6cfbe3b731a13725a9cd14a4dc49b71c12bb7576a29aa00112b37cd2be SHA512 c13210255ebb0f34d464e2799858d6ac2a79afac287ead639821ef5e939b7666a960ebb1ee96bc7098a111ddd6765e72d8a5e53e0647b9a866d0826e02cbd2a1
-AUX tmpfiles.d/opennebula-node.conf 17 BLAKE2B cfd907f606a7b9b24d897960720f97ed3d67723c19fe244f9b69bb22c40a4e4baedfcb5899bcefa364758000a488a3ba501148ce53d3595d7e1f8428186475a6 SHA512 bfc1fca8d933626d16d58b0077e4feab2d37a1bd6a67b62d7c45d264e874e45437b4328b5eff5b8e3236113db13b3e323beac8055ad8026021c0940e88aa505e
-AUX tmpfiles.d/opennebula-sunstone.conf 77 BLAKE2B 9988562b0e36bf74fc67af5a1777eca18b24e0a1bcfc78735f360f1aceca4602e32f7b6cfbe3b731a13725a9cd14a4dc49b71c12bb7576a29aa00112b37cd2be SHA512 c13210255ebb0f34d464e2799858d6ac2a79afac287ead639821ef5e939b7666a960ebb1ee96bc7098a111ddd6765e72d8a5e53e0647b9a866d0826e02cbd2a1
-AUX tmpfiles.d/opennebula.conf 77 BLAKE2B 9988562b0e36bf74fc67af5a1777eca18b24e0a1bcfc78735f360f1aceca4602e32f7b6cfbe3b731a13725a9cd14a4dc49b71c12bb7576a29aa00112b37cd2be SHA512 c13210255ebb0f34d464e2799858d6ac2a79afac287ead639821ef5e939b7666a960ebb1ee96bc7098a111ddd6765e72d8a5e53e0647b9a866d0826e02cbd2a1
-DIST opennebula-5.10.1.tar.gz 43207580 BLAKE2B de87e839cd772bec769af4a689fed02e81fbdc6fbb35def9ad6344383dc935ebd431137cb194dd3b840965004f4e145ac63443d7034d56a9a6bb19af9030642d SHA512 861293298997c825e94228ea28f0f352db3f56dd28b654be24ca2226edd422fc54cf94665f5ae5cc17dc51d3d52081c936f249b77fc4f8198de6a1ec0006edaf
-DIST opennebula-5.10.4.tar.gz 5697792 BLAKE2B fde611cbe5b44ee403b57e915253c9ffba267230bf3a54cd466260615918e871aebeae6f17c246a84ef1686df176134acff272c49e6a9b69c8841bc8fab1f1b5 SHA512 c509ec4a56b7865d118ab79e08227f0a78d1d899361ea2ae2ea3c6ac6ad3ab4a2a38211a4f5b7abf35ef512674d13ffb19f97286fed63515289e4f9a602f3145
-DIST opennebula-5.10.5.tar.gz 5699952 BLAKE2B 35dce44e085342e8d2628bc060ed0644309a6e5aa8ec1898663b537eb698d66f980353cc60ab3b6496bf78b496dcd1097db2d327b54f80d87bf273ab67aeef55 SHA512 e35b9f8c8bc4f1e4424e3a8083c2c31edbe5b799df44a222bd310fdca87c4a3c6d2a3f27da75b12364bdf29883e6f641c2ad5c484e5cc07dce3ebf054681fc58
-DIST opennebula-5.12.0.1.tar.gz 5559467 BLAKE2B 397ffcbf185b38ea0ec811997751ed8a4f0b57e66fe5e924604e2b1cd3f012981c601fcb183e18a1f836ecd06568d5534943a410191228dbfcf192c8c759cd91 SHA512 fdc9621df006c41a91c61184217e35e7511c9342621dd2da43211d9f24be262a066ff9321a0f423224ef7ce1bd8438e91639d625c98b3c18622d17ae6c65fab9
-EBUILD opennebula-5.10.1.ebuild 9405 BLAKE2B fd6dfefc76da0aaadc993b7ed1593b8826fb642a92797220c9ce6226b846539900f6e7914730decfe57f79514654506e9a1aed76ebd28c1fc797d71ee5a6b2ba SHA512 360d3323e46a1253f6489c696e020ea38e260923d6b0fcb50154b0cb412b4bd3db994365a072915f5a8411032cea12dd8b87fe2f730e418d6742dd7218722a66
-EBUILD opennebula-5.10.4.ebuild 9735 BLAKE2B dd7f5bf32aea6bd30f4ca75d7db123fb9ce03f1357d789fefa76a46b7a4f1a669df0d68d5239e85a40da591d7bbf993f759a02704ba468b6c04f6445401343f4 SHA512 3c54819ee10cb07fe7ea41dd0b65b8de9075ac96e34524c512cd58457071b00f7be85f3bd062a57aa4459703b29d98c2b577a97c6b03093699b99021b59cfdf5
-EBUILD opennebula-5.10.5.ebuild 9891 BLAKE2B 253d6ef23eaf8980373ee19c2035aadf3b9363702954dd87be48c7ab87961683834fe857d22d2ae5d112269e940f0f053b070113576b5bde421e69d9484074fd SHA512 04a4e30d1b59ce11d7d135e76bde6c3581318274da81eb27b2055a7fc48060f388888ce62e6c32a7f68dade5221982f80e4773ef36f54acf23638d1b89e90242
-EBUILD opennebula-5.12.0.1.ebuild 9933 BLAKE2B 6ce863cb39dfc90ef06faa3a8a933dceb3d535d98f22e0333ab4d241e71b09f4563a6fc668a38fbbfe03ad0179d2ee866d5de24791aa13576323a477731850b3 SHA512 6c0edfc676f204c0076cf62f63a96a347bcee3ca82fc371089c855410cb9c9a7dcf5a2d83226bc77e84aa18b987ede256bca9ba21673eee516a5825af5c35144
-MISC metadata.xml 931 BLAKE2B abb0ecf04eb6fc45f64c5d2d6636591c9d706fbf1902943a80f7e058443787824581219fb8457a83192e4e2b672521609449d4eef78ab677f8c093fe939034b6 SHA512 c3770f399572b16601e7eeaf4a1eb4b5eea950ad18239be8719124f60f3edd02da4c7b28b177329d70b0810ee7d8597e522dd62a1bd4c8ea1194acf0d92dfeb2
diff --git a/app-emulation/opennebula/files/logrotate/opennebula b/app-emulation/opennebula/files/logrotate/opennebula
deleted file mode 100644
index d37ed39..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/one_xmlrpc.log /var/log/one/oned.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-econe b/app-emulation/opennebula/files/logrotate/opennebula-econe
deleted file mode 100644
index 6b1668e..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-econe
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/econe-server.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-flow b/app-emulation/opennebula/files/logrotate/opennebula-flow
deleted file mode 100644
index 9d1fd2a..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-flow
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/oneflow.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-gate b/app-emulation/opennebula/files/logrotate/opennebula-gate
deleted file mode 100644
index a586d4d..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-gate
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/onegate.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-hem b/app-emulation/opennebula/files/logrotate/opennebula-hem
deleted file mode 100644
index a4e9781..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-hem
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/onehem.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-novnc b/app-emulation/opennebula/files/logrotate/opennebula-novnc
deleted file mode 100644
index 07f6916..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-novnc
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/novnc.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-scheduler b/app-emulation/opennebula/files/logrotate/opennebula-scheduler
deleted file mode 100644
index 07752e3..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-scheduler
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/sched.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/logrotate/opennebula-sunstone b/app-emulation/opennebula/files/logrotate/opennebula-sunstone
deleted file mode 100644
index 945885b..0000000
--- a/app-emulation/opennebula/files/logrotate/opennebula-sunstone
+++ /dev/null
@@ -1,13 +0,0 @@
-delaycompress
-dateext
-dateformat -%Y%m%d-%s
-
-compress
-weekly
-rotate 52
-
-/var/log/one/sunstone.log {
- missingok
- notifempty
- copytruncate
-}
diff --git a/app-emulation/opennebula/files/one_auth b/app-emulation/opennebula/files/one_auth
deleted file mode 100644
index b80189c..0000000
--- a/app-emulation/opennebula/files/one_auth
+++ /dev/null
@@ -1 +0,0 @@
-oneadmin:oneadmin
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/SConstruct b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/SConstruct
deleted file mode 100644
index 8b5dfc3..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/SConstruct
+++ /dev/null
@@ -1,74 +0,0 @@
-# SConstruct for src/template
-
-# -------------------------------------------------------------------------- #
-# Copyright 2002-2019, OpenNebula Project, OpenNebula Systems #
-# #
-# Licensed under the Apache License, Version 2.0 (the "License"); you may #
-# not use this file except in compliance with the License. You may obtain #
-# a copy of the License at #
-# #
-# http://www.apache.org/licenses/LICENSE-2.0 #
-# #
-# Unless required by applicable law or agreed to in writing, software #
-# distributed under the License is distributed on an "AS IS" BASIS, #
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
-# See the License for the specific language governing permissions and #
-# limitations under the License. #
-#--------------------------------------------------------------------------- #
-
-Import('env')
-
-lib_name='nebula_parsers'
-
-if env['parsers']=='yes':
- # LEX
- parser=env.Lex(
- source='template_parser.l'
- )
-
- parser=env.Lex(
- source='vm_var_parser.l'
- )
-
- parser=env.Lex(
- source='expr_parser.l'
- )
- env.NoClean(parser)
-
- # BISON
- parser=env.Bison(
- source='template_syntax.y'
- )
-
- parser=env.Bison(
- source='vm_var_syntax.y'
- )
-
- parser=env.Bison(
- source='vm_file_var_syntax.y'
- )
-
- parser=env.Bison(
- source='expr_arith.y'
- )
-
- parser=env.Bison(
- source='expr_bool.y'
- )
- env.NoClean(parser)
-
-# Sources to generate the library
-source_files=[
- 'template_parser.cc',
- 'template_syntax.cc',
- 'vm_var_parser.cc',
- 'vm_var_syntax.cc',
- 'vm_file_var_syntax.cc',
- 'expr_parser.cc',
- 'expr_bool.cc',
- 'expr_arith.cc',
- 'mem_collector.cc'
-]
-
-# Build library
-env.StaticLibrary(lib_name, source_files)
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.cc
deleted file mode 100644
index db2f5b8..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.cc
+++ /dev/null
@@ -1,1732 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Bison version. */
-#define YYBISON_VERSION "3.4.1"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 1
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse expr_arith_parse
-#define yylex expr_arith_lex
-#define yyerror expr_arith_error
-#define yydebug expr_arith_debug
-#define yynerrs expr_arith_nerrs
-
-
-/* First part of user prologue. */
-#line 17 "expr_arith.y"
-
-#include "expr_arith.h"
-#include "expr_parser.h"
-
-#define YYERROR_VERBOSE
-#define expr_arith_lex expr_lex
-
-
-void expr_arith_error(YYLTYPE * llocp, mem_collector * mc, ObjectXML * oxml,
- int& result, char ** error_msg, yyscan_t scanner, const char * str);
-
-int expr_arith_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int expr_arith_parse(ObjectXML *oxml, int& result, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = expr_arith_parse(&mc, oxml, result, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-#line 106 "expr_arith.cc"
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Use api.header.include to #include this header
- instead of duplicating it here. */
-#ifndef YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED
-# define YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int expr_arith_debug;
-#endif
-/* "%code requires" blocks. */
-#line 47 "expr_arith.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_arith_parse(ObjectXML *oxml, int& result, char ** errmsg,
- yyscan_t scanner);
-
-#line 161 "expr_arith.cc"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- INTEGER = 258,
- STRING = 259,
- FLOAT = 260
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 77 "expr_arith.y"
-
- char * val_str;
- int val_int;
- float val_float;
-
-#line 184 "expr_arith.cc"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int expr_arith_parse (mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED */
-
-
-
-#ifdef short
-# undef short
-#endif
-
-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
-#endif
-
-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
-#else
-typedef unsigned short yytype_uint16;
-#endif
-
-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE
-# if (defined __GNUC__ \
- && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
- || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
-# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
-# else
-# define YY_ATTRIBUTE(Spec) /* empty */
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_PURE
-# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YYUSE(E) ((void) (E))
-#else
-# define YYUSE(E) /* empty */
-#endif
-
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if ! defined yyoverflow || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include <alloca.h> /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include <malloc.h> /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yytype_int16 yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 10
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 25
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 12
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 3
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 12
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 20
-
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 260
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- ((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 10, 11, 5, 3, 2, 4, 2, 6, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 7, 8,
- 9
-};
-
-#if YYDEBUG
- /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_uint8 yyrline[] =
-{
- 0, 99, 99, 100, 103, 104, 105, 106, 107, 108,
- 109, 110, 111
-};
-#endif
-
-#if YYDEBUG || YYERROR_VERBOSE || 0
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "$end", "error", "$undefined", "'+'", "'-'", "'*'", "'/'", "INTEGER",
- "STRING", "FLOAT", "'('", "')'", "$accept", "stmt", "expr", YY_NULLPTR
-};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[NUM] -- (External) token number corresponding to the
- (internal) symbol number NUM (which must be that of a token). */
-static const yytype_uint16 yytoknum[] =
-{
- 0, 256, 257, 43, 45, 42, 47, 258, 259, 260,
- 40, 41
-};
-# endif
-
-#define YYPACT_NINF -5
-
-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-5)))
-
-#define YYTABLE_NINF -1
-
-#define yytable_value_is_error(Yytable_value) \
- 0
-
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int8 yypact[] =
-{
- 11, 11, -5, -5, -5, 11, 5, 19, -4, 3,
- -5, 11, 11, 11, 11, -5, -4, -4, -5, -5
-};
-
- /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 3, 0, 6, 4, 5, 0, 0, 2, 11, 0,
- 1, 0, 0, 0, 0, 12, 7, 8, 9, 10
-};
-
- /* YYPGOTO[NTERM-NUM]. */
-static const yytype_int8 yypgoto[] =
-{
- -5, -5, -1
-};
-
- /* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int8 yydefgoto[] =
-{
- -1, 6, 7
-};
-
- /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_uint8 yytable[] =
-{
- 8, 13, 14, 0, 9, 10, 11, 12, 13, 14,
- 16, 17, 18, 19, 15, 1, 0, 0, 2, 3,
- 4, 5, 11, 12, 13, 14
-};
-
-static const yytype_int8 yycheck[] =
-{
- 1, 5, 6, -1, 5, 0, 3, 4, 5, 6,
- 11, 12, 13, 14, 11, 4, -1, -1, 7, 8,
- 9, 10, 3, 4, 5, 6
-};
-
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
-{
- 0, 4, 7, 8, 9, 10, 13, 14, 14, 14,
- 0, 3, 4, 5, 6, 11, 14, 14, 14, 14
-};
-
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 12, 13, 13, 14, 14, 14, 14, 14, 14,
- 14, 14, 14
-};
-
- /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 1, 0, 1, 1, 1, 3, 3, 3,
- 3, 2, 3
-};
-
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
-
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YY_LOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-#ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
- }
-
-# define YY_LOCATION_PRINT(File, Loc) \
- yy_location_print_ (File, &(Loc))
-
-# else
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-# endif
-#endif
-
-
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value, Location, mc, oxml, result, error_msg, scanner); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner)
-{
- FILE *yyoutput = yyo;
- YYUSE (yyoutput);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (oxml);
- YYUSE (result);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yyvaluep)
- return;
-# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
-# endif
- YYUSE (yytype);
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner)
-{
- YYFPRINTF (yyo, "%s %s (",
- yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
-
- YY_LOCATION_PRINT (yyo, *yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yytype, yyvaluep, yylocationp, mc, oxml, result, error_msg, scanner);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner)
-{
- unsigned long yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- yystos[yyssp[yyi + 1 - yynrhs]],
- &yyvsp[(yyi + 1) - (yynrhs)]
- , &(yylsp[(yyi + 1) - (yynrhs)]) , mc, oxml, result, error_msg, scanner);
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule, mc, oxml, result, error_msg, scanner); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-yystrlen (const char *yystr)
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif
-
-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-{
- char *yyd = yydest;
- const char *yys = yysrc;
-
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- else
- goto append;
-
- append:
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULLPTR;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- default: /* Avoid compiler warnings. */
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner)
-{
- YYUSE (yyvaluep);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (oxml);
- YYUSE (result);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YYUSE (yytype);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner)
-{
-/* The lookahead symbol. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs;
-
- int yystate;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
-
- /* The stacks and their tools:
- 'yyss': related to states.
- 'yyvs': related to semantic values.
- 'yyls': related to locations.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- /* The location stack. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls;
- YYLTYPE *yylsp;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
- YYSIZE_T yystacksize;
-
- int yyn;
- int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yylsp = yyls = yylsa;
- yystacksize = YYINITDEPTH;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yynewstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- *yyssp = (yytype_int16) yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- goto yyexhaustedlab;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yyls1, yysize * sizeof (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = yylex (&yylval, &yylloc, mc, scanner);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 2:
-#line 99 "expr_arith.y"
- { result = static_cast<int>((yyvsp[0].val_float));}
-#line 1403 "expr_arith.cc"
- break;
-
- case 3:
-#line 100 "expr_arith.y"
- { result = 0; }
-#line 1409 "expr_arith.cc"
- break;
-
- case 4:
-#line 103 "expr_arith.y"
- { float val; oxml->search((yyvsp[0].val_str), val); (yyval.val_float) = val; }
-#line 1415 "expr_arith.cc"
- break;
-
- case 5:
-#line 104 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[0].val_float); }
-#line 1421 "expr_arith.cc"
- break;
-
- case 6:
-#line 105 "expr_arith.y"
- { (yyval.val_float) = static_cast<float>((yyvsp[0].val_int)); }
-#line 1427 "expr_arith.cc"
- break;
-
- case 7:
-#line 106 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[-2].val_float) + (yyvsp[0].val_float);}
-#line 1433 "expr_arith.cc"
- break;
-
- case 8:
-#line 107 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[-2].val_float) - (yyvsp[0].val_float);}
-#line 1439 "expr_arith.cc"
- break;
-
- case 9:
-#line 108 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[-2].val_float) * (yyvsp[0].val_float);}
-#line 1445 "expr_arith.cc"
- break;
-
- case 10:
-#line 109 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[-2].val_float) / (yyvsp[0].val_float);}
-#line 1451 "expr_arith.cc"
- break;
-
- case 11:
-#line 110 "expr_arith.y"
- { (yyval.val_float) = - (yyvsp[0].val_float);}
-#line 1457 "expr_arith.cc"
- break;
-
- case 12:
-#line 111 "expr_arith.y"
- { (yyval.val_float) = (yyvsp[-1].val_float);}
-#line 1463 "expr_arith.cc"
- break;
-
-
-#line 1467 "expr_arith.cc"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if ! YYERROR_VERBOSE
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
- }
-
- yyerror_range[1] = yylloc;
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc, mc, oxml, result, error_msg, scanner);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- yystos[yystate], yyvsp, yylsp, mc, oxml, result, error_msg, scanner);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- /* Using YYLLOC is tempting, but would change the location of
- the lookahead. YYLOC is available though. */
- YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
- *++yylsp = yyloc;
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-
-#if !defined yyoverflow || YYERROR_VERBOSE
-/*-------------------------------------------------.
-| yyexhaustedlab -- memory exhaustion comes here. |
-`-------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("memory exhausted"));
- yyresult = 2;
- /* Fall through. */
-#endif
-
-
-/*-----------------------------------------------------.
-| yyreturn -- parsing is finished, return the result. |
-`-----------------------------------------------------*/
-yyreturn:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc, mc, oxml, result, error_msg, scanner);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp, yylsp, mc, oxml, result, error_msg, scanner);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- return yyresult;
-}
-#line 114 "expr_arith.y"
-
-
-void expr_arith_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- ObjectXML * oxml,
- int& result,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.h
deleted file mode 100644
index d8fb402..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.h
+++ /dev/null
@@ -1,117 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-#ifndef YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED
-# define YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int expr_arith_debug;
-#endif
-/* "%code requires" blocks. */
-#line 47 "expr_arith.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_arith_parse(ObjectXML *oxml, int& result, char ** errmsg,
- yyscan_t scanner);
-
-#line 69 "expr_arith.hh"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- INTEGER = 258,
- STRING = 259,
- FLOAT = 260
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 77 "expr_arith.y"
-
- char * val_str;
- int val_int;
- float val_float;
-
-#line 92 "expr_arith.hh"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int expr_arith_parse (mem_collector * mc, ObjectXML * oxml, int& result, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_EXPR_ARITH_EXPR_ARITH_HH_INCLUDED */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.y b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.y
deleted file mode 100644
index 9540c92..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_arith.y
+++ /dev/null
@@ -1,141 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%{
-#include "expr_arith.h"
-#include "expr_parser.h"
-
-#define YYERROR_VERBOSE
-#define expr_arith_lex expr_lex
-
-
-void expr_arith_error(YYLTYPE * llocp, mem_collector * mc, ObjectXML * oxml,
- int& result, char ** error_msg, yyscan_t scanner, const char * str);
-
-int expr_arith_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int expr_arith_parse(ObjectXML *oxml, int& result, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = expr_arith_parse(&mc, oxml, result, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-%}
-
-%code requires {
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_arith_parse(ObjectXML *oxml, int& result, char ** errmsg,
- yyscan_t scanner);
-}
-
-%parse-param {mem_collector * mc}
-%parse-param {ObjectXML * oxml}
-%parse-param {int& result}
-%parse-param {char ** error_msg}
-%parse-param {yyscan_t scanner}
-
-%lex-param {mem_collector * mc}
-%lex-param {yyscan_t scanner}
-
-%union {
- char * val_str;
- int val_int;
- float val_float;
-};
-
-%defines
-%locations
-%pure-parser
-%name-prefix "expr_arith_"
-%output "expr_arith.cc"
-
-%left '+' '-'
-%left '*' '/'
-%token <val_int> INTEGER
-%token <val_str> STRING
-%token <val_float> FLOAT
-%type <val_int> stmt
-%type <val_float> expr
-
-%%
-
-stmt: expr { result = static_cast<int>($1);}
- | { result = 0; }
- ;
-
-expr: STRING { float val; oxml->search($1, val); $$ = val; }
- | FLOAT { $$ = $1; }
- | INTEGER { $$ = static_cast<float>($1); }
- | expr '+' expr { $$ = $1 + $3;}
- | expr '-' expr { $$ = $1 - $3;}
- | expr '*' expr { $$ = $1 * $3;}
- | expr '/' expr { $$ = $1 / $3;}
- | '-' expr { $$ = - $2;}
- | '(' expr ')' { $$ = $2;}
- ;
-
-%%
-
-void expr_arith_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- ObjectXML * oxml,
- int& result,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.cc
deleted file mode 100644
index 024999a..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.cc
+++ /dev/null
@@ -1,1902 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Bison version. */
-#define YYBISON_VERSION "3.4.1"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 1
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse expr_bool_parse
-#define yylex expr_bool_lex
-#define yyerror expr_bool_error
-#define yydebug expr_bool_debug
-#define yynerrs expr_bool_nerrs
-
-
-/* First part of user prologue. */
-#line 18 "expr_bool.y"
-
-#include "expr_bool.h"
-#include "expr_parser.h"
-
-#define YYERROR_VERBOSE
-#define expr_bool_lex expr_lex
-
-void expr_bool_error(YYLTYPE * llocp, mem_collector * mc, ObjectXML * oxml,
- bool& result, char ** error_msg, yyscan_t scanner, const char * str);
-
-int expr_bool_lex (YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int expr_bool_parse(ObjectXML *oxml, bool& result, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = expr_bool_parse(&mc, oxml, result, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-
-#line 106 "expr_bool.cc"
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Use api.header.include to #include this header
- instead of duplicating it here. */
-#ifndef YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED
-# define YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int expr_bool_debug;
-#endif
-/* "%code requires" blocks. */
-#line 48 "expr_bool.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_bool_parse(ObjectXML *oxml, bool& result, char ** errmsg,
- yyscan_t scanner);
-
-#line 162 "expr_bool.cc"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- INTEGER = 258,
- STRING = 259,
- FLOAT = 260
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 79 "expr_bool.y"
-
- char * val_str;
- int val_int;
- float val_float;
-
-#line 185 "expr_bool.cc"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int expr_bool_parse (mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED */
-
-
-
-#ifdef short
-# undef short
-#endif
-
-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
-#endif
-
-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
-#else
-typedef unsigned short yytype_uint16;
-#endif
-
-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE
-# if (defined __GNUC__ \
- && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
- || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
-# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
-# else
-# define YY_ATTRIBUTE(Spec) /* empty */
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_PURE
-# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YYUSE(E) ((void) (E))
-#else
-# define YYUSE(E) /* empty */
-#endif
-
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if ! defined yyoverflow || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include <alloca.h> /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include <malloc.h> /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yytype_int16 yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 13
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 34
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 15
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 3
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 20
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 34
-
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 260
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- ((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 3, 2, 2, 2, 2, 4, 2,
- 13, 14, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 11, 9, 10, 2, 12, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 5, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 6, 7,
- 8
-};
-
-#if YYDEBUG
- /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_uint8 yyrline[] =
-{
- 0, 99, 99, 100, 103, 112, 121, 128, 135, 153,
- 160, 167, 174, 181, 199, 207, 215, 236, 237, 238,
- 239
-};
-#endif
-
-#if YYDEBUG || YYERROR_VERBOSE || 0
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "$end", "error", "$undefined", "'!'", "'&'", "'|'", "INTEGER", "STRING",
- "FLOAT", "'='", "'>'", "'<'", "'@'", "'('", "')'", "$accept", "stmt",
- "expr", YY_NULLPTR
-};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[NUM] -- (External) token number corresponding to the
- (internal) symbol number NUM (which must be that of a token). */
-static const yytype_uint16 yytoknum[] =
-{
- 0, 256, 257, 33, 38, 124, 258, 259, 260, 61,
- 62, 60, 64, 40, 41
-};
-# endif
-
-#define YYPACT_NINF -6
-
-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-6)))
-
-#define YYTABLE_NINF -1
-
-#define yytable_value_is_error(Yytable_value) \
- 0
-
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int8 yypact[] =
-{
- -2, -2, 9, -2, 3, 4, -6, -5, 16, 25,
- 26, 0, 2, -6, -2, -2, 19, -6, -6, -6,
- -6, -6, -6, -6, 22, -6, -6, -6, -6, -6,
- -6, -6, -6, -6
-};
-
- /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 3, 0, 0, 0, 0, 2, 19, 0, 0, 0,
- 0, 0, 0, 1, 0, 0, 0, 4, 14, 9,
- 6, 11, 7, 12, 0, 20, 17, 18, 5, 15,
- 10, 8, 16, 13
-};
-
- /* YYPGOTO[NTERM-NUM]. */
-static const yytype_int8 yypgoto[] =
-{
- -6, -6, -1
-};
-
- /* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int8 yydefgoto[] =
-{
- -1, 4, 5
-};
-
- /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_uint8 yytable[] =
-{
- 6, 1, 12, 13, 16, 2, 14, 15, 14, 15,
- 24, 3, 7, 26, 27, 0, 25, 0, 8, 9,
- 10, 11, 17, 18, 19, 28, 29, 30, 31, 32,
- 33, 20, 22, 21, 23
-};
-
-static const yytype_int8 yycheck[] =
-{
- 1, 3, 3, 0, 9, 7, 4, 5, 4, 5,
- 10, 13, 3, 14, 15, -1, 14, -1, 9, 10,
- 11, 12, 6, 7, 8, 6, 7, 8, 6, 7,
- 8, 6, 6, 8, 8
-};
-
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
-{
- 0, 3, 7, 13, 16, 17, 17, 3, 9, 10,
- 11, 12, 17, 0, 4, 5, 9, 6, 7, 8,
- 6, 8, 6, 8, 10, 14, 17, 17, 6, 7,
- 8, 6, 7, 8
-};
-
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 15, 16, 16, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17
-};
-
- /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 1, 0, 3, 4, 3, 3, 4, 3,
- 4, 3, 3, 4, 3, 4, 4, 3, 3, 2,
- 3
-};
-
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
-
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YY_LOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-#ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
- }
-
-# define YY_LOCATION_PRINT(File, Loc) \
- yy_location_print_ (File, &(Loc))
-
-# else
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-# endif
-#endif
-
-
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value, Location, mc, oxml, result, error_msg, scanner); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner)
-{
- FILE *yyoutput = yyo;
- YYUSE (yyoutput);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (oxml);
- YYUSE (result);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yyvaluep)
- return;
-# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
-# endif
- YYUSE (yytype);
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner)
-{
- YYFPRINTF (yyo, "%s %s (",
- yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
-
- YY_LOCATION_PRINT (yyo, *yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yytype, yyvaluep, yylocationp, mc, oxml, result, error_msg, scanner);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner)
-{
- unsigned long yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- yystos[yyssp[yyi + 1 - yynrhs]],
- &yyvsp[(yyi + 1) - (yynrhs)]
- , &(yylsp[(yyi + 1) - (yynrhs)]) , mc, oxml, result, error_msg, scanner);
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule, mc, oxml, result, error_msg, scanner); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-yystrlen (const char *yystr)
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif
-
-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-{
- char *yyd = yydest;
- const char *yys = yysrc;
-
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- else
- goto append;
-
- append:
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULLPTR;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- default: /* Avoid compiler warnings. */
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner)
-{
- YYUSE (yyvaluep);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (oxml);
- YYUSE (result);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YYUSE (yytype);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner)
-{
-/* The lookahead symbol. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs;
-
- int yystate;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
-
- /* The stacks and their tools:
- 'yyss': related to states.
- 'yyvs': related to semantic values.
- 'yyls': related to locations.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- /* The location stack. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls;
- YYLTYPE *yylsp;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
- YYSIZE_T yystacksize;
-
- int yyn;
- int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yylsp = yyls = yylsa;
- yystacksize = YYINITDEPTH;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yynewstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- *yyssp = (yytype_int16) yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- goto yyexhaustedlab;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yyls1, yysize * sizeof (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = yylex (&yylval, &yylloc, mc, scanner);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 2:
-#line 99 "expr_bool.y"
- { result=(yyvsp[0].val_int); }
-#line 1416 "expr_bool.cc"
- break;
-
- case 3:
-#line 100 "expr_bool.y"
- { result=true; }
-#line 1422 "expr_bool.cc"
- break;
-
- case 4:
-#line 103 "expr_bool.y"
- {
- int val = (yyvsp[0].val_int);
- int rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
-
- (yyval.val_int) = (rc == 0 && val == (yyvsp[0].val_int));
- }
-#line 1435 "expr_bool.cc"
- break;
-
- case 5:
-#line 112 "expr_bool.y"
- {
- int val = (yyvsp[0].val_int);
- int rc;
-
- rc = oxml->search((yyvsp[-3].val_str),val);
-
- (yyval.val_int) = (rc == 0 && val != (yyvsp[0].val_int));
- }
-#line 1448 "expr_bool.cc"
- break;
-
- case 6:
-#line 121 "expr_bool.y"
- {
- int val, rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc == 0 && val > (yyvsp[0].val_int));
- }
-#line 1459 "expr_bool.cc"
- break;
-
- case 7:
-#line 128 "expr_bool.y"
- {
- int val, rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc == 0 && val < (yyvsp[0].val_int));
- }
-#line 1470 "expr_bool.cc"
- break;
-
- case 8:
-#line 135 "expr_bool.y"
- {
- std::vector<int> val;
- std::vector<int>::iterator it;
-
- (yyval.val_int) = false;
-
- oxml->search((yyvsp[-3].val_str),val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ((yyvsp[0].val_int) == *it)
- {
- (yyval.val_int) = true;
- break;
- }
- }
- }
-#line 1492 "expr_bool.cc"
- break;
-
- case 9:
-#line 153 "expr_bool.y"
- {
- float val, rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc == 0 && val == (yyvsp[0].val_float));
- }
-#line 1503 "expr_bool.cc"
- break;
-
- case 10:
-#line 160 "expr_bool.y"
- {
- float val, rc;
-
- rc = oxml->search((yyvsp[-3].val_str),val);
- (yyval.val_int) = (rc == 0 && val != (yyvsp[0].val_float));
- }
-#line 1514 "expr_bool.cc"
- break;
-
- case 11:
-#line 167 "expr_bool.y"
- {
- float val, rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc == 0 && val > (yyvsp[0].val_float));
- }
-#line 1525 "expr_bool.cc"
- break;
-
- case 12:
-#line 174 "expr_bool.y"
- {
- float val, rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc == 0 && val < (yyvsp[0].val_float));
- }
-#line 1536 "expr_bool.cc"
- break;
-
- case 13:
-#line 181 "expr_bool.y"
- {
- std::vector<float> val;
- std::vector<float>::iterator it;
-
- (yyval.val_int) = false;
-
- oxml->search((yyvsp[-3].val_str),val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ((yyvsp[0].val_float) == *it)
- {
- (yyval.val_int) = true;
- break;
- }
- }
- }
-#line 1558 "expr_bool.cc"
- break;
-
- case 14:
-#line 199 "expr_bool.y"
- {
- std::string val;
- int rc;
-
- rc = oxml->search((yyvsp[-2].val_str),val);
- (yyval.val_int) = (rc != 0 || (yyvsp[0].val_str)==0) ? false : fnmatch((yyvsp[0].val_str),val.c_str(),0)==0;
- }
-#line 1570 "expr_bool.cc"
- break;
-
- case 15:
-#line 207 "expr_bool.y"
- {
- std::string val;
- int rc;
-
- rc = oxml->search((yyvsp[-3].val_str),val);
- (yyval.val_int) = (rc != 0 || (yyvsp[0].val_str)==0) ? false : fnmatch((yyvsp[0].val_str),val.c_str(),0)!=0;
- }
-#line 1582 "expr_bool.cc"
- break;
-
- case 16:
-#line 215 "expr_bool.y"
- {
- std::vector<std::string> val;
- std::vector<std::string>::iterator it;
-
- (yyval.val_int) = false;
-
- if ( (yyvsp[0].val_str) != 0 )
- {
- oxml->search((yyvsp[-3].val_str),val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ( fnmatch((yyvsp[0].val_str), (*it).c_str(), 0) == 0 )
- {
- (yyval.val_int) = true;
- break;
- }
- }
- }
- }
-#line 1607 "expr_bool.cc"
- break;
-
- case 17:
-#line 236 "expr_bool.y"
- { (yyval.val_int) = (yyvsp[-2].val_int) && (yyvsp[0].val_int); }
-#line 1613 "expr_bool.cc"
- break;
-
- case 18:
-#line 237 "expr_bool.y"
- { (yyval.val_int) = (yyvsp[-2].val_int) || (yyvsp[0].val_int); }
-#line 1619 "expr_bool.cc"
- break;
-
- case 19:
-#line 238 "expr_bool.y"
- { (yyval.val_int) = ! (yyvsp[0].val_int); }
-#line 1625 "expr_bool.cc"
- break;
-
- case 20:
-#line 239 "expr_bool.y"
- { (yyval.val_int) = (yyvsp[-1].val_int); }
-#line 1631 "expr_bool.cc"
- break;
-
-
-#line 1635 "expr_bool.cc"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if ! YYERROR_VERBOSE
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
- }
-
- yyerror_range[1] = yylloc;
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc, mc, oxml, result, error_msg, scanner);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- yystos[yystate], yyvsp, yylsp, mc, oxml, result, error_msg, scanner);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- /* Using YYLLOC is tempting, but would change the location of
- the lookahead. YYLOC is available though. */
- YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
- *++yylsp = yyloc;
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-
-#if !defined yyoverflow || YYERROR_VERBOSE
-/*-------------------------------------------------.
-| yyexhaustedlab -- memory exhaustion comes here. |
-`-------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, mc, oxml, result, error_msg, scanner, YY_("memory exhausted"));
- yyresult = 2;
- /* Fall through. */
-#endif
-
-
-/*-----------------------------------------------------.
-| yyreturn -- parsing is finished, return the result. |
-`-----------------------------------------------------*/
-yyreturn:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc, mc, oxml, result, error_msg, scanner);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp, yylsp, mc, oxml, result, error_msg, scanner);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- return yyresult;
-}
-#line 242 "expr_bool.y"
-
-
-void expr_bool_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- ObjectXML * oxml,
- bool& result,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-
- result = false;
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.h
deleted file mode 100644
index e179ddb..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.h
+++ /dev/null
@@ -1,118 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-#ifndef YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED
-# define YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int expr_bool_debug;
-#endif
-/* "%code requires" blocks. */
-#line 48 "expr_bool.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_bool_parse(ObjectXML *oxml, bool& result, char ** errmsg,
- yyscan_t scanner);
-
-#line 70 "expr_bool.hh"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- INTEGER = 258,
- STRING = 259,
- FLOAT = 260
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 79 "expr_bool.y"
-
- char * val_str;
- int val_int;
- float val_float;
-
-#line 93 "expr_bool.hh"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int expr_bool_parse (mem_collector * mc, ObjectXML * oxml, bool& result, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_EXPR_BOOL_EXPR_BOOL_HH_INCLUDED */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.y b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.y
deleted file mode 100644
index 17bdd16..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_bool.y
+++ /dev/null
@@ -1,271 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-
-%{
-#include "expr_bool.h"
-#include "expr_parser.h"
-
-#define YYERROR_VERBOSE
-#define expr_bool_lex expr_lex
-
-void expr_bool_error(YYLTYPE * llocp, mem_collector * mc, ObjectXML * oxml,
- bool& result, char ** error_msg, yyscan_t scanner, const char * str);
-
-int expr_bool_lex (YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int expr_bool_parse(ObjectXML *oxml, bool& result, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = expr_bool_parse(&mc, oxml, result, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-%}
-
-%code requires {
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <vector>
-#include <algorithm>
-#include <set>
-
-#include <ctype.h>
-#include <string.h>
-#include <fnmatch.h>
-
-#include "mem_collector.h"
-
-#include "ObjectXML.h"
-
-typedef void * yyscan_t;
-
-int expr_bool_parse(ObjectXML *oxml, bool& result, char ** errmsg,
- yyscan_t scanner);
-}
-
-%parse-param {mem_collector * mc}
-%parse-param {ObjectXML * oxml}
-%parse-param {bool& result}
-%parse-param {char ** error_msg}
-%parse-param {yyscan_t scanner}
-
-%lex-param {mem_collector * mc}
-%lex-param {yyscan_t scanner}
-
-%union {
- char * val_str;
- int val_int;
- float val_float;
-};
-
-%defines
-%locations
-%pure-parser
-%name-prefix "expr_bool_"
-%output "expr_bool.cc"
-
-%left '!' '&' '|'
-%token <val_int> INTEGER
-%token <val_str> STRING
-%token <val_float> FLOAT
-%type <val_int> stmt expr
-
-%%
-
-stmt: expr { result=$1; }
- | { result=true; } /* TRUE BY DEFAULT, ON EMPTY STRINGS */
- ;
-
-expr: STRING '=' INTEGER {
- int val = $3;
- int rc;
-
- rc = oxml->search($1,val);
-
- $$ = (rc == 0 && val == $3);
- }
-
- | STRING '!' '=' INTEGER {
- int val = $4;
- int rc;
-
- rc = oxml->search($1,val);
-
- $$ = (rc == 0 && val != $4);
- }
-
- | STRING '>' INTEGER {
- int val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val > $3);
- }
-
- | STRING '<' INTEGER {
- int val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val < $3);
- }
-
- | STRING '@''>' INTEGER {
- std::vector<int> val;
- std::vector<int>::iterator it;
-
- $$ = false;
-
- oxml->search($1,val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ($4 == *it)
- {
- $$ = true;
- break;
- }
- }
- }
-
- | STRING '=' FLOAT {
- float val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val == $3);
- }
-
- | STRING '!' '=' FLOAT {
- float val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val != $4);
- }
-
- | STRING '>' FLOAT {
- float val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val > $3);
- }
-
- | STRING '<' FLOAT {
- float val, rc;
-
- rc = oxml->search($1,val);
- $$ = (rc == 0 && val < $3);
- }
-
- | STRING '@''>' FLOAT {
- std::vector<float> val;
- std::vector<float>::iterator it;
-
- $$ = false;
-
- oxml->search($1,val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ($4 == *it)
- {
- $$ = true;
- break;
- }
- }
- }
-
- | STRING '=' STRING {
- std::string val;
- int rc;
-
- rc = oxml->search($1,val);
- $$ = (rc != 0 || $3==0) ? false : fnmatch($3,val.c_str(),0)==0;
- }
-
- | STRING '!''=' STRING {
- std::string val;
- int rc;
-
- rc = oxml->search($1,val);
- $$ = (rc != 0 || $4==0) ? false : fnmatch($4,val.c_str(),0)!=0;
- }
-
- | STRING '@''>' STRING {
- std::vector<std::string> val;
- std::vector<std::string>::iterator it;
-
- $$ = false;
-
- if ( $4 != 0 )
- {
- oxml->search($1,val);
-
- for (it=val.begin(); it != val.end(); ++it)
- {
- if ( fnmatch($4, (*it).c_str(), 0) == 0 )
- {
- $$ = true;
- break;
- }
- }
- }
- }
-
- | expr '&' expr { $$ = $1 && $3; }
- | expr '|' expr { $$ = $1 || $3; }
- | '!' expr { $$ = ! $2; }
- | '(' expr ')' { $$ = $2; }
- ;
-
-%%
-
-void expr_bool_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- ObjectXML * oxml,
- bool& result,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-
- result = false;
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.cc
deleted file mode 100644
index 5809272..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.cc
+++ /dev/null
@@ -1,2260 +0,0 @@
-#line 1 "expr_parser.cc"
-
-#line 3 "expr_parser.cc"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define expr__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer expr__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define expr__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer expr__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define expr__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer expr__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define expr__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string expr__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define expr__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes expr__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define expr__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer expr__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define expr__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer expr__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define expr__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state expr__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define expr__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer expr__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define expr_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state expr_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define expr_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state expr_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define expr_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack expr_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define expr_lex_ALREADY_DEFINED
-#else
-#define yylex expr_lex
-#endif
-
-#ifdef yyrestart
-#define expr_restart_ALREADY_DEFINED
-#else
-#define yyrestart expr_restart
-#endif
-
-#ifdef yylex_init
-#define expr_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init expr_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define expr_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra expr_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define expr_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy expr_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define expr_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug expr_get_debug
-#endif
-
-#ifdef yyset_debug
-#define expr_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug expr_set_debug
-#endif
-
-#ifdef yyget_extra
-#define expr_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra expr_get_extra
-#endif
-
-#ifdef yyset_extra
-#define expr_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra expr_set_extra
-#endif
-
-#ifdef yyget_in
-#define expr_get_in_ALREADY_DEFINED
-#else
-#define yyget_in expr_get_in
-#endif
-
-#ifdef yyset_in
-#define expr_set_in_ALREADY_DEFINED
-#else
-#define yyset_in expr_set_in
-#endif
-
-#ifdef yyget_out
-#define expr_get_out_ALREADY_DEFINED
-#else
-#define yyget_out expr_get_out
-#endif
-
-#ifdef yyset_out
-#define expr_set_out_ALREADY_DEFINED
-#else
-#define yyset_out expr_set_out
-#endif
-
-#ifdef yyget_leng
-#define expr_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng expr_get_leng
-#endif
-
-#ifdef yyget_text
-#define expr_get_text_ALREADY_DEFINED
-#else
-#define yyget_text expr_get_text
-#endif
-
-#ifdef yyget_lineno
-#define expr_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno expr_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define expr_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno expr_set_lineno
-#endif
-
-#ifdef yyget_column
-#define expr_get_column_ALREADY_DEFINED
-#else
-#define yyget_column expr_get_column
-#endif
-
-#ifdef yyset_column
-#define expr_set_column_ALREADY_DEFINED
-#else
-#define yyset_column expr_set_column
-#endif
-
-#ifdef yywrap
-#define expr_wrap_ALREADY_DEFINED
-#else
-#define yywrap expr_wrap
-#endif
-
-#ifdef yyget_lval
-#define expr_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval expr_get_lval
-#endif
-
-#ifdef yyset_lval
-#define expr_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval expr_set_lval
-#endif
-
-#ifdef yyalloc
-#define expr_alloc_ALREADY_DEFINED
-#else
-#define yyalloc expr_alloc
-#endif
-
-#ifdef yyrealloc
-#define expr_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc expr_realloc
-#endif
-
-#ifdef yyfree
-#define expr_free_ALREADY_DEFINED
-#else
-#define yyfree expr_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an
- * integer in range [0..255] for use as an array index.
- */
-#define YY_SC_TO_UI(c) ((YY_CHAR) (c))
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yyg->yy_start = 1 + 2 *
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yyg->yy_start - 1) / 2)
-#define YYSTATE YY_START
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin , yyscanner )
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-/* The state buf must be large enough to hold one state per character in the main buffer.
- */
-#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
- /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
- * access to the local variable yy_act. Since yyless() is a macro, it would break
- * existing scanners that call yyless() from OUTSIDE yylex.
- * One obvious solution it to make yy_act a global. I tried that, and saw
- * a 5% performance hit in a non-yylineno scanner, because yy_act is
- * normally declared as a register variable-- so it is not worth it.
- */
- #define YY_LESS_LINENO(n) \
- do { \
- int yyl;\
- for ( yyl = n; yyl < yyleng; ++yyl )\
- if ( yytext[yyl] == '\n' )\
- --yylineno;\
- }while(0)
- #define YY_LINENO_REWIND_TO(dst) \
- do {\
- const char *p;\
- for ( p = yy_cp-1; p >= (dst); --p)\
- if ( *p == '\n' )\
- --yylineno;\
- }while(0)
-
-/* Return all but the first "n" matched characters back to the input stream. */
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- *yy_cp = yyg->yy_hold_char; \
- YY_RESTORE_YY_MORE_OFFSET \
- yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- *
- * Returns the top of the stack, or NULL.
- */
-#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
- ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
- : NULL)
-/* Same as previous macro, but useful when we know that the buffer stack is not
- * NULL or when we need an lvalue. For internal use only.
- */
-#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-static void yyensure_buffer_stack ( yyscan_t yyscanner );
-static void yy_load_buffer_state ( yyscan_t yyscanner );
-static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file , yyscan_t yyscanner );
-#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner)
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-#define yy_new_buffer yy_create_buffer
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! YY_CURRENT_BUFFER ){ \
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
- }
-#define yy_set_bol(at_bol) \
- { \
- if ( ! YY_CURRENT_BUFFER ){\
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
- }
-#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
-
-/* Begin user sect3 */
-typedef flex_uint8_t YY_CHAR;
-
-typedef int yy_state_type;
-
-#define yytext_ptr yytext_r
-
-static yy_state_type yy_get_previous_state ( yyscan_t yyscanner );
-static yy_state_type yy_try_NUL_trans ( yy_state_type current_state , yyscan_t yyscanner);
-static int yy_get_next_buffer ( yyscan_t yyscanner );
-static void yynoreturn yy_fatal_error ( const char* msg , yyscan_t yyscanner );
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yyg->yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yyg->yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yyg->yy_c_buf_p = yy_cp;
-#define YY_NUM_RULES 8
-#define YY_END_OF_BUFFER 9
-/* This struct is not used in this scanner,
- but its presence is necessary. */
-struct yy_trans_info
- {
- flex_int32_t yy_verify;
- flex_int32_t yy_nxt;
- };
-static const flex_int16_t yy_accept[20] =
- { 0,
- 7, 7, 9, 8, 7, 1, 8, 1, 5, 2,
- 7, 0, 3, 5, 0, 2, 4, 6, 0
- } ;
-
-static const YY_CHAR yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 3, 4, 1, 1, 1, 3, 1, 3,
- 3, 3, 3, 1, 5, 6, 3, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 1, 1, 3,
- 3, 3, 1, 3, 8, 8, 8, 8, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 1, 1, 1, 3, 9, 1, 8, 8, 8, 8,
-
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 8, 8, 1, 3, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static const YY_CHAR yy_meta[10] =
- { 0,
- 1, 1, 1, 1, 1, 1, 2, 2, 2
- } ;
-
-static const flex_int16_t yy_base[22] =
- { 0,
- 0, 0, 22, 23, 19, 23, 16, 12, 4, 0,
- 16, 13, 23, 0, 9, 0, 23, 8, 23, 11,
- 12
- } ;
-
-static const flex_int16_t yy_def[22] =
- { 0,
- 19, 1, 19, 19, 19, 19, 20, 19, 19, 21,
- 19, 20, 19, 9, 19, 21, 19, 19, 0, 19,
- 19
- } ;
-
-static const flex_int16_t yy_nxt[33] =
- { 0,
- 4, 5, 6, 7, 8, 4, 9, 10, 4, 15,
- 14, 12, 12, 16, 18, 18, 17, 11, 14, 13,
- 11, 19, 3, 19, 19, 19, 19, 19, 19, 19,
- 19, 19
- } ;
-
-static const flex_int16_t yy_chk[33] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 9,
- 9, 20, 20, 21, 18, 15, 12, 11, 8, 7,
- 5, 3, 19, 19, 19, 19, 19, 19, 19, 19,
- 19, 19
- } ;
-
-/* Table of booleans, true if rule could match eol. */
-static const flex_int32_t yy_rule_can_match_eol[9] =
- { 0,
-0, 0, 0, 1, 0, 0, 0, 0, };
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-#define YY_RESTORE_YY_MORE_OFFSET
-#line 1 "expr_parser.l"
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-#line 18 "expr_parser.l"
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "expr_bool.h"
-#include "expr_arith.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int expr_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-#line 706 "expr_parser.cc"
-#line 707 "expr_parser.cc"
-
-#define INITIAL 0
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-/* Holds the entire state of the reentrant scanner. */
-struct yyguts_t
- {
-
- /* User-defined. Not touched by flex. */
- YY_EXTRA_TYPE yyextra_r;
-
- /* The rest are the same as the globals declared in the non-reentrant scanner. */
- FILE *yyin_r, *yyout_r;
- size_t yy_buffer_stack_top; /**< index of top of stack. */
- size_t yy_buffer_stack_max; /**< capacity of stack. */
- YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
- char yy_hold_char;
- int yy_n_chars;
- int yyleng_r;
- char *yy_c_buf_p;
- int yy_init;
- int yy_start;
- int yy_did_buffer_switch_on_eof;
- int yy_start_stack_ptr;
- int yy_start_stack_depth;
- int *yy_start_stack;
- yy_state_type yy_last_accepting_state;
- char* yy_last_accepting_cpos;
-
- int yylineno_r;
- int yy_flex_debug_r;
-
- char *yytext_r;
- int yy_more_flag;
- int yy_more_len;
-
- YYSTYPE * yylval_r;
-
- }; /* end struct yyguts_t */
-
-static int yy_init_globals ( yyscan_t yyscanner );
-
- /* This must go here because YYSTYPE and YYLTYPE are included
- * from bison output in section 1.*/
- # define yylval yyg->yylval_r
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput ( yyscan_t yyscanner );
-#else
-static int input ( yyscan_t yyscanner );
-#endif
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
- { \
- int c = '*'; \
- int n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else \
- { \
- errno=0; \
- while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
- { \
- if( errno != EINTR) \
- { \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- break; \
- } \
- errno=0; \
- clearerr(yyin); \
- } \
- }\
-\
-
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
-#endif
-
-/* end tables serialization structures and prototypes */
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK /*LINTED*/break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-/** The main scanner function which does all the work.
- */
-YY_DECL
-{
- yy_state_type yy_current_state;
- char *yy_cp, *yy_bp;
- int yy_act;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yylval = yylval_param;
-
- if ( !yyg->yy_init )
- {
- yyg->yy_init = 1;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yyg->yy_start )
- yyg->yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! YY_CURRENT_BUFFER ) {
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_load_buffer_state( yyscanner );
- }
-
- {
-#line 43 "expr_parser.l"
-
-#line 45 "expr_parser.l"
- /* --- Tokens --- */
-
-#line 984 "expr_parser.cc"
-
- while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yyg->yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yyg->yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yyg->yy_start;
-yy_match:
- do
- {
- YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 20 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 23 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
- if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
- {
- int yyl;
- for ( yyl = 0; yyl < yyleng; ++yyl )
- if ( yytext[yyl] == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
- }
-
-do_action: /* This label is used only to access EOF actions. */
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yyg->yy_hold_char;
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-YY_RULE_SETUP
-#line 47 "expr_parser.l"
-{ return *yytext;}
- YY_BREAK
-/* --- Strings, also quoted form --- */
-case 2:
-YY_RULE_SETUP
-#line 51 "expr_parser.l"
-{ yylval_param->val_str = mem_collector_strdup(mc,yytext);
- return STRING;}
- YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 54 "expr_parser.l"
-{ yylval_param->val_str = NULL;
- return STRING;}
- YY_BREAK
-case 4:
-/* rule 4 can match eol */
-YY_RULE_SETUP
-#line 57 "expr_parser.l"
-{ yylval_param->val_str = mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- return STRING;}
- YY_BREAK
-/* --- Numbers --- */
-case 5:
-YY_RULE_SETUP
-#line 63 "expr_parser.l"
-{ yylval_param->val_int = atoi(yytext);
- return INTEGER;}
- YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 66 "expr_parser.l"
-{ yylval_param->val_float = atof(yytext);
- return FLOAT;}
- YY_BREAK
-/* --- blanks --- */
-case 7:
-YY_RULE_SETUP
-#line 71 "expr_parser.l"
-
- YY_BREAK
-case 8:
-YY_RULE_SETUP
-#line 73 "expr_parser.l"
-ECHO;
- YY_BREAK
-#line 1103 "expr_parser.cc"
-case YY_STATE_EOF(INITIAL):
- yyterminate();
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yyg->yy_hold_char;
- YY_RESTORE_YY_MORE_OFFSET
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between YY_CURRENT_BUFFER and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
-
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yyg->yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yyg->yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yyg->yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap( yyscanner ) )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p =
- yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yyg->yy_c_buf_p =
- &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of user's declarations */
-} /* end of yylex */
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-static int yy_get_next_buffer (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
- char *source = yyg->yytext_ptr;
- int number_to_move, i;
- int ret_val;
-
- if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a single character, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
-
- int yy_c_buf_p_offset =
- (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yyrealloc( (void *) b->yy_ch_buf,
- (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = NULL;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
- number_to_move - 1;
-
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
- yyg->yy_n_chars, num_to_read );
-
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- if ( yyg->yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin , yyscanner);
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
- /* Extend the array by 50%, plus the number we really need. */
- int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
- (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner );
- if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
- /* "- 2" to take care of EOB's */
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
- }
-
- yyg->yy_n_chars += number_to_move;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
-
- return ret_val;
-}
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
- static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
-{
- yy_state_type yy_current_state;
- char *yy_cp;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_current_state = yyg->yy_start;
-
- for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
- {
- YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 20 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- }
-
- return yy_current_state;
-}
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
- static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
-{
- int yy_is_jam;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
- char *yy_cp = yyg->yy_c_buf_p;
-
- YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 20 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- yy_is_jam = (yy_current_state == 19);
-
- (void)yyg;
- return yy_is_jam ? 0 : yy_current_state;
-}
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
- static int yyinput (yyscan_t yyscanner)
-#else
- static int input (yyscan_t yyscanner)
-#endif
-
-{
- int c;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
-
- if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- /* This was really a NUL. */
- *yyg->yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- int offset = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr);
- ++yyg->yy_c_buf_p;
-
- switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_LAST_MATCH:
- /* This happens because yy_g_n_b()
- * sees that we've accumulated a
- * token and flags that we need to
- * try matching the token before
- * proceeding. But for input(),
- * there's no matching to consider.
- * So convert the EOB_ACT_LAST_MATCH
- * to EOB_ACT_END_OF_FILE.
- */
-
- /* Reset buffer status. */
- yyrestart( yyin , yyscanner);
-
- /*FALLTHROUGH*/
-
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap( yyscanner ) )
- return 0;
-
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput(yyscanner);
-#else
- return input(yyscanner);
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
- break;
- }
- }
- }
-
- c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
- *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
- yyg->yy_hold_char = *++yyg->yy_c_buf_p;
-
- if ( c == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
-
- return c;
-}
-#endif /* ifndef YY_NO_INPUT */
-
-/** Immediately switch to a different input stream.
- * @param input_file A readable stream.
- * @param yyscanner The scanner object.
- * @note This function does not reset the start condition to @c INITIAL .
- */
- void yyrestart (FILE * input_file , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! YY_CURRENT_BUFFER ){
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
- yy_load_buffer_state( yyscanner );
-}
-
-/** Switch to a different input buffer.
- * @param new_buffer The new input buffer.
- * @param yyscanner The scanner object.
- */
- void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* TODO. We should be able to replace this entire function body
- * with
- * yypop_buffer_state();
- * yypush_buffer_state(new_buffer);
- */
- yyensure_buffer_stack (yyscanner);
- if ( YY_CURRENT_BUFFER == new_buffer )
- return;
-
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
- yy_load_buffer_state( yyscanner );
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-static void yy_load_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
- yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
- yyg->yy_hold_char = *yyg->yy_c_buf_p;
-}
-
-/** Allocate and initialize an input buffer state.
- * @param file A readable stream.
- * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
- * @param yyscanner The scanner object.
- * @return the allocated buffer state.
- */
- YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file , yyscanner);
-
- return b;
-}
-
-/** Destroy the buffer.
- * @param b a buffer created with yy_create_buffer()
- * @param yyscanner The scanner object.
- */
- void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! b )
- return;
-
- if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
- YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yyfree( (void *) b->yy_ch_buf , yyscanner );
-
- yyfree( (void *) b , yyscanner );
-}
-
-/* Initializes or reinitializes a buffer.
- * This function is sometimes called more than once on the same buffer,
- * such as during a yyrestart() or at EOF.
- */
- static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
-
-{
- int oerrno = errno;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_flush_buffer( b , yyscanner);
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
- /* If b is the current buffer, then yy_init_buffer was _probably_
- * called from yyrestart() or through yy_get_next_buffer.
- * In that case, we don't want to reset the lineno or column.
- */
- if (b != YY_CURRENT_BUFFER){
- b->yy_bs_lineno = 1;
- b->yy_bs_column = 0;
- }
-
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-
- errno = oerrno;
-}
-
-/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
- * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
- * @param yyscanner The scanner object.
- */
- void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if ( ! b )
- return;
-
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == YY_CURRENT_BUFFER )
- yy_load_buffer_state( yyscanner );
-}
-
-/** Pushes the new state onto the stack. The new state becomes
- * the current state. This function will allocate the stack
- * if necessary.
- * @param new_buffer The new state.
- * @param yyscanner The scanner object.
- */
-void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (new_buffer == NULL)
- return;
-
- yyensure_buffer_stack(yyscanner);
-
- /* This block is copied from yy_switch_to_buffer. */
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- /* Only push if top exists. Otherwise, replace top. */
- if (YY_CURRENT_BUFFER)
- yyg->yy_buffer_stack_top++;
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
-
- /* copied from yy_switch_to_buffer. */
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-/** Removes and deletes the top of the stack, if present.
- * The next element becomes the new top.
- * @param yyscanner The scanner object.
- */
-void yypop_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (!YY_CURRENT_BUFFER)
- return;
-
- yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
- YY_CURRENT_BUFFER_LVALUE = NULL;
- if (yyg->yy_buffer_stack_top > 0)
- --yyg->yy_buffer_stack_top;
-
- if (YY_CURRENT_BUFFER) {
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
- }
-}
-
-/* Allocates the stack if it does not exist.
- * Guarantees space for at least one push.
- */
-static void yyensure_buffer_stack (yyscan_t yyscanner)
-{
- yy_size_t num_to_alloc;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (!yyg->yy_buffer_stack) {
-
- /* First allocation is just for 2 elements, since we don't know if this
- * scanner will even need a stack. We use 2 instead of 1 to avoid an
- * immediate realloc on the next call.
- */
- num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
- (num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
-
- yyg->yy_buffer_stack_max = num_to_alloc;
- yyg->yy_buffer_stack_top = 0;
- return;
- }
-
- if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
-
- /* Increase the buffer to prepare for a possible push. */
- yy_size_t grow_size = 8 /* arbitrary grow size */;
-
- num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
- (yyg->yy_buffer_stack,
- num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- /* zero only the new slots.*/
- memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
- yyg->yy_buffer_stack_max = num_to_alloc;
- }
-}
-
-/** Setup the input buffer state to scan directly from a user-specified character buffer.
- * @param base the character buffer
- * @param size the size in bytes of the character buffer
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return NULL;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = NULL;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b , yyscanner );
-
- return b;
-}
-
-/** Setup the input buffer state to scan a string. The next call to yylex() will
- * scan from a @e copy of @a str.
- * @param yystr a NUL-terminated string to scan
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- * @note If you want to scan bytes that may contain NUL values, then use
- * yy_scan_bytes() instead.
- */
-YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner)
-{
-
- return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner);
-}
-
-/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
- * scan from a @e copy of @a bytes.
- * @param yybytes the byte buffer to scan
- * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = (yy_size_t) (_yybytes_len + 2);
- buf = (char *) yyalloc( n , yyscanner );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < _yybytes_len; ++i )
- buf[i] = yybytes[i];
-
- buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n , yyscanner);
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
-}
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-static void yynoreturn yy_fatal_error (const char* msg , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
-}
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- yytext[yyleng] = yyg->yy_hold_char; \
- yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
- yyg->yy_hold_char = *yyg->yy_c_buf_p; \
- *yyg->yy_c_buf_p = '\0'; \
- yyleng = yyless_macro_arg; \
- } \
- while ( 0 )
-
-/* Accessor methods (get/set functions) to struct members. */
-
-/** Get the user-defined data for this scanner.
- * @param yyscanner The scanner object.
- */
-YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyextra;
-}
-
-/** Get the current line number.
- * @param yyscanner The scanner object.
- */
-int yyget_lineno (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yylineno;
-}
-
-/** Get the current column number.
- * @param yyscanner The scanner object.
- */
-int yyget_column (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yycolumn;
-}
-
-/** Get the input stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_in (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyin;
-}
-
-/** Get the output stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_out (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyout;
-}
-
-/** Get the length of the current token.
- * @param yyscanner The scanner object.
- */
-int yyget_leng (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyleng;
-}
-
-/** Get the current token.
- * @param yyscanner The scanner object.
- */
-
-char *yyget_text (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yytext;
-}
-
-/** Set the user-defined data. This data is never touched by the scanner.
- * @param user_defined The data to be associated with this scanner.
- * @param yyscanner The scanner object.
- */
-void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyextra = user_defined ;
-}
-
-/** Set the current line number.
- * @param _line_number line number
- * @param yyscanner The scanner object.
- */
-void yyset_lineno (int _line_number , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* lineno is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_lineno called with no buffer" );
-
- yylineno = _line_number;
-}
-
-/** Set the current column.
- * @param _column_no column number
- * @param yyscanner The scanner object.
- */
-void yyset_column (int _column_no , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* column is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_column called with no buffer" );
-
- yycolumn = _column_no;
-}
-
-/** Set the input stream. This does not discard the current
- * input buffer.
- * @param _in_str A readable stream.
- * @param yyscanner The scanner object.
- * @see yy_switch_to_buffer
- */
-void yyset_in (FILE * _in_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyin = _in_str ;
-}
-
-void yyset_out (FILE * _out_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyout = _out_str ;
-}
-
-int yyget_debug (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yy_flex_debug;
-}
-
-void yyset_debug (int _bdebug , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yy_flex_debug = _bdebug ;
-}
-
-/* Accessor methods for yylval and yylloc */
-
-YYSTYPE * yyget_lval (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yylval;
-}
-
-void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yylval = yylval_param;
-}
-
-/* User-visible API */
-
-/* yylex_init is special because it creates the scanner itself, so it is
- * the ONLY reentrant function that doesn't take the scanner as the last argument.
- * That's why we explicitly handle the declaration, instead of using our macros.
- */
-int yylex_init(yyscan_t* ptr_yy_globals)
-{
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-/* yylex_init_extra has the same functionality as yylex_init, but follows the
- * convention of taking the scanner as the last argument. Note however, that
- * this is a *pointer* to a scanner, as it will be allocated by this call (and
- * is the reason, too, why this function also must handle its own declaration).
- * The user defined value in the first argument will be available to yyalloc in
- * the yyextra field.
- */
-int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
-{
- struct yyguts_t dummy_yyguts;
-
- yyset_extra (yy_user_defined, &dummy_yyguts);
-
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in
- yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- yyset_extra (yy_user_defined, *ptr_yy_globals);
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-static int yy_init_globals (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- /* Initialization is the same as for the non-reentrant scanner.
- * This function is called from yylex_destroy(), so don't allocate here.
- */
-
- yyg->yy_buffer_stack = NULL;
- yyg->yy_buffer_stack_top = 0;
- yyg->yy_buffer_stack_max = 0;
- yyg->yy_c_buf_p = NULL;
- yyg->yy_init = 0;
- yyg->yy_start = 0;
-
- yyg->yy_start_stack_ptr = 0;
- yyg->yy_start_stack_depth = 0;
- yyg->yy_start_stack = NULL;
-
-/* Defined in main.c */
-#ifdef YY_STDINIT
- yyin = stdin;
- yyout = stdout;
-#else
- yyin = NULL;
- yyout = NULL;
-#endif
-
- /* For future reference: Set errno on error, since we are called by
- * yylex_init()
- */
- return 0;
-}
-
-/* yylex_destroy is for both reentrant and non-reentrant scanners. */
-int yylex_destroy (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* Pop the buffer stack, destroying each element. */
- while(YY_CURRENT_BUFFER){
- yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
- YY_CURRENT_BUFFER_LVALUE = NULL;
- yypop_buffer_state(yyscanner);
- }
-
- /* Destroy the stack itself. */
- yyfree(yyg->yy_buffer_stack , yyscanner);
- yyg->yy_buffer_stack = NULL;
-
- /* Destroy the start condition stack. */
- yyfree( yyg->yy_start_stack , yyscanner );
- yyg->yy_start_stack = NULL;
-
- /* Reset the globals. This is important in a non-reentrant scanner so the next time
- * yylex() is called, initialization will occur. */
- yy_init_globals( yyscanner);
-
- /* Destroy the main struct (reentrant only). */
- yyfree ( yyscanner , yyscanner );
- yyscanner = NULL;
- return 0;
-}
-
-/*
- * Internal utility routines.
- */
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
-}
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen (const char * s , yyscan_t yyscanner)
-{
- int n;
- for ( n = 0; s[n]; ++n )
- ;
-
- return n;
-}
-#endif
-
-void *yyalloc (yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- return malloc(size);
-}
-
-void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return realloc(ptr, size);
-}
-
-void yyfree (void * ptr , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
-}
-
-#define YYTABLES_NAME "yytables"
-
-#line 73 "expr_parser.l"
-
-
-int expr_wrap(yyscan_t scanner)
-{
- return 1;
-}
-
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.h
deleted file mode 100644
index dcb26ba..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.h
+++ /dev/null
@@ -1,717 +0,0 @@
-#ifndef expr_HEADER_H
-#define expr_HEADER_H 1
-#define expr_IN_HEADER 1
-
-#line 5 "expr_parser.h"
-
-#line 7 "expr_parser.h"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define expr__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer expr__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define expr__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer expr__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define expr__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer expr__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define expr__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string expr__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define expr__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes expr__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define expr__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer expr__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define expr__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer expr__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define expr__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state expr__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define expr__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer expr__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define expr_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state expr_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define expr_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state expr_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define expr_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack expr_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define expr_lex_ALREADY_DEFINED
-#else
-#define yylex expr_lex
-#endif
-
-#ifdef yyrestart
-#define expr_restart_ALREADY_DEFINED
-#else
-#define yyrestart expr_restart
-#endif
-
-#ifdef yylex_init
-#define expr_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init expr_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define expr_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra expr_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define expr_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy expr_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define expr_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug expr_get_debug
-#endif
-
-#ifdef yyset_debug
-#define expr_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug expr_set_debug
-#endif
-
-#ifdef yyget_extra
-#define expr_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra expr_get_extra
-#endif
-
-#ifdef yyset_extra
-#define expr_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra expr_set_extra
-#endif
-
-#ifdef yyget_in
-#define expr_get_in_ALREADY_DEFINED
-#else
-#define yyget_in expr_get_in
-#endif
-
-#ifdef yyset_in
-#define expr_set_in_ALREADY_DEFINED
-#else
-#define yyset_in expr_set_in
-#endif
-
-#ifdef yyget_out
-#define expr_get_out_ALREADY_DEFINED
-#else
-#define yyget_out expr_get_out
-#endif
-
-#ifdef yyset_out
-#define expr_set_out_ALREADY_DEFINED
-#else
-#define yyset_out expr_set_out
-#endif
-
-#ifdef yyget_leng
-#define expr_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng expr_get_leng
-#endif
-
-#ifdef yyget_text
-#define expr_get_text_ALREADY_DEFINED
-#else
-#define yyget_text expr_get_text
-#endif
-
-#ifdef yyget_lineno
-#define expr_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno expr_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define expr_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno expr_set_lineno
-#endif
-
-#ifdef yyget_column
-#define expr_get_column_ALREADY_DEFINED
-#else
-#define yyget_column expr_get_column
-#endif
-
-#ifdef yyset_column
-#define expr_set_column_ALREADY_DEFINED
-#else
-#define yyset_column expr_set_column
-#endif
-
-#ifdef yywrap
-#define expr_wrap_ALREADY_DEFINED
-#else
-#define yywrap expr_wrap
-#endif
-
-#ifdef yyget_lval
-#define expr_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval expr_get_lval
-#endif
-
-#ifdef yyset_lval
-#define expr_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval expr_set_lval
-#endif
-
-#ifdef yyalloc
-#define expr_alloc_ALREADY_DEFINED
-#else
-#define yyalloc expr_alloc
-#endif
-
-#ifdef yyrealloc
-#define expr_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc expr_realloc
-#endif
-
-#ifdef yyfree
-#define expr_free_ALREADY_DEFINED
-#else
-#define yyfree expr_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-/* Begin user sect3 */
-
-#define yytext_ptr yytext_r
-
-#ifdef YY_HEADER_EXPORT_START_CONDITIONS
-#define INITIAL 0
-
-#endif
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-#undef YY_NEW_FILE
-#undef YY_FLUSH_BUFFER
-#undef yy_set_bol
-#undef yy_new_buffer
-#undef yy_set_interactive
-#undef YY_DO_BEFORE_ACTION
-
-#ifdef YY_DECL_IS_OURS
-#undef YY_DECL_IS_OURS
-#undef YY_DECL
-#endif
-
-#ifndef expr__create_buffer_ALREADY_DEFINED
-#undef yy_create_buffer
-#endif
-#ifndef expr__delete_buffer_ALREADY_DEFINED
-#undef yy_delete_buffer
-#endif
-#ifndef expr__scan_buffer_ALREADY_DEFINED
-#undef yy_scan_buffer
-#endif
-#ifndef expr__scan_string_ALREADY_DEFINED
-#undef yy_scan_string
-#endif
-#ifndef expr__scan_bytes_ALREADY_DEFINED
-#undef yy_scan_bytes
-#endif
-#ifndef expr__init_buffer_ALREADY_DEFINED
-#undef yy_init_buffer
-#endif
-#ifndef expr__flush_buffer_ALREADY_DEFINED
-#undef yy_flush_buffer
-#endif
-#ifndef expr__load_buffer_state_ALREADY_DEFINED
-#undef yy_load_buffer_state
-#endif
-#ifndef expr__switch_to_buffer_ALREADY_DEFINED
-#undef yy_switch_to_buffer
-#endif
-#ifndef expr_push_buffer_state_ALREADY_DEFINED
-#undef yypush_buffer_state
-#endif
-#ifndef expr_pop_buffer_state_ALREADY_DEFINED
-#undef yypop_buffer_state
-#endif
-#ifndef expr_ensure_buffer_stack_ALREADY_DEFINED
-#undef yyensure_buffer_stack
-#endif
-#ifndef expr_lex_ALREADY_DEFINED
-#undef yylex
-#endif
-#ifndef expr_restart_ALREADY_DEFINED
-#undef yyrestart
-#endif
-#ifndef expr_lex_init_ALREADY_DEFINED
-#undef yylex_init
-#endif
-#ifndef expr_lex_init_extra_ALREADY_DEFINED
-#undef yylex_init_extra
-#endif
-#ifndef expr_lex_destroy_ALREADY_DEFINED
-#undef yylex_destroy
-#endif
-#ifndef expr_get_debug_ALREADY_DEFINED
-#undef yyget_debug
-#endif
-#ifndef expr_set_debug_ALREADY_DEFINED
-#undef yyset_debug
-#endif
-#ifndef expr_get_extra_ALREADY_DEFINED
-#undef yyget_extra
-#endif
-#ifndef expr_set_extra_ALREADY_DEFINED
-#undef yyset_extra
-#endif
-#ifndef expr_get_in_ALREADY_DEFINED
-#undef yyget_in
-#endif
-#ifndef expr_set_in_ALREADY_DEFINED
-#undef yyset_in
-#endif
-#ifndef expr_get_out_ALREADY_DEFINED
-#undef yyget_out
-#endif
-#ifndef expr_set_out_ALREADY_DEFINED
-#undef yyset_out
-#endif
-#ifndef expr_get_leng_ALREADY_DEFINED
-#undef yyget_leng
-#endif
-#ifndef expr_get_text_ALREADY_DEFINED
-#undef yyget_text
-#endif
-#ifndef expr_get_lineno_ALREADY_DEFINED
-#undef yyget_lineno
-#endif
-#ifndef expr_set_lineno_ALREADY_DEFINED
-#undef yyset_lineno
-#endif
-#ifndef expr_get_column_ALREADY_DEFINED
-#undef yyget_column
-#endif
-#ifndef expr_set_column_ALREADY_DEFINED
-#undef yyset_column
-#endif
-#ifndef expr_wrap_ALREADY_DEFINED
-#undef yywrap
-#endif
-#ifndef expr_get_lval_ALREADY_DEFINED
-#undef yyget_lval
-#endif
-#ifndef expr_set_lval_ALREADY_DEFINED
-#undef yyset_lval
-#endif
-#ifndef expr_get_lloc_ALREADY_DEFINED
-#undef yyget_lloc
-#endif
-#ifndef expr_set_lloc_ALREADY_DEFINED
-#undef yyset_lloc
-#endif
-#ifndef expr_alloc_ALREADY_DEFINED
-#undef yyalloc
-#endif
-#ifndef expr_realloc_ALREADY_DEFINED
-#undef yyrealloc
-#endif
-#ifndef expr_free_ALREADY_DEFINED
-#undef yyfree
-#endif
-#ifndef expr_text_ALREADY_DEFINED
-#undef yytext
-#endif
-#ifndef expr_leng_ALREADY_DEFINED
-#undef yyleng
-#endif
-#ifndef expr_in_ALREADY_DEFINED
-#undef yyin
-#endif
-#ifndef expr_out_ALREADY_DEFINED
-#undef yyout
-#endif
-#ifndef expr__flex_debug_ALREADY_DEFINED
-#undef yy_flex_debug
-#endif
-#ifndef expr_lineno_ALREADY_DEFINED
-#undef yylineno
-#endif
-#ifndef expr_tables_fload_ALREADY_DEFINED
-#undef yytables_fload
-#endif
-#ifndef expr_tables_destroy_ALREADY_DEFINED
-#undef yytables_destroy
-#endif
-#ifndef expr_TABLES_NAME_ALREADY_DEFINED
-#undef yyTABLES_NAME
-#endif
-
-#line 73 "expr_parser.l"
-
-
-#line 715 "expr_parser.h"
-#undef expr_IN_HEADER
-#endif /* expr_HEADER_H */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.l b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.l
deleted file mode 100644
index 0c69a2c..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/expr_parser.l
+++ /dev/null
@@ -1,77 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%{
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "expr_bool.h"
-#include "expr_arith.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int expr_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-%}
-
-%option nounput
-%option prefix="expr_"
-%option outfile="expr_parser.cc"
-%option header-file="expr_parser.h"
-%option reentrant
-%option bison-bridge
-%option yylineno
-
-%%
- /* --- Tokens --- */
-
-[@!&|=><()\*\+/\^-] { return *yytext;}
-
- /* --- Strings, also quoted form --- */
-
-[A-Za-z][0-9A-Za-z_]* { yylval_param->val_str = mem_collector_strdup(mc,yytext);
- return STRING;}
-
-\"\" { yylval_param->val_str = NULL;
- return STRING;}
-
-\"[^\"]*\" { yylval_param->val_str = mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- return STRING;}
-
- /* --- Numbers --- */
-
--?[0-9]+ { yylval_param->val_int = atoi(yytext);
- return INTEGER;}
-
--?[0-9]+\.[0-9]+ { yylval_param->val_float = atof(yytext);
- return FLOAT;}
-
- /* --- blanks --- */
-
-[[:blank:]]*
-
-%%
-
-int expr_wrap(yyscan_t scanner)
-{
- return 1;
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/mem_collector.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/mem_collector.cc
deleted file mode 100644
index 4573d17..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/mem_collector.cc
+++ /dev/null
@@ -1,90 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-#include <stdlib.h>
-#include <string.h>
-
-#include "mem_collector.h"
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void mem_collector_init(mem_collector * mc)
-{
- int i;
-
- mc->str_buffer = (char **) malloc (sizeof(char*) * MEM_COLLECTOR_CHUNK);
- mc->size = MEM_COLLECTOR_CHUNK;
- mc->next = 0;
-
- for (i=0; i< mc->size ; i++)
- {
- mc->str_buffer[i] = 0;
- }
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void mem_collector_cleanup(mem_collector * mc)
-{
- int i;
-
- for (i=0; i< mc->size ; i++)
- {
- if ( mc->str_buffer[i] != 0 )
- {
- free(mc->str_buffer[i]);
- }
- else /* No str's left in the pool */
- {
- break;
- }
- }
-
- free(mc->str_buffer);
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-char * mem_collector_strdup(mem_collector *mc, const char * str)
-{
- int i, old_size;
- char * new_str;
-
- if ( mc->next == mc->size )
- {
- old_size = mc->size;
- mc->size = mc->size + MEM_COLLECTOR_CHUNK;
-
- mc->str_buffer = (char **) realloc(mc->str_buffer,
- sizeof(char*) * mc->size);
-
- for ( i = old_size ; i < mc->size ; i++)
- {
- mc->str_buffer[i] = 0;
- }
- }
-
- new_str = strdup(str);
- mc->str_buffer[mc->next++] = new_str;
-
- return new_str;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.cc
deleted file mode 100644
index 21fbea5..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.cc
+++ /dev/null
@@ -1,2363 +0,0 @@
-#line 1 "template_parser.cc"
-
-#line 3 "template_parser.cc"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define template__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer template__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define template__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer template__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define template__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer template__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define template__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string template__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define template__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes template__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define template__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer template__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define template__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer template__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define template__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state template__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define template__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer template__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define template_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state template_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define template_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state template_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define template_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack template_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define template_lex_ALREADY_DEFINED
-#else
-#define yylex template_lex
-#endif
-
-#ifdef yyrestart
-#define template_restart_ALREADY_DEFINED
-#else
-#define yyrestart template_restart
-#endif
-
-#ifdef yylex_init
-#define template_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init template_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define template_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra template_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define template_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy template_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define template_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug template_get_debug
-#endif
-
-#ifdef yyset_debug
-#define template_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug template_set_debug
-#endif
-
-#ifdef yyget_extra
-#define template_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra template_get_extra
-#endif
-
-#ifdef yyset_extra
-#define template_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra template_set_extra
-#endif
-
-#ifdef yyget_in
-#define template_get_in_ALREADY_DEFINED
-#else
-#define yyget_in template_get_in
-#endif
-
-#ifdef yyset_in
-#define template_set_in_ALREADY_DEFINED
-#else
-#define yyset_in template_set_in
-#endif
-
-#ifdef yyget_out
-#define template_get_out_ALREADY_DEFINED
-#else
-#define yyget_out template_get_out
-#endif
-
-#ifdef yyset_out
-#define template_set_out_ALREADY_DEFINED
-#else
-#define yyset_out template_set_out
-#endif
-
-#ifdef yyget_leng
-#define template_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng template_get_leng
-#endif
-
-#ifdef yyget_text
-#define template_get_text_ALREADY_DEFINED
-#else
-#define yyget_text template_get_text
-#endif
-
-#ifdef yyget_lineno
-#define template_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno template_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define template_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno template_set_lineno
-#endif
-
-#ifdef yyget_column
-#define template_get_column_ALREADY_DEFINED
-#else
-#define yyget_column template_get_column
-#endif
-
-#ifdef yyset_column
-#define template_set_column_ALREADY_DEFINED
-#else
-#define yyset_column template_set_column
-#endif
-
-#ifdef yywrap
-#define template_wrap_ALREADY_DEFINED
-#else
-#define yywrap template_wrap
-#endif
-
-#ifdef yyget_lval
-#define template_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval template_get_lval
-#endif
-
-#ifdef yyset_lval
-#define template_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval template_set_lval
-#endif
-
-#ifdef yyalloc
-#define template_alloc_ALREADY_DEFINED
-#else
-#define yyalloc template_alloc
-#endif
-
-#ifdef yyrealloc
-#define template_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc template_realloc
-#endif
-
-#ifdef yyfree
-#define template_free_ALREADY_DEFINED
-#else
-#define yyfree template_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an
- * integer in range [0..255] for use as an array index.
- */
-#define YY_SC_TO_UI(c) ((YY_CHAR) (c))
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yyg->yy_start = 1 + 2 *
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yyg->yy_start - 1) / 2)
-#define YYSTATE YY_START
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin , yyscanner )
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-/* The state buf must be large enough to hold one state per character in the main buffer.
- */
-#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
- /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
- * access to the local variable yy_act. Since yyless() is a macro, it would break
- * existing scanners that call yyless() from OUTSIDE yylex.
- * One obvious solution it to make yy_act a global. I tried that, and saw
- * a 5% performance hit in a non-yylineno scanner, because yy_act is
- * normally declared as a register variable-- so it is not worth it.
- */
- #define YY_LESS_LINENO(n) \
- do { \
- int yyl;\
- for ( yyl = n; yyl < yyleng; ++yyl )\
- if ( yytext[yyl] == '\n' )\
- --yylineno;\
- }while(0)
- #define YY_LINENO_REWIND_TO(dst) \
- do {\
- const char *p;\
- for ( p = yy_cp-1; p >= (dst); --p)\
- if ( *p == '\n' )\
- --yylineno;\
- }while(0)
-
-/* Return all but the first "n" matched characters back to the input stream. */
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- *yy_cp = yyg->yy_hold_char; \
- YY_RESTORE_YY_MORE_OFFSET \
- yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- *
- * Returns the top of the stack, or NULL.
- */
-#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
- ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
- : NULL)
-/* Same as previous macro, but useful when we know that the buffer stack is not
- * NULL or when we need an lvalue. For internal use only.
- */
-#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-static void yyensure_buffer_stack ( yyscan_t yyscanner );
-static void yy_load_buffer_state ( yyscan_t yyscanner );
-static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file , yyscan_t yyscanner );
-#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner)
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-#define yy_new_buffer yy_create_buffer
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! YY_CURRENT_BUFFER ){ \
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
- }
-#define yy_set_bol(at_bol) \
- { \
- if ( ! YY_CURRENT_BUFFER ){\
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
- }
-#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
-
-/* Begin user sect3 */
-typedef flex_uint8_t YY_CHAR;
-
-typedef int yy_state_type;
-
-#define yytext_ptr yytext_r
-
-static yy_state_type yy_get_previous_state ( yyscan_t yyscanner );
-static yy_state_type yy_try_NUL_trans ( yy_state_type current_state , yyscan_t yyscanner);
-static int yy_get_next_buffer ( yyscan_t yyscanner );
-static void yynoreturn yy_fatal_error ( const char* msg , yyscan_t yyscanner );
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yyg->yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yyg->yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yyg->yy_c_buf_p = yy_cp;
-#define YY_NUM_RULES 12
-#define YY_END_OF_BUFFER 13
-/* This struct is not used in this scanner,
- but its presence is necessary. */
-struct yy_trans_info
- {
- flex_int32_t yy_verify;
- flex_int32_t yy_nxt;
- };
-static const flex_int16_t yy_accept[69] =
- { 0,
- 0, 0, 0, 0, 13, 12, 2, 2, 12, 6,
- 3, 4, 7, 11, 12, 11, 12, 8, 12, 2,
- 2, 0, 6, 4, 7, 0, 1, 6, 3, 4,
- 5, 7, 11, 0, 0, 0, 8, 11, 0, 0,
- 10, 11, 0, 8, 8, 0, 10, 0, 10, 0,
- 10, 0, 9, 10, 10, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 0
- } ;
-
-static const YY_CHAR yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 1, 4, 5, 1, 1, 1, 1, 1,
- 1, 1, 1, 6, 1, 1, 1, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 1, 1, 1,
- 8, 9, 1, 1, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 10, 11, 12, 1, 7, 1, 7, 7, 7, 7,
-
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static const YY_CHAR yy_meta[13] =
- { 0,
- 1, 2, 3, 1, 1, 1, 1, 1, 1, 1,
- 1, 1
- } ;
-
-static const flex_int16_t yy_base[77] =
- { 0,
- 0, 0, 12, 0, 70, 196, 23, 34, 65, 0,
- 60, 45, 0, 48, 59, 71, 54, 82, 53, 0,
- 0, 61, 0, 0, 0, 60, 196, 0, 55, 0,
- 196, 0, 0, 39, 33, 93, 0, 0, 105, 113,
- 0, 40, 31, 0, 0, 116, 30, 37, 196, 125,
- 0, 128, 27, 0, 137, 146, 26, 22, 156, 21,
- 28, 18, 160, 0, 164, 15, 0, 196, 176, 178,
- 180, 183, 185, 187, 190, 192
- } ;
-
-static const flex_int16_t yy_def[77] =
- { 0,
- 68, 1, 68, 3, 68, 68, 68, 68, 69, 70,
- 68, 68, 71, 68, 72, 68, 72, 72, 72, 7,
- 8, 69, 70, 12, 71, 69, 68, 70, 68, 12,
- 68, 71, 14, 72, 72, 72, 18, 16, 16, 73,
- 14, 16, 39, 18, 74, 72, 72, 39, 68, 73,
- 16, 39, 75, 39, 73, 76, 75, 75, 76, 75,
- 59, 59, 75, 59, 59, 75, 59, 0, 68, 68,
- 68, 68, 68, 68, 68, 68
- } ;
-
-static const flex_int16_t yy_nxt[209] =
- { 0,
- 6, 7, 8, 6, 9, 10, 11, 12, 6, 6,
- 6, 13, 14, 15, 6, 16, 17, 17, 14, 17,
- 14, 18, 14, 19, 20, 21, 58, 22, 23, 65,
- 24, 64, 58, 63, 25, 21, 21, 58, 58, 23,
- 54, 35, 52, 51, 46, 25, 30, 31, 33, 34,
- 35, 33, 34, 34, 33, 34, 33, 34, 33, 35,
- 36, 29, 27, 27, 46, 35, 29, 27, 37, 68,
- 35, 38, 39, 40, 41, 39, 39, 38, 39, 38,
- 39, 42, 43, 44, 45, 68, 68, 68, 68, 68,
- 68, 68, 68, 35, 36, 68, 68, 68, 68, 68,
-
- 68, 68, 37, 68, 35, 39, 68, 68, 47, 68,
- 68, 39, 68, 39, 68, 48, 49, 68, 68, 68,
- 68, 68, 68, 50, 53, 68, 68, 46, 55, 68,
- 68, 68, 68, 68, 68, 50, 56, 68, 68, 52,
- 49, 68, 68, 68, 68, 68, 68, 50, 40, 60,
- 68, 68, 68, 68, 68, 68, 61, 62, 40, 60,
- 68, 68, 68, 68, 68, 68, 61, 62, 66, 68,
- 68, 63, 67, 68, 68, 65, 26, 26, 26, 28,
- 28, 32, 32, 34, 34, 40, 40, 40, 45, 45,
- 57, 57, 59, 59, 59, 5, 68, 68, 68, 68,
-
- 68, 68, 68, 68, 68, 68, 68, 68
- } ;
-
-static const flex_int16_t yy_chk[209] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 7, 7, 66, 7, 7, 62,
- 7, 61, 60, 58, 7, 8, 8, 57, 53, 8,
- 48, 47, 43, 42, 35, 8, 12, 12, 14, 14,
- 34, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 15, 29, 26, 22, 19, 17, 11, 9, 15, 5,
- 15, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 18, 18, 0, 0, 0, 0, 0,
- 0, 0, 0, 18, 36, 0, 0, 0, 0, 0,
-
- 0, 0, 36, 0, 36, 39, 0, 0, 39, 0,
- 0, 39, 0, 39, 0, 39, 40, 0, 0, 0,
- 0, 0, 0, 40, 46, 0, 0, 46, 50, 0,
- 0, 0, 0, 0, 0, 50, 52, 0, 0, 52,
- 55, 0, 0, 0, 0, 0, 0, 55, 56, 56,
- 0, 0, 0, 0, 0, 0, 56, 56, 59, 59,
- 0, 0, 0, 0, 0, 0, 59, 59, 63, 0,
- 0, 63, 65, 0, 0, 65, 69, 69, 69, 70,
- 70, 71, 71, 72, 72, 73, 73, 73, 74, 74,
- 75, 75, 76, 76, 76, 68, 68, 68, 68, 68,
-
- 68, 68, 68, 68, 68, 68, 68, 68
- } ;
-
-/* Table of booleans, true if rule could match eol. */
-static const flex_int32_t yy_rule_can_match_eol[13] =
- { 0,
-1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 0, 0, };
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-#define YY_RESTORE_YY_MORE_OFFSET
-#line 1 "template_parser.l"
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-#line 18 "template_parser.l"
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <pthread.h>
-
-#include "template_syntax.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int template_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-#line 761 "template_parser.cc"
-
-#line 763 "template_parser.cc"
-
-#define INITIAL 0
-#define VALUE 1
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-/* Holds the entire state of the reentrant scanner. */
-struct yyguts_t
- {
-
- /* User-defined. Not touched by flex. */
- YY_EXTRA_TYPE yyextra_r;
-
- /* The rest are the same as the globals declared in the non-reentrant scanner. */
- FILE *yyin_r, *yyout_r;
- size_t yy_buffer_stack_top; /**< index of top of stack. */
- size_t yy_buffer_stack_max; /**< capacity of stack. */
- YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
- char yy_hold_char;
- int yy_n_chars;
- int yyleng_r;
- char *yy_c_buf_p;
- int yy_init;
- int yy_start;
- int yy_did_buffer_switch_on_eof;
- int yy_start_stack_ptr;
- int yy_start_stack_depth;
- int *yy_start_stack;
- yy_state_type yy_last_accepting_state;
- char* yy_last_accepting_cpos;
-
- int yylineno_r;
- int yy_flex_debug_r;
-
- char *yytext_r;
- int yy_more_flag;
- int yy_more_len;
-
- YYSTYPE * yylval_r;
-
- }; /* end struct yyguts_t */
-
-static int yy_init_globals ( yyscan_t yyscanner );
-
- /* This must go here because YYSTYPE and YYLTYPE are included
- * from bison output in section 1.*/
- # define yylval yyg->yylval_r
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput ( yyscan_t yyscanner );
-#else
-static int input ( yyscan_t yyscanner );
-#endif
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
- { \
- int c = '*'; \
- int n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else \
- { \
- errno=0; \
- while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
- { \
- if( errno != EINTR) \
- { \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- break; \
- } \
- errno=0; \
- clearerr(yyin); \
- } \
- }\
-\
-
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
-#endif
-
-/* end tables serialization structures and prototypes */
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK /*LINTED*/break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-/** The main scanner function which does all the work.
- */
-YY_DECL
-{
- yy_state_type yy_current_state;
- char *yy_cp, *yy_bp;
- int yy_act;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yylval = yylval_param;
-
- if ( !yyg->yy_init )
- {
- yyg->yy_init = 1;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yyg->yy_start )
- yyg->yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! YY_CURRENT_BUFFER ) {
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_load_buffer_state( yyscanner );
- }
-
- {
-#line 49 "template_parser.l"
-
-
-#line 52 "template_parser.l"
- /* ------------------------------------------------------------------------- */
- /* Comments (lines with an starting #), and empty lines */
- /* ------------------------------------------------------------------------- */
-#line 1043 "template_parser.cc"
-
- while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yyg->yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yyg->yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yyg->yy_start;
-yy_match:
- do
- {
- YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 69 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 196 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
- if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
- {
- int yyl;
- for ( yyl = 0; yyl < yyleng; ++yyl )
- if ( yytext[yyl] == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
- }
-
-do_action: /* This label is used only to access EOF actions. */
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yyg->yy_hold_char;
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-/* rule 1 can match eol */
-YY_RULE_SETUP
-#line 55 "template_parser.l"
-;
- YY_BREAK
-case 2:
-/* rule 2 can match eol */
-YY_RULE_SETUP
-#line 56 "template_parser.l"
-;
- YY_BREAK
-/* ------------------------------------------------------------------------- */
-/* Variable: Alpha numeric charatcers and '_' */
-/* ------------------------------------------------------------------------- */
-case 3:
-YY_RULE_SETUP
-#line 61 "template_parser.l"
-{ yylval_param->val_str = mem_collector_strdup(mc,yytext);
- return VARIABLE; }
- YY_BREAK
-/* ------------------------------------------------------------------------ */
-/* TOKENS */
-/* Single attribute (VARIABLE = VALUE, also empty VAIABLE=) */
-/* Vector attributes (VARIABLE = [ ATTR1 = VAL1, ATTR2 = VAL2 ]) */
-/* ------------------------------------------------------------------------ */
-case 4:
-YY_RULE_SETUP
-#line 69 "template_parser.l"
-{ BEGIN VALUE; return EQUAL;}
- YY_BREAK
-case 5:
-/* rule 5 can match eol */
-YY_RULE_SETUP
-#line 71 "template_parser.l"
-{ return EQUAL_EMPTY;}
- YY_BREAK
-case 6:
-/* rule 6 can match eol */
-YY_RULE_SETUP
-#line 73 "template_parser.l"
-{ return COMMA;}
- YY_BREAK
-case 7:
-/* rule 7 can match eol */
-YY_RULE_SETUP
-#line 75 "template_parser.l"
-{ return CBRACKET;}
- YY_BREAK
-case 8:
-/* rule 8 can match eol */
-YY_RULE_SETUP
-#line 77 "template_parser.l"
-{ BEGIN(INITIAL); return OBRACKET;}
- YY_BREAK
-/* ------------------------------------------------------------------------ */
-/* Attribute values */
-/* - String in double quoted form */
-/* - Anything but =,][# and blanks */
-/* ------------------------------------------------------------------------ */
-case 9:
-YY_RULE_SETUP
-#line 85 "template_parser.l"
-{
- BEGIN(INITIAL);
- return CCDATA;
-}
- YY_BREAK
-case 10:
-/* rule 10 can match eol */
-YY_RULE_SETUP
-#line 90 "template_parser.l"
-{
- yylval_param->val_str = mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- BEGIN(INITIAL);
- return STRING;
-}
- YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 97 "template_parser.l"
-{
- yylval_param->val_str = mem_collector_strdup(mc,yytext);
- BEGIN(INITIAL);
- return STRING;
-}
- YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 103 "template_parser.l"
-ECHO;
- YY_BREAK
-#line 1205 "template_parser.cc"
-case YY_STATE_EOF(INITIAL):
-case YY_STATE_EOF(VALUE):
- yyterminate();
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yyg->yy_hold_char;
- YY_RESTORE_YY_MORE_OFFSET
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between YY_CURRENT_BUFFER and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
-
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yyg->yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yyg->yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yyg->yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap( yyscanner ) )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p =
- yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yyg->yy_c_buf_p =
- &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of user's declarations */
-} /* end of yylex */
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-static int yy_get_next_buffer (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
- char *source = yyg->yytext_ptr;
- int number_to_move, i;
- int ret_val;
-
- if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a single character, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
-
- int yy_c_buf_p_offset =
- (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yyrealloc( (void *) b->yy_ch_buf,
- (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = NULL;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
- number_to_move - 1;
-
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
- yyg->yy_n_chars, num_to_read );
-
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- if ( yyg->yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin , yyscanner);
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
- /* Extend the array by 50%, plus the number we really need. */
- int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
- (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner );
- if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
- /* "- 2" to take care of EOB's */
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
- }
-
- yyg->yy_n_chars += number_to_move;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
-
- return ret_val;
-}
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
- static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
-{
- yy_state_type yy_current_state;
- char *yy_cp;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_current_state = yyg->yy_start;
-
- for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
- {
- YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 69 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- }
-
- return yy_current_state;
-}
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
- static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
-{
- int yy_is_jam;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
- char *yy_cp = yyg->yy_c_buf_p;
-
- YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 69 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- yy_is_jam = (yy_current_state == 68);
-
- (void)yyg;
- return yy_is_jam ? 0 : yy_current_state;
-}
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
- static int yyinput (yyscan_t yyscanner)
-#else
- static int input (yyscan_t yyscanner)
-#endif
-
-{
- int c;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
-
- if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- /* This was really a NUL. */
- *yyg->yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- int offset = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr);
- ++yyg->yy_c_buf_p;
-
- switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_LAST_MATCH:
- /* This happens because yy_g_n_b()
- * sees that we've accumulated a
- * token and flags that we need to
- * try matching the token before
- * proceeding. But for input(),
- * there's no matching to consider.
- * So convert the EOB_ACT_LAST_MATCH
- * to EOB_ACT_END_OF_FILE.
- */
-
- /* Reset buffer status. */
- yyrestart( yyin , yyscanner);
-
- /*FALLTHROUGH*/
-
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap( yyscanner ) )
- return 0;
-
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput(yyscanner);
-#else
- return input(yyscanner);
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
- break;
- }
- }
- }
-
- c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
- *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
- yyg->yy_hold_char = *++yyg->yy_c_buf_p;
-
- if ( c == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
-
- return c;
-}
-#endif /* ifndef YY_NO_INPUT */
-
-/** Immediately switch to a different input stream.
- * @param input_file A readable stream.
- * @param yyscanner The scanner object.
- * @note This function does not reset the start condition to @c INITIAL .
- */
- void yyrestart (FILE * input_file , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! YY_CURRENT_BUFFER ){
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
- yy_load_buffer_state( yyscanner );
-}
-
-/** Switch to a different input buffer.
- * @param new_buffer The new input buffer.
- * @param yyscanner The scanner object.
- */
- void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* TODO. We should be able to replace this entire function body
- * with
- * yypop_buffer_state();
- * yypush_buffer_state(new_buffer);
- */
- yyensure_buffer_stack (yyscanner);
- if ( YY_CURRENT_BUFFER == new_buffer )
- return;
-
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
- yy_load_buffer_state( yyscanner );
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-static void yy_load_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
- yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
- yyg->yy_hold_char = *yyg->yy_c_buf_p;
-}
-
-/** Allocate and initialize an input buffer state.
- * @param file A readable stream.
- * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
- * @param yyscanner The scanner object.
- * @return the allocated buffer state.
- */
- YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file , yyscanner);
-
- return b;
-}
-
-/** Destroy the buffer.
- * @param b a buffer created with yy_create_buffer()
- * @param yyscanner The scanner object.
- */
- void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! b )
- return;
-
- if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
- YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yyfree( (void *) b->yy_ch_buf , yyscanner );
-
- yyfree( (void *) b , yyscanner );
-}
-
-/* Initializes or reinitializes a buffer.
- * This function is sometimes called more than once on the same buffer,
- * such as during a yyrestart() or at EOF.
- */
- static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
-
-{
- int oerrno = errno;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_flush_buffer( b , yyscanner);
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
- /* If b is the current buffer, then yy_init_buffer was _probably_
- * called from yyrestart() or through yy_get_next_buffer.
- * In that case, we don't want to reset the lineno or column.
- */
- if (b != YY_CURRENT_BUFFER){
- b->yy_bs_lineno = 1;
- b->yy_bs_column = 0;
- }
-
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-
- errno = oerrno;
-}
-
-/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
- * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
- * @param yyscanner The scanner object.
- */
- void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if ( ! b )
- return;
-
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == YY_CURRENT_BUFFER )
- yy_load_buffer_state( yyscanner );
-}
-
-/** Pushes the new state onto the stack. The new state becomes
- * the current state. This function will allocate the stack
- * if necessary.
- * @param new_buffer The new state.
- * @param yyscanner The scanner object.
- */
-void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (new_buffer == NULL)
- return;
-
- yyensure_buffer_stack(yyscanner);
-
- /* This block is copied from yy_switch_to_buffer. */
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- /* Only push if top exists. Otherwise, replace top. */
- if (YY_CURRENT_BUFFER)
- yyg->yy_buffer_stack_top++;
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
-
- /* copied from yy_switch_to_buffer. */
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-/** Removes and deletes the top of the stack, if present.
- * The next element becomes the new top.
- * @param yyscanner The scanner object.
- */
-void yypop_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (!YY_CURRENT_BUFFER)
- return;
-
- yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
- YY_CURRENT_BUFFER_LVALUE = NULL;
- if (yyg->yy_buffer_stack_top > 0)
- --yyg->yy_buffer_stack_top;
-
- if (YY_CURRENT_BUFFER) {
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
- }
-}
-
-/* Allocates the stack if it does not exist.
- * Guarantees space for at least one push.
- */
-static void yyensure_buffer_stack (yyscan_t yyscanner)
-{
- yy_size_t num_to_alloc;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (!yyg->yy_buffer_stack) {
-
- /* First allocation is just for 2 elements, since we don't know if this
- * scanner will even need a stack. We use 2 instead of 1 to avoid an
- * immediate realloc on the next call.
- */
- num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
- (num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
-
- yyg->yy_buffer_stack_max = num_to_alloc;
- yyg->yy_buffer_stack_top = 0;
- return;
- }
-
- if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
-
- /* Increase the buffer to prepare for a possible push. */
- yy_size_t grow_size = 8 /* arbitrary grow size */;
-
- num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
- (yyg->yy_buffer_stack,
- num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- /* zero only the new slots.*/
- memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
- yyg->yy_buffer_stack_max = num_to_alloc;
- }
-}
-
-/** Setup the input buffer state to scan directly from a user-specified character buffer.
- * @param base the character buffer
- * @param size the size in bytes of the character buffer
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return NULL;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = NULL;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b , yyscanner );
-
- return b;
-}
-
-/** Setup the input buffer state to scan a string. The next call to yylex() will
- * scan from a @e copy of @a str.
- * @param yystr a NUL-terminated string to scan
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- * @note If you want to scan bytes that may contain NUL values, then use
- * yy_scan_bytes() instead.
- */
-YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner)
-{
-
- return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner);
-}
-
-/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
- * scan from a @e copy of @a bytes.
- * @param yybytes the byte buffer to scan
- * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = (yy_size_t) (_yybytes_len + 2);
- buf = (char *) yyalloc( n , yyscanner );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < _yybytes_len; ++i )
- buf[i] = yybytes[i];
-
- buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n , yyscanner);
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
-}
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-static void yynoreturn yy_fatal_error (const char* msg , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
-}
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- yytext[yyleng] = yyg->yy_hold_char; \
- yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
- yyg->yy_hold_char = *yyg->yy_c_buf_p; \
- *yyg->yy_c_buf_p = '\0'; \
- yyleng = yyless_macro_arg; \
- } \
- while ( 0 )
-
-/* Accessor methods (get/set functions) to struct members. */
-
-/** Get the user-defined data for this scanner.
- * @param yyscanner The scanner object.
- */
-YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyextra;
-}
-
-/** Get the current line number.
- * @param yyscanner The scanner object.
- */
-int yyget_lineno (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yylineno;
-}
-
-/** Get the current column number.
- * @param yyscanner The scanner object.
- */
-int yyget_column (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yycolumn;
-}
-
-/** Get the input stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_in (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyin;
-}
-
-/** Get the output stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_out (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyout;
-}
-
-/** Get the length of the current token.
- * @param yyscanner The scanner object.
- */
-int yyget_leng (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyleng;
-}
-
-/** Get the current token.
- * @param yyscanner The scanner object.
- */
-
-char *yyget_text (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yytext;
-}
-
-/** Set the user-defined data. This data is never touched by the scanner.
- * @param user_defined The data to be associated with this scanner.
- * @param yyscanner The scanner object.
- */
-void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyextra = user_defined ;
-}
-
-/** Set the current line number.
- * @param _line_number line number
- * @param yyscanner The scanner object.
- */
-void yyset_lineno (int _line_number , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* lineno is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_lineno called with no buffer" );
-
- yylineno = _line_number;
-}
-
-/** Set the current column.
- * @param _column_no column number
- * @param yyscanner The scanner object.
- */
-void yyset_column (int _column_no , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* column is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_column called with no buffer" );
-
- yycolumn = _column_no;
-}
-
-/** Set the input stream. This does not discard the current
- * input buffer.
- * @param _in_str A readable stream.
- * @param yyscanner The scanner object.
- * @see yy_switch_to_buffer
- */
-void yyset_in (FILE * _in_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyin = _in_str ;
-}
-
-void yyset_out (FILE * _out_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyout = _out_str ;
-}
-
-int yyget_debug (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yy_flex_debug;
-}
-
-void yyset_debug (int _bdebug , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yy_flex_debug = _bdebug ;
-}
-
-/* Accessor methods for yylval and yylloc */
-
-YYSTYPE * yyget_lval (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yylval;
-}
-
-void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yylval = yylval_param;
-}
-
-/* User-visible API */
-
-/* yylex_init is special because it creates the scanner itself, so it is
- * the ONLY reentrant function that doesn't take the scanner as the last argument.
- * That's why we explicitly handle the declaration, instead of using our macros.
- */
-int yylex_init(yyscan_t* ptr_yy_globals)
-{
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-/* yylex_init_extra has the same functionality as yylex_init, but follows the
- * convention of taking the scanner as the last argument. Note however, that
- * this is a *pointer* to a scanner, as it will be allocated by this call (and
- * is the reason, too, why this function also must handle its own declaration).
- * The user defined value in the first argument will be available to yyalloc in
- * the yyextra field.
- */
-int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
-{
- struct yyguts_t dummy_yyguts;
-
- yyset_extra (yy_user_defined, &dummy_yyguts);
-
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in
- yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- yyset_extra (yy_user_defined, *ptr_yy_globals);
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-static int yy_init_globals (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- /* Initialization is the same as for the non-reentrant scanner.
- * This function is called from yylex_destroy(), so don't allocate here.
- */
-
- yyg->yy_buffer_stack = NULL;
- yyg->yy_buffer_stack_top = 0;
- yyg->yy_buffer_stack_max = 0;
- yyg->yy_c_buf_p = NULL;
- yyg->yy_init = 0;
- yyg->yy_start = 0;
-
- yyg->yy_start_stack_ptr = 0;
- yyg->yy_start_stack_depth = 0;
- yyg->yy_start_stack = NULL;
-
-/* Defined in main.c */
-#ifdef YY_STDINIT
- yyin = stdin;
- yyout = stdout;
-#else
- yyin = NULL;
- yyout = NULL;
-#endif
-
- /* For future reference: Set errno on error, since we are called by
- * yylex_init()
- */
- return 0;
-}
-
-/* yylex_destroy is for both reentrant and non-reentrant scanners. */
-int yylex_destroy (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* Pop the buffer stack, destroying each element. */
- while(YY_CURRENT_BUFFER){
- yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
- YY_CURRENT_BUFFER_LVALUE = NULL;
- yypop_buffer_state(yyscanner);
- }
-
- /* Destroy the stack itself. */
- yyfree(yyg->yy_buffer_stack , yyscanner);
- yyg->yy_buffer_stack = NULL;
-
- /* Destroy the start condition stack. */
- yyfree( yyg->yy_start_stack , yyscanner );
- yyg->yy_start_stack = NULL;
-
- /* Reset the globals. This is important in a non-reentrant scanner so the next time
- * yylex() is called, initialization will occur. */
- yy_init_globals( yyscanner);
-
- /* Destroy the main struct (reentrant only). */
- yyfree ( yyscanner , yyscanner );
- yyscanner = NULL;
- return 0;
-}
-
-/*
- * Internal utility routines.
- */
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
-}
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen (const char * s , yyscan_t yyscanner)
-{
- int n;
- for ( n = 0; s[n]; ++n )
- ;
-
- return n;
-}
-#endif
-
-void *yyalloc (yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- return malloc(size);
-}
-
-void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return realloc(ptr, size);
-}
-
-void yyfree (void * ptr , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
-}
-
-#define YYTABLES_NAME "yytables"
-
-#line 103 "template_parser.l"
-
-
-int template_wrap(yyscan_t scanner)
-{
- return 1;
-}
-
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.h
deleted file mode 100644
index 652c368..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.h
+++ /dev/null
@@ -1,718 +0,0 @@
-#ifndef template_HEADER_H
-#define template_HEADER_H 1
-#define template_IN_HEADER 1
-
-#line 5 "template_parser.h"
-
-#line 7 "template_parser.h"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define template__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer template__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define template__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer template__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define template__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer template__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define template__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string template__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define template__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes template__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define template__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer template__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define template__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer template__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define template__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state template__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define template__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer template__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define template_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state template_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define template_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state template_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define template_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack template_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define template_lex_ALREADY_DEFINED
-#else
-#define yylex template_lex
-#endif
-
-#ifdef yyrestart
-#define template_restart_ALREADY_DEFINED
-#else
-#define yyrestart template_restart
-#endif
-
-#ifdef yylex_init
-#define template_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init template_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define template_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra template_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define template_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy template_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define template_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug template_get_debug
-#endif
-
-#ifdef yyset_debug
-#define template_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug template_set_debug
-#endif
-
-#ifdef yyget_extra
-#define template_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra template_get_extra
-#endif
-
-#ifdef yyset_extra
-#define template_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra template_set_extra
-#endif
-
-#ifdef yyget_in
-#define template_get_in_ALREADY_DEFINED
-#else
-#define yyget_in template_get_in
-#endif
-
-#ifdef yyset_in
-#define template_set_in_ALREADY_DEFINED
-#else
-#define yyset_in template_set_in
-#endif
-
-#ifdef yyget_out
-#define template_get_out_ALREADY_DEFINED
-#else
-#define yyget_out template_get_out
-#endif
-
-#ifdef yyset_out
-#define template_set_out_ALREADY_DEFINED
-#else
-#define yyset_out template_set_out
-#endif
-
-#ifdef yyget_leng
-#define template_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng template_get_leng
-#endif
-
-#ifdef yyget_text
-#define template_get_text_ALREADY_DEFINED
-#else
-#define yyget_text template_get_text
-#endif
-
-#ifdef yyget_lineno
-#define template_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno template_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define template_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno template_set_lineno
-#endif
-
-#ifdef yyget_column
-#define template_get_column_ALREADY_DEFINED
-#else
-#define yyget_column template_get_column
-#endif
-
-#ifdef yyset_column
-#define template_set_column_ALREADY_DEFINED
-#else
-#define yyset_column template_set_column
-#endif
-
-#ifdef yywrap
-#define template_wrap_ALREADY_DEFINED
-#else
-#define yywrap template_wrap
-#endif
-
-#ifdef yyget_lval
-#define template_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval template_get_lval
-#endif
-
-#ifdef yyset_lval
-#define template_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval template_set_lval
-#endif
-
-#ifdef yyalloc
-#define template_alloc_ALREADY_DEFINED
-#else
-#define yyalloc template_alloc
-#endif
-
-#ifdef yyrealloc
-#define template_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc template_realloc
-#endif
-
-#ifdef yyfree
-#define template_free_ALREADY_DEFINED
-#else
-#define yyfree template_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-/* Begin user sect3 */
-
-#define yytext_ptr yytext_r
-
-#ifdef YY_HEADER_EXPORT_START_CONDITIONS
-#define INITIAL 0
-#define VALUE 1
-
-#endif
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-#undef YY_NEW_FILE
-#undef YY_FLUSH_BUFFER
-#undef yy_set_bol
-#undef yy_new_buffer
-#undef yy_set_interactive
-#undef YY_DO_BEFORE_ACTION
-
-#ifdef YY_DECL_IS_OURS
-#undef YY_DECL_IS_OURS
-#undef YY_DECL
-#endif
-
-#ifndef template__create_buffer_ALREADY_DEFINED
-#undef yy_create_buffer
-#endif
-#ifndef template__delete_buffer_ALREADY_DEFINED
-#undef yy_delete_buffer
-#endif
-#ifndef template__scan_buffer_ALREADY_DEFINED
-#undef yy_scan_buffer
-#endif
-#ifndef template__scan_string_ALREADY_DEFINED
-#undef yy_scan_string
-#endif
-#ifndef template__scan_bytes_ALREADY_DEFINED
-#undef yy_scan_bytes
-#endif
-#ifndef template__init_buffer_ALREADY_DEFINED
-#undef yy_init_buffer
-#endif
-#ifndef template__flush_buffer_ALREADY_DEFINED
-#undef yy_flush_buffer
-#endif
-#ifndef template__load_buffer_state_ALREADY_DEFINED
-#undef yy_load_buffer_state
-#endif
-#ifndef template__switch_to_buffer_ALREADY_DEFINED
-#undef yy_switch_to_buffer
-#endif
-#ifndef template_push_buffer_state_ALREADY_DEFINED
-#undef yypush_buffer_state
-#endif
-#ifndef template_pop_buffer_state_ALREADY_DEFINED
-#undef yypop_buffer_state
-#endif
-#ifndef template_ensure_buffer_stack_ALREADY_DEFINED
-#undef yyensure_buffer_stack
-#endif
-#ifndef template_lex_ALREADY_DEFINED
-#undef yylex
-#endif
-#ifndef template_restart_ALREADY_DEFINED
-#undef yyrestart
-#endif
-#ifndef template_lex_init_ALREADY_DEFINED
-#undef yylex_init
-#endif
-#ifndef template_lex_init_extra_ALREADY_DEFINED
-#undef yylex_init_extra
-#endif
-#ifndef template_lex_destroy_ALREADY_DEFINED
-#undef yylex_destroy
-#endif
-#ifndef template_get_debug_ALREADY_DEFINED
-#undef yyget_debug
-#endif
-#ifndef template_set_debug_ALREADY_DEFINED
-#undef yyset_debug
-#endif
-#ifndef template_get_extra_ALREADY_DEFINED
-#undef yyget_extra
-#endif
-#ifndef template_set_extra_ALREADY_DEFINED
-#undef yyset_extra
-#endif
-#ifndef template_get_in_ALREADY_DEFINED
-#undef yyget_in
-#endif
-#ifndef template_set_in_ALREADY_DEFINED
-#undef yyset_in
-#endif
-#ifndef template_get_out_ALREADY_DEFINED
-#undef yyget_out
-#endif
-#ifndef template_set_out_ALREADY_DEFINED
-#undef yyset_out
-#endif
-#ifndef template_get_leng_ALREADY_DEFINED
-#undef yyget_leng
-#endif
-#ifndef template_get_text_ALREADY_DEFINED
-#undef yyget_text
-#endif
-#ifndef template_get_lineno_ALREADY_DEFINED
-#undef yyget_lineno
-#endif
-#ifndef template_set_lineno_ALREADY_DEFINED
-#undef yyset_lineno
-#endif
-#ifndef template_get_column_ALREADY_DEFINED
-#undef yyget_column
-#endif
-#ifndef template_set_column_ALREADY_DEFINED
-#undef yyset_column
-#endif
-#ifndef template_wrap_ALREADY_DEFINED
-#undef yywrap
-#endif
-#ifndef template_get_lval_ALREADY_DEFINED
-#undef yyget_lval
-#endif
-#ifndef template_set_lval_ALREADY_DEFINED
-#undef yyset_lval
-#endif
-#ifndef template_get_lloc_ALREADY_DEFINED
-#undef yyget_lloc
-#endif
-#ifndef template_set_lloc_ALREADY_DEFINED
-#undef yyset_lloc
-#endif
-#ifndef template_alloc_ALREADY_DEFINED
-#undef yyalloc
-#endif
-#ifndef template_realloc_ALREADY_DEFINED
-#undef yyrealloc
-#endif
-#ifndef template_free_ALREADY_DEFINED
-#undef yyfree
-#endif
-#ifndef template_text_ALREADY_DEFINED
-#undef yytext
-#endif
-#ifndef template_leng_ALREADY_DEFINED
-#undef yyleng
-#endif
-#ifndef template_in_ALREADY_DEFINED
-#undef yyin
-#endif
-#ifndef template_out_ALREADY_DEFINED
-#undef yyout
-#endif
-#ifndef template__flex_debug_ALREADY_DEFINED
-#undef yy_flex_debug
-#endif
-#ifndef template_lineno_ALREADY_DEFINED
-#undef yylineno
-#endif
-#ifndef template_tables_fload_ALREADY_DEFINED
-#undef yytables_fload
-#endif
-#ifndef template_tables_destroy_ALREADY_DEFINED
-#undef yytables_destroy
-#endif
-#ifndef template_TABLES_NAME_ALREADY_DEFINED
-#undef yyTABLES_NAME
-#endif
-
-#line 103 "template_parser.l"
-
-
-#line 716 "template_parser.h"
-#undef template_IN_HEADER
-#endif /* template_HEADER_H */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.l b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.l
deleted file mode 100644
index dc96c88..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_parser.l
+++ /dev/null
@@ -1,107 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%{
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <pthread.h>
-
-#include "template_syntax.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int template_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-%}
-
-%option nounput
-%option prefix="template_"
-%option outfile="template_parser.cc"
-%option header-file="template_parser.h"
-%option bison-bridge
-%option yylineno
-%option reentrant
-
-%x VALUE
-
-STRING [^=#[:blank:]\n,\[\]]+
-VALUE_STRING ([^\"]|"\\\"")*
-CDATA "\]\]\>"
-%%
-
- /* ------------------------------------------------------------------------- */
- /* Comments (lines with an starting #), and empty lines */
- /* ------------------------------------------------------------------------- */
-[[:blank:]]*#.*\n ;
-[[:blank:]\n]+ ;
-
- /* ------------------------------------------------------------------------- */
- /* Variable: Alpha numeric charatcers and '_' */
- /* ------------------------------------------------------------------------- */
-[[:alnum:]_]+ { yylval_param->val_str = mem_collector_strdup(mc,yytext);
- return VARIABLE; }
-
- /* ------------------------------------------------------------------------ */
- /* TOKENS */
- /* Single attribute (VARIABLE = VALUE, also empty VAIABLE=) */
- /* Vector attributes (VARIABLE = [ ATTR1 = VAL1, ATTR2 = VAL2 ]) */
- /* ------------------------------------------------------------------------ */
-[[:blank:]]*=[[:blank:]]* { BEGIN VALUE; return EQUAL;}
-
-[[:blank:]]*=[[:blank:]]*\n { return EQUAL_EMPTY;}
-
-[[:blank:]\n]*,[[:blank:]\n]* { return COMMA;}
-
-[[:blank:]\n]*\][[:blank:]\n]* { return CBRACKET;}
-
-<VALUE>[[:blank:]]*\[[[:blank:]\n]* { BEGIN(INITIAL); return OBRACKET;}
-
- /* ------------------------------------------------------------------------ */
- /* Attribute values */
- /* - String in double quoted form */
- /* - Anything but =,][# and blanks */
- /* ------------------------------------------------------------------------ */
-
-<VALUE>.*{CDATA}.* {
- BEGIN(INITIAL);
- return CCDATA;
-}
-
-<VALUE>\"{VALUE_STRING}\" {
- yylval_param->val_str = mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- BEGIN(INITIAL);
- return STRING;
-}
-
-<VALUE>{STRING} {
- yylval_param->val_str = mem_collector_strdup(mc,yytext);
- BEGIN(INITIAL);
- return STRING;
-}
-
-%%
-
-int template_wrap(yyscan_t scanner)
-{
- return 1;
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.cc
deleted file mode 100644
index f23cae5..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.cc
+++ /dev/null
@@ -1,1779 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Bison version. */
-#define YYBISON_VERSION "3.4.1"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 1
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse template_parse
-#define yylex template_lex
-#define yyerror template_error
-#define yydebug template_debug
-#define yynerrs template_nerrs
-
-
-/* First part of user prologue. */
-#line 17 "template_syntax.y"
-
-#include "template_syntax.h"
-#include "template_parser.h"
-#include "NebulaUtil.h"
-
-#define YYERROR_VERBOSE
-
-void template_error( YYLTYPE * llocp, mem_collector * mc, Template * tmpl,
- char ** error_msg, yyscan_t scanner, const char * str);
-
-int template_lex (YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int template_parse(Template * tmpl, char ** errmsg, yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = template_parse(&mc, tmpl, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-static string& unescape (string &str);
-
-#line 106 "template_syntax.cc"
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Use api.header.include to #include this header
- instead of duplicating it here. */
-#ifndef YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED
-# define YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int template_debug;
-#endif
-/* "%code requires" blocks. */
-#line 47 "template_syntax.y"
-
-#include <iostream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-#include <stdio.h>
-
-#include "mem_collector.h"
-
-#include "Template.h"
-
-typedef void * yyscan_t;
-
-int template_parse(Template * tmpl, char ** errmsg, yyscan_t scanner);
-
-#line 159 "template_syntax.cc"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EQUAL_EMPTY = 262,
- CCDATA = 263,
- STRING = 264,
- VARIABLE = 265
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 74 "template_syntax.y"
-
- char * val_str;
- void * val_attr;
-
-#line 186 "template_syntax.cc"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int template_parse (mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED */
-
-
-
-#ifdef short
-# undef short
-#endif
-
-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
-#endif
-
-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
-#else
-typedef unsigned short yytype_uint16;
-#endif
-
-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE
-# if (defined __GNUC__ \
- && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
- || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
-# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
-# else
-# define YY_ATTRIBUTE(Spec) /* empty */
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_PURE
-# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YYUSE(E) ((void) (E))
-#else
-# define YYUSE(E) /* empty */
-#endif
-
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if ! defined yyoverflow || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include <alloca.h> /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include <malloc.h> /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yytype_int16 yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 7
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 16
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 11
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 5
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 12
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 22
-
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 265
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- ((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 9, 10
-};
-
-#if YYDEBUG
- /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_uint8 yyrline[] =
-{
- 0, 94, 94, 95, 98, 99, 102, 112, 125, 134,
- 144, 150, 163
-};
-#endif
-
-#if YYDEBUG || YYERROR_VERBOSE || 0
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "$end", "error", "$undefined", "EQUAL", "COMMA", "OBRACKET", "CBRACKET",
- "EQUAL_EMPTY", "CCDATA", "STRING", "VARIABLE", "$accept",
- "template_file", "template", "attribute", "array_val", YY_NULLPTR
-};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[NUM] -- (External) token number corresponding to the
- (internal) symbol number NUM (which must be that of a token). */
-static const yytype_uint16 yytoknum[] =
-{
- 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
- 265
-};
-# endif
-
-#define YYPACT_NINF -6
-
-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-6)))
-
-#define YYTABLE_NINF -1
-
-#define yytable_value_is_error(Yytable_value) \
- 0
-
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int8 yypact[] =
-{
- 0, -2, 8, 0, -6, -5, -6, -6, -6, -4,
- -6, -6, -6, 9, 3, 2, 4, -6, -6, 10,
- 6, -6
-};
-
- /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 2, 0, 0, 3, 4, 0, 9, 1, 5, 0,
- 10, 6, 8, 0, 0, 0, 0, 7, 11, 0,
- 0, 12
-};
-
- /* YYPGOTO[NTERM-NUM]. */
-static const yytype_int8 yypgoto[] =
-{
- -6, -6, -6, 13, -6
-};
-
- /* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int8 yydefgoto[] =
-{
- -1, 2, 3, 4, 14
-};
-
- /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_uint8 yytable[] =
-{
- 9, 5, 12, 10, 11, 6, 13, 16, 7, 17,
- 1, 18, 15, 20, 19, 21, 8
-};
-
-static const yytype_uint8 yycheck[] =
-{
- 5, 3, 6, 8, 9, 7, 10, 4, 0, 6,
- 10, 9, 3, 3, 10, 9, 3
-};
-
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
-{
- 0, 10, 12, 13, 14, 3, 7, 0, 14, 5,
- 8, 9, 6, 10, 15, 3, 4, 6, 9, 10,
- 3, 9
-};
-
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 11, 12, 12, 13, 13, 14, 14, 14, 14,
- 14, 15, 15
-};
-
- /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 0, 1, 1, 2, 3, 5, 4, 2,
- 3, 3, 5
-};
-
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, mc, tmpl, error_msg, scanner, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
-
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YY_LOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-#ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
- }
-
-# define YY_LOCATION_PRINT(File, Loc) \
- yy_location_print_ (File, &(Loc))
-
-# else
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-# endif
-#endif
-
-
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value, Location, mc, tmpl, error_msg, scanner); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner)
-{
- FILE *yyoutput = yyo;
- YYUSE (yyoutput);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (tmpl);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yyvaluep)
- return;
-# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
-# endif
- YYUSE (yytype);
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner)
-{
- YYFPRINTF (yyo, "%s %s (",
- yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
-
- YY_LOCATION_PRINT (yyo, *yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yytype, yyvaluep, yylocationp, mc, tmpl, error_msg, scanner);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner)
-{
- unsigned long yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- yystos[yyssp[yyi + 1 - yynrhs]],
- &yyvsp[(yyi + 1) - (yynrhs)]
- , &(yylsp[(yyi + 1) - (yynrhs)]) , mc, tmpl, error_msg, scanner);
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule, mc, tmpl, error_msg, scanner); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-yystrlen (const char *yystr)
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif
-
-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-{
- char *yyd = yydest;
- const char *yys = yysrc;
-
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- else
- goto append;
-
- append:
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULLPTR;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- default: /* Avoid compiler warnings. */
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner)
-{
- YYUSE (yyvaluep);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (tmpl);
- YYUSE (error_msg);
- YYUSE (scanner);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YYUSE (yytype);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner)
-{
-/* The lookahead symbol. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs;
-
- int yystate;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
-
- /* The stacks and their tools:
- 'yyss': related to states.
- 'yyvs': related to semantic values.
- 'yyls': related to locations.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- /* The location stack. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls;
- YYLTYPE *yylsp;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
- YYSIZE_T yystacksize;
-
- int yyn;
- int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yylsp = yyls = yylsa;
- yystacksize = YYINITDEPTH;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yynewstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- *yyssp = (yytype_int16) yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- goto yyexhaustedlab;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yyls1, yysize * sizeof (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = yylex (&yylval, &yylloc, mc, scanner);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 6:
-#line 103 "template_syntax.y"
- {
- Attribute * pattr;
- string name((yyvsp[-2].val_str));
- string value((yyvsp[0].val_str));
-
- pattr = new SingleAttribute(name,unescape(value));
-
- tmpl->set(pattr);
- }
-#line 1413 "template_syntax.cc"
- break;
-
- case 7:
-#line 113 "template_syntax.y"
- {
- Attribute * pattr;
- string name((yyvsp[-4].val_str));
- map<string,string> * amap;
-
- amap = static_cast<map<string,string> *>((yyvsp[-1].val_attr));
- pattr = new VectorAttribute(name,*amap);
-
- tmpl->set(pattr);
-
- delete amap;
- }
-#line 1430 "template_syntax.cc"
- break;
-
- case 8:
-#line 126 "template_syntax.y"
- {
- Attribute * pattr;
- string name((yyvsp[-3].val_str));
-
- pattr = new VectorAttribute(name);
-
- tmpl->set(pattr);
- }
-#line 1443 "template_syntax.cc"
- break;
-
- case 9:
-#line 135 "template_syntax.y"
- {
- Attribute * pattr;
- string name((yyvsp[-1].val_str));
- string value;
-
- pattr = new SingleAttribute(name,value);
-
- tmpl->set(pattr);
- }
-#line 1457 "template_syntax.cc"
- break;
-
- case 10:
-#line 145 "template_syntax.y"
- {
- YYABORT;
- }
-#line 1465 "template_syntax.cc"
- break;
-
- case 11:
-#line 151 "template_syntax.y"
- {
- map<string,string>* vattr;
- string name((yyvsp[-2].val_str));
- string value((yyvsp[0].val_str));
-
- one_util::toupper(name);
-
- vattr = new map<string,string>;
- vattr->insert(make_pair(name,unescape(value)));
-
- (yyval.val_attr) = static_cast<void *>(vattr);
- }
-#line 1482 "template_syntax.cc"
- break;
-
- case 12:
-#line 164 "template_syntax.y"
- {
- string name((yyvsp[-2].val_str));
- string value((yyvsp[0].val_str));
- map<string,string> * attrmap;
-
- one_util::toupper(name);
-
- attrmap = static_cast<map<string,string> *>((yyvsp[-4].val_attr));
-
- attrmap->insert(make_pair(name,unescape(value)));
- (yyval.val_attr) = (yyvsp[-4].val_attr);
- }
-#line 1499 "template_syntax.cc"
- break;
-
-
-#line 1503 "template_syntax.cc"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if ! YYERROR_VERBOSE
- yyerror (&yylloc, mc, tmpl, error_msg, scanner, YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (&yylloc, mc, tmpl, error_msg, scanner, yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
- }
-
- yyerror_range[1] = yylloc;
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc, mc, tmpl, error_msg, scanner);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- yystos[yystate], yyvsp, yylsp, mc, tmpl, error_msg, scanner);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- /* Using YYLLOC is tempting, but would change the location of
- the lookahead. YYLOC is available though. */
- YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
- *++yylsp = yyloc;
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-
-#if !defined yyoverflow || YYERROR_VERBOSE
-/*-------------------------------------------------.
-| yyexhaustedlab -- memory exhaustion comes here. |
-`-------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, mc, tmpl, error_msg, scanner, YY_("memory exhausted"));
- yyresult = 2;
- /* Fall through. */
-#endif
-
-
-/*-----------------------------------------------------.
-| yyreturn -- parsing is finished, return the result. |
-`-----------------------------------------------------*/
-yyreturn:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc, mc, tmpl, error_msg, scanner);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp, yylsp, mc, tmpl, error_msg, scanner);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- return yyresult;
-}
-#line 177 "template_syntax.y"
-
-
-string& unescape (string &str)
-{
- size_t pos = 0;
-
- while ((pos = str.find("\\\"", pos)) != string::npos)
- {
- str.replace(pos,2,"\"");
- }
-
- return str;
-}
-
-void template_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- Template * tmpl,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.h
deleted file mode 100644
index 25d2ba5..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.h
+++ /dev/null
@@ -1,119 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-#ifndef YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED
-# define YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int template_debug;
-#endif
-/* "%code requires" blocks. */
-#line 47 "template_syntax.y"
-
-#include <iostream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-#include <stdio.h>
-
-#include "mem_collector.h"
-
-#include "Template.h"
-
-typedef void * yyscan_t;
-
-int template_parse(Template * tmpl, char ** errmsg, yyscan_t scanner);
-
-#line 67 "template_syntax.hh"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EQUAL_EMPTY = 262,
- CCDATA = 263,
- STRING = 264,
- VARIABLE = 265
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 74 "template_syntax.y"
-
- char * val_str;
- void * val_attr;
-
-#line 94 "template_syntax.hh"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int template_parse (mem_collector * mc, Template * tmpl, char ** error_msg, yyscan_t scanner);
-
-#endif /* !YY_TEMPLATE_TEMPLATE_SYNTAX_HH_INCLUDED */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.y b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.y
deleted file mode 100644
index 989f5f5..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/template_syntax.y
+++ /dev/null
@@ -1,215 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%{
-#include "template_syntax.h"
-#include "template_parser.h"
-#include "NebulaUtil.h"
-
-#define YYERROR_VERBOSE
-
-void template_error( YYLTYPE * llocp, mem_collector * mc, Template * tmpl,
- char ** error_msg, yyscan_t scanner, const char * str);
-
-int template_lex (YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int template_parse(Template * tmpl, char ** errmsg, yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = template_parse(&mc, tmpl, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-static string& unescape (string &str);
-%}
-
-%code requires {
-#include <iostream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-#include <stdio.h>
-
-#include "mem_collector.h"
-
-#include "Template.h"
-
-typedef void * yyscan_t;
-
-int template_parse(Template * tmpl, char ** errmsg, yyscan_t scanner);
-}
-
-%parse-param {mem_collector * mc}
-%parse-param {Template * tmpl}
-%parse-param {char ** error_msg}
-%parse-param {yyscan_t scanner}
-
-%lex-param {mem_collector * mc}
-%lex-param {yyscan_t scanner}
-
-%union {
- char * val_str;
- void * val_attr;
-};
-
-%defines
-%locations
-%pure-parser
-%name-prefix "template_"
-%output "template_syntax.cc"
-
-%token EQUAL COMMA OBRACKET CBRACKET EQUAL_EMPTY CCDATA
-%token <val_str> STRING
-%token <val_str> VARIABLE
-%type <val_attr> array_val
-%type <void> attribute
-%type <void> template
-
-%%
-
-template_file :
- | template
- ;
-
-template: attribute
- | template attribute
- ;
-
-attribute: VARIABLE EQUAL STRING
- {
- Attribute * pattr;
- string name($1);
- string value($3);
-
- pattr = new SingleAttribute(name,unescape(value));
-
- tmpl->set(pattr);
- }
- | VARIABLE EQUAL OBRACKET array_val CBRACKET
- {
- Attribute * pattr;
- string name($1);
- map<string,string> * amap;
-
- amap = static_cast<map<string,string> *>($4);
- pattr = new VectorAttribute(name,*amap);
-
- tmpl->set(pattr);
-
- delete amap;
- }
- | VARIABLE EQUAL OBRACKET CBRACKET
- {
- Attribute * pattr;
- string name($1);
-
- pattr = new VectorAttribute(name);
-
- tmpl->set(pattr);
- }
- | VARIABLE EQUAL_EMPTY
- {
- Attribute * pattr;
- string name($1);
- string value;
-
- pattr = new SingleAttribute(name,value);
-
- tmpl->set(pattr);
- }
- | VARIABLE EQUAL CCDATA
- {
- YYABORT;
- }
- ;
-
-array_val: VARIABLE EQUAL STRING
- {
- map<string,string>* vattr;
- string name($1);
- string value($3);
-
- one_util::toupper(name);
-
- vattr = new map<string,string>;
- vattr->insert(make_pair(name,unescape(value)));
-
- $$ = static_cast<void *>(vattr);
- }
- | array_val COMMA VARIABLE EQUAL STRING
- {
- string name($3);
- string value($5);
- map<string,string> * attrmap;
-
- one_util::toupper(name);
-
- attrmap = static_cast<map<string,string> *>($1);
-
- attrmap->insert(make_pair(name,unescape(value)));
- $$ = $1;
- }
- ;
-%%
-
-string& unescape (string &str)
-{
- size_t pos = 0;
-
- while ((pos = str.find("\\\"", pos)) != string::npos)
- {
- str.replace(pos,2,"\"");
- }
-
- return str;
-}
-
-void template_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- Template * tmpl,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.cc
deleted file mode 100644
index ba5e634..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.cc
+++ /dev/null
@@ -1,1843 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Bison version. */
-#define YYBISON_VERSION "3.4.1"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 1
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse vm_file_var_parse
-#define yylex vm_file_var_lex
-#define yyerror vm_file_var_error
-#define yydebug vm_file_var_debug
-#define yynerrs vm_file_var_nerrs
-
-
-/* First part of user prologue. */
-#line 40 "vm_file_var_syntax.y"
-
-#include "vm_file_var_syntax.h"
-#include "vm_var_parser.h"
-
-#define YYERROR_VERBOSE
-#define vm_file_var_lex vm_var_lex
-
-void vm_file_var_error(YYLTYPE * llocp, mem_collector * mc, VirtualMachine * vm,
- vector<int> * img_ids, char ** errmsg, yyscan_t scanner, const char * str);
-
-int vm_var_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int vm_file_var_parse (VirtualMachine * vm, vector<int> * img_ids,
- char ** errmsg, yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = vm_file_var_parse(&mc, vm, img_ids, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-int get_image_path(VirtualMachine * vm,
- const string& var_name,
- const string& var1,
- const string& val1,
- const string& var2,
- const string& val2,
- vector<int> * img_ids,
- string& error_str)
-{
- Nebula& nd = Nebula::instance();
-
- ImagePool * ipool = nd.get_ipool();
- UserPool * upool = nd.get_upool();
- Image * img = 0;
- User * user = 0;
- int iid = -1;
-
- PoolObjectAuth perm;
-
- if (var_name != "FILE" )
- {
- error_str = "Must use FILE variable for attribute.";
- return -1;
- }
-
- if ( var1 == "IMAGE" )
- {
- int uid = vm->get_uid();
-
- if ( !var2.empty() )
- {
- VectorAttribute * vfile;
- map<string,string> file_values;
-
- file_values.insert(make_pair(var1, val1));
- file_values.insert(make_pair(var2, val2));
-
- vfile = new VectorAttribute("FILE", file_values);
-
- VirtualMachineDisk file_disk(vfile, 0);
- uid = file_disk.get_uid(uid);
-
- delete vfile;
- }
-
- img = ipool->get_ro(val1, uid);
-
- if ( img == 0 )
- {
- ostringstream oss;
- oss << "User " << uid << " does not own an image with name: " << val1
- << " . Set IMAGE_UNAME or IMAGE_UID of owner.";
-
- error_str = oss.str();
-
- return -1;
- }
- }
- else if ( var1 == "IMAGE_ID" )
- {
- istringstream is(val1);
-
- is >> iid;
-
- if ( !is.fail() )
- {
- img = ipool->get_ro(iid);
- }
-
- if ( img == 0 )
- {
- ostringstream oss;
- oss << "Image with ID: " << iid << " does not exist";
-
- error_str = oss.str();
-
- return -1;
- }
- }
- else
- {
- error_str = "Cannot get image, set IMAGE_ID or IMAGE.";
- return -1;
- }
-
- iid = img->get_oid();
-
- img->get_permissions(perm);
-
- img->unlock();;
-
- set<int> gids;
-
- user = upool->get_ro(vm->get_uid());
-
- if (user != 0)
- {
- gids = user->get_groups();
- user->unlock();
- }
- else
- {
- gids.insert(vm->get_gid());
- }
-
- AuthRequest ar(vm->get_uid(), gids);
-
- ar.add_auth(AuthRequest::USE, perm);
-
- if (UserPool::authorize(ar) == -1)
- {
- error_str = "User not authorize to use image.";
- return -1;
- }
-
- img_ids->push_back(iid);
-
- return 0;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-
-#line 232 "vm_file_var_syntax.cc"
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Use api.header.include to #include this header
- instead of duplicating it here. */
-#ifndef YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED
-# define YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int vm_file_var_debug;
-#endif
-/* "%code requires" blocks. */
-#line 17 "vm_file_var_syntax.y"
-
-#include <iostream>
-#include <vector>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "ImagePool.h"
-#include "UserPool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_file_var_parse (VirtualMachine * vm, vector<int> * img_ids,
- char ** errmsg, yyscan_t scanner);
-
-#line 289 "vm_file_var_syntax.cc"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EOA = 262,
- STRING = 263,
- VARIABLE = 264,
- RSTRING = 265,
- INTEGER = 266
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 205 "vm_file_var_syntax.y"
-
- char * val_str;
- int val_int;
- char val_char;
-
-#line 318 "vm_file_var_syntax.cc"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int vm_file_var_parse (mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner);
-
-#endif /* !YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED */
-
-
-
-#ifdef short
-# undef short
-#endif
-
-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
-#endif
-
-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
-#else
-typedef unsigned short yytype_uint16;
-#endif
-
-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE
-# if (defined __GNUC__ \
- && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
- || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
-# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
-# else
-# define YY_ATTRIBUTE(Spec) /* empty */
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_PURE
-# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YYUSE(E) ((void) (E))
-#else
-# define YYUSE(E) /* empty */
-#endif
-
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if ! defined yyoverflow || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include <alloca.h> /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include <malloc.h> /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yytype_int16 yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 5
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 16
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 12
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 3
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 5
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 18
-
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 266
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- ((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 9, 10, 11
-};
-
-#if YYDEBUG
- /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_uint8 yyrline[] =
-{
- 0, 229, 229, 230, 234, 252
-};
-#endif
-
-#if YYDEBUG || YYERROR_VERBOSE || 0
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "$end", "error", "$undefined", "EQUAL", "COMMA", "OBRACKET", "CBRACKET",
- "EOA", "STRING", "VARIABLE", "RSTRING", "INTEGER", "$accept",
- "vm_string", "vm_variable", YY_NULLPTR
-};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[NUM] -- (External) token number corresponding to the
- (internal) symbol number NUM (which must be that of a token). */
-static const yytype_uint16 yytoknum[] =
-{
- 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
- 265, 266
-};
-# endif
-
-#define YYPACT_NINF -8
-
-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-8)))
-
-#define YYTABLE_NINF -1
-
-#define yytable_value_is_error(Yytable_value) \
- 0
-
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int8 yypact[] =
-{
- -7, -1, 0, -8, -4, -8, -8, 3, 2, -3,
- -2, 1, 8, -8, 4, 7, 9, -8
-};
-
- /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 0, 0, 0, 2, 0, 1, 3, 0, 0, 0,
- 0, 0, 0, 4, 0, 0, 0, 5
-};
-
- /* YYPGOTO[NTERM-NUM]. */
-static const yytype_int8 yypgoto[] =
-{
- -8, -8, 12
-};
-
- /* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int8 yydefgoto[] =
-{
- -1, 2, 3
-};
-
- /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_uint8 yytable[] =
-{
- 5, 10, 1, 11, 4, 7, 8, 12, 13, 1,
- 9, 14, 15, 16, 6, 0, 17
-};
-
-static const yytype_int8 yycheck[] =
-{
- 0, 4, 9, 6, 5, 9, 3, 9, 7, 9,
- 8, 3, 8, 6, 2, -1, 7
-};
-
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
-{
- 0, 9, 13, 14, 5, 0, 14, 9, 3, 8,
- 4, 6, 9, 7, 3, 8, 6, 7
-};
-
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 12, 13, 13, 14, 14
-};
-
- /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 1, 2, 7, 11
-};
-
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, mc, vm, img_ids, errmsg, scanner, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
-
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YY_LOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-#ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
- }
-
-# define YY_LOCATION_PRINT(File, Loc) \
- yy_location_print_ (File, &(Loc))
-
-# else
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-# endif
-#endif
-
-
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value, Location, mc, vm, img_ids, errmsg, scanner); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner)
-{
- FILE *yyoutput = yyo;
- YYUSE (yyoutput);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (vm);
- YYUSE (img_ids);
- YYUSE (errmsg);
- YYUSE (scanner);
- if (!yyvaluep)
- return;
-# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
-# endif
- YYUSE (yytype);
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner)
-{
- YYFPRINTF (yyo, "%s %s (",
- yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
-
- YY_LOCATION_PRINT (yyo, *yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yytype, yyvaluep, yylocationp, mc, vm, img_ids, errmsg, scanner);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner)
-{
- unsigned long yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- yystos[yyssp[yyi + 1 - yynrhs]],
- &yyvsp[(yyi + 1) - (yynrhs)]
- , &(yylsp[(yyi + 1) - (yynrhs)]) , mc, vm, img_ids, errmsg, scanner);
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule, mc, vm, img_ids, errmsg, scanner); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-yystrlen (const char *yystr)
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif
-
-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-{
- char *yyd = yydest;
- const char *yys = yysrc;
-
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- else
- goto append;
-
- append:
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULLPTR;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- default: /* Avoid compiler warnings. */
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner)
-{
- YYUSE (yyvaluep);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (vm);
- YYUSE (img_ids);
- YYUSE (errmsg);
- YYUSE (scanner);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YYUSE (yytype);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner)
-{
-/* The lookahead symbol. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs;
-
- int yystate;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
-
- /* The stacks and their tools:
- 'yyss': related to states.
- 'yyvs': related to semantic values.
- 'yyls': related to locations.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- /* The location stack. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls;
- YYLTYPE *yylsp;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
- YYSIZE_T yystacksize;
-
- int yyn;
- int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yylsp = yyls = yylsa;
- yystacksize = YYINITDEPTH;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yynewstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- *yyssp = (yytype_int16) yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- goto yyexhaustedlab;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yyls1, yysize * sizeof (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = yylex (&yylval, &yylloc, mc, scanner);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 4:
-#line 235 "vm_file_var_syntax.y"
- {
- string file((yyvsp[-6].val_str));
- string var1((yyvsp[-4].val_str));
- string val1((yyvsp[-2].val_str));
-
- string result;
-
- one_util::toupper(file);
- one_util::toupper(var1);
-
- if (get_image_path(vm, file, var1, val1, "", "", img_ids, result) == -1)
- {
- img_ids->clear();
- *errmsg = strdup(result.c_str());
- YYABORT;
- }
- }
-#line 1549 "vm_file_var_syntax.cc"
- break;
-
- case 5:
-#line 253 "vm_file_var_syntax.y"
- {
- string file((yyvsp[-10].val_str));
- string var1((yyvsp[-8].val_str));
- string val1((yyvsp[-6].val_str));
- string var2((yyvsp[-4].val_str));
- string val2((yyvsp[-2].val_str));
-
- string result;
-
- one_util::toupper(file);
- one_util::toupper(var1);
- one_util::toupper(var2);
-
- if (get_image_path(vm, file, var1, val1, var2, val2, img_ids, result) == -1)
- {
- img_ids->clear();
- *errmsg = strdup(result.c_str());
- YYABORT;
- }
- }
-#line 1574 "vm_file_var_syntax.cc"
- break;
-
-
-#line 1578 "vm_file_var_syntax.cc"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if ! YYERROR_VERBOSE
- yyerror (&yylloc, mc, vm, img_ids, errmsg, scanner, YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (&yylloc, mc, vm, img_ids, errmsg, scanner, yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
- }
-
- yyerror_range[1] = yylloc;
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc, mc, vm, img_ids, errmsg, scanner);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- yystos[yystate], yyvsp, yylsp, mc, vm, img_ids, errmsg, scanner);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- /* Using YYLLOC is tempting, but would change the location of
- the lookahead. YYLOC is available though. */
- YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
- *++yylsp = yyloc;
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-
-#if !defined yyoverflow || YYERROR_VERBOSE
-/*-------------------------------------------------.
-| yyexhaustedlab -- memory exhaustion comes here. |
-`-------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, mc, vm, img_ids, errmsg, scanner, YY_("memory exhausted"));
- yyresult = 2;
- /* Fall through. */
-#endif
-
-
-/*-----------------------------------------------------.
-| yyreturn -- parsing is finished, return the result. |
-`-----------------------------------------------------*/
-yyreturn:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc, mc, vm, img_ids, errmsg, scanner);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp, yylsp, mc, vm, img_ids, errmsg, scanner);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- return yyresult;
-}
-#line 274 "vm_file_var_syntax.y"
-
-
-void vm_file_var_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- VirtualMachine * vm,
- vector<int> * img_ids,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.h
deleted file mode 100644
index bfa01d3..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.h
+++ /dev/null
@@ -1,125 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-#ifndef YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED
-# define YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int vm_file_var_debug;
-#endif
-/* "%code requires" blocks. */
-#line 17 "vm_file_var_syntax.y"
-
-#include <iostream>
-#include <vector>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "ImagePool.h"
-#include "UserPool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_file_var_parse (VirtualMachine * vm, vector<int> * img_ids,
- char ** errmsg, yyscan_t scanner);
-
-#line 71 "vm_file_var_syntax.hh"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EOA = 262,
- STRING = 263,
- VARIABLE = 264,
- RSTRING = 265,
- INTEGER = 266
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 205 "vm_file_var_syntax.y"
-
- char * val_str;
- int val_int;
- char val_char;
-
-#line 100 "vm_file_var_syntax.hh"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int vm_file_var_parse (mem_collector * mc, VirtualMachine * vm, vector<int> * img_ids, char ** errmsg, yyscan_t scanner);
-
-#endif /* !YY_VM_FILE_VAR_VM_FILE_VAR_SYNTAX_HH_INCLUDED */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.y b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.y
deleted file mode 100644
index 6639a72..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_file_var_syntax.y
+++ /dev/null
@@ -1,301 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%code requires {
-#include <iostream>
-#include <vector>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "ImagePool.h"
-#include "UserPool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_file_var_parse (VirtualMachine * vm, vector<int> * img_ids,
- char ** errmsg, yyscan_t scanner);
-}
-
-%{
-#include "vm_file_var_syntax.h"
-#include "vm_var_parser.h"
-
-#define YYERROR_VERBOSE
-#define vm_file_var_lex vm_var_lex
-
-void vm_file_var_error(YYLTYPE * llocp, mem_collector * mc, VirtualMachine * vm,
- vector<int> * img_ids, char ** errmsg, yyscan_t scanner, const char * str);
-
-int vm_var_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int vm_file_var_parse (VirtualMachine * vm, vector<int> * img_ids,
- char ** errmsg, yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = vm_file_var_parse(&mc, vm, img_ids, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-int get_image_path(VirtualMachine * vm,
- const string& var_name,
- const string& var1,
- const string& val1,
- const string& var2,
- const string& val2,
- vector<int> * img_ids,
- string& error_str)
-{
- Nebula& nd = Nebula::instance();
-
- ImagePool * ipool = nd.get_ipool();
- UserPool * upool = nd.get_upool();
- Image * img = 0;
- User * user = 0;
- int iid = -1;
-
- PoolObjectAuth perm;
-
- if (var_name != "FILE" )
- {
- error_str = "Must use FILE variable for attribute.";
- return -1;
- }
-
- if ( var1 == "IMAGE" )
- {
- int uid = vm->get_uid();
-
- if ( !var2.empty() )
- {
- VectorAttribute * vfile;
- map<string,string> file_values;
-
- file_values.insert(make_pair(var1, val1));
- file_values.insert(make_pair(var2, val2));
-
- vfile = new VectorAttribute("FILE", file_values);
-
- VirtualMachineDisk file_disk(vfile, 0);
- uid = file_disk.get_uid(uid);
-
- delete vfile;
- }
-
- img = ipool->get_ro(val1, uid);
-
- if ( img == 0 )
- {
- ostringstream oss;
- oss << "User " << uid << " does not own an image with name: " << val1
- << " . Set IMAGE_UNAME or IMAGE_UID of owner.";
-
- error_str = oss.str();
-
- return -1;
- }
- }
- else if ( var1 == "IMAGE_ID" )
- {
- istringstream is(val1);
-
- is >> iid;
-
- if ( !is.fail() )
- {
- img = ipool->get_ro(iid);
- }
-
- if ( img == 0 )
- {
- ostringstream oss;
- oss << "Image with ID: " << iid << " does not exist";
-
- error_str = oss.str();
-
- return -1;
- }
- }
- else
- {
- error_str = "Cannot get image, set IMAGE_ID or IMAGE.";
- return -1;
- }
-
- iid = img->get_oid();
-
- img->get_permissions(perm);
-
- img->unlock();;
-
- set<int> gids;
-
- user = upool->get_ro(vm->get_uid());
-
- if (user != 0)
- {
- gids = user->get_groups();
- user->unlock();
- }
- else
- {
- gids.insert(vm->get_gid());
- }
-
- AuthRequest ar(vm->get_uid(), gids);
-
- ar.add_auth(AuthRequest::USE, perm);
-
- if (UserPool::authorize(ar) == -1)
- {
- error_str = "User not authorize to use image.";
- return -1;
- }
-
- img_ids->push_back(iid);
-
- return 0;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-%}
-
-%parse-param {mem_collector * mc}
-%parse-param {VirtualMachine * vm}
-%parse-param {vector<int> * img_ids}
-%parse-param {char ** errmsg}
-%parse-param {yyscan_t scanner}
-
-%lex-param {mem_collector * mc}
-%lex-param {yyscan_t scanner}
-
-%union {
- char * val_str;
- int val_int;
- char val_char;
-};
-
-%defines
-%locations
-%pure-parser
-%name-prefix "vm_file_var_"
-%output "vm_file_var_syntax.cc"
-
-%token EQUAL COMMA OBRACKET CBRACKET
-
-%token <val_char> EOA
-%token <val_str> STRING
-%token <val_str> VARIABLE
-%token <val_str> RSTRING
-%token <val_int> INTEGER
-%type <void> vm_variable
-%type <void> vm_string
-
-%%
-
-vm_string: vm_variable
- | vm_string vm_variable
- ;
-
-vm_variable:
- VARIABLE OBRACKET VARIABLE EQUAL STRING CBRACKET EOA
- {
- string file($1);
- string var1($3);
- string val1($5);
-
- string result;
-
- one_util::toupper(file);
- one_util::toupper(var1);
-
- if (get_image_path(vm, file, var1, val1, "", "", img_ids, result) == -1)
- {
- img_ids->clear();
- *errmsg = strdup(result.c_str());
- YYABORT;
- }
- }
- | VARIABLE OBRACKET VARIABLE EQUAL STRING COMMA VARIABLE EQUAL STRING CBRACKET EOA
- {
- string file($1);
- string var1($3);
- string val1($5);
- string var2($7);
- string val2($9);
-
- string result;
-
- one_util::toupper(file);
- one_util::toupper(var1);
- one_util::toupper(var2);
-
- if (get_image_path(vm, file, var1, val1, var2, val2, img_ids, result) == -1)
- {
- img_ids->clear();
- *errmsg = strdup(result.c_str());
- YYABORT;
- }
- }
- ;
-%%
-
-void vm_file_var_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- VirtualMachine * vm,
- vector<int> * img_ids,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.cc
deleted file mode 100644
index 0d94e81..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.cc
+++ /dev/null
@@ -1,2319 +0,0 @@
-#line 1 "vm_var_parser.cc"
-
-#line 3 "vm_var_parser.cc"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define vm_var__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer vm_var__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define vm_var__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer vm_var__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define vm_var__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer vm_var__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define vm_var__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string vm_var__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define vm_var__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes vm_var__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define vm_var__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer vm_var__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define vm_var__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer vm_var__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define vm_var__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state vm_var__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define vm_var__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer vm_var__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define vm_var_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state vm_var_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define vm_var_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state vm_var_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define vm_var_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack vm_var_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define vm_var_lex_ALREADY_DEFINED
-#else
-#define yylex vm_var_lex
-#endif
-
-#ifdef yyrestart
-#define vm_var_restart_ALREADY_DEFINED
-#else
-#define yyrestart vm_var_restart
-#endif
-
-#ifdef yylex_init
-#define vm_var_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init vm_var_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define vm_var_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra vm_var_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define vm_var_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy vm_var_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define vm_var_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug vm_var_get_debug
-#endif
-
-#ifdef yyset_debug
-#define vm_var_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug vm_var_set_debug
-#endif
-
-#ifdef yyget_extra
-#define vm_var_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra vm_var_get_extra
-#endif
-
-#ifdef yyset_extra
-#define vm_var_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra vm_var_set_extra
-#endif
-
-#ifdef yyget_in
-#define vm_var_get_in_ALREADY_DEFINED
-#else
-#define yyget_in vm_var_get_in
-#endif
-
-#ifdef yyset_in
-#define vm_var_set_in_ALREADY_DEFINED
-#else
-#define yyset_in vm_var_set_in
-#endif
-
-#ifdef yyget_out
-#define vm_var_get_out_ALREADY_DEFINED
-#else
-#define yyget_out vm_var_get_out
-#endif
-
-#ifdef yyset_out
-#define vm_var_set_out_ALREADY_DEFINED
-#else
-#define yyset_out vm_var_set_out
-#endif
-
-#ifdef yyget_leng
-#define vm_var_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng vm_var_get_leng
-#endif
-
-#ifdef yyget_text
-#define vm_var_get_text_ALREADY_DEFINED
-#else
-#define yyget_text vm_var_get_text
-#endif
-
-#ifdef yyget_lineno
-#define vm_var_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno vm_var_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define vm_var_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno vm_var_set_lineno
-#endif
-
-#ifdef yyget_column
-#define vm_var_get_column_ALREADY_DEFINED
-#else
-#define yyget_column vm_var_get_column
-#endif
-
-#ifdef yyset_column
-#define vm_var_set_column_ALREADY_DEFINED
-#else
-#define yyset_column vm_var_set_column
-#endif
-
-#ifdef yywrap
-#define vm_var_wrap_ALREADY_DEFINED
-#else
-#define yywrap vm_var_wrap
-#endif
-
-#ifdef yyget_lval
-#define vm_var_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval vm_var_get_lval
-#endif
-
-#ifdef yyset_lval
-#define vm_var_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval vm_var_set_lval
-#endif
-
-#ifdef yyalloc
-#define vm_var_alloc_ALREADY_DEFINED
-#else
-#define yyalloc vm_var_alloc
-#endif
-
-#ifdef yyrealloc
-#define vm_var_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc vm_var_realloc
-#endif
-
-#ifdef yyfree
-#define vm_var_free_ALREADY_DEFINED
-#else
-#define yyfree vm_var_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an
- * integer in range [0..255] for use as an array index.
- */
-#define YY_SC_TO_UI(c) ((YY_CHAR) (c))
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Enter a start condition. This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yyg->yy_start = 1 + 2 *
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state. The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yyg->yy_start - 1) / 2)
-#define YYSTATE YY_START
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin , yyscanner )
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-/* The state buf must be large enough to hold one state per character in the main buffer.
- */
-#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
- /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
- * access to the local variable yy_act. Since yyless() is a macro, it would break
- * existing scanners that call yyless() from OUTSIDE yylex.
- * One obvious solution it to make yy_act a global. I tried that, and saw
- * a 5% performance hit in a non-yylineno scanner, because yy_act is
- * normally declared as a register variable-- so it is not worth it.
- */
- #define YY_LESS_LINENO(n) \
- do { \
- int yyl;\
- for ( yyl = n; yyl < yyleng; ++yyl )\
- if ( yytext[yyl] == '\n' )\
- --yylineno;\
- }while(0)
- #define YY_LINENO_REWIND_TO(dst) \
- do {\
- const char *p;\
- for ( p = yy_cp-1; p >= (dst); --p)\
- if ( *p == '\n' )\
- --yylineno;\
- }while(0)
-
-/* Return all but the first "n" matched characters back to the input stream. */
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- *yy_cp = yyg->yy_hold_char; \
- YY_RESTORE_YY_MORE_OFFSET \
- yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- } \
- while ( 0 )
-#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
- /* When an EOF's been seen but there's still some text to process
- * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- * shouldn't try reading from the input source any more. We might
- * still have a bunch of tokens to match, though, because of
- * possible backing-up.
- *
- * When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
- * just pointing yyin at a new input file.
- */
-#define YY_BUFFER_EOF_PENDING 2
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- *
- * Returns the top of the stack, or NULL.
- */
-#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
- ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
- : NULL)
-/* Same as previous macro, but useful when we know that the buffer stack is not
- * NULL or when we need an lvalue. For internal use only.
- */
-#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-static void yyensure_buffer_stack ( yyscan_t yyscanner );
-static void yy_load_buffer_state ( yyscan_t yyscanner );
-static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file , yyscan_t yyscanner );
-#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner)
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-#define yy_new_buffer yy_create_buffer
-#define yy_set_interactive(is_interactive) \
- { \
- if ( ! YY_CURRENT_BUFFER ){ \
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
- }
-#define yy_set_bol(at_bol) \
- { \
- if ( ! YY_CURRENT_BUFFER ){\
- yyensure_buffer_stack (yyscanner); \
- YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
- } \
- YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
- }
-#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
-
-/* Begin user sect3 */
-typedef flex_uint8_t YY_CHAR;
-
-typedef int yy_state_type;
-
-#define yytext_ptr yytext_r
-
-static yy_state_type yy_get_previous_state ( yyscan_t yyscanner );
-static yy_state_type yy_try_NUL_trans ( yy_state_type current_state , yyscan_t yyscanner);
-static int yy_get_next_buffer ( yyscan_t yyscanner );
-static void yynoreturn yy_fatal_error ( const char* msg , yyscan_t yyscanner );
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
- yyg->yytext_ptr = yy_bp; \
- yyleng = (int) (yy_cp - yy_bp); \
- yyg->yy_hold_char = *yy_cp; \
- *yy_cp = '\0'; \
- yyg->yy_c_buf_p = yy_cp;
-#define YY_NUM_RULES 12
-#define YY_END_OF_BUFFER 13
-/* This struct is not used in this scanner,
- but its presence is necessary. */
-struct yy_trans_info
- {
- flex_int32_t yy_verify;
- flex_int32_t yy_nxt;
- };
-static const flex_int16_t yy_accept[36] =
- { 0,
- 0, 0, 0, 0, 0, 0, 13, 1, 2, 12,
- 11, 11, 12, 10, 4, 7, 3, 5, 6, 12,
- 9, 1, 0, 0, 4, 3, 6, 4, 7, 3,
- 5, 0, 8, 9, 0
- } ;
-
-static const YY_CHAR yy_ec[256] =
- { 0,
- 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 1, 4, 1, 5, 1, 1, 1, 1,
- 1, 1, 1, 6, 1, 1, 1, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 1, 1, 1,
- 8, 1, 1, 1, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 9, 10, 11, 1, 12, 1, 7, 7, 7, 7,
-
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1
- } ;
-
-static const YY_CHAR yy_meta[13] =
- { 0,
- 1, 1, 1, 1, 2, 1, 3, 1, 1, 1,
- 1, 3
- } ;
-
-static const flex_int16_t yy_base[41] =
- { 0,
- 0, 6, 16, 0, 25, 29, 45, 34, 59, 37,
- 59, 35, 59, 59, 38, 0, 37, 36, 59, 31,
- 27, 21, 25, 0, 13, 12, 59, 11, 0, 10,
- 7, 4, 59, 0, 59, 46, 49, 52, 0, 55
- } ;
-
-static const flex_int16_t yy_def[41] =
- { 0,
- 36, 36, 35, 3, 37, 37, 35, 38, 35, 38,
- 35, 35, 35, 35, 35, 39, 35, 35, 35, 40,
- 35, 38, 38, 12, 35, 35, 35, 35, 39, 35,
- 35, 40, 35, 35, 0, 35, 35, 35, 35, 35
- } ;
-
-static const flex_int16_t yy_nxt[72] =
- { 0,
- 35, 35, 29, 35, 9, 35, 34, 33, 31, 10,
- 9, 30, 28, 30, 28, 10, 11, 12, 13, 11,
- 14, 15, 16, 17, 18, 11, 19, 16, 20, 22,
- 23, 21, 20, 34, 33, 21, 24, 31, 30, 28,
- 25, 22, 26, 23, 35, 27, 8, 8, 8, 13,
- 13, 13, 22, 35, 22, 32, 32, 32, 7, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35
- } ;
-
-static const flex_int16_t yy_chk[72] =
- { 0,
- 0, 0, 39, 0, 1, 0, 34, 32, 31, 1,
- 2, 30, 28, 26, 25, 2, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 5, 23,
- 22, 5, 6, 21, 20, 6, 12, 18, 17, 15,
- 12, 10, 12, 8, 7, 12, 36, 36, 36, 37,
- 37, 37, 38, 0, 38, 40, 40, 40, 35, 35,
- 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
- 35
- } ;
-
-/* Table of booleans, true if rule could match eol. */
-static const flex_int32_t yy_rule_can_match_eol[13] =
- { 0,
-1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, };
-
-/* The intent behind this definition is that it'll catch
- * any uses of REJECT which flex missed.
- */
-#define REJECT reject_used_but_not_detected
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-#define YY_RESTORE_YY_MORE_OFFSET
-#line 1 "vm_var_parser.l"
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-#line 18 "vm_var_parser.l"
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <pthread.h>
-
-#include "vm_var_syntax.h"
-#include "vm_file_var_syntax.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int vm_var_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-#line 721 "vm_var_parser.cc"
-
-#line 723 "vm_var_parser.cc"
-
-#define INITIAL 0
-#define VAR 1
-#define VALUE 2
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-/* Holds the entire state of the reentrant scanner. */
-struct yyguts_t
- {
-
- /* User-defined. Not touched by flex. */
- YY_EXTRA_TYPE yyextra_r;
-
- /* The rest are the same as the globals declared in the non-reentrant scanner. */
- FILE *yyin_r, *yyout_r;
- size_t yy_buffer_stack_top; /**< index of top of stack. */
- size_t yy_buffer_stack_max; /**< capacity of stack. */
- YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
- char yy_hold_char;
- int yy_n_chars;
- int yyleng_r;
- char *yy_c_buf_p;
- int yy_init;
- int yy_start;
- int yy_did_buffer_switch_on_eof;
- int yy_start_stack_ptr;
- int yy_start_stack_depth;
- int *yy_start_stack;
- yy_state_type yy_last_accepting_state;
- char* yy_last_accepting_cpos;
-
- int yylineno_r;
- int yy_flex_debug_r;
-
- char *yytext_r;
- int yy_more_flag;
- int yy_more_len;
-
- YYSTYPE * yylval_r;
-
- }; /* end struct yyguts_t */
-
-static int yy_init_globals ( yyscan_t yyscanner );
-
- /* This must go here because YYSTYPE and YYLTYPE are included
- * from bison output in section 1.*/
- # define yylval yyg->yylval_r
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput ( yyscan_t yyscanner );
-#else
-static int input ( yyscan_t yyscanner );
-#endif
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
-#endif
-
-/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
- if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
- { \
- int c = '*'; \
- int n; \
- for ( n = 0; n < max_size && \
- (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
- buf[n] = (char) c; \
- if ( c == '\n' ) \
- buf[n++] = (char) c; \
- if ( c == EOF && ferror( yyin ) ) \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- result = n; \
- } \
- else \
- { \
- errno=0; \
- while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
- { \
- if( errno != EINTR) \
- { \
- YY_FATAL_ERROR( "input in flex scanner failed" ); \
- break; \
- } \
- errno=0; \
- clearerr(yyin); \
- } \
- }\
-\
-
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
-#endif
-
-/* end tables serialization structures and prototypes */
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK /*LINTED*/break;
-#endif
-
-#define YY_RULE_SETUP \
- YY_USER_ACTION
-
-/** The main scanner function which does all the work.
- */
-YY_DECL
-{
- yy_state_type yy_current_state;
- char *yy_cp, *yy_bp;
- int yy_act;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yylval = yylval_param;
-
- if ( !yyg->yy_init )
- {
- yyg->yy_init = 1;
-
-#ifdef YY_USER_INIT
- YY_USER_INIT;
-#endif
-
- if ( ! yyg->yy_start )
- yyg->yy_start = 1; /* first start state */
-
- if ( ! yyin )
- yyin = stdin;
-
- if ( ! yyout )
- yyout = stdout;
-
- if ( ! YY_CURRENT_BUFFER ) {
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_load_buffer_state( yyscanner );
- }
-
- {
-#line 47 "vm_var_parser.l"
-
-
-#line 50 "vm_var_parser.l"
- /* ------------------------------------------------------------------------- */
- /* Just copy the string verbatim till we find a variable (starts with $) */
- /* ------------------------------------------------------------------------- */
-
-#line 1005 "vm_var_parser.cc"
-
- while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
- {
- yy_cp = yyg->yy_c_buf_p;
-
- /* Support of yytext. */
- *yy_cp = yyg->yy_hold_char;
-
- /* yy_bp points to the position in yy_ch_buf of the start of
- * the current run.
- */
- yy_bp = yy_cp;
-
- yy_current_state = yyg->yy_start;
-yy_match:
- do
- {
- YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 36 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- ++yy_cp;
- }
- while ( yy_base[yy_current_state] != 59 );
-
-yy_find_action:
- yy_act = yy_accept[yy_current_state];
- if ( yy_act == 0 )
- { /* have to back up */
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- yy_act = yy_accept[yy_current_state];
- }
-
- YY_DO_BEFORE_ACTION;
-
- if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
- {
- int yyl;
- for ( yyl = 0; yyl < yyleng; ++yyl )
- if ( yytext[yyl] == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
- }
-
-do_action: /* This label is used only to access EOF actions. */
-
- switch ( yy_act )
- { /* beginning of action switch */
- case 0: /* must back up */
- /* undo the effects of YY_DO_BEFORE_ACTION */
- *yy_cp = yyg->yy_hold_char;
- yy_cp = yyg->yy_last_accepting_cpos;
- yy_current_state = yyg->yy_last_accepting_state;
- goto yy_find_action;
-
-case 1:
-/* rule 1 can match eol */
-YY_RULE_SETUP
-#line 54 "vm_var_parser.l"
-{ yylval_param->val_str = mem_collector_strdup(mc,yytext); return RSTRING;}
- YY_BREAK
-/* ------------------------------------------------------------------------- */
-/* Parse variables in the form: */
-/* $VARIABLE */
-/* $VARIABLE[ATTR] */
-/* $VARIABLE[ATTR,ATTR=VALUE] */
-/* $NUM.CONTEXT_VARIABLE */
-/* ------------------------------------------------------------------------- */
-case 2:
-YY_RULE_SETUP
-#line 64 "vm_var_parser.l"
-{ BEGIN VAR;}
- YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 66 "vm_var_parser.l"
-{ BEGIN VALUE; return EQUAL; }
- YY_BREAK
-case 4:
-YY_RULE_SETUP
-#line 67 "vm_var_parser.l"
-{ return COMMA;}
- YY_BREAK
-case 5:
-YY_RULE_SETUP
-#line 68 "vm_var_parser.l"
-{ return OBRACKET;}
- YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 69 "vm_var_parser.l"
-{ return CBRACKET;}
- YY_BREAK
-case 7:
-YY_RULE_SETUP
-#line 71 "vm_var_parser.l"
-{ yylval_param->val_str =
- mem_collector_strdup(mc,yytext);
- return VARIABLE;}
- YY_BREAK
-case 8:
-/* rule 8 can match eol */
-YY_RULE_SETUP
-#line 75 "vm_var_parser.l"
-{ yylval_param->val_str =
- mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- BEGIN(VAR);
- return STRING;}
- YY_BREAK
-case 9:
-YY_RULE_SETUP
-#line 81 "vm_var_parser.l"
-{ yylval_param->val_str =
- mem_collector_strdup(mc,yytext);
- BEGIN(VAR);
- return STRING;}
- YY_BREAK
-case 10:
-YY_RULE_SETUP
-#line 86 "vm_var_parser.l"
-{ yylval_param->val_char = '\0';
- return EOA;}
- YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 89 "vm_var_parser.l"
-{ yylval_param->val_char = *yytext;
- BEGIN(INITIAL);
- return EOA;}
- YY_BREAK
-case YY_STATE_EOF(VAR):
-#line 93 "vm_var_parser.l"
-{ yylval_param->val_char = '\0';
- BEGIN(INITIAL);
- return EOA;}
- YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 96 "vm_var_parser.l"
-ECHO;
- YY_BREAK
-#line 1161 "vm_var_parser.cc"
-case YY_STATE_EOF(INITIAL):
-case YY_STATE_EOF(VALUE):
- yyterminate();
-
- case YY_END_OF_BUFFER:
- {
- /* Amount of text matched not including the EOB char. */
- int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
-
- /* Undo the effects of YY_DO_BEFORE_ACTION. */
- *yy_cp = yyg->yy_hold_char;
- YY_RESTORE_YY_MORE_OFFSET
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
- {
- /* We're scanning a new file or input source. It's
- * possible that this happened because the user
- * just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
- * consistency between YY_CURRENT_BUFFER and our
- * globals. Here is the right place to do so, because
- * this is the first action (other than possibly a
- * back-up) that will match for the new input source.
- */
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
- }
-
- /* Note that here we test for yy_c_buf_p "<=" to the position
- * of the first EOB in the buffer, since yy_c_buf_p will
- * already have been incremented past the NUL character
- * (since all states make transitions on EOB to the
- * end-of-buffer state). Contrast this with the test
- * in input().
- */
- if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- { /* This was really a NUL. */
- yy_state_type yy_next_state;
-
- yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- /* Okay, we're now positioned to make the NUL
- * transition. We couldn't have
- * yy_get_previous_state() go ahead and do it
- * for us because it doesn't know how to deal
- * with the possibility of jamming (and we don't
- * want to build jamming into it because then it
- * will run more slowly).
- */
-
- yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
-
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
-
- if ( yy_next_state )
- {
- /* Consume the NUL. */
- yy_cp = ++yyg->yy_c_buf_p;
- yy_current_state = yy_next_state;
- goto yy_match;
- }
-
- else
- {
- yy_cp = yyg->yy_c_buf_p;
- goto yy_find_action;
- }
- }
-
- else switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_END_OF_FILE:
- {
- yyg->yy_did_buffer_switch_on_eof = 0;
-
- if ( yywrap( yyscanner ) )
- {
- /* Note: because we've taken care in
- * yy_get_next_buffer() to have set up
- * yytext, we can now set up
- * yy_c_buf_p so that if some total
- * hoser (like flex itself) wants to
- * call the scanner after we return the
- * YY_NULL, it'll still work - another
- * YY_NULL will get returned.
- */
- yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
-
- yy_act = YY_STATE_EOF(YY_START);
- goto do_action;
- }
-
- else
- {
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
- }
- break;
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p =
- yyg->yytext_ptr + yy_amount_of_matched_text;
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_match;
-
- case EOB_ACT_LAST_MATCH:
- yyg->yy_c_buf_p =
- &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
-
- yy_current_state = yy_get_previous_state( yyscanner );
-
- yy_cp = yyg->yy_c_buf_p;
- yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
- goto yy_find_action;
- }
- break;
- }
-
- default:
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--no action found" );
- } /* end of action switch */
- } /* end of scanning one token */
- } /* end of user's declarations */
-} /* end of yylex */
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- * EOB_ACT_LAST_MATCH -
- * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- * EOB_ACT_END_OF_FILE - end of file
- */
-static int yy_get_next_buffer (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
- char *source = yyg->yytext_ptr;
- int number_to_move, i;
- int ret_val;
-
- if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
- YY_FATAL_ERROR(
- "fatal flex scanner internal error--end of buffer missed" );
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
- { /* Don't try to fill the buffer, so this is an EOF. */
- if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
- {
- /* We matched a single character, the EOB, so
- * treat this as a final EOF.
- */
- return EOB_ACT_END_OF_FILE;
- }
-
- else
- {
- /* We matched some text prior to the EOB, first
- * process it.
- */
- return EOB_ACT_LAST_MATCH;
- }
- }
-
- /* Try to read more data. */
-
- /* First move last chars to start of buffer. */
- number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
-
- for ( i = 0; i < number_to_move; ++i )
- *(dest++) = *(source++);
-
- if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
- /* don't do the read, it's not guaranteed to return an EOF,
- * just force an EOF
- */
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
-
- else
- {
- int num_to_read =
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
-
- while ( num_to_read <= 0 )
- { /* Not enough room in the buffer - grow it. */
-
- /* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
-
- int yy_c_buf_p_offset =
- (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
-
- if ( b->yy_is_our_buffer )
- {
- int new_size = b->yy_buf_size * 2;
-
- if ( new_size <= 0 )
- b->yy_buf_size += b->yy_buf_size / 8;
- else
- b->yy_buf_size *= 2;
-
- b->yy_ch_buf = (char *)
- /* Include room in for 2 EOB chars. */
- yyrealloc( (void *) b->yy_ch_buf,
- (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- }
- else
- /* Can't grow it, we don't own it. */
- b->yy_ch_buf = NULL;
-
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR(
- "fatal error - scanner input buffer overflow" );
-
- yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
- num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
- number_to_move - 1;
-
- }
-
- if ( num_to_read > YY_READ_BUF_SIZE )
- num_to_read = YY_READ_BUF_SIZE;
-
- /* Read in more data. */
- YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
- yyg->yy_n_chars, num_to_read );
-
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- if ( yyg->yy_n_chars == 0 )
- {
- if ( number_to_move == YY_MORE_ADJ )
- {
- ret_val = EOB_ACT_END_OF_FILE;
- yyrestart( yyin , yyscanner);
- }
-
- else
- {
- ret_val = EOB_ACT_LAST_MATCH;
- YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
- YY_BUFFER_EOF_PENDING;
- }
- }
-
- else
- ret_val = EOB_ACT_CONTINUE_SCAN;
-
- if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
- /* Extend the array by 50%, plus the number we really need. */
- int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
- (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner );
- if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
- /* "- 2" to take care of EOB's */
- YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
- }
-
- yyg->yy_n_chars += number_to_move;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
- yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
-
- return ret_val;
-}
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
- static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
-{
- yy_state_type yy_current_state;
- char *yy_cp;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_current_state = yyg->yy_start;
-
- for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
- {
- YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 36 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- }
-
- return yy_current_state;
-}
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- * next_state = yy_try_NUL_trans( current_state );
- */
- static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
-{
- int yy_is_jam;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
- char *yy_cp = yyg->yy_c_buf_p;
-
- YY_CHAR yy_c = 1;
- if ( yy_accept[yy_current_state] )
- {
- yyg->yy_last_accepting_state = yy_current_state;
- yyg->yy_last_accepting_cpos = yy_cp;
- }
- while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- {
- yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 36 )
- yy_c = yy_meta[yy_c];
- }
- yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- yy_is_jam = (yy_current_state == 35);
-
- (void)yyg;
- return yy_is_jam ? 0 : yy_current_state;
-}
-
-#ifndef YY_NO_UNPUT
-
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
- static int yyinput (yyscan_t yyscanner)
-#else
- static int input (yyscan_t yyscanner)
-#endif
-
-{
- int c;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
-
- if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- {
- /* yy_c_buf_p now points to the character we want to return.
- * If this occurs *before* the EOB characters, then it's a
- * valid NUL; if not, then we've hit the end of the buffer.
- */
- if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
- /* This was really a NUL. */
- *yyg->yy_c_buf_p = '\0';
-
- else
- { /* need more input */
- int offset = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr);
- ++yyg->yy_c_buf_p;
-
- switch ( yy_get_next_buffer( yyscanner ) )
- {
- case EOB_ACT_LAST_MATCH:
- /* This happens because yy_g_n_b()
- * sees that we've accumulated a
- * token and flags that we need to
- * try matching the token before
- * proceeding. But for input(),
- * there's no matching to consider.
- * So convert the EOB_ACT_LAST_MATCH
- * to EOB_ACT_END_OF_FILE.
- */
-
- /* Reset buffer status. */
- yyrestart( yyin , yyscanner);
-
- /*FALLTHROUGH*/
-
- case EOB_ACT_END_OF_FILE:
- {
- if ( yywrap( yyscanner ) )
- return 0;
-
- if ( ! yyg->yy_did_buffer_switch_on_eof )
- YY_NEW_FILE;
-#ifdef __cplusplus
- return yyinput(yyscanner);
-#else
- return input(yyscanner);
-#endif
- }
-
- case EOB_ACT_CONTINUE_SCAN:
- yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
- break;
- }
- }
- }
-
- c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
- *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
- yyg->yy_hold_char = *++yyg->yy_c_buf_p;
-
- if ( c == '\n' )
-
- do{ yylineno++;
- yycolumn=0;
- }while(0)
-;
-
- return c;
-}
-#endif /* ifndef YY_NO_INPUT */
-
-/** Immediately switch to a different input stream.
- * @param input_file A readable stream.
- * @param yyscanner The scanner object.
- * @note This function does not reset the start condition to @c INITIAL .
- */
- void yyrestart (FILE * input_file , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! YY_CURRENT_BUFFER ){
- yyensure_buffer_stack (yyscanner);
- YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
- }
-
- yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
- yy_load_buffer_state( yyscanner );
-}
-
-/** Switch to a different input buffer.
- * @param new_buffer The new input buffer.
- * @param yyscanner The scanner object.
- */
- void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* TODO. We should be able to replace this entire function body
- * with
- * yypop_buffer_state();
- * yypush_buffer_state(new_buffer);
- */
- yyensure_buffer_stack (yyscanner);
- if ( YY_CURRENT_BUFFER == new_buffer )
- return;
-
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
- yy_load_buffer_state( yyscanner );
-
- /* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
- * to go ahead and always set it.
- */
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-static void yy_load_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
- yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
- yyg->yy_hold_char = *yyg->yy_c_buf_p;
-}
-
-/** Allocate and initialize an input buffer state.
- * @param file A readable stream.
- * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
- * @param yyscanner The scanner object.
- * @return the allocated buffer state.
- */
- YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_buf_size = size;
-
- /* yy_ch_buf has to be 2 characters longer than the size given because
- * we need to put in 2 end-of-buffer characters.
- */
- b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
- if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
- b->yy_is_our_buffer = 1;
-
- yy_init_buffer( b, file , yyscanner);
-
- return b;
-}
-
-/** Destroy the buffer.
- * @param b a buffer created with yy_create_buffer()
- * @param yyscanner The scanner object.
- */
- void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if ( ! b )
- return;
-
- if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
- YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
-
- if ( b->yy_is_our_buffer )
- yyfree( (void *) b->yy_ch_buf , yyscanner );
-
- yyfree( (void *) b , yyscanner );
-}
-
-/* Initializes or reinitializes a buffer.
- * This function is sometimes called more than once on the same buffer,
- * such as during a yyrestart() or at EOF.
- */
- static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
-
-{
- int oerrno = errno;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- yy_flush_buffer( b , yyscanner);
-
- b->yy_input_file = file;
- b->yy_fill_buffer = 1;
-
- /* If b is the current buffer, then yy_init_buffer was _probably_
- * called from yyrestart() or through yy_get_next_buffer.
- * In that case, we don't want to reset the lineno or column.
- */
- if (b != YY_CURRENT_BUFFER){
- b->yy_bs_lineno = 1;
- b->yy_bs_column = 0;
- }
-
- b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-
- errno = oerrno;
-}
-
-/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
- * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
- * @param yyscanner The scanner object.
- */
- void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if ( ! b )
- return;
-
- b->yy_n_chars = 0;
-
- /* We always need two end-of-buffer characters. The first causes
- * a transition to the end-of-buffer state. The second causes
- * a jam in that state.
- */
- b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
- b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
- b->yy_buf_pos = &b->yy_ch_buf[0];
-
- b->yy_at_bol = 1;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- if ( b == YY_CURRENT_BUFFER )
- yy_load_buffer_state( yyscanner );
-}
-
-/** Pushes the new state onto the stack. The new state becomes
- * the current state. This function will allocate the stack
- * if necessary.
- * @param new_buffer The new state.
- * @param yyscanner The scanner object.
- */
-void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (new_buffer == NULL)
- return;
-
- yyensure_buffer_stack(yyscanner);
-
- /* This block is copied from yy_switch_to_buffer. */
- if ( YY_CURRENT_BUFFER )
- {
- /* Flush out information for old buffer. */
- *yyg->yy_c_buf_p = yyg->yy_hold_char;
- YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
- YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
- }
-
- /* Only push if top exists. Otherwise, replace top. */
- if (YY_CURRENT_BUFFER)
- yyg->yy_buffer_stack_top++;
- YY_CURRENT_BUFFER_LVALUE = new_buffer;
-
- /* copied from yy_switch_to_buffer. */
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
-}
-
-/** Removes and deletes the top of the stack, if present.
- * The next element becomes the new top.
- * @param yyscanner The scanner object.
- */
-void yypop_buffer_state (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- if (!YY_CURRENT_BUFFER)
- return;
-
- yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
- YY_CURRENT_BUFFER_LVALUE = NULL;
- if (yyg->yy_buffer_stack_top > 0)
- --yyg->yy_buffer_stack_top;
-
- if (YY_CURRENT_BUFFER) {
- yy_load_buffer_state( yyscanner );
- yyg->yy_did_buffer_switch_on_eof = 1;
- }
-}
-
-/* Allocates the stack if it does not exist.
- * Guarantees space for at least one push.
- */
-static void yyensure_buffer_stack (yyscan_t yyscanner)
-{
- yy_size_t num_to_alloc;
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (!yyg->yy_buffer_stack) {
-
- /* First allocation is just for 2 elements, since we don't know if this
- * scanner will even need a stack. We use 2 instead of 1 to avoid an
- * immediate realloc on the next call.
- */
- num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
- (num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
-
- yyg->yy_buffer_stack_max = num_to_alloc;
- yyg->yy_buffer_stack_top = 0;
- return;
- }
-
- if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
-
- /* Increase the buffer to prepare for a possible push. */
- yy_size_t grow_size = 8 /* arbitrary grow size */;
-
- num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
- (yyg->yy_buffer_stack,
- num_to_alloc * sizeof(struct yy_buffer_state*)
- , yyscanner);
- if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
-
- /* zero only the new slots.*/
- memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
- yyg->yy_buffer_stack_max = num_to_alloc;
- }
-}
-
-/** Setup the input buffer state to scan directly from a user-specified character buffer.
- * @param base the character buffer
- * @param size the size in bytes of the character buffer
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
-
- if ( size < 2 ||
- base[size-2] != YY_END_OF_BUFFER_CHAR ||
- base[size-1] != YY_END_OF_BUFFER_CHAR )
- /* They forgot to leave room for the EOB's. */
- return NULL;
-
- b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
- if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
- b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
- b->yy_buf_pos = b->yy_ch_buf = base;
- b->yy_is_our_buffer = 0;
- b->yy_input_file = NULL;
- b->yy_n_chars = b->yy_buf_size;
- b->yy_is_interactive = 0;
- b->yy_at_bol = 1;
- b->yy_fill_buffer = 0;
- b->yy_buffer_status = YY_BUFFER_NEW;
-
- yy_switch_to_buffer( b , yyscanner );
-
- return b;
-}
-
-/** Setup the input buffer state to scan a string. The next call to yylex() will
- * scan from a @e copy of @a str.
- * @param yystr a NUL-terminated string to scan
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- * @note If you want to scan bytes that may contain NUL values, then use
- * yy_scan_bytes() instead.
- */
-YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner)
-{
-
- return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner);
-}
-
-/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
- * scan from a @e copy of @a bytes.
- * @param yybytes the byte buffer to scan
- * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
- * @param yyscanner The scanner object.
- * @return the newly allocated buffer state object.
- */
-YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len , yyscan_t yyscanner)
-{
- YY_BUFFER_STATE b;
- char *buf;
- yy_size_t n;
- int i;
-
- /* Get memory for full buffer, including space for trailing EOB's. */
- n = (yy_size_t) (_yybytes_len + 2);
- buf = (char *) yyalloc( n , yyscanner );
- if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
- for ( i = 0; i < _yybytes_len; ++i )
- buf[i] = yybytes[i];
-
- buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
-
- b = yy_scan_buffer( buf, n , yyscanner);
- if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
- /* It's okay to grow etc. this buffer, and we should throw it
- * away when we're done.
- */
- b->yy_is_our_buffer = 1;
-
- return b;
-}
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-static void yynoreturn yy_fatal_error (const char* msg , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- fprintf( stderr, "%s\n", msg );
- exit( YY_EXIT_FAILURE );
-}
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
- do \
- { \
- /* Undo effects of setting up yytext. */ \
- int yyless_macro_arg = (n); \
- YY_LESS_LINENO(yyless_macro_arg);\
- yytext[yyleng] = yyg->yy_hold_char; \
- yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
- yyg->yy_hold_char = *yyg->yy_c_buf_p; \
- *yyg->yy_c_buf_p = '\0'; \
- yyleng = yyless_macro_arg; \
- } \
- while ( 0 )
-
-/* Accessor methods (get/set functions) to struct members. */
-
-/** Get the user-defined data for this scanner.
- * @param yyscanner The scanner object.
- */
-YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyextra;
-}
-
-/** Get the current line number.
- * @param yyscanner The scanner object.
- */
-int yyget_lineno (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yylineno;
-}
-
-/** Get the current column number.
- * @param yyscanner The scanner object.
- */
-int yyget_column (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- if (! YY_CURRENT_BUFFER)
- return 0;
-
- return yycolumn;
-}
-
-/** Get the input stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_in (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyin;
-}
-
-/** Get the output stream.
- * @param yyscanner The scanner object.
- */
-FILE *yyget_out (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyout;
-}
-
-/** Get the length of the current token.
- * @param yyscanner The scanner object.
- */
-int yyget_leng (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yyleng;
-}
-
-/** Get the current token.
- * @param yyscanner The scanner object.
- */
-
-char *yyget_text (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yytext;
-}
-
-/** Set the user-defined data. This data is never touched by the scanner.
- * @param user_defined The data to be associated with this scanner.
- * @param yyscanner The scanner object.
- */
-void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyextra = user_defined ;
-}
-
-/** Set the current line number.
- * @param _line_number line number
- * @param yyscanner The scanner object.
- */
-void yyset_lineno (int _line_number , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* lineno is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_lineno called with no buffer" );
-
- yylineno = _line_number;
-}
-
-/** Set the current column.
- * @param _column_no column number
- * @param yyscanner The scanner object.
- */
-void yyset_column (int _column_no , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* column is only valid if an input buffer exists. */
- if (! YY_CURRENT_BUFFER )
- YY_FATAL_ERROR( "yyset_column called with no buffer" );
-
- yycolumn = _column_no;
-}
-
-/** Set the input stream. This does not discard the current
- * input buffer.
- * @param _in_str A readable stream.
- * @param yyscanner The scanner object.
- * @see yy_switch_to_buffer
- */
-void yyset_in (FILE * _in_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyin = _in_str ;
-}
-
-void yyset_out (FILE * _out_str , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yyout = _out_str ;
-}
-
-int yyget_debug (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yy_flex_debug;
-}
-
-void yyset_debug (int _bdebug , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yy_flex_debug = _bdebug ;
-}
-
-/* Accessor methods for yylval and yylloc */
-
-YYSTYPE * yyget_lval (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- return yylval;
-}
-
-void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yylval = yylval_param;
-}
-
-/* User-visible API */
-
-/* yylex_init is special because it creates the scanner itself, so it is
- * the ONLY reentrant function that doesn't take the scanner as the last argument.
- * That's why we explicitly handle the declaration, instead of using our macros.
- */
-int yylex_init(yyscan_t* ptr_yy_globals)
-{
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-/* yylex_init_extra has the same functionality as yylex_init, but follows the
- * convention of taking the scanner as the last argument. Note however, that
- * this is a *pointer* to a scanner, as it will be allocated by this call (and
- * is the reason, too, why this function also must handle its own declaration).
- * The user defined value in the first argument will be available to yyalloc in
- * the yyextra field.
- */
-int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
-{
- struct yyguts_t dummy_yyguts;
-
- yyset_extra (yy_user_defined, &dummy_yyguts);
-
- if (ptr_yy_globals == NULL){
- errno = EINVAL;
- return 1;
- }
-
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
-
- if (*ptr_yy_globals == NULL){
- errno = ENOMEM;
- return 1;
- }
-
- /* By setting to 0xAA, we expose bugs in
- yy_init_globals. Leave at 0x00 for releases. */
- memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
-
- yyset_extra (yy_user_defined, *ptr_yy_globals);
-
- return yy_init_globals ( *ptr_yy_globals );
-}
-
-static int yy_init_globals (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- /* Initialization is the same as for the non-reentrant scanner.
- * This function is called from yylex_destroy(), so don't allocate here.
- */
-
- yyg->yy_buffer_stack = NULL;
- yyg->yy_buffer_stack_top = 0;
- yyg->yy_buffer_stack_max = 0;
- yyg->yy_c_buf_p = NULL;
- yyg->yy_init = 0;
- yyg->yy_start = 0;
-
- yyg->yy_start_stack_ptr = 0;
- yyg->yy_start_stack_depth = 0;
- yyg->yy_start_stack = NULL;
-
-/* Defined in main.c */
-#ifdef YY_STDINIT
- yyin = stdin;
- yyout = stdout;
-#else
- yyin = NULL;
- yyout = NULL;
-#endif
-
- /* For future reference: Set errno on error, since we are called by
- * yylex_init()
- */
- return 0;
-}
-
-/* yylex_destroy is for both reentrant and non-reentrant scanners. */
-int yylex_destroy (yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-
- /* Pop the buffer stack, destroying each element. */
- while(YY_CURRENT_BUFFER){
- yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
- YY_CURRENT_BUFFER_LVALUE = NULL;
- yypop_buffer_state(yyscanner);
- }
-
- /* Destroy the stack itself. */
- yyfree(yyg->yy_buffer_stack , yyscanner);
- yyg->yy_buffer_stack = NULL;
-
- /* Destroy the start condition stack. */
- yyfree( yyg->yy_start_stack , yyscanner );
- yyg->yy_start_stack = NULL;
-
- /* Reset the globals. This is important in a non-reentrant scanner so the next time
- * yylex() is called, initialization will occur. */
- yy_init_globals( yyscanner);
-
- /* Destroy the main struct (reentrant only). */
- yyfree ( yyscanner , yyscanner );
- yyscanner = NULL;
- return 0;
-}
-
-/*
- * Internal utility routines.
- */
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- int i;
- for ( i = 0; i < n; ++i )
- s1[i] = s2[i];
-}
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen (const char * s , yyscan_t yyscanner)
-{
- int n;
- for ( n = 0; s[n]; ++n )
- ;
-
- return n;
-}
-#endif
-
-void *yyalloc (yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- return malloc(size);
-}
-
-void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
-
- /* The cast to (char *) in the following accommodates both
- * implementations that use char* generic pointers, and those
- * that use void* generic pointers. It works with the latter
- * because both ANSI C and C++ allow castless assignment from
- * any pointer type to void*, and deal with argument conversions
- * as though doing an assignment.
- */
- return realloc(ptr, size);
-}
-
-void yyfree (void * ptr , yyscan_t yyscanner)
-{
- struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- (void)yyg;
- free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
-}
-
-#define YYTABLES_NAME "yytables"
-
-#line 96 "vm_var_parser.l"
-
-
-int vm_var_wrap(yyscan_t scanner)
-{
- return 1;
-}
-
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.h
deleted file mode 100644
index a2b85a7..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.h
+++ /dev/null
@@ -1,719 +0,0 @@
-#ifndef vm_var_HEADER_H
-#define vm_var_HEADER_H 1
-#define vm_var_IN_HEADER 1
-
-#line 5 "vm_var_parser.h"
-
-#line 7 "vm_var_parser.h"
-
-#define YY_INT_ALIGNED short int
-
-/* A lexical scanner generated by flex */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 4
-#if YY_FLEX_SUBMINOR_VERSION > 0
-#define FLEX_BETA
-#endif
-
-#ifdef yy_create_buffer
-#define vm_var__create_buffer_ALREADY_DEFINED
-#else
-#define yy_create_buffer vm_var__create_buffer
-#endif
-
-#ifdef yy_delete_buffer
-#define vm_var__delete_buffer_ALREADY_DEFINED
-#else
-#define yy_delete_buffer vm_var__delete_buffer
-#endif
-
-#ifdef yy_scan_buffer
-#define vm_var__scan_buffer_ALREADY_DEFINED
-#else
-#define yy_scan_buffer vm_var__scan_buffer
-#endif
-
-#ifdef yy_scan_string
-#define vm_var__scan_string_ALREADY_DEFINED
-#else
-#define yy_scan_string vm_var__scan_string
-#endif
-
-#ifdef yy_scan_bytes
-#define vm_var__scan_bytes_ALREADY_DEFINED
-#else
-#define yy_scan_bytes vm_var__scan_bytes
-#endif
-
-#ifdef yy_init_buffer
-#define vm_var__init_buffer_ALREADY_DEFINED
-#else
-#define yy_init_buffer vm_var__init_buffer
-#endif
-
-#ifdef yy_flush_buffer
-#define vm_var__flush_buffer_ALREADY_DEFINED
-#else
-#define yy_flush_buffer vm_var__flush_buffer
-#endif
-
-#ifdef yy_load_buffer_state
-#define vm_var__load_buffer_state_ALREADY_DEFINED
-#else
-#define yy_load_buffer_state vm_var__load_buffer_state
-#endif
-
-#ifdef yy_switch_to_buffer
-#define vm_var__switch_to_buffer_ALREADY_DEFINED
-#else
-#define yy_switch_to_buffer vm_var__switch_to_buffer
-#endif
-
-#ifdef yypush_buffer_state
-#define vm_var_push_buffer_state_ALREADY_DEFINED
-#else
-#define yypush_buffer_state vm_var_push_buffer_state
-#endif
-
-#ifdef yypop_buffer_state
-#define vm_var_pop_buffer_state_ALREADY_DEFINED
-#else
-#define yypop_buffer_state vm_var_pop_buffer_state
-#endif
-
-#ifdef yyensure_buffer_stack
-#define vm_var_ensure_buffer_stack_ALREADY_DEFINED
-#else
-#define yyensure_buffer_stack vm_var_ensure_buffer_stack
-#endif
-
-#ifdef yylex
-#define vm_var_lex_ALREADY_DEFINED
-#else
-#define yylex vm_var_lex
-#endif
-
-#ifdef yyrestart
-#define vm_var_restart_ALREADY_DEFINED
-#else
-#define yyrestart vm_var_restart
-#endif
-
-#ifdef yylex_init
-#define vm_var_lex_init_ALREADY_DEFINED
-#else
-#define yylex_init vm_var_lex_init
-#endif
-
-#ifdef yylex_init_extra
-#define vm_var_lex_init_extra_ALREADY_DEFINED
-#else
-#define yylex_init_extra vm_var_lex_init_extra
-#endif
-
-#ifdef yylex_destroy
-#define vm_var_lex_destroy_ALREADY_DEFINED
-#else
-#define yylex_destroy vm_var_lex_destroy
-#endif
-
-#ifdef yyget_debug
-#define vm_var_get_debug_ALREADY_DEFINED
-#else
-#define yyget_debug vm_var_get_debug
-#endif
-
-#ifdef yyset_debug
-#define vm_var_set_debug_ALREADY_DEFINED
-#else
-#define yyset_debug vm_var_set_debug
-#endif
-
-#ifdef yyget_extra
-#define vm_var_get_extra_ALREADY_DEFINED
-#else
-#define yyget_extra vm_var_get_extra
-#endif
-
-#ifdef yyset_extra
-#define vm_var_set_extra_ALREADY_DEFINED
-#else
-#define yyset_extra vm_var_set_extra
-#endif
-
-#ifdef yyget_in
-#define vm_var_get_in_ALREADY_DEFINED
-#else
-#define yyget_in vm_var_get_in
-#endif
-
-#ifdef yyset_in
-#define vm_var_set_in_ALREADY_DEFINED
-#else
-#define yyset_in vm_var_set_in
-#endif
-
-#ifdef yyget_out
-#define vm_var_get_out_ALREADY_DEFINED
-#else
-#define yyget_out vm_var_get_out
-#endif
-
-#ifdef yyset_out
-#define vm_var_set_out_ALREADY_DEFINED
-#else
-#define yyset_out vm_var_set_out
-#endif
-
-#ifdef yyget_leng
-#define vm_var_get_leng_ALREADY_DEFINED
-#else
-#define yyget_leng vm_var_get_leng
-#endif
-
-#ifdef yyget_text
-#define vm_var_get_text_ALREADY_DEFINED
-#else
-#define yyget_text vm_var_get_text
-#endif
-
-#ifdef yyget_lineno
-#define vm_var_get_lineno_ALREADY_DEFINED
-#else
-#define yyget_lineno vm_var_get_lineno
-#endif
-
-#ifdef yyset_lineno
-#define vm_var_set_lineno_ALREADY_DEFINED
-#else
-#define yyset_lineno vm_var_set_lineno
-#endif
-
-#ifdef yyget_column
-#define vm_var_get_column_ALREADY_DEFINED
-#else
-#define yyget_column vm_var_get_column
-#endif
-
-#ifdef yyset_column
-#define vm_var_set_column_ALREADY_DEFINED
-#else
-#define yyset_column vm_var_set_column
-#endif
-
-#ifdef yywrap
-#define vm_var_wrap_ALREADY_DEFINED
-#else
-#define yywrap vm_var_wrap
-#endif
-
-#ifdef yyget_lval
-#define vm_var_get_lval_ALREADY_DEFINED
-#else
-#define yyget_lval vm_var_get_lval
-#endif
-
-#ifdef yyset_lval
-#define vm_var_set_lval_ALREADY_DEFINED
-#else
-#define yyset_lval vm_var_set_lval
-#endif
-
-#ifdef yyalloc
-#define vm_var_alloc_ALREADY_DEFINED
-#else
-#define yyalloc vm_var_alloc
-#endif
-
-#ifdef yyrealloc
-#define vm_var_realloc_ALREADY_DEFINED
-#else
-#define yyrealloc vm_var_realloc
-#endif
-
-#ifdef yyfree
-#define vm_var_free_ALREADY_DEFINED
-#else
-#define yyfree vm_var_free
-#endif
-
-/* First, we deal with platform-specific or compiler-specific issues. */
-
-/* begin standard C headers. */
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
-
-/* end standard C headers. */
-
-/* flex integer type definitions */
-
-#ifndef FLEXINT_H
-#define FLEXINT_H
-
-/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
-
-#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-
-/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
- * if you want the limit (max/min) macros for int types.
- */
-#ifndef __STDC_LIMIT_MACROS
-#define __STDC_LIMIT_MACROS 1
-#endif
-
-#include <inttypes.h>
-typedef int8_t flex_int8_t;
-typedef uint8_t flex_uint8_t;
-typedef int16_t flex_int16_t;
-typedef uint16_t flex_uint16_t;
-typedef int32_t flex_int32_t;
-typedef uint32_t flex_uint32_t;
-#else
-typedef signed char flex_int8_t;
-typedef short int flex_int16_t;
-typedef int flex_int32_t;
-typedef unsigned char flex_uint8_t;
-typedef unsigned short int flex_uint16_t;
-typedef unsigned int flex_uint32_t;
-
-/* Limits of integral types. */
-#ifndef INT8_MIN
-#define INT8_MIN (-128)
-#endif
-#ifndef INT16_MIN
-#define INT16_MIN (-32767-1)
-#endif
-#ifndef INT32_MIN
-#define INT32_MIN (-2147483647-1)
-#endif
-#ifndef INT8_MAX
-#define INT8_MAX (127)
-#endif
-#ifndef INT16_MAX
-#define INT16_MAX (32767)
-#endif
-#ifndef INT32_MAX
-#define INT32_MAX (2147483647)
-#endif
-#ifndef UINT8_MAX
-#define UINT8_MAX (255U)
-#endif
-#ifndef UINT16_MAX
-#define UINT16_MAX (65535U)
-#endif
-#ifndef UINT32_MAX
-#define UINT32_MAX (4294967295U)
-#endif
-
-#ifndef SIZE_MAX
-#define SIZE_MAX (~(size_t)0)
-#endif
-
-#endif /* ! C99 */
-
-#endif /* ! FLEXINT_H */
-
-/* begin standard C++ headers. */
-
-/* TODO: this is always defined, so inline it */
-#define yyconst const
-
-#if defined(__GNUC__) && __GNUC__ >= 3
-#define yynoreturn __attribute__((__noreturn__))
-#else
-#define yynoreturn
-#endif
-
-/* An opaque pointer. */
-#ifndef YY_TYPEDEF_YY_SCANNER_T
-#define YY_TYPEDEF_YY_SCANNER_T
-typedef void* yyscan_t;
-#endif
-
-/* For convenience, these vars (plus the bison vars far below)
- are macros in the reentrant scanner. */
-#define yyin yyg->yyin_r
-#define yyout yyg->yyout_r
-#define yyextra yyg->yyextra_r
-#define yyleng yyg->yyleng_r
-#define yytext yyg->yytext_r
-#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
-#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
-#define yy_flex_debug yyg->yy_flex_debug_r
-
-/* Size of default input buffer. */
-#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
-#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
-#endif
-
-#ifndef YY_TYPEDEF_YY_BUFFER_STATE
-#define YY_TYPEDEF_YY_BUFFER_STATE
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-#endif
-
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
-#ifndef YY_STRUCT_YY_BUFFER_STATE
-#define YY_STRUCT_YY_BUFFER_STATE
-struct yy_buffer_state
- {
- FILE *yy_input_file;
-
- char *yy_ch_buf; /* input buffer */
- char *yy_buf_pos; /* current position in input buffer */
-
- /* Size of input buffer in bytes, not including room for EOB
- * characters.
- */
- int yy_buf_size;
-
- /* Number of characters read into yy_ch_buf, not including EOB
- * characters.
- */
- int yy_n_chars;
-
- /* Whether we "own" the buffer - i.e., we know we created it,
- * and can realloc() it to grow it, and should free() it to
- * delete it.
- */
- int yy_is_our_buffer;
-
- /* Whether this is an "interactive" input source; if so, and
- * if we're using stdio for input, then we want to use getc()
- * instead of fread(), to make sure we stop fetching input after
- * each newline.
- */
- int yy_is_interactive;
-
- /* Whether we're considered to be at the beginning of a line.
- * If so, '^' rules will be active on the next match, otherwise
- * not.
- */
- int yy_at_bol;
-
- int yy_bs_lineno; /**< The line count. */
- int yy_bs_column; /**< The column count. */
-
- /* Whether to try to fill the input buffer when we reach the
- * end of it.
- */
- int yy_fill_buffer;
-
- int yy_buffer_status;
-
- };
-#endif /* !YY_STRUCT_YY_BUFFER_STATE */
-
-void yyrestart ( FILE *input_file , yyscan_t yyscanner );
-void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
-void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
-void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
-void yypop_buffer_state ( yyscan_t yyscanner );
-
-YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
-
-void *yyalloc ( yy_size_t , yyscan_t yyscanner );
-void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
-void yyfree ( void * , yyscan_t yyscanner );
-
-/* Begin user sect3 */
-
-#define yytext_ptr yytext_r
-
-#ifdef YY_HEADER_EXPORT_START_CONDITIONS
-#define INITIAL 0
-#define VAR 1
-#define VALUE 2
-
-#endif
-
-#ifndef YY_NO_UNISTD_H
-/* Special case for "unistd.h", since it is non-ANSI. We include it way
- * down here because we want the user's section 1 to have been scanned first.
- * The user has a chance to override it with an option.
- */
-#include <unistd.h>
-#endif
-
-#ifndef YY_EXTRA_TYPE
-#define YY_EXTRA_TYPE void *
-#endif
-
-int yylex_init (yyscan_t* scanner);
-
-int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
-
-/* Accessor methods to globals.
- These are made visible to non-reentrant scanners for convenience. */
-
-int yylex_destroy ( yyscan_t yyscanner );
-
-int yyget_debug ( yyscan_t yyscanner );
-
-void yyset_debug ( int debug_flag , yyscan_t yyscanner );
-
-YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
-
-void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
-
-FILE *yyget_in ( yyscan_t yyscanner );
-
-void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
-
-FILE *yyget_out ( yyscan_t yyscanner );
-
-void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
-
- int yyget_leng ( yyscan_t yyscanner );
-
-char *yyget_text ( yyscan_t yyscanner );
-
-int yyget_lineno ( yyscan_t yyscanner );
-
-void yyset_lineno ( int _line_number , yyscan_t yyscanner );
-
-int yyget_column ( yyscan_t yyscanner );
-
-void yyset_column ( int _column_no , yyscan_t yyscanner );
-
-YYSTYPE * yyget_lval ( yyscan_t yyscanner );
-
-void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap ( yyscan_t yyscanner );
-#else
-extern int yywrap ( yyscan_t yyscanner );
-#endif
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
-#endif
-
-#ifndef YY_NO_INPUT
-
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
-#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL_IS_OURS 1
-
-extern int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner);
-
-#define YY_DECL int yylex \
- (YYSTYPE * yylval_param , yyscan_t yyscanner)
-#endif /* !YY_DECL */
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-#undef YY_NEW_FILE
-#undef YY_FLUSH_BUFFER
-#undef yy_set_bol
-#undef yy_new_buffer
-#undef yy_set_interactive
-#undef YY_DO_BEFORE_ACTION
-
-#ifdef YY_DECL_IS_OURS
-#undef YY_DECL_IS_OURS
-#undef YY_DECL
-#endif
-
-#ifndef vm_var__create_buffer_ALREADY_DEFINED
-#undef yy_create_buffer
-#endif
-#ifndef vm_var__delete_buffer_ALREADY_DEFINED
-#undef yy_delete_buffer
-#endif
-#ifndef vm_var__scan_buffer_ALREADY_DEFINED
-#undef yy_scan_buffer
-#endif
-#ifndef vm_var__scan_string_ALREADY_DEFINED
-#undef yy_scan_string
-#endif
-#ifndef vm_var__scan_bytes_ALREADY_DEFINED
-#undef yy_scan_bytes
-#endif
-#ifndef vm_var__init_buffer_ALREADY_DEFINED
-#undef yy_init_buffer
-#endif
-#ifndef vm_var__flush_buffer_ALREADY_DEFINED
-#undef yy_flush_buffer
-#endif
-#ifndef vm_var__load_buffer_state_ALREADY_DEFINED
-#undef yy_load_buffer_state
-#endif
-#ifndef vm_var__switch_to_buffer_ALREADY_DEFINED
-#undef yy_switch_to_buffer
-#endif
-#ifndef vm_var_push_buffer_state_ALREADY_DEFINED
-#undef yypush_buffer_state
-#endif
-#ifndef vm_var_pop_buffer_state_ALREADY_DEFINED
-#undef yypop_buffer_state
-#endif
-#ifndef vm_var_ensure_buffer_stack_ALREADY_DEFINED
-#undef yyensure_buffer_stack
-#endif
-#ifndef vm_var_lex_ALREADY_DEFINED
-#undef yylex
-#endif
-#ifndef vm_var_restart_ALREADY_DEFINED
-#undef yyrestart
-#endif
-#ifndef vm_var_lex_init_ALREADY_DEFINED
-#undef yylex_init
-#endif
-#ifndef vm_var_lex_init_extra_ALREADY_DEFINED
-#undef yylex_init_extra
-#endif
-#ifndef vm_var_lex_destroy_ALREADY_DEFINED
-#undef yylex_destroy
-#endif
-#ifndef vm_var_get_debug_ALREADY_DEFINED
-#undef yyget_debug
-#endif
-#ifndef vm_var_set_debug_ALREADY_DEFINED
-#undef yyset_debug
-#endif
-#ifndef vm_var_get_extra_ALREADY_DEFINED
-#undef yyget_extra
-#endif
-#ifndef vm_var_set_extra_ALREADY_DEFINED
-#undef yyset_extra
-#endif
-#ifndef vm_var_get_in_ALREADY_DEFINED
-#undef yyget_in
-#endif
-#ifndef vm_var_set_in_ALREADY_DEFINED
-#undef yyset_in
-#endif
-#ifndef vm_var_get_out_ALREADY_DEFINED
-#undef yyget_out
-#endif
-#ifndef vm_var_set_out_ALREADY_DEFINED
-#undef yyset_out
-#endif
-#ifndef vm_var_get_leng_ALREADY_DEFINED
-#undef yyget_leng
-#endif
-#ifndef vm_var_get_text_ALREADY_DEFINED
-#undef yyget_text
-#endif
-#ifndef vm_var_get_lineno_ALREADY_DEFINED
-#undef yyget_lineno
-#endif
-#ifndef vm_var_set_lineno_ALREADY_DEFINED
-#undef yyset_lineno
-#endif
-#ifndef vm_var_get_column_ALREADY_DEFINED
-#undef yyget_column
-#endif
-#ifndef vm_var_set_column_ALREADY_DEFINED
-#undef yyset_column
-#endif
-#ifndef vm_var_wrap_ALREADY_DEFINED
-#undef yywrap
-#endif
-#ifndef vm_var_get_lval_ALREADY_DEFINED
-#undef yyget_lval
-#endif
-#ifndef vm_var_set_lval_ALREADY_DEFINED
-#undef yyset_lval
-#endif
-#ifndef vm_var_get_lloc_ALREADY_DEFINED
-#undef yyget_lloc
-#endif
-#ifndef vm_var_set_lloc_ALREADY_DEFINED
-#undef yyset_lloc
-#endif
-#ifndef vm_var_alloc_ALREADY_DEFINED
-#undef yyalloc
-#endif
-#ifndef vm_var_realloc_ALREADY_DEFINED
-#undef yyrealloc
-#endif
-#ifndef vm_var_free_ALREADY_DEFINED
-#undef yyfree
-#endif
-#ifndef vm_var_text_ALREADY_DEFINED
-#undef yytext
-#endif
-#ifndef vm_var_leng_ALREADY_DEFINED
-#undef yyleng
-#endif
-#ifndef vm_var_in_ALREADY_DEFINED
-#undef yyin
-#endif
-#ifndef vm_var_out_ALREADY_DEFINED
-#undef yyout
-#endif
-#ifndef vm_var__flex_debug_ALREADY_DEFINED
-#undef yy_flex_debug
-#endif
-#ifndef vm_var_lineno_ALREADY_DEFINED
-#undef yylineno
-#endif
-#ifndef vm_var_tables_fload_ALREADY_DEFINED
-#undef yytables_fload
-#endif
-#ifndef vm_var_tables_destroy_ALREADY_DEFINED
-#undef yytables_destroy
-#endif
-#ifndef vm_var_TABLES_NAME_ALREADY_DEFINED
-#undef yyTABLES_NAME
-#endif
-
-#line 96 "vm_var_parser.l"
-
-
-#line 717 "vm_var_parser.h"
-#undef vm_var_IN_HEADER
-#endif /* vm_var_HEADER_H */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.l b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.l
deleted file mode 100644
index ff93f64..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_parser.l
+++ /dev/null
@@ -1,100 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%{
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <pthread.h>
-
-#include "vm_var_syntax.h"
-#include "vm_file_var_syntax.h"
-#include "mem_collector.h"
-
-#define YY_NO_INPUT
-
-#define YY_DECL int vm_var_lex (YYSTYPE *yylval_param, YYLTYPE *llocp, \
- mem_collector *mc, yyscan_t yyscanner)
-
-#define YY_USER_ACTION llocp->first_line = yylineno; \
- llocp->first_column = llocp->last_column; \
- llocp->last_column += yyleng;
-%}
-
-%option nounput
-%option prefix="vm_var_"
-%option outfile="vm_var_parser.cc"
-%option header-file="vm_var_parser.h"
-%option yylineno
-%option bison-bridge
-%option reentrant
-
-%x VAR
-%x VALUE
-%%
-
- /* ------------------------------------------------------------------------- */
- /* Just copy the string verbatim till we find a variable (starts with $) */
- /* ------------------------------------------------------------------------- */
-
-([^\$\\]|"\\\$"|\\[^\$])+ { yylval_param->val_str = mem_collector_strdup(mc,yytext); return RSTRING;}
-
- /* ------------------------------------------------------------------------- */
- /* Parse variables in the form: */
- /* $VARIABLE */
- /* $VARIABLE[ATTR] */
- /* $VARIABLE[ATTR,ATTR=VALUE] */
- /* $NUM.CONTEXT_VARIABLE */
- /* ------------------------------------------------------------------------- */
-
-\$ { BEGIN VAR;}
-
-<VAR>[[:blank:]]*=[[:blank:]]* { BEGIN VALUE; return EQUAL; }
-<VAR>[[:blank:]]*,[[:blank:]]* { return COMMA;}
-<VAR>\[[[:blank:]]* { return OBRACKET;}
-<VAR>[[:blank:]]*\] { return CBRACKET;}
-
-<VAR>[[:alnum:]_]+ { yylval_param->val_str =
- mem_collector_strdup(mc,yytext);
- return VARIABLE;}
-
-<VALUE>\"[^\"]*\" { yylval_param->val_str =
- mem_collector_strdup(mc,yytext+1);
- yylval_param->val_str[yyleng-2] = '\0';
- BEGIN(VAR);
- return STRING;}
-
-<VALUE>[[:alnum:]]+ { yylval_param->val_str =
- mem_collector_strdup(mc,yytext);
- BEGIN(VAR);
- return STRING;}
-
-<VAR>\$ { yylval_param->val_char = '\0';
- return EOA;}
-
-<VAR>. { yylval_param->val_char = *yytext;
- BEGIN(INITIAL);
- return EOA;}
-
-<VAR><<EOF>> { yylval_param->val_char = '\0';
- BEGIN(INITIAL);
- return EOA;}
-%%
-
-int vm_var_wrap(yyscan_t scanner)
-{
- return 1;
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.cc b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.cc
deleted file mode 100644
index 81df4bd..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.cc
+++ /dev/null
@@ -1,2089 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Bison version. */
-#define YYBISON_VERSION "3.4.1"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 1
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse vm_var_parse
-#define yylex vm_var_lex
-#define yyerror vm_var_error
-#define yydebug vm_var_debug
-#define yynerrs vm_var_nerrs
-
-
-/* First part of user prologue. */
-#line 39 "vm_var_syntax.y"
-
-#include "vm_var_syntax.h"
-#include "vm_var_parser.h"
-
-#include "NebulaUtil.h"
-
-#define YYERROR_VERBOSE
-
-void vm_var_error(YYLTYPE * llocp, mem_collector * mc, VirtualMachine * vm,
- ostringstream * parsed, char ** errmsg, yyscan_t scanner, const char * str);
-
-int vm_var_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int vm_var_parse (VirtualMachine * vm, ostringstream * parsed, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = vm_var_parse(&mc, vm, parsed, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_image_attribute(VirtualMachine * vm,
- const string& attr_name,
- const string& img_name,
- const string& img_value,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- ImagePool * ipool = nd.get_ipool();
- Image * img;
- int iid = -1;
-
- int num;
- vector<const VectorAttribute *> disks;
-
- attr_value.clear();
-
- if ( img_name.empty() || (img_name!="IMAGE" && img_name!="IMAGE_ID") )
- {
- return;
- }
-
- // ----------------------------------------------
- // Check that the image is in the template, so
- // are sure that we can access the image template
- // ----------------------------------------------
- num = vm->get_template_attribute("DISK", disks);
-
- for (int i=0; i < num ;i++)
- {
- if ( disks[i]->vector_value(img_name) == img_value )
- {
- string iid_str = disks[i]->vector_value("IMAGE_ID");
- istringstream iss(iid_str);
-
- iss >> iid;
-
- if (iss.fail())
- {
- iid = -1;
- }
-
- break;
- }
- }
-
- if (iid == -1)
- {
- return;
- }
-
- // ----------------------------------------------
- // Get the attribute template from the image
- // ----------------------------------------------
- img = ipool->get_ro(iid);
-
- if ( img == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = img->to_xml64(attr_value);
- }
- else
- {
- img->get_template_attribute(attr_name, attr_value);
- }
-
- img->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_network_attribute(VirtualMachine * vm,
- const string& attr_name,
- const string& net_name,
- const string& net_value,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- VirtualNetworkPool * vnpool = nd.get_vnpool();
- VirtualNetwork * vn;
- int ar_id, vnet_id = -1;
-
- int num;
- vector<const VectorAttribute *> nets;
-
- attr_value.clear();
-
- if ( net_name.empty() ||
- (net_name!="NETWORK" && net_name!="NETWORK_ID" && net_name!="NIC_ID"))
- {
- return;
- }
-
- // ----------------------------------------------
- // Check that the network is in the template, so
- // are sure that we can access its template
- // ----------------------------------------------
- num = vm->get_template_attribute("NIC", nets);
-
- for (int i=0; i < num ;i++)
- {
- if ( nets[i]->vector_value(net_name) == net_value )
- {
- if (nets[i]->vector_value("NETWORK_ID", vnet_id) != 0)
- {
- vnet_id = -1;
- }
-
- if (nets[i]->vector_value("AR_ID", ar_id) != 0)
- {
- vnet_id = -1;
- }
-
- break;
- }
- }
-
- vector<const VectorAttribute *> alias;
- int alias_num = vm->get_template_attribute("NIC_ALIAS", alias);
-
- if (vnet_id == -1 && alias_num == 0)
- {
- return;
- }
- else
- {
- for (int i=0; i < alias_num ;i++)
- {
- if ( alias[i]->vector_value(net_name.c_str()) == net_value )
- {
- if (alias[i]->vector_value("NETWORK_ID", vnet_id) != 0)
- {
- vnet_id = -1;
- }
-
- if (alias[i]->vector_value("AR_ID", ar_id) != 0)
- {
- vnet_id = -1;
- }
-
- break;
- }
- }
-
- if (vnet_id == -1)
- {
- return;
- }
- }
-
- // ----------------------------------------------
- // Get the attribute template from the image
- // ----------------------------------------------
- vn = vnpool->get_ro(vnet_id);
-
- if ( vn == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = vn->to_xml64(attr_value);
- }
- else
- {
- vn->get_template_attribute(attr_name, attr_value, ar_id);
- }
-
- vn->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_user_attribute(VirtualMachine * vm,
- const string& attr_name,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- UserPool * upool = nd.get_upool();
- User * user;
-
- attr_value.clear();
-
- user = upool->get_ro(vm->get_uid());
-
- if ( user == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = user->to_xml64(attr_value);
- }
- else
- {
- user->get_template_attribute(attr_name, attr_value);
- }
-
- user->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void insert_single(VirtualMachine * vm,
- ostringstream& parsed,
- const string& name)
-{
- string value = "";
-
- if (name == "TEMPLATE")
- {
- vm->to_xml64(value);
- }
- else if (name == "UID")
- {
- parsed << vm->get_uid();
- }
- else if (name == "UNAME")
- {
- parsed << vm->get_uname();
- }
- else if (name == "GID")
- {
- parsed << vm->get_gid();
- }
- else if (name == "GNAME")
- {
- parsed << vm->get_gname();
- }
- else if (name == "NAME")
- {
-
- parsed << vm->get_name();
- }
- else
- {
-
- vm->get_template_attribute(name, value);
-
- if (value.empty())
- {
- vm->get_user_template_attribute(name, value);
- }
- }
-
- if (!value.empty())
- {
- parsed << value;
- }
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void insert_vector(VirtualMachine * vm,
- ostringstream& parsed,
- const string& name,
- const string& vname,
- const string& vvar,
- const string& vval)
-
-{
- vector<const VectorAttribute*> values;
- const VectorAttribute * vattr = 0;
-
- int num;
-
- if (name == "NETWORK")
- {
- string value;
-
- get_network_attribute(vm,vname,vvar,vval,value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else if (name == "IMAGE")
- {
- string value;
-
- get_image_attribute(vm,vname,vvar,vval,value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else if (name == "USER")
- {
- string value;
-
- get_user_attribute(vm, vname, value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else
- {
- if ( ( num = vm->get_template_attribute(name, values) ) <= 0 )
- {
- return;
- }
-
- if ( vvar.empty() )
- {
- vattr = values[0];
- }
- else
- {
- for (int i=0 ; i < num ; i++)
- {
- if (values[i]->vector_value(vvar) == vval)
- {
- vattr = values[i];
- break;
- }
- }
- }
-
- if ( vattr != 0 )
- {
- parsed << vattr->vector_value(vname);
- }
- }
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-
-#line 460 "vm_var_syntax.cc"
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-/* Use api.header.include to #include this header
- instead of duplicating it here. */
-#ifndef YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED
-# define YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int vm_var_debug;
-#endif
-/* "%code requires" blocks. */
-#line 17 "vm_var_syntax.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "VirtualMachinePool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_var_parse (VirtualMachine * vm, ostringstream * parsed, char ** errmsg,
- yyscan_t scanner);
-
-#line 516 "vm_var_syntax.cc"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EOA = 262,
- STRING = 263,
- VARIABLE = 264,
- RSTRING = 265,
- INTEGER = 266
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 432 "vm_var_syntax.y"
-
- char * val_str;
- int val_int;
- char val_char;
-
-#line 545 "vm_var_syntax.cc"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int vm_var_parse (mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner);
-
-#endif /* !YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED */
-
-
-
-#ifdef short
-# undef short
-#endif
-
-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
-#endif
-
-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
-#else
-typedef unsigned short yytype_uint16;
-#endif
-
-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE
-# if (defined __GNUC__ \
- && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
- || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
-# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
-# else
-# define YY_ATTRIBUTE(Spec) /* empty */
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_PURE
-# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YYUSE(E) ((void) (E))
-#else
-# define YYUSE(E) /* empty */
-#endif
-
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if ! defined yyoverflow || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include <alloca.h> /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include <malloc.h> /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yytype_int16 yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 7
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 18
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 12
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 3
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 7
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 18
-
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 266
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- ((unsigned) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 9, 10, 11
-};
-
-#if YYDEBUG
- /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_uint16 yyrline[] =
-{
- 0, 456, 456, 457, 460, 464, 477, 492
-};
-#endif
-
-#if YYDEBUG || YYERROR_VERBOSE || 0
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "$end", "error", "$undefined", "EQUAL", "COMMA", "OBRACKET", "CBRACKET",
- "EOA", "STRING", "VARIABLE", "RSTRING", "INTEGER", "$accept",
- "vm_string", "vm_variable", YY_NULLPTR
-};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[NUM] -- (External) token number corresponding to the
- (internal) symbol number NUM (which must be that of a token). */
-static const yytype_uint16 yytoknum[] =
-{
- 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
- 265, 266
-};
-# endif
-
-#define YYPACT_NINF -5
-
-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-5)))
-
-#define YYTABLE_NINF -1
-
-#define yytable_value_is_error(Yytable_value) \
- 0
-
- /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int8 yypact[] =
-{
- -3, -4, -5, 0, -5, -1, -5, -5, -5, -2,
- 2, 5, 10, -5, 6, 9, 11, -5
-};
-
- /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 0, 0, 4, 0, 2, 0, 5, 1, 3, 0,
- 0, 0, 0, 6, 0, 0, 0, 7
-};
-
- /* YYPGOTO[NTERM-NUM]. */
-static const yytype_int8 yypgoto[] =
-{
- -5, -5, 13
-};
-
- /* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int8 yydefgoto[] =
-{
- -1, 3, 4
-};
-
- /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_uint8 yytable[] =
-{
- 7, 5, 10, 6, 11, 0, 1, 2, 9, 1,
- 2, 12, 13, 14, 15, 16, 8, 0, 17
-};
-
-static const yytype_int8 yycheck[] =
-{
- 0, 5, 4, 7, 6, -1, 9, 10, 9, 9,
- 10, 9, 7, 3, 8, 6, 3, -1, 7
-};
-
- /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
-{
- 0, 9, 10, 13, 14, 5, 7, 0, 14, 9,
- 4, 6, 9, 7, 3, 8, 6, 7
-};
-
- /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 12, 13, 13, 14, 14, 14, 14
-};
-
- /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 1, 2, 1, 2, 5, 9
-};
-
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, mc, vm, parsed, errmsg, scanner, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
-
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YY_LOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-#ifndef YY_LOCATION_PRINT
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
- }
-
-# define YY_LOCATION_PRINT(File, Loc) \
- yy_location_print_ (File, &(Loc))
-
-# else
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-# endif
-#endif
-
-
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value, Location, mc, vm, parsed, errmsg, scanner); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner)
-{
- FILE *yyoutput = yyo;
- YYUSE (yyoutput);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (vm);
- YYUSE (parsed);
- YYUSE (errmsg);
- YYUSE (scanner);
- if (!yyvaluep)
- return;
-# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
-# endif
- YYUSE (yytype);
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner)
-{
- YYFPRINTF (yyo, "%s %s (",
- yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
-
- YY_LOCATION_PRINT (yyo, *yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yytype, yyvaluep, yylocationp, mc, vm, parsed, errmsg, scanner);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner)
-{
- unsigned long yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- yystos[yyssp[yyi + 1 - yynrhs]],
- &yyvsp[(yyi + 1) - (yynrhs)]
- , &(yylsp[(yyi + 1) - (yynrhs)]) , mc, vm, parsed, errmsg, scanner);
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule, mc, vm, parsed, errmsg, scanner); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-yystrlen (const char *yystr)
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif
-
-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-{
- char *yyd = yydest;
- const char *yys = yysrc;
-
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- else
- goto append;
-
- append:
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return (YYSIZE_T) (yystpcpy (yyres, yystr) - yyres);
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULLPTR;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- default: /* Avoid compiler warnings. */
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
- yysize = yysize1;
- else
- return 2;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner)
-{
- YYUSE (yyvaluep);
- YYUSE (yylocationp);
- YYUSE (mc);
- YYUSE (vm);
- YYUSE (parsed);
- YYUSE (errmsg);
- YYUSE (scanner);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YYUSE (yytype);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner)
-{
-/* The lookahead symbol. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs;
-
- int yystate;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
-
- /* The stacks and their tools:
- 'yyss': related to states.
- 'yyvs': related to semantic values.
- 'yyls': related to locations.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- /* The location stack. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls;
- YYLTYPE *yylsp;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
- YYSIZE_T yystacksize;
-
- int yyn;
- int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yylsp = yyls = yylsa;
- yystacksize = YYINITDEPTH;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yynewstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- *yyssp = (yytype_int16) yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- goto yyexhaustedlab;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = (YYSIZE_T) (yyssp - yyss + 1);
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yyls1, yysize * sizeof (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = yylex (&yylval, &yylloc, mc, scanner);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 4:
-#line 461 "vm_var_syntax.y"
- {
- (*parsed) << (yyvsp[0].val_str);
- }
-#line 1762 "vm_var_syntax.cc"
- break;
-
- case 5:
-#line 465 "vm_var_syntax.y"
- {
- string name((yyvsp[-1].val_str));
-
- one_util::toupper(name);
-
- insert_single(vm,*parsed,name);
-
- if ( (yyvsp[0].val_char) != '\0' )
- {
- (*parsed) << (yyvsp[0].val_char);
- }
- }
-#line 1779 "vm_var_syntax.cc"
- break;
-
- case 6:
-#line 478 "vm_var_syntax.y"
- {
- string name((yyvsp[-4].val_str));
- string vname((yyvsp[-2].val_str));
-
- one_util::toupper(name);
- one_util::toupper(vname);
-
- insert_vector(vm,*parsed,name,vname,"","");
-
- if ( (yyvsp[0].val_char) != '\0' )
- {
- (*parsed) << (yyvsp[0].val_char);
- }
- }
-#line 1798 "vm_var_syntax.cc"
- break;
-
- case 7:
-#line 493 "vm_var_syntax.y"
- {
- string name((yyvsp[-8].val_str));
- string vname((yyvsp[-6].val_str));
- string vvar((yyvsp[-4].val_str));
- string vval((yyvsp[-2].val_str));
-
- one_util::toupper(name);
- one_util::toupper(vname);
- one_util::toupper(vvar);
-
- insert_vector(vm,*parsed,name,vname,vvar,vval);
-
- if ( (yyvsp[0].val_char) != '\0' )
- {
- (*parsed) << (yyvsp[0].val_char);
- }
- }
-#line 1820 "vm_var_syntax.cc"
- break;
-
-
-#line 1824 "vm_var_syntax.cc"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if ! YYERROR_VERBOSE
- yyerror (&yylloc, mc, vm, parsed, errmsg, scanner, YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (&yylloc, mc, vm, parsed, errmsg, scanner, yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
- }
-
- yyerror_range[1] = yylloc;
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc, mc, vm, parsed, errmsg, scanner);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- yystos[yystate], yyvsp, yylsp, mc, vm, parsed, errmsg, scanner);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- /* Using YYLLOC is tempting, but would change the location of
- the lookahead. YYLOC is available though. */
- YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
- *++yylsp = yyloc;
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-
-#if !defined yyoverflow || YYERROR_VERBOSE
-/*-------------------------------------------------.
-| yyexhaustedlab -- memory exhaustion comes here. |
-`-------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, mc, vm, parsed, errmsg, scanner, YY_("memory exhausted"));
- yyresult = 2;
- /* Fall through. */
-#endif
-
-
-/*-----------------------------------------------------.
-| yyreturn -- parsing is finished, return the result. |
-`-----------------------------------------------------*/
-yyreturn:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc, mc, vm, parsed, errmsg, scanner);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp, yylsp, mc, vm, parsed, errmsg, scanner);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- return yyresult;
-}
-#line 511 "vm_var_syntax.y"
-
-
-void vm_var_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- VirtualMachine * vm,
- ostringstream * parsed,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.h b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.h
deleted file mode 100644
index 694f8e5..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.4.1. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* Undocumented macros, especially those whose name start with YY_,
- are private implementation details. Do not rely on them. */
-
-#ifndef YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED
-# define YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int vm_var_debug;
-#endif
-/* "%code requires" blocks. */
-#line 17 "vm_var_syntax.y"
-
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "VirtualMachinePool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_var_parse (VirtualMachine * vm, ostringstream * parsed, char ** errmsg,
- yyscan_t scanner);
-
-#line 70 "vm_var_syntax.hh"
-
-/* Token type. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- EQUAL = 258,
- COMMA = 259,
- OBRACKET = 260,
- CBRACKET = 261,
- EOA = 262,
- STRING = 263,
- VARIABLE = 264,
- RSTRING = 265,
- INTEGER = 266
- };
-#endif
-
-/* Value type. */
-#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-union YYSTYPE
-{
-#line 432 "vm_var_syntax.y"
-
- char * val_str;
- int val_int;
- char val_char;
-
-#line 99 "vm_var_syntax.hh"
-
-};
-typedef union YYSTYPE YYSTYPE;
-# define YYSTYPE_IS_TRIVIAL 1
-# define YYSTYPE_IS_DECLARED 1
-#endif
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-int vm_var_parse (mem_collector * mc, VirtualMachine * vm, ostringstream * parsed, char ** errmsg, yyscan_t scanner);
-
-#endif /* !YY_VM_VAR_VM_VAR_SYNTAX_HH_INCLUDED */
diff --git a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.y b/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.y
deleted file mode 100644
index 243f3ce..0000000
--- a/app-emulation/opennebula/files/opennebula-5.10.1/parsers/vm_var_syntax.y
+++ /dev/null
@@ -1,538 +0,0 @@
-/* -------------------------------------------------------------------------- */
-/* Copyright 2002-2019, OpenNebula Project, OpenNebula Systems */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
-/* not use this file except in compliance with the License. You may obtain */
-/* a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
-/* See the License for the specific language governing permissions and */
-/* limitations under the License. */
-/* -------------------------------------------------------------------------- */
-
-%code requires {
-#include <iostream>
-#include <sstream>
-#include <string>
-#include <map>
-#include <algorithm>
-
-#include <ctype.h>
-#include <string.h>
-
-#include "VirtualMachinePool.h"
-#include "VirtualMachine.h"
-#include "Nebula.h"
-
-#include "mem_collector.h"
-
-typedef void * yyscan_t;
-
-int vm_var_parse (VirtualMachine * vm, ostringstream * parsed, char ** errmsg,
- yyscan_t scanner);
-}
-
-%{
-#include "vm_var_syntax.h"
-#include "vm_var_parser.h"
-
-#include "NebulaUtil.h"
-
-#define YYERROR_VERBOSE
-
-void vm_var_error(YYLTYPE * llocp, mem_collector * mc, VirtualMachine * vm,
- ostringstream * parsed, char ** errmsg, yyscan_t scanner, const char * str);
-
-int vm_var_lex(YYSTYPE *lvalp, YYLTYPE *llocp, mem_collector * mc,
- yyscan_t scanner);
-
-int vm_var_parse (VirtualMachine * vm, ostringstream * parsed, char ** errmsg,
- yyscan_t scanner)
-{
- mem_collector mc;
- int rc;
-
- mem_collector_init(&mc);
-
- rc = vm_var_parse(&mc, vm, parsed, errmsg, scanner);
-
- mem_collector_cleanup(&mc);
-
- return rc;
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_image_attribute(VirtualMachine * vm,
- const string& attr_name,
- const string& img_name,
- const string& img_value,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- ImagePool * ipool = nd.get_ipool();
- Image * img;
- int iid = -1;
-
- int num;
- vector<const VectorAttribute *> disks;
-
- attr_value.clear();
-
- if ( img_name.empty() || (img_name!="IMAGE" && img_name!="IMAGE_ID") )
- {
- return;
- }
-
- // ----------------------------------------------
- // Check that the image is in the template, so
- // are sure that we can access the image template
- // ----------------------------------------------
- num = vm->get_template_attribute("DISK", disks);
-
- for (int i=0; i < num ;i++)
- {
- if ( disks[i]->vector_value(img_name) == img_value )
- {
- string iid_str = disks[i]->vector_value("IMAGE_ID");
- istringstream iss(iid_str);
-
- iss >> iid;
-
- if (iss.fail())
- {
- iid = -1;
- }
-
- break;
- }
- }
-
- if (iid == -1)
- {
- return;
- }
-
- // ----------------------------------------------
- // Get the attribute template from the image
- // ----------------------------------------------
- img = ipool->get_ro(iid);
-
- if ( img == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = img->to_xml64(attr_value);
- }
- else
- {
- img->get_template_attribute(attr_name, attr_value);
- }
-
- img->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_network_attribute(VirtualMachine * vm,
- const string& attr_name,
- const string& net_name,
- const string& net_value,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- VirtualNetworkPool * vnpool = nd.get_vnpool();
- VirtualNetwork * vn;
- int ar_id, vnet_id = -1;
-
- int num;
- vector<const VectorAttribute *> nets;
-
- attr_value.clear();
-
- if ( net_name.empty() ||
- (net_name!="NETWORK" && net_name!="NETWORK_ID" && net_name!="NIC_ID"))
- {
- return;
- }
-
- // ----------------------------------------------
- // Check that the network is in the template, so
- // are sure that we can access its template
- // ----------------------------------------------
- num = vm->get_template_attribute("NIC", nets);
-
- for (int i=0; i < num ;i++)
- {
- if ( nets[i]->vector_value(net_name) == net_value )
- {
- if (nets[i]->vector_value("NETWORK_ID", vnet_id) != 0)
- {
- vnet_id = -1;
- }
-
- if (nets[i]->vector_value("AR_ID", ar_id) != 0)
- {
- vnet_id = -1;
- }
-
- break;
- }
- }
-
- vector<const VectorAttribute *> alias;
- int alias_num = vm->get_template_attribute("NIC_ALIAS", alias);
-
- if (vnet_id == -1 && alias_num == 0)
- {
- return;
- }
- else
- {
- for (int i=0; i < alias_num ;i++)
- {
- if ( alias[i]->vector_value(net_name.c_str()) == net_value )
- {
- if (alias[i]->vector_value("NETWORK_ID", vnet_id) != 0)
- {
- vnet_id = -1;
- }
-
- if (alias[i]->vector_value("AR_ID", ar_id) != 0)
- {
- vnet_id = -1;
- }
-
- break;
- }
- }
-
- if (vnet_id == -1)
- {
- return;
- }
- }
-
- // ----------------------------------------------
- // Get the attribute template from the image
- // ----------------------------------------------
- vn = vnpool->get_ro(vnet_id);
-
- if ( vn == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = vn->to_xml64(attr_value);
- }
- else
- {
- vn->get_template_attribute(attr_name, attr_value, ar_id);
- }
-
- vn->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void get_user_attribute(VirtualMachine * vm,
- const string& attr_name,
- string& attr_value)
-{
- Nebula& nd = Nebula::instance();
-
- UserPool * upool = nd.get_upool();
- User * user;
-
- attr_value.clear();
-
- user = upool->get_ro(vm->get_uid());
-
- if ( user == 0 )
- {
- return;
- }
-
- if (attr_name == "TEMPLATE")
- {
- attr_value = user->to_xml64(attr_value);
- }
- else
- {
- user->get_template_attribute(attr_name, attr_value);
- }
-
- user->unlock();
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void insert_single(VirtualMachine * vm,
- ostringstream& parsed,
- const string& name)
-{
- string value = "";
-
- if (name == "TEMPLATE")
- {
- vm->to_xml64(value);
- }
- else if (name == "UID")
- {
- parsed << vm->get_uid();
- }
- else if (name == "UNAME")
- {
- parsed << vm->get_uname();
- }
- else if (name == "GID")
- {
- parsed << vm->get_gid();
- }
- else if (name == "GNAME")
- {
- parsed << vm->get_gname();
- }
- else if (name == "NAME")
- {
-
- parsed << vm->get_name();
- }
- else
- {
-
- vm->get_template_attribute(name, value);
-
- if (value.empty())
- {
- vm->get_user_template_attribute(name, value);
- }
- }
-
- if (!value.empty())
- {
- parsed << value;
- }
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-void insert_vector(VirtualMachine * vm,
- ostringstream& parsed,
- const string& name,
- const string& vname,
- const string& vvar,
- const string& vval)
-
-{
- vector<const VectorAttribute*> values;
- const VectorAttribute * vattr = 0;
-
- int num;
-
- if (name == "NETWORK")
- {
- string value;
-
- get_network_attribute(vm,vname,vvar,vval,value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else if (name == "IMAGE")
- {
- string value;
-
- get_image_attribute(vm,vname,vvar,vval,value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else if (name == "USER")
- {
- string value;
-
- get_user_attribute(vm, vname, value);
-
- if (!value.empty())
- {
- parsed << value;
- }
-
- return;
- }
- else
- {
- if ( ( num = vm->get_template_attribute(name, values) ) <= 0 )
- {
- return;
- }
-
- if ( vvar.empty() )
- {
- vattr = values[0];
- }
- else
- {
- for (int i=0 ; i < num ; i++)
- {
- if (values[i]->vector_value(vvar) == vval)
- {
- vattr = values[i];
- break;
- }
- }
- }
-
- if ( vattr != 0 )
- {
- parsed << vattr->vector_value(vname);
- }
- }
-}
-
-/* -------------------------------------------------------------------------- */
-/* -------------------------------------------------------------------------- */
-
-%}
-
-%parse-param {mem_collector * mc}
-%parse-param {VirtualMachine * vm}
-%parse-param {ostringstream * parsed}
-%parse-param {char ** errmsg}
-%parse-param {yyscan_t scanner}
-
-%lex-param {mem_collector * mc}
-%lex-param {yyscan_t scanner}
-
-%union {
- char * val_str;
- int val_int;
- char val_char;
-};
-
-%defines
-%locations
-%pure-parser
-%name-prefix "vm_var_"
-%output "vm_var_syntax.cc"
-
-%token EQUAL COMMA OBRACKET CBRACKET
-
-%token <val_char> EOA
-%token <val_str> STRING
-%token <val_str> VARIABLE
-%token <val_str> RSTRING
-%token <val_int> INTEGER
-%type <void> vm_variable
-%type <void> vm_string
-
-%%
-
-vm_string: vm_variable
- | vm_string vm_variable
- ;
-
-vm_variable:RSTRING
- {
- (*parsed) << $1;
- }
- | VARIABLE EOA
- {
- string name($1);
-
- one_util::toupper(name);
-
- insert_single(vm,*parsed,name);
-
- if ( $2 != '\0' )
- {
- (*parsed) << $2;
- }
- }
- | VARIABLE OBRACKET VARIABLE CBRACKET EOA
- {
- string name($1);
- string vname($3);
-
- one_util::toupper(name);
- one_util::toupper(vname);
-
- insert_vector(vm,*parsed,name,vname,"","");
-
- if ( $5 != '\0' )
- {
- (*parsed) << $5;
- }
- }
- | VARIABLE OBRACKET VARIABLE COMMA VARIABLE EQUAL STRING CBRACKET EOA
- {
- string name($1);
- string vname($3);
- string vvar($5);
- string vval($7);
-
- one_util::toupper(name);
- one_util::toupper(vname);
- one_util::toupper(vvar);
-
- insert_vector(vm,*parsed,name,vname,vvar,vval);
-
- if ( $9 != '\0' )
- {
- (*parsed) << $9;
- }
- }
- ;
-%%
-
-void vm_var_error(
- YYLTYPE * llocp,
- mem_collector * mc,
- VirtualMachine * vm,
- ostringstream * parsed,
- char ** error_msg,
- yyscan_t scanner,
- const char * str)
-{
- int length;
-
- length = strlen(str)+ 64;
-
- *error_msg = (char *) malloc(sizeof(char)*length);
-
- if (*error_msg != 0)
- {
- snprintf(*error_msg,
- length,
- "%s at line %i, columns %i:%i",
- str,
- llocp->first_line,
- llocp->first_column,
- llocp->last_column);
- }
-}
diff --git a/app-emulation/opennebula/files/openrc/99one b/app-emulation/opennebula/files/openrc/99one
deleted file mode 100644
index 53e21b1..0000000
--- a/app-emulation/opennebula/files/openrc/99one
+++ /dev/null
@@ -1 +0,0 @@
-ONE_AUTH="/etc/one/one_auth"
diff --git a/app-emulation/opennebula/files/openrc/oneflow-server.confd b/app-emulation/opennebula/files/openrc/oneflow-server.confd
deleted file mode 100644
index 67d6db8..0000000
--- a/app-emulation/opennebula/files/openrc/oneflow-server.confd
+++ /dev/null
@@ -1,10 +0,0 @@
-
-# opennebula user
-USER="oneadmin"
-GROUP="oneadmin"
-
-ONEFLOWSERVER_STARTOPTIONS="start"
-ONEFLOWSERVER_STOPOPTIONS="stop"
-
-ONEFLOW_PID="/var/run/one/oneflow.pid"
-
diff --git a/app-emulation/opennebula/files/openrc/oneflow-server.initd b/app-emulation/opennebula/files/openrc/oneflow-server.initd
deleted file mode 100644
index 1d62127..0000000
--- a/app-emulation/opennebula/files/openrc/oneflow-server.initd
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/opennebula/files/opennebula.initd,v 1.1 2010/08/11 16:07:57 dev-zero Exp $
-
-depend() {
- after mysql
- use libvirtd
-}
-
-start() {
-
- ebegin "Starting Oneflow Server"
- start-stop-daemon \
- --start \
- --exec /usr/bin/oneflow-server \
- --user ${USER}:${GROUP} \
- --pidfile ${ONEFLOW_PID} \
- -- ${ONEFLOWSERVER_STARTOPTIONS}
- eend $?
-}
-
-stop() {
-
- ebegin "Stopping Oneflow Server"
- start-stop-daemon \
- --stop \
- --exec /usr/bin/oneflow-server \
- --user ${USER}:${GROUP} \
- --pidfile ${ONEFLOW_PID} \
- -- ${ONEFLOWSERVER_STOPOPTIONS} \
- eend $?
-
-}
diff --git a/app-emulation/opennebula/files/openrc/opennebula.confd b/app-emulation/opennebula/files/openrc/opennebula.confd
deleted file mode 100644
index 0a14ca8..0000000
--- a/app-emulation/opennebula/files/openrc/opennebula.confd
+++ /dev/null
@@ -1,12 +0,0 @@
-
-# opennebula user
-USER="oneadmin"
-GROUP="oneadmin"
-
-# options for oned
-ONE_STARTOPTIONS="start"
-ONE_STOPOPTIONS="stop"
-
-ONE_PID="/var/run/one/oned.pid"
-SCHED_PID="/var/run/one/sched.pid"
-
diff --git a/app-emulation/opennebula/files/openrc/opennebula.initd b/app-emulation/opennebula/files/openrc/opennebula.initd
deleted file mode 100644
index d8ba3d1..0000000
--- a/app-emulation/opennebula/files/openrc/opennebula.initd
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/opennebula/files/opennebula.initd,v 1.1 2010/08/11 16:07:57 dev-zero Exp $
-
-depend() {
- after mysql
- use libvirtd
-}
-
-start() {
- ebegin "Starting OpenNebula daemon"
- start-stop-daemon \
- --start \
- --exec /usr/bin/one \
- --user ${USER}:${GROUP} \
- --pidfile ${ONE_PID} \
- -- ${ONE_STARTOPTIONS}
- eend $?
-
-}
-
-stop() {
- ebegin "Stopping OpenNebula daemon"
- start-stop-daemon \
- --stop \
- --exec /usr/bin/one \
- --user ${USER}:${GROUP} \
- --pidfile ${ONE_PID} \
- -- ${ONE_STOPOPTIONS}
- eend $?
-
- ebegin "Stopping Scheduler Deamon"
- start-stop-daemon \
- --stop \
- --exec /usr/bin/mm_sched \
- --user ${USER}:${GROUP} \
- --pidfile ${SCHED_PID} \
- eend $?
-}
diff --git a/app-emulation/opennebula/files/openrc/sunstone-server.confd b/app-emulation/opennebula/files/openrc/sunstone-server.confd
deleted file mode 100644
index b073c4a..0000000
--- a/app-emulation/opennebula/files/openrc/sunstone-server.confd
+++ /dev/null
@@ -1,10 +0,0 @@
-
-# opennebula user
-USER="oneadmin"
-GROUP="oneadmin"
-
-SUNSTONESERVER_STARTOPTIONS="start"
-SUNSTONESERVER_STOPOPTIONS="stop"
-
-SUNSTONE_PID="/var/run/one/sunstone.pid"
-
diff --git a/app-emulation/opennebula/files/openrc/sunstone-server.initd b/app-emulation/opennebula/files/openrc/sunstone-server.initd
deleted file mode 100644
index af2e7a7..0000000
--- a/app-emulation/opennebula/files/openrc/sunstone-server.initd
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/opennebula/files/opennebula.initd,v 1.1 2010/08/11 16:07:57 dev-zero Exp $
-
-depend() {
- after mysql
- use libvirtd
-}
-
-start() {
-
- ebegin "Starting Sunstone Server"
- start-stop-daemon \
- --start \
- --exec /usr/bin/sunstone-server \
- --user ${USER}:${GROUP} \
- --pidfile ${SUNSTONE_PID} \
- -- ${SUNSTONESERVER_STARTOPTIONS}
- eend $?
-}
-
-stop() {
-
- ebegin "Stopping Sunstone Server"
- start-stop-daemon \
- --stop \
- --exec /usr/bin/sunstone-server \
- --user ${USER}:${GROUP} \
- --pidfile ${SUNSTONE_PID} \
- -- ${SUNSTONESERVER_STOPOPTIONS} \
- eend $?
-
-}
diff --git a/app-emulation/opennebula/files/patches/fix_kvm_emulator.5.12.0.1.patch b/app-emulation/opennebula/files/patches/fix_kvm_emulator.5.12.0.1.patch
deleted file mode 100644
index 7b7e4fc..0000000
--- a/app-emulation/opennebula/files/patches/fix_kvm_emulator.5.12.0.1.patch
+++ /dev/null
@@ -1,11 +0,0 @@
-diff -Naur a/src/vmm_mad/exec/vmm_exec_kvm.conf b/src/vmm_mad/exec/vmm_exec_kvm.conf
---- a/src/vmm_mad/exec/vmm_exec_kvm.conf 2020-07-14 18:02:27.000000000 +0100
-+++ b/src/vmm_mad/exec/vmm_exec_kvm.conf 2020-09-20 19:32:44.702940463 +0100
-@@ -29,6 +29,7 @@
- # NOTE: raw attribute value is appended to that on the VM template
-
- #EMULATOR = /usr/libexec/qemu-kvm
-+EMULATOR = /usr/bin/qemu-system-x86_64
-
- #VCPU = 1
-
diff --git a/app-emulation/opennebula/files/patches/fix_kvm_emulator.patch b/app-emulation/opennebula/files/patches/fix_kvm_emulator.patch
deleted file mode 100644
index 1e9511c..0000000
--- a/app-emulation/opennebula/files/patches/fix_kvm_emulator.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Index: src/vmm_mad/exec/vmm_exec_kvm.conf
---- src/vmm_mad/exec/vmm_exec_kvm.conf
-+++ src/vmm_mad/exec/vmm_exec_kvm.conf
-@@ -27,7 +27,7 @@
- # - hyperv_options: options used for FEATURES = [ HYPERV = yes ]
- # NOTE: raw attribute value is appended to that on the VM template
-
--#EMULATOR = /usr/libexec/qemu-kvm
-+EMULATOR = /usr/bin/qemu-system-x86_64
-
- #VCPU = 1
-
diff --git a/app-emulation/opennebula/files/patches/install.sh.5.12.0.1.patch b/app-emulation/opennebula/files/patches/install.sh.5.12.0.1.patch
deleted file mode 100644
index 920597e..0000000
--- a/app-emulation/opennebula/files/patches/install.sh.5.12.0.1.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-diff -Naur a/install.sh b/install.sh
---- a/install.sh 2020-07-14 18:02:27.000000000 +0100
-+++ b/install.sh 2020-09-20 14:11:35.962024833 +0100
-@@ -108,8 +108,8 @@
- ONEHEM_LOCATION="$LIB_LOCATION/onehem"
- SYSTEM_DS_LOCATION="$VAR_LOCATION/datastores/0"
- DEFAULT_DS_LOCATION="$VAR_LOCATION/datastores/1"
-- RUN_LOCATION="/var/run/one"
-- LOCK_LOCATION="/var/lock/one"
-+ RUN_LOCATION="/run/one"
-+ LOCK_LOCATION="/run/lock/one"
- INCLUDE_LOCATION="/usr/include"
- SHARE_LOCATION="/usr/share/one"
- MAN_LOCATION="/usr/share/man/man1"
diff --git a/app-emulation/opennebula/files/patches/install.sh.patch b/app-emulation/opennebula/files/patches/install.sh.patch
deleted file mode 100644
index 133960d..0000000
--- a/app-emulation/opennebula/files/patches/install.sh.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Index: install.sh
-===================================================================
---- install.sh 2019-12-10 16:00:55.000000000 +0100
-+++ install.sh 2019-12-15 08:55:09.000000000 +0100
-@@ -107,8 +107,8 @@
- ONEHEM_LOCATION="$LIB_LOCATION/onehem"
- SYSTEM_DS_LOCATION="$VAR_LOCATION/datastores/0"
- DEFAULT_DS_LOCATION="$VAR_LOCATION/datastores/1"
-- RUN_LOCATION="/var/run/one"
-- LOCK_LOCATION="/var/lock/one"
-+ RUN_LOCATION="/run/one"
-+ LOCK_LOCATION="/run/lock/one"
- INCLUDE_LOCATION="/usr/include"
- SHARE_LOCATION="/usr/share/one"
- MAN_LOCATION="/usr/share/man/man1"
-@@ -2450,7 +2450,8 @@
- ln -s $VAR_LOCATION/sunstone/main.js $DESTDIR$SUNSTONE_LOCATION/public/dist/main.js
- fi
- for d in $CHOWN_DIRS; do
-- chown -R $ONEADMIN_USER:$ONEADMIN_GROUP $DESTDIR$d
-+ :
-+ #chown -R $ONEADMIN_USER:$ONEADMIN_GROUP $DESTDIR$d
- done
- else
- for d in `echo $DELETE_DIRS | awk '{for (i=NF;i>=1;i--) printf $i" "}'`; do
diff --git a/app-emulation/opennebula/files/patches/node-sass.5.12.0.1.patch b/app-emulation/opennebula/files/patches/node-sass.5.12.0.1.patch
deleted file mode 100644
index 1c70a05..0000000
--- a/app-emulation/opennebula/files/patches/node-sass.5.12.0.1.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-diff -Naur a/src/sunstone/public/Gruntfile.js b/src/sunstone/public/Gruntfile.js
---- a/src/sunstone/public/Gruntfile.js 2020-07-14 18:02:27.000000000 +0100
-+++ b/src/sunstone/public/Gruntfile.js 2020-09-20 13:18:19.158839478 +0100
-@@ -15,11 +15,16 @@
- /* -------------------------------------------------------------------------- */
-
- module.exports = function(grunt) {
-+ const sass = require('node-sass');
-+
-+ require('load-grunt-tasks')(grunt);
-+
- grunt.initConfig({
- pkg: grunt.file.readJSON("package.json"),
-
- sass: {
- options: {
-+ implementation: sass,
- includePaths: ["bower_components/foundation-sites/scss"]
- },
- dist: {
diff --git a/app-emulation/opennebula/files/patches/package.js.5.12.0.1.patch b/app-emulation/opennebula/files/patches/package.js.5.12.0.1.patch
deleted file mode 100644
index 7be32bd..0000000
--- a/app-emulation/opennebula/files/patches/package.js.5.12.0.1.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-diff -Naur a/src/sunstone/public/package.json b/src/sunstone/public/package.json
---- a/src/sunstone/public/package.json 2020-07-14 18:02:27.000000000 +0100
-+++ b/src/sunstone/public/package.json 2020-09-20 15:39:20.106057317 +0100
-@@ -2,11 +2,12 @@
- "name": "opennebula-sunstone",
- "version": "0.0.1",
- "devDependencies": {
-- "grunt": "<1.1.0",
-+ "grunt": "^1.3.0",
- "grunt-cli": "^1.2.0",
- "grunt-contrib-requirejs": "^1.0.0",
-- "grunt-contrib-watch": "^1.0.0",
-- "grunt-sass": "^1.2.1",
-- "node-sass": "^3.10.1"
-+ "grunt-contrib-watch": "^1.1.0",
-+ "grunt-sass": "^3.1.0",
-+ "node-sass": "^4.12.0",
-+ "load-grunt-tasks": "^5.1.0"
- }
- }
diff --git a/app-emulation/opennebula/files/sudoers/opennebula b/app-emulation/opennebula/files/sudoers/opennebula
deleted file mode 100644
index 7137789..0000000
--- a/app-emulation/opennebula/files/sudoers/opennebula
+++ /dev/null
@@ -1,14 +0,0 @@
-Defaults:oneadmin !requiretty
-Defaults:oneadmin secure_path = /sbin:/bin:/usr/sbin:/usr/bin
-
-Cmnd_Alias ONE_CEPH = /usr/bin/rbd
-Cmnd_Alias ONE_HA = /usr/bin/systemctl start opennebula-flow, /usr/bin/systemctl stop opennebula-flow, /usr/bin/systemctl start opennebula-gate, /usr/bin/systemctl stop opennebula-gate, /usr/bin/systemctl start opennebula-hem, /usr/bin/systemctl stop opennebula-hem, /usr/sbin/service opennebula-flow start, /usr/sbin/service opennebula-flow stop, /usr/sbin/service opennebula-gate start, /usr/sbin/service opennebula-gate stop, /usr/sbin/service opennebula-hem start, /usr/sbin/service opennebula-hem stop, /bin/arping, /bin/ip
-Cmnd_Alias ONE_LVM = /sbin/lvcreate, /sbin/lvremove, /sbin/lvs, /sbin/vgdisplay, /sbin/lvchange, /sbin/lvscan, /sbin/lvextend
-Cmnd_Alias ONE_LXD = /usr/bin/lxc, /bin/mount, /bin/umount, /bin/mkdir, /bin/lsblk, /sbin/losetup, /sbin/kpartx, /usr/bin/qemu-nbd, /sbin/blkid, /sbin/e2fsck, /sbin/resize2fs, /usr/sbin/xfs_growfs, /usr/bin/rbd-nbd, /usr/sbin/xfs_admin, /sbin/tune2fs
-Cmnd_Alias ONE_MARKET = /usr/lib64/one/sh/create_container_image.sh
-Cmnd_Alias ONE_NET = /sbin/ebtables, /sbin/iptables, /sbin/ip6tables, /bin/ip
-Cmnd_Alias ONE_OVS = /usr/bin/ovs-ofctl, /usr/bin/ovs-vsctl
-
-## Command aliases are enabled individually in dedicated
-## sudoers files by each OpenNebula component (server, node).
-# oneadmin ALL=(ALL) NOPASSWD: ONE_CEPH, ONE_HA, ONE_LVM, ONE_LXD, ONE_MARKET, ONE_NET, ONE_OVS
diff --git a/app-emulation/opennebula/files/sudoers/opennebula-node b/app-emulation/opennebula/files/sudoers/opennebula-node
deleted file mode 100644
index 2f0b3e7..0000000
--- a/app-emulation/opennebula/files/sudoers/opennebula-node
+++ /dev/null
@@ -1 +0,0 @@
-oneadmin ALL=(ALL:ALL) NOPASSWD: ONE_CEPH, ONE_NET, ONE_OVS, ONE_LVM
diff --git a/app-emulation/opennebula/files/sudoers/opennebula-node-lxd b/app-emulation/opennebula/files/sudoers/opennebula-node-lxd
deleted file mode 100644
index a7fd1dc..0000000
--- a/app-emulation/opennebula/files/sudoers/opennebula-node-lxd
+++ /dev/null
@@ -1 +0,0 @@
-oneadmin ALL=(ALL:ALL) NOPASSWD: ONE_LXD
diff --git a/app-emulation/opennebula/files/sudoers/opennebula-server b/app-emulation/opennebula/files/sudoers/opennebula-server
deleted file mode 100644
index afbe9a6..0000000
--- a/app-emulation/opennebula/files/sudoers/opennebula-server
+++ /dev/null
@@ -1 +0,0 @@
-oneadmin ALL=(ALL) NOPASSWD: ONE_CEPH, ONE_HA, ONE_MARKET
diff --git a/app-emulation/opennebula/files/systemd/opennebula-econe.service b/app-emulation/opennebula/files/systemd/opennebula-econe.service
deleted file mode 100644
index 434c4ff..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-econe.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=OpenNebula econe Server
-After=syslog.target network.target
-After=opennebula.service
-AssertFileNotEmpty=/var/lib/one/.one/ec2_auth
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-econe -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/ruby /usr/lib64/one/ruby/cloud/econe/econe-server.rb
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-flow.service b/app-emulation/opennebula/files/systemd/opennebula-flow.service
deleted file mode 100644
index 6916d3d..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-flow.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=OpenNebula Flow Service
-After=syslog.target network.target
-After=opennebula.service
-AssertFileNotEmpty=/var/lib/one/.one/oneflow_auth
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-flow -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/ruby /usr/lib64/one/oneflow/oneflow-server.rb
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-gate.service b/app-emulation/opennebula/files/systemd/opennebula-gate.service
deleted file mode 100644
index cc410e6..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-gate.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=OpenNebula Gate Service
-After=syslog.target network.target
-After=opennebula.service
-AssertFileNotEmpty=/var/lib/one/.one/onegate_auth
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-gate -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/ruby /usr/lib64/one/onegate/onegate-server.rb
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-hem.service b/app-emulation/opennebula/files/systemd/opennebula-hem.service
deleted file mode 100644
index e59544f..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-hem.service
+++ /dev/null
@@ -1,18 +0,0 @@
-[Unit]
-Description=OpenNebula Hook Execution Service
-After=syslog.target network.target
-After=opennebula.service
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-hem -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/ruby /usr/lib64/one/onehem/onehem-server.rb
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-novnc.service b/app-emulation/opennebula/files/systemd/opennebula-novnc.service
deleted file mode 100644
index e8026ed..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-novnc.service
+++ /dev/null
@@ -1,18 +0,0 @@
-[Unit]
-Description=OpenNebula noVNC Server
-After=syslog.target network.target
-
-[Service]
-Type=forking
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-novnc -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/novnc-server start
-PIDFile=/run/lock/one/.novnc.lock
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-scheduler.service b/app-emulation/opennebula/files/systemd/opennebula-scheduler.service
deleted file mode 100644
index 6e0b3b9..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-scheduler.service
+++ /dev/null
@@ -1,19 +0,0 @@
-[Unit]
-Description=OpenNebula Cloud Scheduler Daemon
-After=syslog.target network.target remote-fs.target
-After=opennebula.service
-AssertFileNotEmpty=/var/lib/one/.one/one_auth
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-scheduler -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/mm_sched
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula-sunstone.service b/app-emulation/opennebula/files/systemd/opennebula-sunstone.service
deleted file mode 100644
index 1db2649..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula-sunstone.service
+++ /dev/null
@@ -1,20 +0,0 @@
-[Unit]
-Description=OpenNebula Web UI Server
-After=syslog.target network.target
-After=opennebula.service
-Wants=opennebula-novnc.service
-AssertFileNotEmpty=/var/lib/one/.one/sunstone_auth
-
-[Service]
-Type=simple
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula-sunstone -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/ruby /usr/lib64/one/sunstone/sunstone-server.rb
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/systemd/opennebula.service b/app-emulation/opennebula/files/systemd/opennebula.service
deleted file mode 100644
index 68eaac9..0000000
--- a/app-emulation/opennebula/files/systemd/opennebula.service
+++ /dev/null
@@ -1,21 +0,0 @@
-[Unit]
-Description=OpenNebula Cloud Controller Daemon
-After=syslog.target network.target remote-fs.target
-After=mariadb.service mysqld.service
-Wants=opennebula-scheduler.service opennebula-hem.service
-
-[Service]
-Type=notify
-Group=oneadmin
-User=oneadmin
-ExecStartPre=-/usr/bin/logrotate -f /etc/logrotate.d/opennebula -s /var/lib/one/.logrotate.status
-ExecStart=/usr/bin/oned -f
-ExecStopPost=/usr/share/one/follower_cleanup
-PIDFile=/run/lock/one/one
-StartLimitInterval=60
-StartLimitBurst=3
-Restart=on-failure
-RestartSec=5
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-emulation/opennebula/files/tmpfiles.d/opennebula-flow.conf b/app-emulation/opennebula/files/tmpfiles.d/opennebula-flow.conf
deleted file mode 100644
index 3d93976..0000000
--- a/app-emulation/opennebula/files/tmpfiles.d/opennebula-flow.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-d /run/lock/one 0755 oneadmin oneadmin -
-d /run/one 0755 oneadmin oneadmin -
diff --git a/app-emulation/opennebula/files/tmpfiles.d/opennebula-gate.conf b/app-emulation/opennebula/files/tmpfiles.d/opennebula-gate.conf
deleted file mode 100644
index 3d93976..0000000
--- a/app-emulation/opennebula/files/tmpfiles.d/opennebula-gate.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-d /run/lock/one 0755 oneadmin oneadmin -
-d /run/one 0755 oneadmin oneadmin -
diff --git a/app-emulation/opennebula/files/tmpfiles.d/opennebula-node.conf b/app-emulation/opennebula/files/tmpfiles.d/opennebula-node.conf
deleted file mode 100644
index d00686b..0000000
--- a/app-emulation/opennebula/files/tmpfiles.d/opennebula-node.conf
+++ /dev/null
@@ -1 +0,0 @@
-x /var/tmp/one/*
diff --git a/app-emulation/opennebula/files/tmpfiles.d/opennebula-sunstone.conf b/app-emulation/opennebula/files/tmpfiles.d/opennebula-sunstone.conf
deleted file mode 100644
index 3d93976..0000000
--- a/app-emulation/opennebula/files/tmpfiles.d/opennebula-sunstone.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-d /run/lock/one 0755 oneadmin oneadmin -
-d /run/one 0755 oneadmin oneadmin -
diff --git a/app-emulation/opennebula/files/tmpfiles.d/opennebula.conf b/app-emulation/opennebula/files/tmpfiles.d/opennebula.conf
deleted file mode 100644
index 3d93976..0000000
--- a/app-emulation/opennebula/files/tmpfiles.d/opennebula.conf
+++ /dev/null
@@ -1,2 +0,0 @@
-d /run/lock/one 0755 oneadmin oneadmin -
-d /run/one 0755 oneadmin oneadmin -
diff --git a/app-emulation/opennebula/metadata.xml b/app-emulation/opennebula/metadata.xml
deleted file mode 100644
index aed7391..0000000
--- a/app-emulation/opennebula/metadata.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
-<pkgmetadata>
- <herd>opennebula</herd>
- <longdescription>
- Virtual management infrastructure as a service (IaaS) toolkit
- for cloud computing.
-
- Official documentation at
- http://docs.opennebula.org/stable
- </longdescription>
- <use>
- <flag name='qemu'>Enables qemu support.
- </flag>
- <flag name='mysql'>Enables mysql support.
- </flag>
- <flag name='xen'>Enables xen support.
- </flag>
- <flag name='sqlite'>Enables sqlite support.
- </flag>
- <flag name='extras'>Enables additional packages found on
- arch aur opennebula version.
- </flag>
- <flag name='systemd'>Use systemd init system.
- </flag>
- <flag name='docker'>Build docker machine driver.
- </flag>
- <flag name='sunstone'>Build sunstone minified files.
- </flag>
- <flag name='vnc'>Build vnc support for LXD drivers.
- </flag>
- </use>
-</pkgmetadata>
diff --git a/app-emulation/opennebula/opennebula-5.10.1.ebuild b/app-emulation/opennebula/opennebula-5.10.1.ebuild
deleted file mode 100644
index 3e44fa8..0000000
--- a/app-emulation/opennebula/opennebula-5.10.1.ebuild
+++ /dev/null
@@ -1,292 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI=7
-USE_RUBY="ruby24 ruby25 ruby26 ruby27"
-PYTHON_COMPAT=( python2_7 python3_6 )
-
-inherit user eutils multilib ruby-ng systemd rpm python-r1
-
-MY_P="one-release-${PV}"
-P_RPM="${P}-1"
-
-DESCRIPTION="OpenNebula Virtual Infrastructure Engine"
-HOMEPAGE="http://www.opennebula.org/"
-
-IUSE="qemu +mysql xen sqlite +extras systemd docker +sunstone vnc +python"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-LICENSE="Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64"
-SRC_URI="http://downloads.opennebula.org/packages/${P}/${P}.tar.gz -> ${P}.tar.gz"
-#SRC_URI="http://downloads.opennebula.org/packages/${P}/${P}.tar.gz -> ${P}.tar.gz
-# http://downloads.opennebula.io/packages/${P}/centos8/${P_RPM}.tar.gz -> ${P}-centos8.tar.gz"
-
-RDEPEND=">=dev-libs/xmlrpc-c-1.18.02[abyss,cxx,threads]
- dev-lang/ruby
- python? ( ${PYTHON_DEPS}
- >=dev-python/pygobject-2.90.4:3[${PYTHON_USEDEP}] )
- extras? ( dev-libs/openssl
- dev-ruby/libxml
- net-misc/curl
- dev-libs/libxslt
- dev-libs/expat
- dev-ruby/uuidtools
- dev-ruby/amazon-ec2
- dev-ruby/webmock
- dev-ruby/mysql
- dev-ruby/mysql2
- dev-ruby/parse-cron
- dev-ruby/sequel
- dev-ruby/treetop
- dev-ruby/xml-simple
- dev-ruby/zendesk_api
- dev-ruby/ffi-rzmq
- dev-ruby/ffi-rzmq-core
- dev-ruby/rqrcode
- dev-ruby/rqrcode_core
- dev-ruby/chunky_png
- dev-ruby/rotp
- dev-libs/log4cpp )
- mysql? ( virtual/mysql )
- dev-db/sqlite
- net-misc/openssh
- net-fs/nfs-utils
- dev-db/mariadb
- net-libs/zeromq
- || ( app-cdr/cdrkit app-cdr/cdrtools )
- sqlite? ( dev-ruby/sqlite3 )
- qemu? ( app-emulation/libvirt[libvirtd,qemu] )
- xen? ( app-emulation/xen-tools )"
-DEPEND="${RDEPEND}
- >=dev-util/scons-3.0.0
- dev-ruby/nokogiri
- dev-ruby/bundler
- dev-nodejs/grunt-cli
- dev-nodejs/bower
- net-libs/nodejs[npm]
- net-libs/libvncserver
- app-text/ronn
- dev-ruby/builder
- dev-ruby/highline
- dev-ruby/ipaddress:1
- docker? ( dev-go/dep )"
-
-# make sure no eclass is running tests
-RESTRICT="test"
-
-S="${WORKDIR}/${P}"
-
-ONEUSER="oneadmin"
-ONEGROUP="oneadmin"
-
-PATCHES=(
- "${FILESDIR}/patches/fix_kvm_emulator.patch"
- "${FILESDIR}/patches/install.sh.patch"
-)
-
-pkg_pretend() {
- if use docker; then
- elog "Opennebula releases needs to build docker without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
-}
-
-pkg_setup () {
- enewgroup ${ONEGROUP}
- enewuser ${ONEUSER} -1 /bin/bash /var/lib/one ${ONEGROUP}
-}
-
-src_unpack() {
- default
- #rm -rf ${WORKDIR}/${P_RPM}/src
- #rpm_unpack $(find . -name "*.rpm")
-}
-
-src_prepare() {
- # install missing source file
- cp "${FILESDIR}"/${P}/parsers/* "${S}"/src/parsers/ || die "copy parsers files failed"
-
- # set correct lib path
- use docker && make -C src/docker_machine/src/docker_machine vendor
- for f in $(grep -rlI "/usr/lib/one" .); do sed -i -e "s/\/usr\/lib\/one/\/usr\/$(get_libdir)\/one/g" $f; done || die "correct lib dir failed"
-
- # grunt-sass and node-sass versions
- #sed -i -e 's|1.2.1|2.1.0|' -e 's|3.10.1|4.13.0|' src/sunstone/public/package.json || die "sed failed"
-
- # As we install from the github release sources we need to build sunstone as well.
- # To do that we need the npm environment set up
- # https://docs.opennebula.org/5.4/integration/references/sunstone_dev.html#sunstone-dev
- #pushd src/sunstone/public/ >/dev/null
- #./build.sh -d
- #popd >/dev/null
-
- eapply_user
-}
-
-src_configure() {
- :
-}
-
-src_compile() {
- ###########################################################################
- ## ##
- ## It is highly recommended that you read the documentation and tweak ##
- ## the PKGBUILD accordingly: ##
- ## http://docs.opennebula.org/stable/integration/references/compile.html ##
- ## ##
- ###########################################################################
- local myconf
- myconf+="parsers=yes new_xmlrpc=yes "
- use extras && myconf+="new_xmlrpc=yes "
- use mysql && myconf+="mysql=yes " || myconf+="mysql=no "
- use docker && myconf+="docker_machine=yes "
- use systemd && myconf+="systemd=yes "
- use vnc && myconf+="svncterm=yes "
- python3 $(which scons) \
- ${myconf} \
- $(sed -r 's/.*(-j\s*|--jobs=)([0-9]+).*/-j\2/' <<< ${MAKEOPTS}) \
- || die "building ${PN} failed"
-
- if use !sunstone; then
- rm -rf ${S}/src/sunstone
- fi
-}
-
-src_install() {
- # Prepare installation
- keepdir /var/{lib,run}/${PN} || die "keepdir failed"
-
- dodir /usr/$(get_libdir)/one
- dodir /var/log/one
- dodir /var/lib/one
- dodir /var/tmp/one
- dodir /var/lib/one
- dodir /var/lib/one/vms
- dodir /usr/share/one
- dodir /etc/tmpfiles.d
-
- # Installing Opennebula
- DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} || die "install opennebula core failed"
- use extras && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -c || die "install opennebula client tools failed"
- use docker && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -e -k || die "install docker machine failed"
-
- pushd "${T}" >/dev/null
- # Clean files
- rm -rf etc/{logrotate.d,sudoers.d} lib/ var/{lock,run}
-
- # setup etc
- insinto /etc
- doins -r etc/one
- rm -rf etc/one
-
- insinto /etc/one
- insopts -m 0640
- doins "${FILESDIR}/one_auth"
-
- insinto /etc/tmpfiles.d
- insopts -m 0644
- doins "${FILESDIR}"/tmpfiles.d/*
-
- insinto /etc/logrotate.d
- doins "${FILESDIR}"/logrotate/*
-
- insinto /etc/sudoers.d
- doins "${FILESDIR}"/sudoers/*
-
- # set binaries executable
- into /usr
- dobin usr/bin/*
-
- cp -a usr/$(get_libdir)/one/* "${ED}"/usr/$(get_libdir)/one/
- cp -a usr/share/one/* "${ED}"/usr/share/one/
- cp -a var/lib/one/* "${ED}"/var/lib/one/
- rm -rf usr/bin usr/$(get_libdir)/one usr/share/one var/lib/one
-
- # add documentation
- dodoc usr/share/docs/one/*
- rm -rf usr/share/docs
-
- # install remaining files
- insinto /usr/share/man/man1
- doins -r usr/share/man/man1/
-
- # set correct owner
- fowners -R ${ONEUSER}:${ONEGROUP} /etc/one /usr/$(get_libdir)/one /usr/share/one /var/lib/{one,opennebula} /var/log/one /var/tmp/one
-
- # install daemon files
- if use systemd; then
- systemd_dounit "${FILESDIR}"/systemd/*.service
- else
- doenvd "${FILESDIR}/openrc/99one"
- newinitd "${FILESDIR}/openrc/opennebula.initd" opennebula
- newinitd "${FILESDIR}/openrc/sunstone-server.initd" sunstone-server
- newinitd "${FILESDIR}/openrc/oneflow-server.initd" oneflow-server
- newconfd "${FILESDIR}/openrc/opennebula.confd" opennebula
- newconfd "${FILESDIR}/openrc/sunstone-server.confd" sunstone-server
- newconfd "${FILESDIR}/openrc/oneflow-server.confd" oneflow-server
- fi
-
- popd >/dev/null
-
-}
-
-pkg_postinst() {
-
- #chown -R oneadmin:oneadmin ${ROOT}var/{lock,lib,log,run,tmp}/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/share/one
- #chown -R oneadmin:oneadmin ${ROOT}etc/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/$(get_libdir)/one
-
- local onedir="${EROOT}var/lib/one"
- if [ ! -d "${onedir}/.ssh" ] ; then
- #einfo "Generating ssh-key..."
- #umask 0027 || die "setting umask failed"
- #mkdir "${onedir}/.ssh" || die "creating ssh directory failed"
- #ssh-keygen -q -t rsa -N "" -f "${onedir}/.ssh/id_rsa" || die "ssh-keygen failed"
- #cat > "${onedir}/.ssh/config" <<EOF
-#UserKnownHostsFile /dev/null
-#Host *
-# StrictHostKeyChecking no
-#EOF
- #cat "${onedir}/.ssh/id_rsa.pub" >> "${onedir}/.ssh/authorized_keys" || die "adding key failed"
- #chown -R ${ONEUSER}:${ONEGROUP} "${onedir}/.ssh" || die "changing owner failed"
- elog "Create directory ${onedir}/.ssh with umask 0027."
- elog "Then generate ssh key using proper cypher algorithm (at least rsa)."
- elog "Add public key to ${ONEUSER} authorized_keys:"
- elog "cat ${onedir}/.ssh/id_rsa.pub >> ${onedir}/.ssh/authorized_keys"
- elog "${ONEUSER} ssh config for any host with"
- elog "StrictHostKeyChecking no"
- elog "and"
- elog "UserKnownHostsFile /dev/null"
- elog "In the end set correct owner to ${ONEUSER}:"
- elog "chown -R ${ONEUSER}:${ONEGROUP} ${onedir}/.ssh"
- fi
-
- if use qemu ; then
- elog "Make sure that the user ${ONEUSER} has access to the libvirt control socket"
- elog " /var/run/libvirt/libvirt-sock"
- elog "You can easily check this by executing the following command as ${ONEUSER} user"
- elog " virsh -c qemu:///system nodeinfo"
- elog "If not using using policykit in libvirt, the file you should take a look at is:"
- elog " /etc/libvirt/libvirtd.conf (look for the unix_sock_*_perms parameters)"
- elog "Failure to do so may lead to nodes hanging in PENDING state forever without further notice."
- echo ""
- elog "Should a node hang in PENDING state even with correct permissions, try the following to get more information."
- elog "In /tmp/one-im execute the following command for the biggest one_im-* file:"
- elog " ruby -wd one_im-???"
- echo ""
- elog "OpenNebula doesn't allow you to specify the disc format."
- elog "Unfortunately the default in libvirt is not to guess and"
- elog "it therefores assumes a 'raw' format when using qemu/kvm."
- elog "Set 'allow_disk_format_probing = 0' in /etc/libvirt/qemu.conf"
- elog "to work around this until OpenNebula fixes it."
- fi
-
- elog "If you wish to use the sunstone server, please issue the command"
- #elog "/usr/share/one/install_gems as oneadmin user"
- elog "gem install sequel thin json rack sinatra builder treetop zendesk_api mysql parse-cron"
-
-}
-
diff --git a/app-emulation/opennebula/opennebula-5.10.4.ebuild b/app-emulation/opennebula/opennebula-5.10.4.ebuild
deleted file mode 100644
index 7d8d079..0000000
--- a/app-emulation/opennebula/opennebula-5.10.4.ebuild
+++ /dev/null
@@ -1,306 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI=7
-USE_RUBY="ruby24 ruby25 ruby26 ruby27"
-PYTHON_COMPAT=( python2_7 python3_6 )
-
-inherit user eutils multilib ruby-ng systemd rpm python-r1
-
-MY_P="one-release-${PV}"
-P_RPM="${P}-1"
-
-DESCRIPTION="OpenNebula Virtual Infrastructure Engine"
-HOMEPAGE="http://www.opennebula.org/"
-
-IUSE="qemu +mysql xen sqlite +extras systemd docker +sunstone vnc +python +doc"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-LICENSE="Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64"
-SRC_URI="https://github.com/OpenNebula/one/archive/release-${PV}.tar.gz -> ${P}.tar.gz"
-
-RDEPEND=">=dev-libs/xmlrpc-c-1.18.02[abyss,cxx,threads]
- dev-lang/ruby
- python? ( ${PYTHON_DEPS}
- >=dev-python/pygobject-2.90.4:3[${PYTHON_USEDEP}] )
- extras? ( dev-libs/openssl
- dev-ruby/libxml
- net-misc/curl
- dev-libs/libxslt
- dev-libs/expat
- dev-ruby/uuidtools
- dev-ruby/amazon-ec2
- dev-ruby/webmock
- dev-ruby/mysql
- dev-ruby/mysql2
- dev-ruby/parse-cron
- dev-ruby/sequel
- dev-ruby/treetop
- dev-ruby/xml-simple
- dev-ruby/zendesk_api
- dev-ruby/ffi-rzmq
- dev-ruby/ffi-rzmq-core
- dev-ruby/rqrcode
- dev-ruby/rqrcode_core
- dev-ruby/chunky_png
- dev-ruby/rotp
- dev-libs/log4cpp )
- mysql? ( virtual/mysql )
- dev-db/sqlite
- net-misc/openssh
- net-fs/nfs-utils
- dev-db/mariadb
- net-libs/zeromq
- || ( app-cdr/cdrkit app-cdr/cdrtools )
- sqlite? ( dev-ruby/sqlite3 )
- qemu? ( app-emulation/libvirt[libvirtd,qemu] )
- xen? ( app-emulation/xen-tools )"
-DEPEND="${RDEPEND}
- dev-lang/ruby:2.5
- >=dev-util/scons-3.0.0
- dev-ruby/nokogiri
- dev-ruby/bundler
- dev-nodejs/grunt
- dev-nodejs/bower
- dev-nodejs/ini
- dev-nodejs/braces
- net-libs/nodejs[npm]
- net-libs/libvncserver
- app-text/ronn
- dev-ruby/builder
- dev-ruby/highline
- dev-ruby/ipaddress:1
- docker? ( dev-go/dep )"
-
-# make sure no eclass is running tests
-RESTRICT="test"
-
-S="${WORKDIR}/${MY_P}"
-
-ONEUSER="oneadmin"
-ONEGROUP="oneadmin"
-
-PATCHES=(
- "${FILESDIR}/patches/fix_kvm_emulator.patch"
- "${FILESDIR}/patches/install.sh.patch"
-)
-
-test_netsandbox() {
- if use sunstone; then
- elog "Opennebula hotfix releases needs to build sunstone without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
- if use docker; then
- elog "Opennebula releases needs to build docker without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
-}
-
-pkg_pretend() {
- test_netsandbox
-}
-
-pkg_setup () {
- test_netsandbox
- enewgroup ${ONEGROUP}
- enewuser ${ONEUSER} -1 /bin/bash /var/lib/one ${ONEGROUP}
-}
-
-src_unpack() {
- default
-}
-
-src_prepare() {
- # install missing source file
- #cp "${FILESDIR}"/${P}/parsers/* "${S}"/src/parsers/ || die "copy parsers files failed"
-
- # set correct lib path
- use docker && make -C src/docker_machine/src/docker_machine vendor
- for f in $(grep -rlI "/usr/lib/one" .); do sed -i -e "s/\/usr\/lib\/one/\/usr\/$(get_libdir)\/one/g" $f; done || die "correct lib dir failed"
-
- # grunt-sass and node-sass versions
- sed -i -e 's|1.2.1|2.1.0|' -e 's|3.10.1|4.13.0|' src/sunstone/public/package.json || die "sed failed"
-
- # As we install from the github release sources we need to build sunstone as well.
- # To do that we need the npm environment set up
- # https://docs.opennebula.org/5.4/integration/references/sunstone_dev.html#sunstone-dev
- pushd src/sunstone/public/ >/dev/null
- ./build.sh -d || die "Install required dependencies for npm and bower failed."
- #export PATH=$PATH:$PWD/node_modules/.bin
- #./build.sh || die "Prepare minified files failed."
- popd >/dev/null
-
- eapply_user
-}
-
-src_configure() {
- :
-}
-
-src_compile() {
- # manual pages
- if use doc; then
- pushd ${S}/share/man >/dev/null
- ./build.sh
- popd >/dev/null
- fi
-
- ###########################################################################
- ## ##
- ## It is highly recommended that you read the documentation and tweak ##
- ## the PKGBUILD accordingly: ##
- ## http://docs.opennebula.org/stable/integration/references/compile.html ##
- ## ##
- ###########################################################################
- local myconf
- myconf+="parsers=yes new_xmlrpc=yes "
- use extras && myconf+="new_xmlrpc=yes "
- use mysql && myconf+="mysql=yes " || myconf+="mysql=no "
- use sunstone && myconf+="sunstone=yes "
- use docker && myconf+="docker_machine=yes "
- use systemd && myconf+="systemd=yes "
- use vnc && myconf+="svncterm=yes "
- python3 $(which scons) \
- ${myconf} \
- $(sed -r 's/.*(-j\s*|--jobs=)([0-9]+).*/-j\2/' <<< ${MAKEOPTS}) \
- || die "building ${PN} failed"
-}
-
-src_install() {
- # Prepare installation
- keepdir /var/{lib,run}/${PN} || die "keepdir failed"
-
- dodir /usr/$(get_libdir)/one
- dodir /var/log/one
- dodir /var/lib/one
- dodir /var/tmp/one
- dodir /var/lib/one
- dodir /var/lib/one/vms
- dodir /usr/share/one
- dodir /etc/tmpfiles.d
-
- # Installing Opennebula
- DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} || die "install opennebula core failed"
- use extras && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -c || die "install opennebula client tools failed"
- use docker && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -e -k || die "install docker machine failed"
-
- pushd "${T}" >/dev/null
- # Clean files
- rm -rf etc/{logrotate.d,sudoers.d} lib/ var/{lock,run}
-
- # setup etc
- insinto /etc
- doins -r etc/one
- rm -rf etc/one
-
- insinto /etc/one
- insopts -m 0640
- doins "${FILESDIR}/one_auth"
-
- insinto /etc/tmpfiles.d
- insopts -m 0644
- doins "${FILESDIR}"/tmpfiles.d/*
-
- insinto /etc/logrotate.d
- doins "${FILESDIR}"/logrotate/*
-
- insinto /etc/sudoers.d
- doins "${FILESDIR}"/sudoers/*
-
- # set binaries executable
- into /usr
- dobin usr/bin/*
-
- cp -a usr/$(get_libdir)/one/* "${ED}"/usr/$(get_libdir)/one/
- cp -a usr/share/one/* "${ED}"/usr/share/one/
- cp -a var/lib/one/* "${ED}"/var/lib/one/
- rm -rf usr/bin usr/$(get_libdir)/one usr/share/one var/lib/one
-
- # add documentation
- dodoc usr/share/docs/one/*
- rm -rf usr/share/docs
-
- # install remaining files
- insinto /usr/share/man
- doins -r usr/share/man/man1/
-
- # set correct owner
- fowners -R ${ONEUSER}:${ONEGROUP} /etc/one /usr/$(get_libdir)/one /usr/share/one /var/lib/{one,opennebula} /var/log/one /var/tmp/one
-
- # install daemon files
- if use systemd; then
- systemd_dounit "${FILESDIR}"/systemd/*.service
- else
- doenvd "${FILESDIR}/openrc/99one"
- newinitd "${FILESDIR}/openrc/opennebula.initd" opennebula
- newinitd "${FILESDIR}/openrc/sunstone-server.initd" sunstone-server
- newinitd "${FILESDIR}/openrc/oneflow-server.initd" oneflow-server
- newconfd "${FILESDIR}/openrc/opennebula.confd" opennebula
- newconfd "${FILESDIR}/openrc/sunstone-server.confd" sunstone-server
- newconfd "${FILESDIR}/openrc/oneflow-server.confd" oneflow-server
- fi
-
- popd >/dev/null
-
-}
-
-pkg_postinst() {
-
- #chown -R oneadmin:oneadmin ${ROOT}var/{lock,lib,log,run,tmp}/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/share/one
- #chown -R oneadmin:oneadmin ${ROOT}etc/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/$(get_libdir)/one
-
- local onedir="${EROOT}var/lib/one"
- if [ ! -d "${onedir}/.ssh" ] ; then
- #einfo "Generating ssh-key..."
- #umask 0027 || die "setting umask failed"
- #mkdir "${onedir}/.ssh" || die "creating ssh directory failed"
- #ssh-keygen -q -t rsa -N "" -f "${onedir}/.ssh/id_rsa" || die "ssh-keygen failed"
- #cat > "${onedir}/.ssh/config" <<EOF
-#UserKnownHostsFile /dev/null
-#Host *
-# StrictHostKeyChecking no
-#EOF
- #cat "${onedir}/.ssh/id_rsa.pub" >> "${onedir}/.ssh/authorized_keys" || die "adding key failed"
- #chown -R ${ONEUSER}:${ONEGROUP} "${onedir}/.ssh" || die "changing owner failed"
- elog "Create directory ${onedir}/.ssh with umask 0027."
- elog "Then generate ssh key using proper cypher algorithm (at least rsa)."
- elog "Add public key to ${ONEUSER} authorized_keys:"
- elog "cat ${onedir}/.ssh/id_rsa.pub >> ${onedir}/.ssh/authorized_keys"
- elog "${ONEUSER} ssh config for any host with"
- elog "StrictHostKeyChecking no"
- elog "and"
- elog "UserKnownHostsFile /dev/null"
- elog "In the end set correct owner to ${ONEUSER}:"
- elog "chown -R ${ONEUSER}:${ONEGROUP} ${onedir}/.ssh"
- fi
-
- if use qemu ; then
- elog "Make sure that the user ${ONEUSER} has access to the libvirt control socket"
- elog " /var/run/libvirt/libvirt-sock"
- elog "You can easily check this by executing the following command as ${ONEUSER} user"
- elog " virsh -c qemu:///system nodeinfo"
- elog "If not using using policykit in libvirt, the file you should take a look at is:"
- elog " /etc/libvirt/libvirtd.conf (look for the unix_sock_*_perms parameters)"
- elog "Failure to do so may lead to nodes hanging in PENDING state forever without further notice."
- echo ""
- elog "Should a node hang in PENDING state even with correct permissions, try the following to get more information."
- elog "In /tmp/one-im execute the following command for the biggest one_im-* file:"
- elog " ruby -wd one_im-???"
- echo ""
- elog "OpenNebula doesn't allow you to specify the disc format."
- elog "Unfortunately the default in libvirt is not to guess and"
- elog "it therefores assumes a 'raw' format when using qemu/kvm."
- elog "Set 'allow_disk_format_probing = 0' in /etc/libvirt/qemu.conf"
- elog "to work around this until OpenNebula fixes it."
- fi
-
- elog "If you wish to use the sunstone server, please issue the command"
- #elog "/usr/share/one/install_gems as oneadmin user"
- elog "gem install sequel thin json rack sinatra builder treetop zendesk_api mysql parse-cron"
-
-}
-
diff --git a/app-emulation/opennebula/opennebula-5.10.5.ebuild b/app-emulation/opennebula/opennebula-5.10.5.ebuild
deleted file mode 100644
index f5fdf78..0000000
--- a/app-emulation/opennebula/opennebula-5.10.5.ebuild
+++ /dev/null
@@ -1,314 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI=7
-USE_RUBY="ruby24 ruby25 ruby26 ruby27"
-PYTHON_COMPAT=( python2_7 python3_6 )
-
-inherit user eutils multilib ruby-ng systemd rpm python-r1
-
-MY_P="one-release-${PV}"
-P_RPM="${P}-1"
-
-DESCRIPTION="OpenNebula Virtual Infrastructure Engine"
-HOMEPAGE="http://www.opennebula.org/"
-
-IUSE="qemu +mysql xen sqlite +extras systemd docker +sunstone vnc +python +doc"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-LICENSE="Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64"
-SRC_URI="https://github.com/OpenNebula/one/archive/release-${PV}.tar.gz -> ${P}.tar.gz"
-
-RDEPEND=">=dev-libs/xmlrpc-c-1.18.02[abyss,cxx,threads]
- dev-lang/ruby
- python? ( ${PYTHON_DEPS}
- >=dev-python/pygobject-2.90.4:3[${PYTHON_USEDEP}] )
- extras? ( dev-libs/openssl
- dev-ruby/xmlparser
- net-misc/curl
- dev-libs/libxslt
- dev-libs/expat
- dev-ruby/uuidtools
- dev-ruby/amazon-ec2
- dev-ruby/webmock
- dev-ruby/mysql
- dev-ruby/mysql2
- dev-ruby/parse-cron
- dev-ruby/treetop
- dev-ruby/xml-simple
- dev-ruby/zendesk_api
- dev-ruby/ffi-rzmq
- dev-ruby/ffi-rzmq-core
- dev-ruby/rqrcode
- dev-ruby/rqrcode_core
- dev-ruby/chunky_png
- dev-ruby/rotp
- dev-ruby/rake
- dev-ruby/ruby-net-ldap
- dev-ruby/curb
- dev-ruby/rubygems
- dev-libs/log4cpp )
- mysql? ( virtual/mysql )
- dev-db/sqlite
- net-misc/openssh
- net-fs/nfs-utils
- dev-db/mariadb
- net-libs/zeromq
- dev-ruby/json
- dev-ruby/sequel
- dev-ruby/sinatra
- dev-ruby/thin
- dev-ruby/nokogiri
- sunstone? ( dev-ruby/rack )
- || ( app-cdr/cdrkit app-cdr/cdrtools )
- sqlite? ( dev-ruby/sqlite3 )
- qemu? ( app-emulation/libvirt[libvirtd,qemu] )
- xen? ( app-emulation/xen-tools )"
-DEPEND="${RDEPEND}
- dev-lang/ruby:2.5
- >=dev-util/scons-3.0.0
- dev-ruby/bundler
- dev-nodejs/grunt
- dev-nodejs/bower
- dev-nodejs/ini
- dev-nodejs/braces
- net-libs/nodejs[npm]
- net-libs/libvncserver
- app-text/ronn
- dev-ruby/builder
- dev-ruby/highline
- dev-ruby/ipaddress:1
- docker? ( dev-go/dep )"
-
-# make sure no eclass is running tests
-RESTRICT="test"
-
-S="${WORKDIR}/${MY_P}"
-
-ONEUSER="oneadmin"
-ONEGROUP="oneadmin"
-
-PATCHES=(
- "${FILESDIR}/patches/fix_kvm_emulator.patch"
- "${FILESDIR}/patches/install.sh.patch"
-)
-
-test_netsandbox() {
- if use sunstone; then
- elog "Opennebula hotfix releases needs to build sunstone without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
- if use docker; then
- elog "Opennebula releases needs to build docker without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
-}
-
-pkg_pretend() {
- test_netsandbox
-}
-
-pkg_setup () {
- test_netsandbox
- enewgroup ${ONEGROUP}
- enewuser ${ONEUSER} -1 /bin/bash /var/lib/one ${ONEGROUP}
-}
-
-src_unpack() {
- default
-}
-
-src_prepare() {
- # install missing source file
- #cp "${FILESDIR}"/${P}/parsers/* "${S}"/src/parsers/ || die "copy parsers files failed"
-
- # set correct lib path
- use docker && make -C src/docker_machine/src/docker_machine vendor
- for f in $(grep -rlI "/usr/lib/one" .); do sed -i -e "s/\/usr\/lib\/one/\/usr\/$(get_libdir)\/one/g" $f; done || die "correct lib dir failed"
-
- # grunt-sass and node-sass versions
- sed -i -e 's|1.2.1|2.1.0|' -e 's|3.10.1|4.13.0|' src/sunstone/public/package.json || die "sed failed"
-
- # As we install from the github release sources we need to build sunstone as well.
- # To do that we need the npm environment set up
- # https://docs.opennebula.org/5.4/integration/references/sunstone_dev.html#sunstone-dev
- pushd src/sunstone/public/ >/dev/null
- ./build.sh -d || die "Install required dependencies for npm and bower failed."
- #export PATH=$PATH:$PWD/node_modules/.bin
- #./build.sh || die "Prepare minified files failed."
- popd >/dev/null
-
- eapply_user
-}
-
-src_configure() {
- :
-}
-
-src_compile() {
- # manual pages
- if use doc; then
- pushd ${S}/share/man >/dev/null
- ./build.sh
- popd >/dev/null
- fi
-
- ###########################################################################
- ## ##
- ## It is highly recommended that you read the documentation and tweak ##
- ## the PKGBUILD accordingly: ##
- ## http://docs.opennebula.org/stable/integration/references/compile.html ##
- ## ##
- ###########################################################################
- local myconf
- myconf+="parsers=yes new_xmlrpc=yes "
- use extras && myconf+="new_xmlrpc=yes "
- use mysql && myconf+="mysql=yes " || myconf+="mysql=no "
- use sunstone && myconf+="sunstone=yes "
- use docker && myconf+="docker_machine=yes "
- use systemd && myconf+="systemd=yes "
- use vnc && myconf+="svncterm=yes "
- python3 $(which scons) \
- ${myconf} \
- $(sed -r 's/.*(-j\s*|--jobs=)([0-9]+).*/-j\2/' <<< ${MAKEOPTS}) \
- || die "building ${PN} failed"
-}
-
-src_install() {
- # Prepare installation
- keepdir /var/{lib,run}/${PN} || die "keepdir failed"
-
- dodir /usr/$(get_libdir)/one
- dodir /var/log/one
- dodir /var/lib/one
- dodir /var/tmp/one
- dodir /var/lib/one
- dodir /var/lib/one/vms
- dodir /usr/share/one
- dodir /etc/tmpfiles.d
-
- # Installing Opennebula
- DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} || die "install opennebula core failed"
- use extras && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -c || die "install opennebula client tools failed"
- use docker && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -e -k || die "install docker machine failed"
-
- pushd "${T}" >/dev/null
- # Clean files
- rm -rf etc/{logrotate.d,sudoers.d} lib/ var/{lock,run}
-
- # setup etc
- insinto /etc
- doins -r etc/one
- rm -rf etc/one
-
- insinto /etc/one
- insopts -m 0640
- doins "${FILESDIR}/one_auth"
-
- insinto /etc/tmpfiles.d
- insopts -m 0644
- doins "${FILESDIR}"/tmpfiles.d/*
-
- insinto /etc/logrotate.d
- doins "${FILESDIR}"/logrotate/*
-
- insinto /etc/sudoers.d
- doins "${FILESDIR}"/sudoers/*
-
- # set binaries executable
- into /usr
- dobin usr/bin/*
-
- cp -a usr/$(get_libdir)/one/* "${ED}"/usr/$(get_libdir)/one/
- cp -a usr/share/one/* "${ED}"/usr/share/one/
- cp -a var/lib/one/* "${ED}"/var/lib/one/
- rm -rf usr/bin usr/$(get_libdir)/one usr/share/one var/lib/one
-
- # add documentation
- dodoc usr/share/docs/one/*
- rm -rf usr/share/docs
-
- # install remaining files
- insinto /usr/share/man
- doins -r usr/share/man/man1/
-
- # set correct owner
- fowners -R ${ONEUSER}:${ONEGROUP} /etc/one /usr/$(get_libdir)/one /usr/share/one /var/lib/{one,opennebula} /var/log/one /var/tmp/one
-
- # install daemon files
- if use systemd; then
- systemd_dounit "${FILESDIR}"/systemd/*.service
- else
- doenvd "${FILESDIR}/openrc/99one"
- newinitd "${FILESDIR}/openrc/opennebula.initd" opennebula
- newinitd "${FILESDIR}/openrc/sunstone-server.initd" sunstone-server
- newinitd "${FILESDIR}/openrc/oneflow-server.initd" oneflow-server
- newconfd "${FILESDIR}/openrc/opennebula.confd" opennebula
- newconfd "${FILESDIR}/openrc/sunstone-server.confd" sunstone-server
- newconfd "${FILESDIR}/openrc/oneflow-server.confd" oneflow-server
- fi
-
- popd >/dev/null
-
-}
-
-pkg_postinst() {
-
- #chown -R oneadmin:oneadmin ${ROOT}var/{lock,lib,log,run,tmp}/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/share/one
- #chown -R oneadmin:oneadmin ${ROOT}etc/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/$(get_libdir)/one
-
- local onedir="${EROOT}var/lib/one"
- if [ ! -d "${onedir}/.ssh" ] ; then
- #einfo "Generating ssh-key..."
- #umask 0027 || die "setting umask failed"
- #mkdir "${onedir}/.ssh" || die "creating ssh directory failed"
- #ssh-keygen -q -t rsa -N "" -f "${onedir}/.ssh/id_rsa" || die "ssh-keygen failed"
- #cat > "${onedir}/.ssh/config" <<EOF
-#UserKnownHostsFile /dev/null
-#Host *
-# StrictHostKeyChecking no
-#EOF
- #cat "${onedir}/.ssh/id_rsa.pub" >> "${onedir}/.ssh/authorized_keys" || die "adding key failed"
- #chown -R ${ONEUSER}:${ONEGROUP} "${onedir}/.ssh" || die "changing owner failed"
- elog "Create directory ${onedir}/.ssh with umask 0027."
- elog "Then generate ssh key using proper cypher algorithm (at least rsa)."
- elog "Add public key to ${ONEUSER} authorized_keys:"
- elog "cat ${onedir}/.ssh/id_rsa.pub >> ${onedir}/.ssh/authorized_keys"
- elog "${ONEUSER} ssh config for any host with"
- elog "StrictHostKeyChecking no"
- elog "and"
- elog "UserKnownHostsFile /dev/null"
- elog "In the end set correct owner to ${ONEUSER}:"
- elog "chown -R ${ONEUSER}:${ONEGROUP} ${onedir}/.ssh"
- fi
-
- if use qemu ; then
- elog "Make sure that the user ${ONEUSER} has access to the libvirt control socket"
- elog " /var/run/libvirt/libvirt-sock"
- elog "You can easily check this by executing the following command as ${ONEUSER} user"
- elog " virsh -c qemu:///system nodeinfo"
- elog "If not using using policykit in libvirt, the file you should take a look at is:"
- elog " /etc/libvirt/libvirtd.conf (look for the unix_sock_*_perms parameters)"
- elog "Failure to do so may lead to nodes hanging in PENDING state forever without further notice."
- echo ""
- elog "Should a node hang in PENDING state even with correct permissions, try the following to get more information."
- elog "In /tmp/one-im execute the following command for the biggest one_im-* file:"
- elog " ruby -wd one_im-???"
- echo ""
- elog "OpenNebula doesn't allow you to specify the disc format."
- elog "Unfortunately the default in libvirt is not to guess and"
- elog "it therefores assumes a 'raw' format when using qemu/kvm."
- elog "Set 'allow_disk_format_probing = 0' in /etc/libvirt/qemu.conf"
- elog "to work around this until OpenNebula fixes it."
- fi
-
- elog "If you wish to use the sunstone server, please issue the command"
- #elog "/usr/share/one/install_gems as oneadmin user"
- elog "gem install sequel thin json rack sinatra builder treetop zendesk_api mysql parse-cron"
-
-}
-
diff --git a/app-emulation/opennebula/opennebula-5.12.0.1.ebuild b/app-emulation/opennebula/opennebula-5.12.0.1.ebuild
deleted file mode 100644
index 5c13e80..0000000
--- a/app-emulation/opennebula/opennebula-5.12.0.1.ebuild
+++ /dev/null
@@ -1,315 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI=7
-USE_RUBY="ruby24 ruby25 ruby26 ruby27"
-PYTHON_COMPAT=( python2_7 python3_6 )
-
-inherit user eutils multilib ruby-ng systemd rpm python-r1
-
-MY_P="one-release-${PV}"
-P_RPM="${P}-1"
-
-DESCRIPTION="OpenNebula Virtual Infrastructure Engine"
-HOMEPAGE="http://www.opennebula.org/"
-
-IUSE="qemu +mysql xen sqlite +extras systemd docker +sunstone vnc +python +doc"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-LICENSE="Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64"
-SRC_URI="https://github.com/OpenNebula/one/archive/release-${PV}.tar.gz -> ${P}.tar.gz"
-
-RDEPEND=">=dev-libs/xmlrpc-c-1.18.02[abyss,cxx,threads]
- dev-lang/ruby
- python? ( ${PYTHON_DEPS}
- >=dev-python/pygobject-2.90.4:3[${PYTHON_USEDEP}] )
- extras? ( dev-libs/openssl
- dev-ruby/xmlparser
- net-misc/curl
- dev-libs/libxslt
- dev-libs/expat
- dev-ruby/uuidtools
- dev-ruby/amazon-ec2
- dev-ruby/webmock
- dev-ruby/mysql
- dev-ruby/mysql2
- dev-ruby/parse-cron
- dev-ruby/treetop
- dev-ruby/xml-simple
- dev-ruby/zendesk_api
- dev-ruby/ffi-rzmq
- dev-ruby/ffi-rzmq-core
- dev-ruby/rqrcode
- dev-ruby/rqrcode_core
- dev-ruby/chunky_png
- dev-ruby/rotp
- dev-ruby/rake
- dev-ruby/ruby-net-ldap
- dev-ruby/curb
- dev-ruby/rubygems
- dev-libs/log4cpp )
- mysql? ( virtual/mysql )
- dev-db/sqlite
- net-misc/openssh
- net-fs/nfs-utils
- dev-db/mariadb
- net-libs/zeromq
- dev-ruby/json
- dev-ruby/sequel
- dev-ruby/sinatra
- dev-ruby/thin
- dev-ruby/nokogiri
- sunstone? ( dev-ruby/rack )
- || ( app-cdr/cdrkit app-cdr/cdrtools )
- sqlite? ( dev-ruby/sqlite3 )
- qemu? ( app-emulation/libvirt[libvirtd,qemu] )
- xen? ( app-emulation/xen-tools )"
-DEPEND="${RDEPEND}
- dev-lang/ruby:2.5
- >=dev-util/scons-3.0.0
- dev-ruby/bundler
- dev-nodejs/grunt
- dev-nodejs/bower
- dev-nodejs/ini
- dev-nodejs/braces
- net-libs/nodejs[npm]
- net-libs/libvncserver
- app-text/ronn
- dev-ruby/builder
- dev-ruby/highline
- dev-ruby/ipaddress:1
- docker? ( dev-go/dep )"
-
-# make sure no eclass is running tests
-RESTRICT="test"
-
-S="${WORKDIR}/${MY_P}"
-
-ONEUSER="oneadmin"
-ONEGROUP="oneadmin"
-
-PATCHES=(
- "${FILESDIR}/patches/install.sh.${PV}.patch"
- "${FILESDIR}/patches/node-sass.${PV}.patch"
- "${FILESDIR}/patches/fix_kvm_emulator.${PV}.patch"
- "${FILESDIR}/patches/package.js.${PV}.patch"
-)
-
-test_netsandbox() {
- if use sunstone; then
- elog "Opennebula hotfix releases needs to build sunstone without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
- if use docker; then
- elog "Opennebula releases needs to build docker without network sandbox restriction."
- has network-sandbox ${FEATURES} && die "Please disable feature network-sandbox: -network-sandbox"
- fi
-}
-
-pkg_pretend() {
- test_netsandbox
-}
-
-pkg_setup () {
- test_netsandbox
- enewgroup ${ONEGROUP}
- enewuser ${ONEUSER} -1 /bin/bash /var/lib/one ${ONEGROUP}
-}
-
-src_unpack() {
- default
-}
-
-src_prepare() {
- default
- eapply_user
- #EPATCH_SOURCE="${FILESDIR}/patches" EPATCH_SUFFIX="patch" EPATCH_FORCE="yes" epatch
-
- # install missing source file
- #cp "${FILESDIR}"/${P}/parsers/* "${S}"/src/parsers/ || die "copy parsers files failed"
-
- # set correct lib path
- use docker && make -C src/docker_machine/src/docker_machine vendor
- for f in $(grep -rlI "/usr/lib/one" .); do sed -i -e "s/\/usr\/lib\/one/\/usr\/$(get_libdir)\/one/g" $f; done || die "correct lib dir failed"
-
- # As we install from the github release sources we need to build sunstone as well.
- # To do that we need the npm environment set up
- # https://docs.opennebula.org/5.4/integration/references/sunstone_dev.html#sunstone-dev
- pushd src/sunstone/public/ >/dev/null
- ./build.sh -d || die "Install required dependencies for npm and bower failed."
- #export PATH=$PATH:$PWD/node_modules/.bin
- #./build.sh || die "Prepare minified files failed."
- popd >/dev/null
-}
-
-src_configure() {
- :
-}
-
-src_compile() {
- # manual pages
- if use doc; then
- pushd ${S}/share/man >/dev/null
- ./build.sh
- popd >/dev/null
- fi
-
- ###########################################################################
- ## ##
- ## It is highly recommended that you read the documentation and tweak ##
- ## the PKGBUILD accordingly: ##
- ## http://docs.opennebula.org/stable/integration/references/compile.html ##
- ## ##
- ###########################################################################
- local myconf
- myconf+="parsers=yes "
- use extras && myconf+="new_xmlrpc=yes "
- use mysql && myconf+="mysql=yes " || myconf+="mysql=no "
- use sunstone && myconf+="sunstone=yes "
- use docker && myconf+="docker_machine=yes "
- use systemd && myconf+="systemd=yes "
- use vnc && myconf+="svncterm=yes "
- python3 $(which scons) \
- ${myconf} \
- $(sed -r 's/.*(-j\s*|--jobs=)([0-9]+).*/-j\2/' <<< ${MAKEOPTS}) \
- || die "building ${PN} failed"
-}
-
-src_install() {
- # Prepare installation
- keepdir /var/{lib,run}/${PN} || die "keepdir failed"
-
- dodir /usr/$(get_libdir)/one
- dodir /var/log/one
- dodir /var/lib/one
- dodir /var/tmp/one
- dodir /var/lib/one
- dodir /var/lib/one/vms
- dodir /usr/share/one
- dodir /etc/tmpfiles.d
-
- # Installing Opennebula
- DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} || die "install opennebula core failed"
- use extras && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -c || die "install opennebula client tools failed"
- use docker && DESTDIR="${T}" ./install.sh -u ${ONEUSER} -g ${ONEGROUP} -e -k || die "install docker machine failed"
-
- pushd "${T}" >/dev/null
- # Clean files
- rm -rf etc/{logrotate.d,sudoers.d} lib/ var/{lock,run}
-
- # setup etc
- insinto /etc
- doins -r etc/one
- rm -rf etc/one
-
- insinto /etc/one
- insopts -m 0640
- doins "${FILESDIR}/one_auth"
-
- insinto /etc/tmpfiles.d
- insopts -m 0644
- doins "${FILESDIR}"/tmpfiles.d/*
-
- insinto /etc/logrotate.d
- doins "${FILESDIR}"/logrotate/*
-
- insinto /etc/sudoers.d
- doins "${FILESDIR}"/sudoers/*
-
- # set binaries executable
- into /usr
- dobin usr/bin/*
-
- cp -a usr/$(get_libdir)/one/* "${ED}"/usr/$(get_libdir)/one/
- cp -a usr/share/one/* "${ED}"/usr/share/one/
- cp -a var/lib/one/* "${ED}"/var/lib/one/
- rm -rf usr/bin usr/$(get_libdir)/one usr/share/one var/lib/one
-
- # add documentation
- dodoc usr/share/docs/one/*
- rm -rf usr/share/docs
-
- # install remaining files
- insinto /usr/share/man
- doins -r usr/share/man/man1/
-
- # set correct owner
- fowners -R ${ONEUSER}:${ONEGROUP} /etc/one /usr/$(get_libdir)/one /usr/share/one /var/lib/{one,opennebula} /var/log/one /var/tmp/one
-
- # install daemon files
- if use systemd; then
- systemd_dounit "${FILESDIR}"/systemd/*.service
- else
- doenvd "${FILESDIR}/openrc/99one"
- newinitd "${FILESDIR}/openrc/opennebula.initd" opennebula
- newinitd "${FILESDIR}/openrc/sunstone-server.initd" sunstone-server
- newinitd "${FILESDIR}/openrc/oneflow-server.initd" oneflow-server
- newconfd "${FILESDIR}/openrc/opennebula.confd" opennebula
- newconfd "${FILESDIR}/openrc/sunstone-server.confd" sunstone-server
- newconfd "${FILESDIR}/openrc/oneflow-server.confd" oneflow-server
- fi
-
- popd >/dev/null
-
-}
-
-pkg_postinst() {
-
- #chown -R oneadmin:oneadmin ${ROOT}var/{lock,lib,log,run,tmp}/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/share/one
- #chown -R oneadmin:oneadmin ${ROOT}etc/one
- #chown -R oneadmin:oneadmin ${ROOT}usr/$(get_libdir)/one
-
- local onedir="${EROOT}var/lib/one"
- if [ ! -d "${onedir}/.ssh" ] ; then
- #einfo "Generating ssh-key..."
- #umask 0027 || die "setting umask failed"
- #mkdir "${onedir}/.ssh" || die "creating ssh directory failed"
- #ssh-keygen -q -t rsa -N "" -f "${onedir}/.ssh/id_rsa" || die "ssh-keygen failed"
- #cat > "${onedir}/.ssh/config" <<EOF
-#UserKnownHostsFile /dev/null
-#Host *
-# StrictHostKeyChecking no
-#EOF
- #cat "${onedir}/.ssh/id_rsa.pub" >> "${onedir}/.ssh/authorized_keys" || die "adding key failed"
- #chown -R ${ONEUSER}:${ONEGROUP} "${onedir}/.ssh" || die "changing owner failed"
- elog "Create directory ${onedir}/.ssh with umask 0027."
- elog "Then generate ssh key using proper cypher algorithm (at least rsa)."
- elog "Add public key to ${ONEUSER} authorized_keys:"
- elog "cat ${onedir}/.ssh/id_rsa.pub >> ${onedir}/.ssh/authorized_keys"
- elog "${ONEUSER} ssh config for any host with"
- elog "StrictHostKeyChecking no"
- elog "and"
- elog "UserKnownHostsFile /dev/null"
- elog "In the end set correct owner to ${ONEUSER}:"
- elog "chown -R ${ONEUSER}:${ONEGROUP} ${onedir}/.ssh"
- fi
-
- if use qemu ; then
- elog "Make sure that the user ${ONEUSER} has access to the libvirt control socket"
- elog " /var/run/libvirt/libvirt-sock"
- elog "You can easily check this by executing the following command as ${ONEUSER} user"
- elog " virsh -c qemu:///system nodeinfo"
- elog "If not using using policykit in libvirt, the file you should take a look at is:"
- elog " /etc/libvirt/libvirtd.conf (look for the unix_sock_*_perms parameters)"
- elog "Failure to do so may lead to nodes hanging in PENDING state forever without further notice."
- echo ""
- elog "Should a node hang in PENDING state even with correct permissions, try the following to get more information."
- elog "In /tmp/one-im execute the following command for the biggest one_im-* file:"
- elog " ruby -wd one_im-???"
- echo ""
- elog "OpenNebula doesn't allow you to specify the disc format."
- elog "Unfortunately the default in libvirt is not to guess and"
- elog "it therefores assumes a 'raw' format when using qemu/kvm."
- elog "Set 'allow_disk_format_probing = 0' in /etc/libvirt/qemu.conf"
- elog "to work around this until OpenNebula fixes it."
- fi
-
- elog "If you wish to use the sunstone server, please issue the command"
- #elog "/usr/share/one/install_gems as oneadmin user"
- elog "gem install sequel thin json rack sinatra builder treetop zendesk_api mysql parse-cron"
-
-}
-
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2021-02-08 10:19 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-02-08 10:19 [gentoo-commits] repo/user/ssnb:master commit in: app-emulation/opennebula/files/openrc/, app-emulation/opennebula/, Samuel Bernardo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox