Compare commits
2206 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2b8eb8deb6 | |||
| 7262f3d0b7 | |||
| 6f80fd0063 | |||
| 7a51b7a019 | |||
| d9eb31000d | |||
| f8589de476 | |||
| f1c61067bc | |||
| 8a5620592b | |||
| 5227e65808 | |||
| c4c6dc19a5 | |||
| 7fc26b1fab | |||
| c0e121abef | |||
| 7db13fdeff | |||
| e68027b464 | |||
| 220b69058c | |||
| 9c3e55787e | |||
| c952e99f3e | |||
| 35322b5d14 | |||
| 6b96807112 | |||
| 57621d1c4e | |||
| e04b2eebc3 | |||
| 02b684b810 | |||
| 76b1acf99d | |||
| 18c120ab9f | |||
| f87dd91b52 | |||
| 4a8a161a43 | |||
| e3dec420a2 | |||
| 1e32311a65 | |||
| 92e5bb88e8 | |||
| 66581d115b | |||
| 4399324955 | |||
| 733f31f90e | |||
| bef2c50b03 | |||
| a96b4412d3 | |||
| bee76fc8d1 | |||
| d9cb1a6319 | |||
| 567d23d856 | |||
| c94a98e15a | |||
| 72e6e87d82 | |||
| 0055d84bd6 | |||
| d17d22139e | |||
| 87b6284275 | |||
| 2c6b974f24 | |||
| 020acc8235 | |||
| a8e0d261b7 | |||
| 6357b9a04f | |||
| 43a58df8a0 | |||
| b7bf316c1a | |||
| 41ee792f95 | |||
| 6c1b6c1704 | |||
| acadaeed3a | |||
| 96bde3df81 | |||
| 5cb70ddbd5 | |||
| b9b9a0465f | |||
| bd269bccaf | |||
| 5f618814f6 | |||
| 43c87e99b0 | |||
| 74a09a6338 | |||
| 2b9c407dc3 | |||
| 59ed222205 | |||
| 2c06043617 | |||
| ef884642e4 | |||
| e449111c33 | |||
| 066e53da55 | |||
| c74b2cb085 | |||
| eec11bfba9 | |||
| d254a5736b | |||
| b655e4aa47 | |||
| 1adec3d8e5 | |||
| db9b7db531 | |||
| 05099e2ae1 | |||
| 77352a2a86 | |||
| ae633292c0 | |||
| d6042cf891 | |||
| 534c63bf57 | |||
| fb29933d3d | |||
| 360c4d1554 | |||
| 4cfa9b11f3 | |||
| 908465b274 | |||
| a7f10d142e | |||
| e855673802 | |||
| 112ac7bd13 | |||
| ec7963df3d | |||
| 343d006ae2 | |||
| ed8e5498d1 | |||
| 3cfead4ca6 | |||
| c8947eee6a | |||
| 6c1ca7d797 | |||
| 2172974db9 | |||
| ba03df8511 | |||
| fb47d1f788 | |||
| 3c86e14ea4 | |||
| c16fb61bea | |||
| 2acead357b | |||
| 235db57f0e | |||
| cfbde005fb | |||
| 0a865bd9dc | |||
| 6b3f722ff0 | |||
| 3dbecada4e | |||
| d21f87af5d | |||
| 0bfec59af8 | |||
| 035a76f26d | |||
| 42f4e831a2 | |||
| d3686dbb75 | |||
| fb1c790350 | |||
| 0ef5743261 | |||
| e82bef425f | |||
| 24c246a9f6 | |||
| e39348ad96 | |||
| ca5f0444bf | |||
| 4a883ba6ea | |||
| bfe1a8673a | |||
| 0445ef393f | |||
| 7eb16e13bb | |||
| 03ad5c6830 | |||
| ab23e5ca0e | |||
| 35ecd00559 | |||
| e5603fec1e | |||
| e321765c54 | |||
| 62fdcf50ea | |||
| 09d293592e | |||
| f83c2f0b6b | |||
| d775c8dc73 | |||
| 8e07b19bc7 | |||
| cb8ef46ec7 | |||
| ee814cfd0c | |||
| a6a5292cd7 | |||
| b59f142d4e | |||
| 666a18f5e5 | |||
| dff4392c10 | |||
| b09b7c1184 | |||
| 6e05dcadb6 | |||
| bc7acf9f7a | |||
| cb19316a17 | |||
| 33c3977036 | |||
| 7a015b6fc0 | |||
| aa3aef4beb | |||
| 12a48fc6d1 | |||
| 72284b4530 | |||
| 65c04e4ddd | |||
| b382d3b3e9 | |||
| 61b882b2a6 | |||
| 36c8654fb8 | |||
| d25c401aec | |||
| aac874a842 | |||
| 5d934c8759 | |||
| e055d16b2c | |||
| 38745e5782 | |||
| d0c271e534 | |||
| 33635c5723 | |||
| f8d2830ac7 | |||
| a7e5c255b4 | |||
| 062c605eb1 | |||
| 2602be426f | |||
| 51dcb4a79d | |||
| 24e4e329ed | |||
| eb66302907 | |||
| b16cc618b5 | |||
| 77aa9e58f2 | |||
| 3a0b3a85a5 | |||
| 15a12afe25 | |||
| 427cf91447 | |||
| af8c661a64 | |||
| 7b694ebeb4 | |||
| d1e7837422 | |||
| 8efc22bd45 | |||
| 983439076b | |||
| 019f566239 | |||
| 332410d20b | |||
| c2a85bde08 | |||
| 13a0b88755 | |||
| 32f39fec1c | |||
| cad3a6c547 | |||
| 2aa5c437e8 | |||
| 67f48ce21c | |||
| 845a7d9968 | |||
| 924774d3ef | |||
| e0635cf65c | |||
| 3b8e3a9714 | |||
| 2bee096246 | |||
| 872655369a | |||
| 0892758994 | |||
| 22a24446c1 | |||
| b5d498ffda | |||
| bd90e3e37f | |||
| 8b6d615aa6 | |||
| 9e352da052 | |||
| ca9898e838 | |||
| 95b8467a76 | |||
| 2b674d4d8c | |||
| 487b572aa6 | |||
| 600c0ea5ba | |||
| 00e64920c8 | |||
| 9efedbe76a | |||
| d8e9382573 | |||
| ab248e170c | |||
| 27097cbcfe | |||
| 43952e18e2 | |||
| 5076da8f77 | |||
| 8228a4adcd | |||
| 721883f64e | |||
| b55c759f71 | |||
| 3f028fbb83 | |||
| f0cba1371c | |||
| 14fa96fdef | |||
| b954a41f2a | |||
| f1c65dcefc | |||
| d4c17ecda5 | |||
| a4458e2c8c | |||
| 16cc88dd0e | |||
| 280f5f0b54 | |||
| e38eaa7cd7 | |||
| a27bd2275c | |||
| 7d00c69a4f | |||
| a2c189b45a | |||
| 41320688b7 | |||
| f85c8584b0 | |||
| 6cf50f8f6c | |||
| d70ab11477 | |||
| cab4c78b7b | |||
| 14358d5e84 | |||
| 7553429130 | |||
| 3ddfa288cf | |||
| e89a568765 | |||
| 71f1021648 | |||
| 60cff6f3d4 | |||
| 5f010c2f4c | |||
| c0f3d1f06d | |||
| 6c18e00977 | |||
| 72ac1aa537 | |||
| 5bcaa25c02 | |||
| 85880ffded | |||
| 5b207c3b95 | |||
| 3087f15dd8 | |||
| 36f1193497 | |||
| 292af1e4cd | |||
| d4d5dc99f3 | |||
| 3e1344e4e4 | |||
| 6d37bc62a5 | |||
| e9f7c100a0 | |||
| 190676c982 | |||
| 28cbba5a7d | |||
| 0e7a705254 | |||
| 68931b4c43 | |||
| a4e28df9cf | |||
| 65c81c5e83 | |||
| ccd0d2046d | |||
| 0fec99e75b | |||
| f8d1f070f5 | |||
| 3dd48a24ce | |||
| 984e97cbdc | |||
| 50ea1a12c9 | |||
| 992a372fc7 | |||
| d789250976 | |||
| d7e1cf7dd2 | |||
| ea5f5aea5f | |||
| eaf0bbc108 | |||
| b1710bb712 | |||
| dfae7bd073 | |||
| 333fe9a561 | |||
| badb3dc2dd | |||
| 3ac819ee70 | |||
| 00f877e812 | |||
| 1e269751bf | |||
| 5b69eda39a | |||
| 71ca413067 | |||
| 0c7f9458c0 | |||
| ab365fe494 | |||
| e48f160a29 | |||
| cfda4d0ade | |||
| debfae06a8 | |||
| e6f2f8ad0d | |||
| 67785a918c | |||
| 50d80c64fa | |||
| 1378645413 | |||
| 3888b0429c | |||
| 70761a4ef0 | |||
| e37df998e9 | |||
| c30cdfb3a7 | |||
| 350b704cd7 | |||
| ad013d59f4 | |||
| d391133524 | |||
| 4b823469f7 | |||
| 7cd1e767be | |||
| 829a697c39 | |||
| fefab50e06 | |||
| 6e27ab60ca | |||
| 74274f6d77 | |||
| 908b2703f3 | |||
| c047ab6147 | |||
| 52fa69d93d | |||
| a83df01bfd | |||
| b32d989a10 | |||
| d1ee7c651f | |||
| dcbe8ef5f4 | |||
| bd5253047b | |||
| cdaa8cb5c4 | |||
| 083397a555 | |||
| e98eb4659e | |||
| d1988d384c | |||
| bc61835d97 | |||
| 8a50880613 | |||
| b05d12df0e | |||
| 733b46d51a | |||
| 8bc9868c1f | |||
| 3507cd0a37 | |||
| 21ec32b465 | |||
| 1c99a2e7fb | |||
| b68bdafadc | |||
| bacfa9be19 | |||
| 5265eb81e0 | |||
| 516da4ecdd | |||
| 6fcc68699a | |||
| 3cb5fd8ebc | |||
| fd7ea82965 | |||
| 0bd989b118 | |||
| bd0b292b39 | |||
| 31f0a0c064 | |||
| 3e445eff8e | |||
| 6dcd482dd0 | |||
| a28ab0a408 | |||
| a3eb5c2d63 | |||
| e2303f3378 | |||
| acb17b0298 | |||
| fde7cf1fab | |||
| c2cb7e1004 | |||
| 4075f5c497 | |||
| debd44fa9b | |||
| 0a5742587a | |||
| ad4df2d946 | |||
| bfe9580551 | |||
| 1e45437498 | |||
| f9c8f78000 | |||
| 4554eedd19 | |||
| 557f0c5a8a | |||
| 9fb8d449fe | |||
| 1bb7c74c93 | |||
| cc07e5306e | |||
| 34fa010601 | |||
| 7d56069243 | |||
| fc77fb9b4c | |||
| ebdf93e5dc | |||
| 5248240e10 | |||
| b66628baca | |||
| ba5ed5f380 | |||
| 8d5e119582 | |||
| d022e7cd27 | |||
| 5d7acda80e | |||
| 9b595c68a5 | |||
| 2d38d8a639 | |||
| dea8aa675a | |||
| 027eba2b59 | |||
| 91b8e7504e | |||
| 088931525d | |||
| ef9638e094 | |||
| 09a9d08466 | |||
| 1b8bf081b5 | |||
| 06ecc2ae68 | |||
| 46d3066c62 | |||
| 8d12816001 | |||
| fe03b55046 | |||
| ca57f25f26 | |||
| 3c639ff8e1 | |||
| 78c986b5dd | |||
| a42663b09b | |||
| 36149fd986 | |||
| c2c559f8d9 | |||
| 5e8419af0d | |||
| 86fc842c89 | |||
| 80530e8aef | |||
| ba26e16411 | |||
| 2cee26c3e7 | |||
| 5d55e509ec | |||
| 4984e87776 | |||
| c65b7d0aea | |||
| 54fd224fd8 | |||
| 5ca2b1200d | |||
| b5014d56ab | |||
| c4e89f8bb4 | |||
| 7dd85b207f | |||
| cb0431d960 | |||
| 58adb6a1aa | |||
| 13c564f2af | |||
| 95aeebe4b5 | |||
| 605d57c541 | |||
| f972fa26a4 | |||
| 150e18539c | |||
| f03d4cf8fd | |||
| 3419d15878 | |||
| 0da24f21d6 | |||
| e794109a67 | |||
| 006c783aba | |||
| 4378a09867 | |||
| fb24b06a5d | |||
| 425fce5070 | |||
| d5667a859a | |||
| 95dbcf2fd7 | |||
| 8ce0819b42 | |||
| 688a456642 | |||
| 59b3a3d26b | |||
| ea1cdbfdd8 | |||
| 3641926333 | |||
| 280958ee74 | |||
| f4070731a8 | |||
| e791678dfc | |||
| 6f5bbf550a | |||
| ff550b5c3c | |||
| d6daa0d05b | |||
| 86785dffa4 | |||
| c491b73f3a | |||
| c50233cc92 | |||
| 13de773486 | |||
| 4966f6de73 | |||
| 6806e3d5c7 | |||
| 0a121e9d26 | |||
| 15e8cba398 | |||
| b32eecb5a7 | |||
| 8ce0eaa9d0 | |||
| 8307f82f86 | |||
| 2b6a56c21c | |||
| f1e66085cd | |||
| d344701fd5 | |||
| 130a0ef20e | |||
| 18ca3ed449 | |||
| af6fcb19a8 | |||
| eec2dfad7b | |||
| 0fcf767ee9 | |||
| 1e7bf218e0 | |||
| 4ea7628204 | |||
| 7db77a5580 | |||
| 97ae5ab561 | |||
| 89d9813a45 | |||
| 2b52b4a749 | |||
| c479d431a4 | |||
| 8628fc441d | |||
| d48d67767a | |||
| 10caa2981f | |||
| 49610f52f5 | |||
| 27643cb715 | |||
| fe3c7926f7 | |||
| 552d8e6aec | |||
| 0bb3609cad | |||
| b56bc7e087 | |||
| abcf265bc7 | |||
| 6d3c421823 | |||
| e70f430b5a | |||
| 8c927d3cc8 | |||
| b998852385 | |||
| 59d9e7ce98 | |||
| 306593a0c5 | |||
| 3b8bce1bed | |||
| f0fd7e2e19 | |||
| 4384ae15b4 | |||
| dc8252bb9f | |||
| 182a998cb6 | |||
| ea8e435b32 | |||
| 72d1ac22aa | |||
| 8ce5392390 | |||
| 311682b341 | |||
| 44c90c060a | |||
| a5eb11d79f | |||
| 120849c734 | |||
| adf50b7c4b | |||
| f5c575961f | |||
| a90801e2aa | |||
| 402e8b12a6 | |||
| 701f7f39d6 | |||
| 6590366f8e | |||
| fa0b02ed30 | |||
| 15efb73aae | |||
| d0057c92e4 | |||
| 4078f43984 | |||
| 3d980a9f66 | |||
| a0d95a823e | |||
| 9e14d240a8 | |||
| 1393bb2caf | |||
| e9914f3004 | |||
| 073772a801 | |||
| 2babe4c236 | |||
| bbda618beb | |||
| 344c813eb1 | |||
| abaa8f855f | |||
| ea1171f624 | |||
| 1e83d2a4e9 | |||
| 443c2b920d | |||
| 953663e00b | |||
| 5185ddb8b5 | |||
| 583ed61712 | |||
| 492ed27495 | |||
| facde63460 | |||
| 494953997e | |||
| 1b89ad00e7 | |||
| 40558e7ac1 | |||
| 3bddba0c7a | |||
| 97cd641da9 | |||
| 91db4b724c | |||
| dcff8c2637 | |||
| 7a76fb1469 | |||
| 17f805ae64 | |||
| 1606f97177 | |||
| dc39a9b84f | |||
| 4ff23a9943 | |||
| a806be8bc4 | |||
| b57a9c31f0 | |||
| 95c1443e30 | |||
| 5bd5a382c0 | |||
| 1885e4345c | |||
| 2f329cf7b5 | |||
| f2d2a6b605 | |||
| 3c935f7834 | |||
| 2c8b3f05ac | |||
| e8e3a3b2a2 | |||
| ec7d243ee9 | |||
| b74c5e04f5 | |||
| 050c3e1d6b | |||
| 6d83c9cc0e | |||
| 346a1d4433 | |||
| d962bb018d | |||
| bca3a3f4ed | |||
| ffea52dc36 | |||
| 865464f607 | |||
| 73f96f48ee | |||
| 89f1248140 | |||
| 59be63167f | |||
| c628147521 | |||
| a5cff8b186 | |||
| 983547af7e | |||
| d5f7e7b179 | |||
| 2a258dc21e | |||
| ec1244bb82 | |||
| ac6e042223 | |||
| a0b387e0a9 | |||
| 4cafd5a31c | |||
| 888b520b31 | |||
| 493e57837b | |||
| bddfa76b2e | |||
| ee00fdb61b | |||
| 9b22661c19 | |||
| 0ac3dbfec9 | |||
| 56cebd99c2 | |||
| 04c3d8d1bb | |||
| 7fdf3dd760 | |||
| 1f28bee86a | |||
| aed560b630 | |||
| 871b15f6e1 | |||
| ef0faf03fd | |||
| 5226076676 | |||
| 046923d9f7 | |||
| 531eb04fd7 | |||
| f4ca6f02a1 | |||
| 3f7eba19c8 | |||
| 04ff7913b4 | |||
| 09cddc84be | |||
| 9baef8c705 | |||
| a14a358b73 | |||
| 259844f4f3 | |||
| 264df11132 | |||
| 53c8ed6a63 | |||
| f22348a9f9 | |||
| 83d71519e0 | |||
| 8ad36e2526 | |||
| 0f67c68993 | |||
| b79d236bfa | |||
| 92efaf0bba | |||
| 3b11f22062 | |||
| 6164b3d2e2 | |||
| c806da51f8 | |||
| 183aa31319 | |||
| 7b3c0a69f3 | |||
| 6b11d82dd0 | |||
| d0f1b29b39 | |||
| b8fa6fb4c4 | |||
| 22269ca0d7 | |||
| 9ea478008c | |||
| 20f1eb865b | |||
| 53212ba7a9 | |||
| 3372409590 | |||
| 4fe2951509 | |||
| ff8a94714f | |||
| b45d6fee2d | |||
| f44e696edf | |||
| 5a049322ed | |||
| 04deb97f94 | |||
| 0c3c34179e | |||
| e938ddda2c | |||
| 97e26f9d6c | |||
| bfa78870cb | |||
| ad37259ccc | |||
| 418968d974 | |||
| 89905bc1c4 | |||
| 3a96d99187 | |||
| a50ea09053 | |||
| d012abd924 | |||
| 7ed82c0791 | |||
| cf61198fe3 | |||
| 5d50602397 | |||
| 34eff440eb | |||
| 0b42cf06f8 | |||
| 4c4be331f5 | |||
| 511e9920c2 | |||
| 75c3fdcb6f | |||
| 9031c5a6e0 | |||
| 5ac6f090fc | |||
| 0d183a24be | |||
| a21790b992 | |||
| 762ceaf87e | |||
| 2620a51cc9 | |||
| f1e8739608 | |||
| b31a0115b2 | |||
| ed032dc985 | |||
| c436ef0c6f | |||
| 9db97278f3 | |||
| d3898fda57 | |||
| 36ac68b436 | |||
| cdc3ee6c1c | |||
| 6540393df5 | |||
| 3f534b33ec | |||
| 9a6aac1662 | |||
| 4c70864588 | |||
| 17c8b34088 | |||
| 7900780cea | |||
| 0eb739756e | |||
| 05364908f3 | |||
| 92d65ff3c2 | |||
| a52a16807f | |||
| 8df1d74395 | |||
| f84697ad5c | |||
| a2da187615 | |||
| d0ffbbfc4d | |||
| 460a933267 | |||
| fe9c61fe73 | |||
| 3206378ae6 | |||
| 7ce790f369 | |||
| 5db1427923 | |||
| 81eceb1728 | |||
| 639650c65a | |||
| 9d034ea4a2 | |||
| 9ff0b460a2 | |||
| 4f0125a0e9 | |||
| 54493747a8 | |||
| b48c036636 | |||
| d489b02fc1 | |||
| 595fdb2f57 | |||
| 8d56dd1969 | |||
| 44371dedd9 | |||
| fb62c297fa | |||
| 676fed7cfc | |||
| d9d354c981 | |||
| 8c8048f037 | |||
| da6760ed98 | |||
| 1d04f14a53 | |||
| 570eee3202 | |||
| ca07605835 | |||
| 46e8b4f561 | |||
| 1e4655aef6 | |||
| 3e1b76258e | |||
| a845a0395a | |||
| f0053bfc1a | |||
| 22dc2947b3 | |||
| 43fce92aa9 | |||
| 6380e67af9 | |||
| dc465df3bc | |||
| 2e88924cb9 | |||
| fee96ec92d | |||
| c39ad1ee12 | |||
| 5669c7497d | |||
| 60f8fc293d | |||
| 9134388f94 | |||
| 10820fa135 | |||
| 2f3e0044f1 | |||
| 5060c779da | |||
| 6d2cb94e3e | |||
| 85e5b077f7 | |||
| 85dd1b4ea9 | |||
| 220e86bbd1 | |||
| abc715bc5c | |||
| e1adb18491 | |||
| 2688081656 | |||
| e4abd3dc5a | |||
| c7a185d4e7 | |||
| baf96b3eb6 | |||
| 8e2b07ba9e | |||
| 0b023d4e28 | |||
| 4ffc58a8ce | |||
| c5c9ea1b21 | |||
| 3c43d8fe05 | |||
| 21f06e1074 | |||
| 875e252db3 | |||
| 610e71b71b | |||
| 73d23eb6e6 | |||
| ddfa077c3e | |||
| 006f546e7c | |||
| 1dac01498c | |||
| ae0e454fc2 | |||
| ca3ee019cc | |||
| a86a3d2fee | |||
| a917f55ef8 | |||
| 21b535b5c5 | |||
| af9e217fa4 | |||
| 9a51f22265 | |||
| 144b185802 | |||
| 3c0f6a2919 | |||
| 22c33d4fb4 | |||
| e9cdb248a0 | |||
| e8274d5a59 | |||
| 6952be5ce4 | |||
| 4317291827 | |||
| bd40430d2b | |||
| ebc4a0188a | |||
| bfa4fcf584 | |||
| 48f70fbf10 | |||
| 019d2d5dcf | |||
| 17f7f329a8 | |||
| 933737e8f0 | |||
| 47b545282e | |||
| 190822c2b2 | |||
| d000d648b0 | |||
| d257ba5156 | |||
| 9828d6146b | |||
| 9e4bec8cec | |||
| 65ead08880 | |||
| f6c6c04648 | |||
| 794378d5e9 | |||
| a5ac5a9861 | |||
| faaf28b41d | |||
| 700c540434 | |||
| c177bf7480 | |||
| bccfb1cda7 | |||
| c099bb817f | |||
| 7fe98d8d66 | |||
| d356e0d1e7 | |||
| 3ce7fd7894 | |||
| 6f42297b58 | |||
| c5aebe4564 | |||
| 841b8fad38 | |||
| ab0df0a0f5 | |||
| 27e3317449 | |||
| edc09e22b4 | |||
| b487c09d34 | |||
| 4a40ef6a19 | |||
| bcddbc15f0 | |||
| 2a19d0a579 | |||
| 9af66e22da | |||
| 715f4f0669 | |||
| e6e753f37f | |||
| e958c3cc6a | |||
| 19500ac9ad | |||
| 25dee4a78e | |||
| ee953f7953 | |||
| acee590733 | |||
| cd94d9849d | |||
| c3709fa744 | |||
| 853e2b90a3 | |||
| 995cb8125e | |||
| 01d3585bf3 | |||
| a11afe05bf | |||
| 9e4f43f4d1 | |||
| 8cdfe5952a | |||
| 0f8ca1f7c5 | |||
| fd2607ad52 | |||
| 7e1b24224d | |||
| 56c63170b9 | |||
| b41349546c | |||
| 6850533b50 | |||
| 4ce2ad54a8 | |||
| 0c85d4c0d0 | |||
| 57471f8c94 | |||
| 7e11855330 | |||
| f188589685 | |||
| 96428a7555 | |||
| d3585e1f80 | |||
| c0c86521a2 | |||
| 22f5e7a9be | |||
| 06c42bba5d | |||
| ada6db2df4 | |||
| eee5e812f7 | |||
| eb5ae94c24 | |||
| 7109fe9889 | |||
| 17557df9f4 | |||
| fab1f7d939 | |||
| 815d6f4223 | |||
| 25d73f5a70 | |||
| d633a266c1 | |||
| 938bf8624c | |||
| 2cdb46b167 | |||
| 8799eebfe1 | |||
| 70fb5712e5 | |||
| 6a51c27fde | |||
| 17f965c171 | |||
| bd21930d1a | |||
| 4df933275b | |||
| 107129f95a | |||
| e11734f971 | |||
| 3bba9708d9 | |||
| dd497625a5 | |||
| f6764767f6 | |||
| e52dd9dc6f | |||
| 03ae1481fb | |||
| 82068cf802 | |||
| ebf832214e | |||
| 4315363f4b | |||
| f073ff8fe8 | |||
| 47040be3ad | |||
| d0bb9d2b62 | |||
| cb6e536fbd | |||
| f820a7a205 | |||
| 16212854b4 | |||
| 1c6003acd5 | |||
| ef3e8d26ce | |||
| 21a1072117 | |||
| 2ce49e3674 | |||
| e58e1ebfd9 | |||
| 609182b131 | |||
| 7898ae6fe6 | |||
| a9d0ffcac1 | |||
| 824be77bba | |||
| 74c8a44d84 | |||
| 9f829b375a | |||
| da44d5f10d | |||
| be4b71b805 | |||
| b0c7ca6d1f | |||
| 4d8de282f9 | |||
| c5d39ace2b | |||
| de80a4b6c7 | |||
| 917069e31a | |||
| 3354c800d7 | |||
| bb3ac62126 | |||
| 6e25fea16a | |||
| 5e7c6853c2 | |||
| f76a011ba0 | |||
| d854a39500 | |||
| a00ebacef3 | |||
| c2f4244c4d | |||
| 7437c324c6 | |||
| 54b87b6dbb | |||
| a029a94c73 | |||
| 3157a10428 | |||
| f8d2d8ca11 | |||
| 0d8152cd4e | |||
| c37bc3c55c | |||
| 6cc0fe4221 | |||
| af1ceb1151 | |||
| c1a80b8146 | |||
| 268bcd1c7b | |||
| 42a9ac9e6c | |||
| 182b20c33d | |||
| 58e2465369 | |||
| 07a44d0ff9 | |||
| d00f882c23 | |||
| e70e534bfa | |||
| d345916241 | |||
| fe8bcac270 | |||
| 60f05fdbf3 | |||
| ad0f12c742 | |||
| 2f2a03b37b | |||
| 881e8e4723 | |||
| e1af6dc4af | |||
| 4d9533ea54 | |||
| d6623e0f22 | |||
| ab3d36f0f3 | |||
| 632af8d723 | |||
| 282b00674a | |||
| 235d12aa6b | |||
| 5d1fc546a8 | |||
| eb993781ef | |||
| 0756fd9c7e | |||
| a3e79fc105 | |||
| 84470c34db | |||
| f8dbfa1d1e | |||
| d9750e8f9f | |||
| e09c4b72c8 | |||
| 53b95fea19 | |||
| e2fd4e46f7 | |||
| 20d6664dc1 | |||
| 8ee953ef8e | |||
| 5b7ee43352 | |||
| 8add57f8e9 | |||
| bb0aaea92d | |||
| 987ede2e6c | |||
| 5fae1b3637 | |||
| cb08c53f2f | |||
| 171e4fafed | |||
| 8d2ce2815c | |||
| d91551c277 | |||
| 332f9cae77 | |||
| dc25a3fa2a | |||
| c98ec4d014 | |||
| 05dc6ad610 | |||
| 3fe8499956 | |||
| f1b1c9053c | |||
| ea4cc0b395 | |||
| be8980fc23 | |||
| e4a9c177e6 | |||
| 99be645fcc | |||
| f8920edb2e | |||
| acf51f0ead | |||
| ddd202b5ff | |||
| 78eb7e73bc | |||
| 72337f2678 | |||
| 14200c1a1f | |||
| c495ef10b0 | |||
| 3bdce6050b | |||
| c9c0d7361d | |||
| d7ffc8b4ac | |||
| b5f01372ee | |||
| bec6bde919 | |||
| 1f25924384 | |||
| 36cf5dca82 | |||
| eea12bad07 | |||
| 6a9fe8e3c4 | |||
| 55e907385b | |||
| bd14429f20 | |||
| 5867b3b72e | |||
| 45e1a8756f | |||
| 6742fad753 | |||
| c6190fa95d | |||
| 372eff2d8f | |||
| 98eb0cd3f2 | |||
| 541e20cbec | |||
| ef203f6bcb | |||
| a5368d766a | |||
| cf2e2a0511 | |||
| e5bb5f02e0 | |||
| 3a17eefde7 | |||
| 7d2ecbf29a | |||
| c72a6f8e6f | |||
| 6a486d3402 | |||
| e43db24b2c | |||
| 3ea33763bc | |||
| 695cfead16 | |||
| 12dded403f | |||
| a7a5034958 | |||
| fa81146b79 | |||
| 5269b69bc5 | |||
| d9e3f0ccfa | |||
| 2483cc6f8d | |||
| 97717defa5 | |||
| 5e29bdbe22 | |||
| b437794e92 | |||
| 9fcbad326a | |||
| 2c93fecd8b | |||
| 20fcc6530f | |||
| 11e75853a6 | |||
| 9cb4402c16 | |||
| f29589e5cf | |||
| d7842b7de2 | |||
| 5a8eb9d3d7 | |||
| ab4c40c988 | |||
| 5ea6535fd5 | |||
| 76faaf43f7 | |||
| 9679ae68cb | |||
| 7d3389d548 | |||
| ab9cdc70ad | |||
| e45d37073a | |||
| e353ad3557 | |||
| abec850379 | |||
| 431e0eb30c | |||
| 628cb1c779 | |||
| a14e0a0104 | |||
| f3637cdfdb | |||
| c6a9a5d5d7 | |||
| 7e3ece7d9f | |||
| 7f917c8ba5 | |||
| e992cbe01b | |||
| 1974911a71 | |||
| 8659994b2c | |||
| 5affc459a2 | |||
| cd4ed11700 | |||
| c4fe418f66 | |||
| 7d9d58f38f | |||
| b212f29cf2 | |||
| fd2cd84555 | |||
| bf978ac8ca | |||
| d3c6472c0f | |||
| 1c7a318413 | |||
| 591624b96c | |||
| 2323cd2a2d | |||
| cc5c89539b | |||
| a7ee059419 | |||
| 7d5c8fe553 | |||
| fd048a75da | |||
| 5c1ce6350b | |||
| d86c9a2549 | |||
| 249686708c | |||
| 3ee1d8aed1 | |||
| 5c6dae498b | |||
| 2086e7f2e8 | |||
| 4092e3e95f | |||
| c764925b4d | |||
| 83d818d96f | |||
| 3d3c91d654 | |||
| 0ad4e91001 | |||
| 731d4330fe | |||
| 5777a1d426 | |||
| 5fda9a4efb | |||
| c15b5f1eca | |||
| 314dc4c5de | |||
| a0f0f58fc5 | |||
| 92b7c56f29 | |||
| 8d8fb4a2e4 | |||
| 717e851a99 | |||
| 2e737ad483 | |||
| 88a0e0fe2d | |||
| e2248332ae | |||
| 3663a8ab4d | |||
| 5430892052 | |||
| ff04cd6d69 | |||
| aa4fdff82c | |||
| 5bc4f9df0d | |||
| 5d0066029f | |||
| 56962a58da | |||
| 746615a937 | |||
| e485c9c79c | |||
| bd6fdf3f2d | |||
| e1f8573c68 | |||
| 4bc157881d | |||
| f0d526411c | |||
| e1183f6919 | |||
| f4ec28d932 | |||
| ce587f43a0 | |||
| 6892399699 | |||
| 22b1cc765a | |||
| b9cb181691 | |||
| 4a03f06175 | |||
| 768bb8d31f | |||
| 0bf8f2a527 | |||
| 2dca8d84e1 | |||
| 1668900fb8 | |||
| 66f1cbfb34 | |||
| b75af69cf9 | |||
| c36c425fb9 | |||
| f75b26d1c9 | |||
| bfee541540 | |||
| 3d7c38ff9d | |||
| 5d27f1c732 | |||
| 3b8e7d0967 | |||
| ebbf329b6a | |||
| 87cc937d4e | |||
| dcf5c06d6d | |||
| 8357523ec0 | |||
| 39149fd84d | |||
| 289c594187 | |||
| d47d597b34 | |||
| 69c2150fbd | |||
| 334d0bbc86 | |||
| 1cb4fb9c50 | |||
| 413f87b737 | |||
| 8a8edb1b62 | |||
| caa1324457 | |||
| 776c2ada6a | |||
| 41eb6d4461 | |||
| 0315781306 | |||
| 437f374bae | |||
| 9657b3f1d4 | |||
| 650152e05f | |||
| 73fe9b51de | |||
| 26b2e4253d | |||
| b353bf6c56 | |||
| c601374b1f | |||
| 66d13da2ac | |||
| 938ca90a02 | |||
| 2d2ed7efd0 | |||
| 1507a59786 | |||
| 675fde69aa | |||
| 99895471ae | |||
| 3e2aede85c | |||
| 377ad9887c | |||
| c9a978a03e | |||
| 59d44cd1cc | |||
| 542a6aed51 | |||
| 1677618c75 | |||
| 3df83e03a9 | |||
| a199c71a55 | |||
| 3d20ce70f5 | |||
| f0cdd8ace6 | |||
| 8e9d2fa70e | |||
| abf9a08ee3 | |||
| 9d02231074 | |||
| f56b362769 | |||
| 865180e63e | |||
| 3265772ae4 | |||
| 224a0e4b1a | |||
| bd41a108d8 | |||
| 695b6e8f46 | |||
| ab6942d974 | |||
| 6efc735728 | |||
| 3048bb1a75 | |||
| b8f86eb78d | |||
| 68bee397eb | |||
| a703f6febb | |||
| 81749f4353 | |||
| 2d1d36678d | |||
| 0e6abd66ca | |||
| 7080305d82 | |||
| 7c3166a0c6 | |||
| 4405f46aec | |||
| 81684919f5 | |||
| 1a8fb61373 | |||
| c47d04fd2f | |||
| 91ee480e56 | |||
| 3d320aea2c | |||
| 703841e251 | |||
| 1fffffad7a | |||
| 72fedccaba | |||
| ae519200ed | |||
| 201d54ee08 | |||
| 2591d99db1 | |||
| a2327de3cb | |||
| 581176fb1a | |||
| 377e2ce3e8 | |||
| a2653532ef | |||
| 37df3c6f96 | |||
| a8bca8b2ed | |||
| b0d3c4d75e | |||
| 3db2f23e02 | |||
| 661636efef | |||
| 99f5145aab | |||
| 8a0425570c | |||
| eecb22e749 | |||
| 3ad12cf5f8 | |||
| d4333788e2 | |||
| 308cdfac35 | |||
| db4414ca87 | |||
| b5dbb2eb36 | |||
| 67b002f586 | |||
| e186ef9490 | |||
| cccc5bc18d | |||
| 7824419bbf | |||
| c22d778143 | |||
| 61f43d78df | |||
| 54dd9f4eae | |||
| 91d06a9729 | |||
| 310f367fb1 | |||
| b1fb5b6239 | |||
| 20d8d38e53 | |||
| 78ac2a86bb | |||
| cc723ed45c | |||
| ed82288c1b | |||
| 7680466e0d | |||
| 9266507e4c | |||
| 8cca113ef4 | |||
| 7ff25588f4 | |||
| 93122196d9 | |||
| 5c4c8f4539 | |||
| 118bfbbe98 | |||
| 12f0278808 | |||
| b38580bf32 | |||
| 525453794f | |||
| eb5ec211c2 | |||
| 69ea573b0d | |||
| dd9397473a | |||
| 86cf8a1717 | |||
| 6374a9f19b | |||
| f95b81574f | |||
| d67e77899f | |||
| dd5c54290c | |||
| b6e8560532 | |||
| 5dc8b05275 | |||
| 48ecc00368 | |||
| 04ead3cba4 | |||
| 79e2a87bc5 | |||
| bd61347b21 | |||
| 09797c3584 | |||
| 14969cd8d0 | |||
| 79c54aeba9 | |||
| a1b6415c5a | |||
| 8e2b2bc179 | |||
| e1042bc631 | |||
| a6025df7de | |||
| 5c4b8e8dee | |||
| f95bf01c78 | |||
| d4606cfdb9 | |||
| 907adc817e | |||
| a6f0b1b532 | |||
| 1bd6cb2105 | |||
| 142a1da0e0 | |||
| fb3d5827f0 | |||
| a3f25bc7c7 | |||
| a0f63a31e3 | |||
| f72385b00c | |||
| 4f7c020e63 | |||
| 9a4c26dc8c | |||
| edde748519 | |||
| 37ce7056ac | |||
| b84b8f4db4 | |||
| 72bef8dd7f | |||
| 0e6937a359 | |||
| b18dcd7660 | |||
| 2b69a68ef6 | |||
| fc68c508c8 | |||
| cda8b3a59e | |||
| 31035608ee | |||
| f6200ba635 | |||
| c1bd154bcd | |||
| a568c958af | |||
| 2de6a9bc44 | |||
| 7df8258551 | |||
| 2b75df22d9 | |||
| 37110098c7 | |||
| 8f0af6a6fe | |||
| 2281c4f662 | |||
| 2ed50ba263 | |||
| fc5b4026e1 | |||
| bc5c4c9205 | |||
| 930bc9179d | |||
| b4bf48c33b | |||
| 0072df7f20 | |||
| 65e9e568b5 | |||
| 19acf260d8 | |||
| f4f0fb88b1 | |||
| dd6825a7bd | |||
| c1dc6838fa | |||
| 69f82a7311 | |||
| 0db91aa56b | |||
| 791ec95313 | |||
| 954e3f6e6c | |||
| d66bdf1653 | |||
| 76294beae1 | |||
| 689419b0ca | |||
| 833ace1190 | |||
| e095eaf16e | |||
| a505d87565 | |||
| 98ab5d5ba2 | |||
| 790fd9ce14 | |||
| 7da8ba5c15 | |||
| a9c18964b6 | |||
| fe7933b0d2 | |||
| 9506676223 | |||
| 7d7909149f | |||
| 3be687cd18 | |||
| e423128a32 | |||
| 3ec73b651e | |||
| 4f71c570bd | |||
| 8ae2554505 | |||
| c5d390c979 | |||
| 8e95c0e44d | |||
| 58ba6d68bb | |||
| 3788ef3e27 | |||
| b923eb058a | |||
| 773448a8f6 | |||
| af854835b2 | |||
| 72ab5f05f4 | |||
| 1791bb5059 | |||
| 3fd3bd7ca1 | |||
| 3937733182 | |||
| de58f19866 | |||
| e4cb9ef7cd | |||
| 4e6d95c5b8 | |||
| 256c74def2 | |||
| c48ccc6f3c | |||
| 18219afbf7 | |||
| 1805cb44e6 | |||
| b4b8c1e4b2 | |||
| 193837298b | |||
| 18e0b83ac9 | |||
| 1a374126e1 | |||
| 2b6afb6916 | |||
| ebd92a2f2f | |||
| 8c747bf0a2 | |||
| b94e4247cc | |||
| a203ff677b | |||
| c3af19148f | |||
| dbce10d0e3 | |||
| 5101bc189e | |||
| 5960de2e20 | |||
| 1cb3bf6dab | |||
| 0bf73ba0bc | |||
| 368bd7cf02 | |||
| 83c7f6f149 | |||
| 2094e52d7d | |||
| 5657363642 | |||
| d35a29bbe4 | |||
| 22d01e4d05 | |||
| 1762324702 | |||
| e4b6de409a | |||
| 3a6bda4d93 | |||
| 3b9dc29781 | |||
| 6210507a37 | |||
| 0df6c41556 | |||
| 7ba5f1f503 | |||
| 171367fe88 | |||
| ec4e8eda04 | |||
| e361bac945 | |||
| 06d4505992 | |||
| a3f2dfa232 | |||
| 921b1aadfb | |||
| 8f3b04cbd6 | |||
| 0f6a0d2740 | |||
| c7fe8567b8 | |||
| 8cb1f4fe26 | |||
| cf229a8e9f | |||
| 074b9f94db | |||
| 20f53e65eb | |||
| b1b67a13c6 | |||
| bc3b70c338 | |||
| 63be05d5d3 | |||
| ec1e82bc9d | |||
| 2e397e38a4 | |||
| 7e0bc26241 | |||
| f37adc4188 | |||
| 4d8bfe328b | |||
| f72af2973d | |||
| 032e7c0491 | |||
| d0c199d455 | |||
| adfc9d93c3 | |||
| 2dcc3255b2 | |||
| 167159698d | |||
| 4838f72e50 | |||
| a8a83c9724 | |||
| f0b1c8302a | |||
| c8b8cafeec | |||
| 791c0da236 | |||
| b45d836b89 | |||
| 492a80f6c5 | |||
| 8f32d44635 | |||
| 9fb30f130a | |||
| d91d420981 | |||
| 442035c251 | |||
| 063902728b | |||
| 60a63fa4b6 | |||
| 7399a3f1e9 | |||
| c4f6968aae | |||
| 00957ca4bf | |||
| 179a9b3bf0 | |||
| 926e0467cf | |||
| c69691f19b | |||
| 5524cd1e75 | |||
| 17f3a114be | |||
| cb14805d78 | |||
| ae1ff1e96d | |||
| c3a4e57efe | |||
| bb950cbb3b | |||
| 6b0f7a8f55 | |||
| 8e61c65c0d | |||
| 141d62fbf9 | |||
| e407018bb5 | |||
| ff74c241c7 | |||
| d69bec8f59 | |||
| 504ba8d824 | |||
| 8228fa1ece | |||
| 1f9f455801 | |||
| 5ba26e247b | |||
| 93b8f3b5db | |||
| 11b980c9ac | |||
| df20410cf1 | |||
| d451a0b7b7 | |||
| 158b24ec25 | |||
| 1b68f90e42 | |||
| 765b14a8ba | |||
| 36fd1d0f0d | |||
| e8f9fd5430 | |||
| c4a21438ad | |||
| c2ae8be3eb | |||
| 6fe671a5e8 | |||
| cce946f10e | |||
| c948c9305c | |||
| 8c838698af | |||
| c0f4fb6e35 | |||
| cc8f024c6c | |||
| 2e18df7223 | |||
| 995fa63f4c | |||
| dce81d4a66 | |||
| f7536bbce0 | |||
| 3f48450408 | |||
| a38d2461c9 | |||
| 6c8d844ec5 | |||
| 91d80aa7b9 | |||
| 7939160178 | |||
| 3eabec0030 | |||
| 8f3ad8b81a | |||
| 5834a466cd | |||
| 4ff69dc0cd | |||
| 4aae9a17c1 | |||
| 5e6928a182 | |||
| cc6a03cbd7 | |||
| 3c3ccdbf1e | |||
| 15f01a1bf6 | |||
| b6e52ad975 | |||
| 2bd4485082 | |||
| 96086d57fa | |||
| 078c31c1da | |||
| 7a409af0b0 | |||
| e6a6d7e9bc | |||
| 133e897c8b | |||
| b1fdbc7fcc | |||
| 89f16548f3 | |||
| e7d5d17fd8 | |||
| bbbd06dcee | |||
| fd09dde911 | |||
| 0b6e2b26fa | |||
| b301fecfd8 | |||
| dc5cdb3bb4 | |||
| 72d1efa383 | |||
| f36686b1a7 | |||
| f33373ca1b | |||
| ae140a1ac9 | |||
| 8053d2602a | |||
| 18dbd788e6 | |||
| a53d0d50b3 | |||
| 7f9d41ac47 | |||
| f05e24e8e8 | |||
| cd64990558 | |||
| 0b24b09a06 | |||
| a178374052 | |||
| dd8a3eaac5 | |||
| 63080c22a3 | |||
| 55baaea8e7 | |||
| 13820d6802 | |||
| 0beea91d5e | |||
| 3f559cd86e | |||
| 39796141fc | |||
| 7c972c8860 | |||
| 2fb600e458 | |||
| 6cbb12e5cd | |||
| 2eea18469d | |||
| 1113221340 | |||
| 9024ba69b4 | |||
| 1231274e0f | |||
| 72c0aed4c1 | |||
| c2c5005278 | |||
| 2ed370093e | |||
| d97e9f7b4a | |||
| 85c4321c24 | |||
| ba7f4af02b | |||
| 69d90f6fec | |||
| 8c847d3a4b | |||
| b327e329d6 | |||
| 92f821aeb1 | |||
| fc3a134e7d | |||
| d6b8213c9f | |||
| f079eb4026 | |||
| 28bea14d72 | |||
| a76a4d8136 | |||
| fdd7f0645d | |||
| 29be815302 | |||
| 1510505b30 | |||
| afce3ee2ed | |||
| 019aae8bec | |||
| 6d32ebecca | |||
| ad13075b36 | |||
| 8581a2775a | |||
| cc100f4008 | |||
| cba9ed3527 | |||
| dcc269128f | |||
| aae338a91c | |||
| 9db088e17b | |||
| c2a24fd047 | |||
| 4215499b7f | |||
| 049825812e | |||
| 66bd8308d9 | |||
| d96dabcd60 | |||
| 777f0a7c82 | |||
| 58492ef92d | |||
| f5a51599d9 | |||
| 6712ac0a72 | |||
| d6258fce54 | |||
| 4e28aa4681 | |||
| 70d6a12894 | |||
| 96185af64f | |||
| c00ee7ed5b | |||
| cd4eed0704 | |||
| 2aac46efcc | |||
| a2bf0719ea | |||
| e8177906e7 | |||
| 17a9ce6fb9 | |||
| 36d8553f9c | |||
| 9d971e3b07 | |||
| 7ed570dc4a | |||
| a5ba4a18df | |||
| 214a3ba21b | |||
| 30a8cadf60 | |||
| 15a36bb844 | |||
| fa29c5aa94 | |||
| 8d1a9dce91 | |||
| 453478c98b | |||
| ccc7cb7994 | |||
| 38c8dd98b4 | |||
| 433a21286a | |||
| ec4287cbd3 | |||
| e58fa7d51f | |||
| 70f1302fa7 | |||
| 3b9f419859 | |||
| d26c465911 | |||
| 158e34faca | |||
| 768b4f8c65 | |||
| 150d1bcdd5 | |||
| e1f2f3f081 | |||
| 717dd1625c | |||
| a11c77c009 | |||
| 844f9683ec | |||
| f27de28ee9 | |||
| bd49ad358c | |||
| 89514c043a | |||
| b33648fd14 | |||
| 471db3219d | |||
| fd3522436a | |||
| 1ceb779a38 | |||
| ecb6d38451 | |||
| a936533eb1 | |||
| eb1de04ca8 | |||
| 2aff36647a | |||
| 19e20d9c19 | |||
| 3d78694590 | |||
| 52360b3f98 | |||
| 08e66ab14c | |||
| 3de41bfea7 | |||
| 1537f505a5 | |||
| 5ebc538d7e | |||
| 4965bf7d7a | |||
| a0509328d4 | |||
| 537f175f52 | |||
| 017ef5a94e | |||
| cccc32fa9d | |||
| 9de9ec1f01 | |||
| ef10ed4499 | |||
| b447e6f55d | |||
| 3c63db93ed | |||
| da09badd8d | |||
| 7f8d802bd5 | |||
| 532215fb81 | |||
| 13e166084d | |||
| 425e032a62 | |||
| 5261886449 | |||
| e606130262 | |||
| 7d33ca7059 | |||
| af4efafae1 | |||
| 09a8974786 | |||
| b1d8bf754e | |||
| 132c3e1c1a | |||
| dc839e1784 | |||
| f1cf62ac57 | |||
| 12044bd8b0 | |||
| 01cafc042d | |||
| ceaee0ec68 | |||
| b6a288d383 | |||
| ae14eb0747 | |||
| be0e586671 | |||
| 66916df4ae | |||
| fae46bf194 | |||
| e1cb827488 | |||
| 3a36b713ce | |||
| 49d8731c1c | |||
| ad552c6b78 | |||
| ebb007ecb4 | |||
| 9acf8e283d | |||
| 7f5dd1dd62 | |||
| c577bd2111 | |||
| eb2dcaf602 | |||
| fd8cda0f2b | |||
| c63f77e3b0 | |||
| a1f70bf96e | |||
| f1127f1894 | |||
| 27367dc493 | |||
| 5ba07ed50f | |||
| 1dbb5422a2 | |||
| a3289e9d40 | |||
| f2d6a1ff60 | |||
| fd45bf5fba | |||
| e3668cc26c | |||
| 7139c4fbab | |||
| 0bfdc1f62e | |||
| b11e8f8b8d | |||
| 7be35315da | |||
| aa5c6c4d2b | |||
| 6a2571d0e1 | |||
| 20f7544a8a | |||
| 6ec149d8f5 | |||
| 2678ac6382 | |||
| c9b5ba4a5c | |||
| 03a6d67c6c | |||
| a9f492b605 | |||
| 664d606123 | |||
| 00d25a191b | |||
| 3566faabd9 | |||
| 7e224c5585 | |||
| 9e14e835e7 | |||
| 33d01fd252 | |||
| d25ba03e82 | |||
| 7025985c0d | |||
| a756c0679e | |||
| 377e06a4a2 | |||
| a0612ff4a7 | |||
| 11d5bd3452 | |||
| 231e837f9b | |||
| 45389dca51 | |||
| 4e6934c9dc | |||
| 74c05ec5ee | |||
| cb4192bce9 | |||
| 83a2204f87 | |||
| c16124f0d9 | |||
| efe6e1eb0a | |||
| c3d36940c7 | |||
| ff341fe597 | |||
| db71d4852a | |||
| 88ee198d78 | |||
| 9176ca084c | |||
| 70cd8afafa | |||
| 6a8f5e6b38 | |||
| 6c234b48ce | |||
| bf957a575c | |||
| 0c65a1721d | |||
| 5d78d81c00 | |||
| b21b4faca8 | |||
| d58f52ff31 | |||
| 54af8ec544 | |||
| fdf47f43d8 | |||
| 2ae83782e1 | |||
| f3877d11e8 | |||
| 28e9cade2c | |||
| c04abac630 | |||
| 7e9dbeff7b | |||
| f0edcc16fe | |||
| e7adef9fe1 | |||
| 9c5da55dca | |||
| d802b3d8b2 | |||
| 04dedb17eb | |||
| 47bbfdd2aa | |||
| 6bd96a4590 | |||
| 92eeec39b7 | |||
| 656db6c668 | |||
| 7989de9d16 | |||
| 3ea94c286b | |||
| 4e25daffa6 | |||
| b4f416cb76 | |||
| 1678b37aa0 | |||
| adfd8ab43c | |||
| 87d4b14ca9 | |||
| d3eb267ba9 | |||
| 12b73c8bdc | |||
| 5751b77688 | |||
| 636ed4a48b | |||
| af7cdcb5c7 | |||
| 2985a39d2e | |||
| 609c0d46af | |||
| a2b6546d37 | |||
| 9dca2887d8 | |||
| 6268a2d384 | |||
| c87beaa694 | |||
| 1bbe2e9b15 | |||
| e40019354c | |||
| 07e1766a7c | |||
| 814c73407d | |||
| 5692c3de04 | |||
| 8214425a3c | |||
| 84a542fbce | |||
| ab4189998c | |||
| 9b672cb969 | |||
| 5f247cbedc | |||
| 53676067fc | |||
| 11bc7de0ca | |||
| 091dcc1052 | |||
| 934a2eb9fa | |||
| 426643c44d | |||
| 7dd36ff829 | |||
| 0c45457101 | |||
| e56b3256b0 | |||
| 892f74d762 | |||
| deb6bd3e25 | |||
| 5e86ef2371 | |||
| e74d3c2674 | |||
| 149d550f7e | |||
| 70f2577b9e | |||
| 93295f7f50 | |||
| 1725f7a34b | |||
| 6e3406b3f5 | |||
| 19107b2de5 | |||
| 7599c66639 | |||
| b726aa5a3e | |||
| 12a3cdf0e8 | |||
| e4a81b1d13 | |||
| a166d3680e | |||
| 8461a5cbe2 | |||
| 66b0b78055 | |||
| 2209be5216 | |||
| 1669e95870 | |||
| acd50eefaf | |||
| 7514e53385 | |||
| e1b4cf1557 | |||
| 9e449db0c2 | |||
| f776910966 | |||
| 0361184930 | |||
| f6cf36f6a7 | |||
| 7a8772dafa | |||
| 0a41999818 | |||
| f1147f70f4 | |||
| 39eafc1f3b | |||
| 21b6495aaa | |||
| 250736ece5 | |||
| f2f3321952 | |||
| c3f3451269 | |||
| 54775d91dc | |||
| f1f5c91386 | |||
| bb1b4bac9b | |||
| bdbc7b5f1d | |||
| 8d847d6f1c | |||
| d594490329 | |||
| 6c66153372 | |||
| 5b0476e772 | |||
| 68f50c7035 | |||
| 5c3d417b35 | |||
| 01db83bc36 | |||
| de1774d8f2 | |||
| 0f1fd059fc | |||
| 87c8d1800b | |||
| 3105b21909 | |||
| d94b875187 | |||
| 7129902b25 | |||
| bd234a7668 | |||
| 73a9946212 | |||
| c7fa4e2375 | |||
| 6ee9153329 | |||
| 752c4a7b0d | |||
| 582c98359e | |||
| 7dfd50d5cc | |||
| b05b16aedc | |||
| ffd5a9e91c | |||
| fbe6900b28 | |||
| 7fe9802f87 | |||
| 14aebeac58 | |||
| 76bbbe27f1 | |||
| 9af52d12a8 | |||
| 5eb314fbbb | |||
| 655f7ce8a2 | |||
| c11074a128 | |||
| ef6854ca46 | |||
| 7e590eaa2f | |||
| 94478ad4a0 | |||
| e28e51463b | |||
| cb252b1ce2 | |||
| d37e770497 | |||
| 5871c4e93f | |||
| 50f51be06a | |||
| 8e5a03f171 | |||
| f72971f19f | |||
| eb140c52a4 | |||
| 198c84cabf | |||
| 5a73943be6 | |||
| 34a0c3f488 | |||
| 8762f2a588 | |||
| d7dd4897f8 | |||
| a84077f174 | |||
| 08f3460365 | |||
| be0e4e9879 | |||
| 799c3f9708 | |||
| 490f58ff3c | |||
| cb047fcc75 | |||
| ac2581659a | |||
| f335d034fc | |||
| 05bb6e1545 | |||
| 65eeee0f4c | |||
| bf4bdf73b7 | |||
| 30f7c81cc5 | |||
| 08ab9c4b04 | |||
| 4474757162 | |||
| bacd1698fc | |||
| e133c7a7dc | |||
| 0eabfdcadd | |||
| d86241bbcd | |||
| 42a0512c66 | |||
| 556aba46b5 | |||
| 2b853cc8bc | |||
| 00b74fb951 | |||
| ecd68dfc70 | |||
| d0b2eecc9a | |||
| d5c85f308a | |||
| f71cdb4eb8 | |||
| ee46ad1ca9 | |||
| 762c106e19 | |||
| 93552a5958 | |||
| c0fbf3091e | |||
| 49294a3dd2 | |||
| abfa303e07 | |||
| 5094ab8283 | |||
| a0d2bc9769 | |||
| e102dc2a94 | |||
| 5e59f18720 | |||
| b35a5982e8 | |||
| 4d3cdca7f6 | |||
| 0d4f8ca234 | |||
| 569e1c2df6 | |||
| 6e9392fb45 | |||
| df1813b4e2 | |||
| ff16e678a5 | |||
| 982856e70d | |||
| 144c20649f | |||
| e719bcf338 | |||
| 3f4226b70e | |||
| 620cfd5063 | |||
| 69b2e746fa | |||
| 2341749485 | |||
| 33abcf74f2 | |||
| 4e33ae319b | |||
| b083edccd3 | |||
| b59bb16fad | |||
| 3f943945a7 | |||
| 136d769895 | |||
| 9c9c2eb2c9 | |||
| 318a364d09 | |||
| fa02a04baa | |||
| 7eebe06931 | |||
| cd40bc8c61 | |||
| f6ebd88687 | |||
| 13ef0cc8c4 | |||
| df5059b142 | |||
| f7666f44da | |||
| 7b49249f5f | |||
| 64ed2f1151 | |||
| 17f335648c | |||
| 1dc2eb1cc8 | |||
| 1a702de9e4 | |||
| f1241c572c | |||
| 522daf5eac | |||
| e772dde3cc | |||
| 8b4b859091 | |||
| 18db020b93 | |||
| 7069e7265f | |||
| fa0bf6a92c | |||
| 758902382d | |||
| cc71d2c4bf | |||
| 9b7d28b5dd | |||
| b9ee53d82a | |||
| 479a64c4e8 | |||
| 7b54d386f2 | |||
| 7eccbecb2f | |||
| 2bab3afae0 | |||
| fa3fde7a29 | |||
| 3aa293a7a3 | |||
| 4befa36365 | |||
| 96be40bf30 | |||
| 3001701059 | |||
| fa41297b27 | |||
| b8f51398b7 | |||
| cb2129c7e4 | |||
| 703ec9f896 | |||
| 19350d024b | |||
| 8e68427daf | |||
| 6220206cbc | |||
| 1df1ceb4ea | |||
| 6178a0ab25 | |||
| 6bb083a77c | |||
| 171e6c6e54 | |||
| 313b967217 | |||
| b47a8b9995 | |||
| c4a1c6f845 | |||
| 24d3e2b2b8 | |||
| 145b80d262 | |||
| 5e75a0c497 | |||
| 972e0ab31d | |||
| 54f2c27ba0 | |||
| 0ba1f8f4ef | |||
| 4d7e53d7a0 | |||
| 0c757222cb | |||
| 0ed87be47a | |||
| e005581dda | |||
| 312fc94daa | |||
| 0dd417e5f2 | |||
| dd85e733d3 | |||
| 9e9ddf42c9 | |||
| 4d1f818162 | |||
| 3e0e1f668c | |||
| 4662ee0255 | |||
| 2f255a528e | |||
| 987223da3f | |||
| 78cc36cdd8 | |||
| 580b5cda0e | |||
| 81f974125c | |||
| 48c47eede4 | |||
| da036de3e4 | |||
| 92e3eaf3ff | |||
| 771eff273b | |||
| 0cf35e3b22 | |||
| 70bcb1cd52 | |||
| 762c8d5430 | |||
| aa9055f4c3 | |||
| 9d1833c5a8 | |||
| 583220b95a | |||
| 85bde0f43f | |||
| b96f064868 | |||
| 6de91a1691 | |||
| 1aa11440e0 | |||
| df8d0cde4a | |||
| 57a9844279 | |||
| f02b4801b2 | |||
| 727d783959 | |||
| fad8b38b28 | |||
| 8a176de6a1 | |||
| 0ee2f761ae | |||
| c48ceafc15 | |||
| ee6494c14b | |||
| a1456da24e | |||
| f08c778d2c | |||
| 90f4023cb8 | |||
| ea9abe7701 | |||
| 5c42d29c98 | |||
| 950940febe | |||
| 6e7fbc5c5c | |||
| 6a1a0bf48d | |||
| 244e74ebe2 | |||
| aa14432846 | |||
| afb594c233 | |||
| 7a7ac625cd | |||
| fe75311be2 | |||
| 812d03894b | |||
| 5e6b1003ec | |||
| a08ed0d22e | |||
| b5ed73ebe0 | |||
| c1bdaccd8c | |||
| 4421831c8b | |||
| d03804b523 | |||
| 634c4355fe | |||
| ee54ba970a | |||
| 23f1515448 | |||
| 4018b833ad | |||
| ddf87864de | |||
| 299af768e8 | |||
| e645627b78 | |||
| 1cb1d14d0c | |||
| 1c2df15755 | |||
| 687bb1697b | |||
| 04e0bf2eff | |||
| eb8710d3c1 | |||
| e98fcfdf77 | |||
| cdda19c79f | |||
| fa9330d0e0 | |||
| 1d4595a349 | |||
| 9344b21484 | |||
| 07f300a14e | |||
| ddeb39d8de | |||
| 0d7aa5e310 | |||
| 606693a9f7 | |||
| 78c49e7331 | |||
| 9760053c8c | |||
| e8988faed5 | |||
| 7137142351 | |||
| bacd234258 | |||
| 3006b003c4 | |||
| e30637351e | |||
| d2b83c69bb | |||
| bcbe324534 | |||
| dcb30df7c8 | |||
| bdab26ec09 | |||
| f47333997f | |||
| 3787108ee7 | |||
| 30d176ac5e | |||
| 98f91457bf | |||
| 6847e52364 | |||
| 896d16ec7b | |||
| 6862790cf7 | |||
| 639245c071 | |||
| 034267adb2 | |||
| 6e47a6fb76 | |||
| 9569ae24e0 | |||
| 491526b421 | |||
| 5a41d75eb8 | |||
| 4bc431ec31 | |||
| 1bc9fd2863 | |||
| 5d82b0f4c4 | |||
| d3abff5486 | |||
| 77aa1fbeea | |||
| af9bc631cc | |||
| 762718002e | |||
| 16bbd93885 | |||
| 80eff58950 | |||
| 7ea4eb0095 | |||
| efc8c3f4a9 | |||
| 792c481f6d | |||
| 7973b01b1c | |||
| 11675d7645 | |||
| 1915fe75a4 | |||
| 9d1bb60ad7 | |||
| b7043ce000 | |||
| c64935f9dd | |||
| 629eddfb9f | |||
| 1f94c8f272 | |||
| 0c8611bd49 | |||
| 5dcb91b671 | |||
| 7abda27b46 | |||
| 901fc87bca | |||
| 54da9ac7e5 | |||
| e45360de2b | |||
| d59c449ff6 | |||
| 17df6c8878 | |||
| f901846acb | |||
| edcd2fc14a | |||
| 382bdcdcb7 | |||
| 1bbc60c3e7 | |||
| c13d345604 | |||
| efe907ffae | |||
| 0bba04ef8d | |||
| 43dae6c14d | |||
| 2b5c24b304 | |||
| 50b1e26b17 | |||
| 18e0559438 | |||
| 37513b1898 | |||
| fbbad7c851 | |||
| f8b3c48af7 | |||
| 3cc42c1bf8 | |||
| b6422c9a33 | |||
| 049e392a97 | |||
| 9a64d08c9f | |||
| c0f80cfe7a | |||
| 49e11b7cfd | |||
| 6a32ceaab5 | |||
| acc7320cae | |||
| 1a78e0e80c | |||
| e9e8f0c5b7 | |||
| cb52ee0a4d | |||
| 4488312e81 | |||
| 9d9b5c4d66 | |||
| b9ec012922 | |||
| d47a8b49a4 | |||
| 1759d6d90a | |||
| c4a01875d0 | |||
| f9a8efe406 | |||
| 7f4e546f19 | |||
| 0a2874405d | |||
| 87a5dd66ab | |||
| e57c01907e | |||
| 32df809626 | |||
| 7d2ed9200d | |||
| f6e90b4c72 | |||
| c1180d76dd | |||
| 6dfd97f0b6 | |||
| 327bb2d8f0 | |||
| 21f7b0ff0f | |||
| 15391f45d0 | |||
| 3c0bd821c8 | |||
| ec80932c21 | |||
| 3eca2d5d6c | |||
| d9a0619ddd | |||
| efafda2650 | |||
| 943368912b | |||
| 1d0f359406 | |||
| d5f019c3d3 | |||
| 67075dfc6c | |||
| a867522b16 | |||
| 26cccead6e | |||
| e6f7467f67 | |||
| 36d5db7f30 | |||
| e7b24461ec | |||
| 007a7a5859 | |||
| 59a0f810b9 | |||
| 9f678cc47a | |||
| aeebcfe141 | |||
| 48a847d1b6 | |||
| 232c6c3aaf | |||
| c9e35926f5 | |||
| 8ef69429d8 | |||
| 336cd6e33a | |||
| 360e484b08 | |||
| 92466165f6 | |||
| 1206a5d4b7 | |||
| c1d7b46235 | |||
| 795bc5d52b | |||
| ad8988afd3 | |||
| 7f07b79c04 | |||
| 610a6a1404 | |||
| a7aef22754 | |||
| 4e0070f16d | |||
| 7ae679adbe | |||
| d481c3c7fd | |||
| a9162a3f57 | |||
| b341113ad8 | |||
| 1e69de1205 | |||
| 79216917b3 | |||
| 698702cd4a | |||
| 1166ae19bb | |||
| 44f2cacf7b | |||
| 7a275eaa3a | |||
| 331c1a394a | |||
| e4ba096190 | |||
| 46df58b662 | |||
| 95ed2ef62e | |||
| 3f076d63e3 | |||
| 3e8a5c6395 | |||
| 18f167ddd0 | |||
| 1abdee242a | |||
| adcc3e9c4b | |||
| 949cfa7fdb | |||
| fe381b8581 | |||
| 160ddcf86b | |||
| f05a3da964 | |||
| ddda09607d | |||
| 9993df9b8b | |||
| 98a8eeaac2 | |||
| 0f87c6c7c3 | |||
| 0147bc2c72 | |||
| 1e7a02badb | |||
| 3617f12a1e | |||
| 63f67c88cc | |||
| 1b1b804d7e | |||
| 55cb96ab3b | |||
| 5ef3465f65 | |||
| 9a27cc9442 | |||
| 858ce014fd | |||
| 4dbad6cce6 | |||
| 485b22d664 | |||
| 30d5a849e3 | |||
| 9ef96e8274 | |||
| cbaa8f3329 | |||
| 807d6cfea4 | |||
| 22ca2827de | |||
| 5e0ca4c0c4 | |||
| 48407752a6 | |||
| bad4d1ff05 | |||
| 7453e46a7c | |||
| b07b5c9005 | |||
| 9d15083c61 | |||
| 14b99d9e8b | |||
| b36b9e4822 | |||
| 0a2b6a290d | |||
| ca5bc512ae | |||
| 449cbb7281 | |||
| e2512e78b6 | |||
| a005090d3d | |||
| 7fcc49004d | |||
| 833fbe015e | |||
| c9b0f0e734 | |||
| 9b34f00241 | |||
| 82af17beb1 | |||
| 47b196e9d0 | |||
| db014d8a58 | |||
| 621fab2ad9 | |||
| 086ecf4ba6 | |||
| 309251ce7a | |||
| 9084209cfc | |||
| 74ad525566 | |||
| 05e5e6058f | |||
| 556ac1cf22 | |||
| 85695c8bac | |||
| 2984300385 | |||
| ac4cadf538 | |||
| 175f78f5b3 | |||
| 3d96fe79cc | |||
| 1ccb3c4492 | |||
| 01035d35bd | |||
| 8bbda3dedb | |||
| a24514651c | |||
| 542d2ef8da | |||
| be2d225d96 | |||
| 765bd6b6c6 | |||
| aeed349a99 | |||
| 8447d75dda | |||
| fc6356a74c | |||
| 41f2ee7b6c | |||
| 87cd653c6e | |||
| 7e35fd54a8 | |||
| 582ee80552 | |||
| 0b4b87f069 | |||
| a8e1afa0af | |||
| 71df5044fc | |||
| db5d03c340 | |||
| 4a5559ee65 | |||
| 7523416a12 | |||
| 9075208c80 | |||
| d477889763 | |||
| ef3b0db7d8 | |||
| f5cb147f8d | |||
| 63e669c0cf | |||
| 9c54305e10 | |||
| f3d52de429 | |||
| 3f34a0196c | |||
| ecf00be155 | |||
| 071e73a68e | |||
| ad845861be | |||
| c51779d4d3 | |||
| 55f9a56e45 | |||
| 5bace118a7 | |||
| 28770c1580 | |||
| 192912131e | |||
| 94d2f97f27 | |||
| 632cc79c54 | |||
| e7845357e2 | |||
| 4450ae0c7a | |||
| 9fc0aec066 | |||
| bed2d558a6 | |||
| d5f0957558 | |||
| 7f09def94e | |||
| b88fb43acc | |||
| e7ddc5187a | |||
| 872be25ed1 | |||
| 9d2c9e5d62 | |||
| 28fb0d1741 | |||
| 5534c9e27c | |||
| 049f852a9c | |||
| 69f11d82d1 | |||
| f92794360d | |||
| bdb5115c7f | |||
| 3ada97d2d3 | |||
| 49d5ce3ba4 | |||
| 691a57a4da | |||
| 671ae20876 | |||
| 7af7e3cec1 | |||
| ca52c1e2d1 | |||
| 31b07fece5 | |||
| b3ad89cc8b | |||
| 5e7d25ad35 | |||
| d94d094a7e | |||
| c9aee27d48 | |||
| d12762414a | |||
| 7786681954 | |||
| 02ca8f0002 | |||
| 7af2ebb6f4 | |||
| 2c4ecc55af | |||
| c4e59b5115 | |||
| 4c20881f8f |
Executable
+29
@@ -0,0 +1,29 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
# Pull all the submodules except llvm
|
||||
# Note: Tried to use git submodule status, but it takes over 20 seconds
|
||||
# shellcheck disable=SC2046
|
||||
git submodule -q update --init --depth 1 $(awk '/path/ && !/llvm/ { print $3 }' .gitmodules)
|
||||
|
||||
# Prefer newer Clang than in base system (see also .ci/install-freebsd.sh)
|
||||
# libc++ isn't in llvm* packages, so download manually
|
||||
fetch https://github.com/llvm/llvm-project/releases/download/llvmorg-11.0.0/libcxx-11.0.0.src.tar.xz
|
||||
tar xf libcxx-11.0.0.src.tar.xz
|
||||
export CC=clang11 CXX=clang++11
|
||||
export CXXFLAGS="$CXXFLAGS -nostdinc++ -isystem $PWD/libcxx-11.0.0.src/include"
|
||||
|
||||
CONFIGURE_ARGS="
|
||||
-DWITH_LLVM=OFF
|
||||
-DUSE_PRECOMPILED_HEADERS=OFF
|
||||
-DUSE_NATIVE_INSTRUCTIONS=OFF
|
||||
-DUSE_SYSTEM_FFMPEG=ON
|
||||
-DUSE_SYSTEM_CURL=ON
|
||||
-DUSE_SYSTEM_LIBPNG=ON
|
||||
"
|
||||
|
||||
# shellcheck disable=SC2086
|
||||
cmake -B build -G Ninja $CONFIGURE_ARGS
|
||||
cmake --build build
|
||||
|
||||
ccache --show-stats
|
||||
ccache --zero-stats
|
||||
Executable
+65
@@ -0,0 +1,65 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
# Setup Qt variables
|
||||
export QT_BASE_DIR=/opt/qt${QTVERMIN}
|
||||
export PATH=$QT_BASE_DIR/bin:$PATH
|
||||
export LD_LIBRARY_PATH=$QT_BASE_DIR/lib/x86_64-linux-gnu:$QT_BASE_DIR/lib
|
||||
|
||||
cd rpcs3 || exit 1
|
||||
|
||||
# Pull all the submodules except llvm, since it is built separately and we just download that build
|
||||
# Note: Tried to use git submodule status, but it takes over 20 seconds
|
||||
# shellcheck disable=SC2046
|
||||
git submodule -q update --init $(awk '/path/ && !/llvm/ { print $3 }' .gitmodules)
|
||||
|
||||
# Download pre-compiled llvm libs
|
||||
curl -sLO https://github.com/RPCS3/llvm-mirror/releases/download/custom-build/llvmlibs-linux.tar.gz
|
||||
mkdir llvmlibs
|
||||
tar -xzf ./llvmlibs-linux.tar.gz -C llvmlibs
|
||||
|
||||
mkdir build && cd build || exit 1
|
||||
|
||||
if [ "$COMPILER" = "gcc" ]; then
|
||||
# These are set in the dockerfile
|
||||
export CC=${GCC_BINARY}
|
||||
export CXX=${GXX_BINARY}
|
||||
export LINKER=gold
|
||||
# We need to set the following variables for LTO to link properly
|
||||
export AR=/usr/bin/gcc-ar-$GCCVER
|
||||
export RANLIB=/usr/bin/gcc-ranlib-$GCCVER
|
||||
export CFLAGS="-fuse-linker-plugin"
|
||||
else
|
||||
export CC=${CLANG_BINARY}
|
||||
export CXX=${CLANGXX_BINARY}
|
||||
export LINKER=lld
|
||||
export AR=/usr/bin/llvm-ar-$LLVMVER
|
||||
export RANLIB=/usr/bin/llvm-ranlib-$LLVMVER
|
||||
fi
|
||||
|
||||
export CFLAGS="$CFLAGS -fuse-ld=${LINKER}"
|
||||
|
||||
cmake .. \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr \
|
||||
-DBUILD_LLVM_SUBMODULE=OFF \
|
||||
-DLLVM_DIR=llvmlibs/lib/cmake/llvm/ \
|
||||
-DUSE_NATIVE_INSTRUCTIONS=OFF \
|
||||
-DUSE_PRECOMPILED_HEADERS=OFF \
|
||||
-DCMAKE_C_FLAGS="$CFLAGS" \
|
||||
-DCMAKE_CXX_FLAGS="$CFLAGS" \
|
||||
-DCMAKE_AR="$AR" \
|
||||
-DCMAKE_RANLIB="$RANLIB" \
|
||||
-DUSE_SYSTEM_CURL=ON \
|
||||
-G Ninja
|
||||
|
||||
ninja; build_status=$?;
|
||||
|
||||
cd ..
|
||||
|
||||
# If it compiled succesfully let's deploy depending on the build pipeline (Azure Pipelines).
|
||||
# Azure publishes PRs as artifacts only.
|
||||
{ [ "$IS_AZURE" = "true" ];
|
||||
} && SHOULD_DEPLOY="true" || SHOULD_DEPLOY="false"
|
||||
|
||||
if [ "$build_status" -eq 0 ] && [ "$SHOULD_DEPLOY" = "true" ]; then
|
||||
.ci/deploy-linux.sh
|
||||
fi
|
||||
Regular → Executable
+10
-5
@@ -1,3 +1,5 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
export CCACHE_SLOPPINESS=pch_defines,time_macros
|
||||
export CMAKE_PREFIX_PATH=/usr/local/opt/qt5/
|
||||
export PATH="/usr/local/opt/ccache/libexec:$PATH"
|
||||
@@ -8,15 +10,18 @@ unzip -: gfx-portability-macos-latest.zip
|
||||
curl -sLO https://github.com/KhronosGroup/Vulkan-Headers/archive/sdk-1.1.106.0.zip
|
||||
unzip -: sdk-*.zip
|
||||
mkdir vulkan-sdk
|
||||
ln -s ${PWD}/Vulkan-Headers*/include vulkan-sdk/include
|
||||
ln -s "${PWD}"/Vulkan-Headers*/include vulkan-sdk/include
|
||||
mkdir vulkan-sdk/lib
|
||||
cp target/release/libportability.dylib vulkan-sdk/lib/libVulkan.dylib
|
||||
# Let macdeployqt locate and install Vulkan library
|
||||
install_name_tool -id ${PWD}/vulkan-sdk/lib/libVulkan.dylib vulkan-sdk/lib/libVulkan.dylib
|
||||
export VULKAN_SDK=${PWD}/vulkan-sdk
|
||||
install_name_tool -id "${PWD}"/vulkan-sdk/lib/libVulkan.dylib vulkan-sdk/lib/libVulkan.dylib
|
||||
export VULKAN_SDK="${PWD}/vulkan-sdk"
|
||||
|
||||
git submodule update --quiet --init asmjit 3rdparty/ffmpeg 3rdparty/pugixml 3rdparty/span 3rdparty/libpng 3rdparty/cereal 3rdparty/hidapi 3rdparty/libusb 3rdparty/xxHash 3rdparty/yaml-cpp 3rdparty/FAudio Vulkan/glslang
|
||||
# Pull all the submodules except llvm
|
||||
# Note: Tried to use git submodule status, but it takes over 20 seconds
|
||||
# shellcheck disable=SC2046
|
||||
git submodule -q update --init $(awk '/path/ && !/llvm/ { print $3 }' .gitmodules)
|
||||
|
||||
mkdir build; cd build
|
||||
mkdir build && cd build || exit 1
|
||||
cmake .. -DWITH_LLVM=OFF -DUSE_NATIVE_INSTRUCTIONS=OFF -G Ninja
|
||||
ninja
|
||||
Executable
+59
@@ -0,0 +1,59 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
cd build || exit 1
|
||||
|
||||
if [ "$DEPLOY_APPIMAGE" = "true" ]; then
|
||||
DESTDIR=appdir ninja install
|
||||
QT_APPIMAGE="linuxdeployqt.AppImage"
|
||||
|
||||
curl -sL "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage" > "$QT_APPIMAGE"
|
||||
chmod a+x "$QT_APPIMAGE"
|
||||
"./$QT_APPIMAGE" --appimage-extract
|
||||
./squashfs-root/AppRun ./appdir/usr/share/applications/*.desktop -bundle-non-qt-libs
|
||||
ls ./appdir/usr/lib/
|
||||
rm -r ./appdir/usr/share/doc
|
||||
rm ./appdir/usr/lib/libxcb*
|
||||
cp "$(readlink -f /lib/x86_64-linux-gnu/libnsl.so.1)" ./appdir/usr/lib/libnsl.so.1
|
||||
export PATH=/rpcs3/build/squashfs-root/usr/bin/:${PATH}
|
||||
|
||||
# Embed newer libstdc++ for distros that don't come with it (ubuntu 16.04)
|
||||
mkdir -p appdir/usr/optional/ ; mkdir -p appdir/usr/optional/libstdc++/
|
||||
cp /usr/lib/x86_64-linux-gnu/libstdc++.so.6 ./appdir/usr/optional/libstdc++/
|
||||
rm ./appdir/AppRun
|
||||
curl -sL https://github.com/RPCS3/AppImageKit-checkrt/releases/download/continuous2/AppRun-patched-x86_64 -o ./appdir/AppRun
|
||||
chmod a+x ./appdir/AppRun
|
||||
curl -sL https://github.com/RPCS3/AppImageKit-checkrt/releases/download/continuous2/exec-x86_64.so -o ./appdir/usr/optional/exec.so
|
||||
|
||||
# Compile checker binary for AppImageKit-checkrt
|
||||
|
||||
# This may need updating if you update the compiler or rpcs3 uses newer c++ features
|
||||
# See https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/config/abi/pre/gnu.ver
|
||||
# for which definitions correlate to which CXXABI version.
|
||||
# Currently we target a minimum of GLIBCXX_3.4.26 and CXXABI_1.3.11
|
||||
printf "#include <bits/stdc++.h>\nint main(){std::make_exception_ptr(0);std::pmr::get_default_resource();}" | $CXX -x c++ -std=c++2a -o ./appdir/usr/optional/checker -
|
||||
|
||||
# Package it up and send it off
|
||||
./squashfs-root/usr/bin/appimagetool /rpcs3/build/appdir
|
||||
ls
|
||||
|
||||
COMM_TAG="$(grep 'version{.*}' ../rpcs3/rpcs3_version.cpp | awk -F[\{,] '{printf "%d.%d.%d", $2, $3, $4}')"
|
||||
COMM_COUNT="$(git rev-list --count HEAD)"
|
||||
COMM_HASH="$(git rev-parse --short=8 HEAD)"
|
||||
RPCS3_APPIMAGE="rpcs3-v${COMM_TAG}-${COMM_COUNT}-${COMM_HASH}_linux64.AppImage"
|
||||
|
||||
mv ./RPCS3*.AppImage "$RPCS3_APPIMAGE"
|
||||
|
||||
# If we're building using Azure Pipelines, let's copy over the AppImage artifact
|
||||
if [ -n "$BUILD_ARTIFACTSTAGINGDIRECTORY" ]; then
|
||||
cp "$RPCS3_APPIMAGE" ~/artifacts
|
||||
fi
|
||||
|
||||
FILESIZE=$(stat -c %s ./rpcs3*.AppImage)
|
||||
SHA256SUM=$(sha256sum ./rpcs3*.AppImage | awk '{ print $1 }')
|
||||
echo "${SHA256SUM};${FILESIZE}B" > /rpcs3/GitHubReleaseMessage.txt
|
||||
|
||||
fi
|
||||
|
||||
if [ "$DEPLOY_PPA" = "true" ]; then
|
||||
export DEBFULLNAME="RPCS3 Build Bot"
|
||||
fi
|
||||
Executable
+24
@@ -0,0 +1,24 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
# BUILD_blablabla is Azure specific, so we wrap it for portability
|
||||
ARTIFACT_DIR="$BUILD_ARTIFACTSTAGINGDIRECTORY"
|
||||
|
||||
# Remove unecessary files
|
||||
rm -f ./bin/rpcs3.exp ./bin/rpcs3.lib ./bin/rpcs3.pdb
|
||||
|
||||
# Prepare compatibility database for packaging, as well as
|
||||
# certificate for ssl (auto-updater)
|
||||
curl -sL 'https://rpcs3.net/compatibility?api=v1&export' | iconv -t UTF-8 > ./bin/GuiConfigs/compat_database.dat
|
||||
curl -sL 'https://curl.haxx.se/ca/cacert.pem' > ./bin/cacert.pem
|
||||
|
||||
# Package artifacts
|
||||
7z a -m0=LZMA2 -mx9 "$BUILD" ./bin/*
|
||||
|
||||
# Generate sha256 hashes
|
||||
# Write to file for GitHub releases
|
||||
sha256sum "$BUILD" | awk '{ print $1 }' | tee "$BUILD.sha256"
|
||||
echo "$(cat "$BUILD.sha256");$(stat -c %s "$BUILD")B" > GitHubReleaseMessage.txt
|
||||
|
||||
# Move files to publishing directory
|
||||
mv -- "$BUILD" "$ARTIFACT_DIR"
|
||||
mv -- "$BUILD.sha256" "$ARTIFACT_DIR"
|
||||
@@ -0,0 +1,12 @@
|
||||
# Variables set by Azure Pipelines
|
||||
IS_AZURE
|
||||
BUILD_REASON
|
||||
BUILD_SOURCEVERSION
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY
|
||||
BUILD_REPOSITORY_NAME
|
||||
BUILD_SOURCEBRANCHNAME
|
||||
# Variables for build matrix
|
||||
COMPILER
|
||||
DEPLOY_APPIMAGE
|
||||
# Private variables
|
||||
GITHUB_TOKEN
|
||||
Executable
+13
@@ -0,0 +1,13 @@
|
||||
#!/bin/sh -e
|
||||
|
||||
# Export variables for later stages of the Azure pipeline
|
||||
# Values done in this manner will appear as environment variables
|
||||
# in later stages.
|
||||
|
||||
# From pure-sh-bible
|
||||
# Setting 'IFS' tells 'read' where to split the string.
|
||||
while IFS='=' read -r key val; do
|
||||
# Skip over lines containing comments.
|
||||
[ "${key##\#*}" ] || continue
|
||||
echo "##vso[task.setvariable variable=$key]$val"
|
||||
done < ".ci/azure-vars.env"
|
||||
@@ -0,0 +1,4 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
curl -L -o "./llvm.lock" "https://github.com/RPCS3/llvm-mirror/releases/download/custom-build-win/llvmlibs_mt.7z.sha256"
|
||||
curl -L -o "./glslang.lock" "https://github.com/RPCS3/glslang/releases/download/custom-build-win/glslanglibs_mt.7z.sha256"
|
||||
Executable
+42
@@ -0,0 +1,42 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
ARTIFACT_DIR="$BUILD_ARTIFACTSTAGINGDIRECTORY"
|
||||
generate_post_data()
|
||||
{
|
||||
body=$(cat GitHubReleaseMessage.txt)
|
||||
cat <<EOF
|
||||
{
|
||||
"tag_name": "build-${BUILD_SOURCEVERSION}",
|
||||
"target_commitish": "${UPLOAD_COMMIT_HASH}",
|
||||
"name": "${AVVER}",
|
||||
"body": "$body",
|
||||
"draft": false,
|
||||
"prerelease": false
|
||||
}
|
||||
EOF
|
||||
}
|
||||
|
||||
curl -s \
|
||||
-H "Authorization: token ${RPCS3_TOKEN}" \
|
||||
-H "Accept: application/vnd.github.v3+json" \
|
||||
--data "$(generate_post_data)" "https://api.github.com/repos/$UPLOAD_REPO_FULL_NAME/releases" >> release.json
|
||||
|
||||
cat release.json
|
||||
id=$(grep '"id"' release.json | cut -d ':' -f2 | head -n1 | awk '{$1=$1;print}')
|
||||
id=${id%?}
|
||||
echo ${id:?}
|
||||
|
||||
upload_file()
|
||||
{
|
||||
curl -s \
|
||||
-H "Authorization: token ${RPCS3_TOKEN}" \
|
||||
-H "Accept: application/vnd.github.v3+json" \
|
||||
-H "Content-Type: application/octet-stream" \
|
||||
--data-binary @"$2"/"$3" \
|
||||
"https://uploads.github.com/repos/$UPLOAD_REPO_FULL_NAME/releases/$1/assets?name=$3"
|
||||
}
|
||||
|
||||
for file in "$ARTIFACT_DIR"/*; do
|
||||
name=$(basename "$file")
|
||||
upload_file "$id" "$ARTIFACT_DIR" "$name"
|
||||
done
|
||||
Executable
+18
@@ -0,0 +1,18 @@
|
||||
#!/usr/bin/env -S su -m root -ex
|
||||
# NOTE: this script is run under root permissions
|
||||
# shellcheck shell=sh disable=SC2096
|
||||
|
||||
# RPCS3 often needs recent Qt5 and Vulkan-Headers
|
||||
sed -i '' 's/quarterly/latest/' /etc/pkg/FreeBSD.conf
|
||||
|
||||
export ASSUME_ALWAYS_YES=true
|
||||
pkg info # debug
|
||||
|
||||
# Prefer newer Clang than in base system (see also .ci/build-freebsd.sh)
|
||||
pkg install llvm11
|
||||
|
||||
# Mandatory dependencies (qt5-dbus and qt5-gui are pulled via qt5-widgets)
|
||||
pkg install git ccache cmake ninja qt5-qmake qt5-buildtools qt5-widgets qt5-concurrent glew openal-soft ffmpeg
|
||||
|
||||
# Optional dependencies (libevdev is pulled by qt5-gui)
|
||||
pkg install pkgconf alsa-lib pulseaudio sdl2 evdev-proto vulkan-headers vulkan-loader
|
||||
Executable
+115
@@ -0,0 +1,115 @@
|
||||
#!/bin/sh -ex
|
||||
|
||||
# These are Azure specific, so we wrap them for portability
|
||||
REPO_NAME="$BUILD_REPOSITORY_NAME"
|
||||
REPO_BRANCH="$SYSTEM_PULLREQUEST_SOURCEBRANCH"
|
||||
PR_NUMBER="$SYSTEM_PULLREQUEST_PULLREQUESTID"
|
||||
|
||||
# Resource/dependency URLs
|
||||
# Qt mirrors can be volatile and slow, so we list 2
|
||||
QT_HOST="http://mirrors.ocf.berkeley.edu/qt/"
|
||||
#QT_HOST="http://qt.mirror.constant.com/"
|
||||
QT_URL_VER=$(echo "$QT_VER" | sed "s/\.//g")
|
||||
QT_VER_MSVC_UP=$(echo ${QT_VER_MSVC} | tr '[:lower:]' '[:upper:]')
|
||||
QT_PREFIX="online/qtsdkrepository/windows_x86/desktop/qt${QT_VER_MAIN}_${QT_URL_VER}/qt.qt${QT_VER_MAIN}.${QT_URL_VER}.win64_${QT_VER_MSVC}_64/${QT_VER}-0-${QT_DATE}"
|
||||
QT_SUFFIX="-Windows-Windows_10-${QT_VER_MSVC_UP}-Windows-Windows_10-X86_64.7z"
|
||||
QT_BASE_URL="${QT_HOST}${QT_PREFIX}qtbase${QT_SUFFIX}"
|
||||
QT_WINE_URL="${QT_HOST}${QT_PREFIX}qtwinextras${QT_SUFFIX}"
|
||||
QT_DECL_URL="${QT_HOST}${QT_PREFIX}qtdeclarative${QT_SUFFIX}"
|
||||
QT_TOOL_URL="${QT_HOST}${QT_PREFIX}qttools${QT_SUFFIX}"
|
||||
LLVMLIBS_URL='https://github.com/RPCS3/llvm-mirror/releases/download/custom-build-win/llvmlibs_mt.7z'
|
||||
GLSLANG_URL='https://github.com/RPCS3/glslang/releases/download/custom-build-win/glslanglibs_mt.7z'
|
||||
VULKAN_SDK_URL="https://www.dropbox.com/s/kn005de7gsv5whe/VulkanSDK-1.2.154.1-Installer.exe"
|
||||
|
||||
DEP_URLS=" \
|
||||
$QT_BASE_URL \
|
||||
$QT_WINE_URL \
|
||||
$QT_DECL_URL \
|
||||
$QT_TOOL_URL \
|
||||
$LLVMLIBS_URL \
|
||||
$GLSLANG_URL \
|
||||
$VULKAN_SDK_URL"
|
||||
|
||||
# Azure pipelines doesn't make a cache dir if it doesn't exist, so we do it manually
|
||||
[ -d "$CACHE_DIR" ] || mkdir "$CACHE_DIR"
|
||||
|
||||
# Pull all the submodules except llvm, since it is built separately and we just download that build
|
||||
# Note: Tried to use git submodule status, but it takes over 20 seconds
|
||||
# shellcheck disable=SC2046
|
||||
git submodule -q update --init --depth 1 $(awk '/path/ && !/llvm/ { print $3 }' .gitmodules)
|
||||
|
||||
# Git bash doesn't have rev, so here it is
|
||||
rev()
|
||||
{
|
||||
echo "$1" | awk '{ for(i = length($0); i != 0; --i) { a = a substr($0, i, 1); } } END { print a }'
|
||||
}
|
||||
|
||||
# Usage: download_and_verify url checksum algo file
|
||||
# Check to see if a file is already cached, and the checksum matches. If not, download it.
|
||||
# Tries up to 3 times
|
||||
download_and_verify()
|
||||
{
|
||||
url="$1"
|
||||
correctChecksum="$2"
|
||||
algo="$3"
|
||||
fileName="$4"
|
||||
|
||||
for _ in 1 2 3; do
|
||||
[ -e "$CACHE_DIR/$fileName" ] || curl -L -o "$CACHE_DIR/$fileName" "$url"
|
||||
fileChecksum=$("${algo}sum" "$CACHE_DIR/$fileName" | awk '{ print $1 }')
|
||||
[ "$fileChecksum" = "$correctChecksum" ] && return 0
|
||||
rm "$CACHE_DIR/$fileName"
|
||||
done
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
# Some dependencies install here
|
||||
[ -d "./lib" ] || mkdir "./lib"
|
||||
|
||||
for url in $DEP_URLS; do
|
||||
# Get the filename from the URL. Breaks if urls have js args, so don't do that pls
|
||||
fileName="$(rev "$(rev "$url" | cut -d'/' -f1)")"
|
||||
[ -z "$fileName" ] && echo "Unable to parse url: $url" && exit 1
|
||||
|
||||
# shellcheck disable=SC1003
|
||||
case "$url" in
|
||||
*qt*) checksum=$(curl -L "${url}.sha1"); algo="sha1"; outDir='C:\Qt\' ;;
|
||||
*llvm*) checksum=$(curl -L "${url}.sha256"); algo="sha256"; outDir="." ;;
|
||||
*glslang*) checksum=$(curl -L "${url}.sha256"); algo="sha256"; outDir="./lib/Release - LLVM-x64" ;;
|
||||
*Vulkan*)
|
||||
# Vulkan setup needs to be run in batch environment
|
||||
# Need to subshell this or else it doesn't wait
|
||||
download_and_verify "$url" "$VULKAN_SDK_SHA" "sha256" "$fileName"
|
||||
cp "$CACHE_DIR/$fileName" .
|
||||
_=$(echo "$fileName /S" | cmd)
|
||||
continue
|
||||
;;
|
||||
*) echo "Unknown url resource: $url"; exit 1 ;;
|
||||
esac
|
||||
|
||||
download_and_verify "$url" "$checksum" "$algo" "$fileName"
|
||||
7z x -y "$CACHE_DIR/$fileName" -aos -o"$outDir"
|
||||
done
|
||||
|
||||
# Gather explicit version number and number of commits
|
||||
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ./rpcs3/rpcs3_version.cpp)
|
||||
COMM_COUNT=$(git rev-list --count HEAD)
|
||||
COMM_HASH=$(git rev-parse --short=8 HEAD)
|
||||
|
||||
# Format the above into filenames
|
||||
if [ -n "$PR_NUMBER" ]; then
|
||||
AVVER="${COMM_TAG}-${COMM_HASH}"
|
||||
BUILD="rpcs3-v${AVVER}_win64.7z"
|
||||
else
|
||||
AVVER="${COMM_TAG}-${COMM_COUNT}"
|
||||
BUILD="rpcs3-v${AVVER}-${COMM_HASH}_win64.7z"
|
||||
fi
|
||||
|
||||
# BRANCH is used for experimental build warnings for pr builds, used in main_window.cpp.
|
||||
# BUILD is the name of the release artifact
|
||||
# AVVER is used for GitHub releases, it is the version number.
|
||||
BRANCH="${REPO_NAME}/${REPO_BRANCH}"
|
||||
echo "BRANCH=$BRANCH" > .ci/azure-vars.env
|
||||
echo "BUILD=$BUILD" >> .ci/azure-vars.env
|
||||
echo "AVVER=$AVVER" >> .ci/azure-vars.env
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
env:
|
||||
CIRRUS_CLONE_DEPTH: 0 # Unshallow clone to obtain proper GIT_VERSION
|
||||
|
||||
freebsd_task:
|
||||
matrix:
|
||||
- name: FreeBSD 12.2
|
||||
freebsd_instance:
|
||||
image_family: freebsd-12-2
|
||||
cpu: 8
|
||||
memory: 8G
|
||||
env:
|
||||
CCACHE_MAXSIZE: 300M # 3x clean build, rounded
|
||||
CCACHE_DIR: /tmp/ccache_dir
|
||||
ccache_cache:
|
||||
folder: /tmp/ccache_dir
|
||||
packages_cache:
|
||||
folder: /var/cache/pkg
|
||||
install_script: "sh -ex ./.ci/install-freebsd.sh"
|
||||
script: "./.ci/build-freebsd.sh"
|
||||
+11
-11
@@ -1,20 +1,20 @@
|
||||
Standard: Cpp11
|
||||
Standard: c++20
|
||||
UseTab: ForIndentation
|
||||
TabWidth: 1
|
||||
IndentWidth: 1
|
||||
AccessModifierOffset: -1
|
||||
TabWidth: 4
|
||||
IndentWidth: 4
|
||||
AccessModifierOffset: -4
|
||||
PointerAlignment: Left
|
||||
NamespaceIndentation: All
|
||||
ColumnLimit: 200
|
||||
ColumnLimit: 0
|
||||
BreakBeforeBraces: Allman
|
||||
BreakConstructorInitializersBeforeComma: true
|
||||
BreakBeforeBinaryOperators: false
|
||||
BreakConstructorInitializers: BeforeColon
|
||||
BreakBeforeBinaryOperators: None
|
||||
BreakBeforeTernaryOperators: false
|
||||
AlwaysBreakTemplateDeclarations: true
|
||||
AllowShortIfStatementsOnASingleLine: false
|
||||
AllowShortBlocksOnASingleLine: false
|
||||
AlwaysBreakTemplateDeclarations: Yes
|
||||
AllowShortIfStatementsOnASingleLine: Never
|
||||
AllowShortBlocksOnASingleLine: Never
|
||||
AllowShortCaseLabelsOnASingleLine: true
|
||||
AllowShortFunctionsOnASingleLine: false
|
||||
AllowShortFunctionsOnASingleLine: Empty
|
||||
AllowShortLoopsOnASingleLine: false
|
||||
Cpp11BracedListStyle: true
|
||||
IndentCaseLabels: false
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
root = true
|
||||
|
||||
[*.{h,cpp,hpp}]
|
||||
charset = utf-8-bom
|
||||
charset = utf-8
|
||||
indent_style = tab
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
<!---
|
||||
|
||||
THIS IS NOT A SUPPORT FORUM, FOR SUPPORT GO TO:
|
||||
https://forums.rpcs3.net
|
||||
or our discord:
|
||||
https://discord.me/RPCS3
|
||||
|
||||
PLEASE READ THE GUIDELINES BEFORE OPENING AN ISSUE:
|
||||
https://github.com/RPCS3/rpcs3/blob/master/.github/CONTRIBUTING.md
|
||||
|
||||
====================================================
|
||||
|
||||
When submitting an issue, please check the following:
|
||||
|
||||
- You have read the above.
|
||||
- You have provided the version (commit hash) of RPCS3 you are using.
|
||||
- You have provided sufficient detail for the issue to be reproduced.
|
||||
- You have provided system specs.
|
||||
- Please also provide:
|
||||
- For crashes, a backtrace.
|
||||
- For graphical issues, comparison screenshots with real hardware.
|
||||
|
||||
Remember that the GitHub Issue Tracker is not the place to ask for support or to submit Game Compatibility reports. You must use our forums for that.
|
||||
--->
|
||||
@@ -0,0 +1,62 @@
|
||||
---
|
||||
name: Regression report
|
||||
about: If something used to work before, but now it doesn't
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
## Please do not ask for help or report compatibility regressions here, use [RPCS3 Discord server](https://discord.me/RPCS3) or [forums](https://forums.rpcs3.net/) instead.
|
||||
|
||||
## Quick summary
|
||||
Please briefly describe what has stopped working correctly.
|
||||
|
||||
## Details
|
||||
Please describe the regression as accurately as possible.
|
||||
|
||||
#### 1. Please provide _exact_ build (or commit) information that introduced the regression you're reporting.
|
||||
* Please see [How to find the build that caused a regression](https://wiki.rpcs3.net/index.php?title=Help:Using_different_versions_of_RPCS3#How_to_find_the_build_that_caused_a_regression.3F) in our wiki.
|
||||
* You can find [History of RPCS3 builds](https://rpcs3.net/compatibility?b) here.
|
||||
|
||||
#### 2. Please attach TWO logs:
|
||||
* One for the build with regression.
|
||||
* One for the build that works as expected.
|
||||
|
||||
##### How to obtain RPCS3's log:
|
||||
* Run the game until you find the regression.
|
||||
* Completely close RPCS3, or move to the next step in case it has crashed.
|
||||
* Locate RPCS3's log file:
|
||||
+ ```RPCS3.log``` (It can show up as just RPCS3 and have a notepad icon)
|
||||
or
|
||||
+ ```RPCS3.log.gz``` (It can show up as RPCS3.log and have a zip or rar icon)
|
||||

|
||||
On Linux it will be in ```~/.cache/rpcs3/```.
|
||||
On Windows it will be near the executable.
|
||||
* Attach the log:
|
||||
+ Drag and drop your log file into the issue.
|
||||
+ Or upload it to the cloud, such as Dropbox, Mega etc.
|
||||
|
||||
#### 3. If you describe graphical regression, please provide an RSX capture and a RenderDoc capture that demonstrate it.
|
||||
* To create an RSX capture, use _Create_ _RSX_ _Capture_ under _Utilities_.
|
||||
Captures will be stored in RPCS3 folder → captures.
|
||||
+ Compress your capture with 7z, Rar etc.
|
||||
And drag and drop it into the issue.
|
||||
+ Or upload it to the cloud, such as Dropbox, Mega etc.
|
||||
* To create a RenderDoc capture, please refer to [RenderDoc's documentation](https://renderdoc.org/docs/how/how_capture_frame.html).
|
||||
|
||||
#### 4. Please attach screenshots of your problem.
|
||||
* Enable performance overlay with at least medium level of detail.
|
||||
You can find it in _Emulator_ tab in _Settings_.
|
||||
|
||||
#### 5. Please provide comparison with real PS3.
|
||||
|
||||
#### 6. Please provide your system configuration:
|
||||
* OS
|
||||
* CPU
|
||||
* GPU
|
||||
* Driver version
|
||||
* etc.
|
||||
|
||||
#### Please include.
|
||||
* Anything else you deem to be important
|
||||
@@ -0,0 +1,55 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: If something doesn't work correctly in RPCS3
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
## Please do not ask for help or report compatibility regressions here, use [RPCS3 Discord server](https://discord.me/RPCS3) or [forums](https://forums.rpcs3.net/) instead.
|
||||
|
||||
## Quick summary
|
||||
Please briefly describe what is not working correctly.
|
||||
|
||||
## Details
|
||||
|
||||
Please describe the problem as accurately as possible.
|
||||
|
||||
#### 1. Please attach RPCS3's log.
|
||||
* Run the game until you find the issue.
|
||||
* Completely close RPCS3, or move to the next step in case it has crashed.
|
||||
* Locate RPCS3's log file:
|
||||
+ ```RPCS3.log``` (It can show up as just RPCS3 and have a notepad icon)
|
||||
or
|
||||
+ ```RPCS3.log.gz``` (It can show up as RPCS3.log and have a zip or rar icon)
|
||||

|
||||
On Linux it will be in ```~/.cache/rpcs3/```.
|
||||
On Windows it will be near the executable.
|
||||
* Attach the log:
|
||||
+ Drag and drop your log file into the issue.
|
||||
+ Or upload it to the cloud, such as Dropbox, Mega etc.
|
||||
|
||||
#### 2. If you describe graphical issue, please provide an RSX capture and a RenderDoc capture that demonstrate it.
|
||||
* To create an RSX capture, use _Create_ _RSX_ _Capture_ under _Utilities_.
|
||||
Captures will be stored in RPCS3 folder → captures.
|
||||
+ Compress your capture with 7z, Rar etc.
|
||||
And drag and drop it into the issue.
|
||||
+ Or upload it to the cloud, such as Dropbox, Mega etc.
|
||||
* To create a RenderDoc capture, please refer to [RenderDoc's documentation](https://renderdoc.org/docs/how/how_capture_frame.html).
|
||||
|
||||
#### 3. Please attach screenshots of your problem.
|
||||
* Enable performance overlay with at least medium level of detail.
|
||||
You can find it in _Emulator_ tab in _Settings_.
|
||||
|
||||
#### 4. Please provide comparison with real PS3.
|
||||
|
||||
#### 5. Please provide your system configuration:
|
||||
* OS
|
||||
* CPU
|
||||
* GPU
|
||||
* Driver version
|
||||
* etc.
|
||||
|
||||
#### Please include.
|
||||
* Anything else you deem to be important
|
||||
@@ -0,0 +1,41 @@
|
||||
---
|
||||
name: Feature Request
|
||||
about: If RPCS3 lacks a feature you would like to see
|
||||
title: '[Feature Request] Enter Feature Title Here'
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
## Please do not ask for help or report compatibility regressions here, use [RPCS3 Discord server](https://discord.me/RPCS3) or [forums](https://forums.rpcs3.net/) instead.
|
||||
|
||||
## Quick summary
|
||||
Please briefly describe what feature you would like RPCS3 to have.
|
||||
|
||||
## Details
|
||||
|
||||
Please describe the feature as accurately as possible.
|
||||
|
||||
#### 1. Please describe, what part of RPCS3 would be affected by your feature:
|
||||
* Gameplay
|
||||
* Debugging
|
||||
* UI
|
||||
* Patches
|
||||
* Installation
|
||||
* Github
|
||||
* CI
|
||||
* etc.
|
||||
|
||||
#### 2. Please tell us, why your feature is important to RPCS3.
|
||||
|
||||
#### 3. Please attach screenshots of the feature implemented in other projects.
|
||||
|
||||
#### 4. Please provide your system configuration:
|
||||
* OS
|
||||
* CPU
|
||||
* GPU
|
||||
* Driver version
|
||||
* etc.
|
||||
|
||||
#### Please include.
|
||||
* Anything else you deem to be important
|
||||
@@ -0,0 +1,11 @@
|
||||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: Quickstart guide
|
||||
url: https://rpcs3.net/quickstart
|
||||
about: Everything you need to know to install and configure emulator, and add games
|
||||
- name: Ask for help
|
||||
url: https://discord.me/RPCS3
|
||||
about: If you have some questions or need help, please use our Discord server instead of GitHub
|
||||
- name: Report game compatibility
|
||||
url: https://forums.rpcs3.net/thread-196671.html
|
||||
about: Please use RPCS3 forums to submit or update game compatibility status
|
||||
@@ -0,0 +1,20 @@
|
||||
## How to test a PR build
|
||||
|
||||
Please take into account, that RPCS3 build usually takes some time (about 20 min), so you can't access a build, if a PR was just submitted.
|
||||
|
||||
- Open a PR you want to test
|
||||
- Scroll to the very bottom and locate "Checks" section
|
||||
- Expand all checks
|
||||
You are supposed to see something like this
|
||||

|
||||
- Click on **Linux_Build** or **Windows_Build** __Details__
|
||||
- Click **View more details on Azure Pipelines** at the very bottom
|
||||

|
||||
- Click on *1 artifact produced*
|
||||

|
||||
- Select a build for your OS and click three dots on the right, Click **Download artifacts**
|
||||

|
||||
|
||||
- Congratulations! You are now downloading RPCS3 build for specific PR.
|
||||
|
||||
Please note, that PR builds are not supposed to be stable, because they contain new changesets.
|
||||
@@ -0,0 +1,3 @@
|
||||
<!-- Please include a summary of the change and which issue is fixed. -->
|
||||
|
||||
[How to test this PR](.github/PR-BUILD.md)
|
||||
+17
@@ -37,8 +37,10 @@
|
||||
/rpcs3/Debug
|
||||
/rpcs3/Release
|
||||
/llvm_build
|
||||
/3rdparty/llvm_build
|
||||
/Vulkan/Vulkan-build
|
||||
/Vulkan/glslang-build
|
||||
/Vulkan/spirv-tools-build
|
||||
|
||||
!/bin
|
||||
/bin/*
|
||||
@@ -71,10 +73,15 @@ Makefile
|
||||
*CMakeFiles*
|
||||
CMakeCache.txt
|
||||
*cmake_install.cmake*
|
||||
CPackConfig.cmake
|
||||
CPackSourceConfig.cmake
|
||||
compile_commands.json
|
||||
|
||||
# cotire
|
||||
rpcs3/cotire/*
|
||||
rpcs3/rpcs3_*_cotire.cmake
|
||||
rpcs3/Emu/rpcs3_emu_CXX_Release_cotire.cmake
|
||||
rpcs3/Emu/rpcs3_emu_CXX_cotire.cmake
|
||||
|
||||
# kdevelop
|
||||
*.kdev4
|
||||
@@ -99,3 +106,13 @@ CMakeLists.txt.user
|
||||
|
||||
# 7zlib
|
||||
/3rdparty/7z/**/*.lib
|
||||
|
||||
# yaml-cpp
|
||||
yaml-cpp.pc
|
||||
|
||||
# libusb
|
||||
/3rdparty/libusb_cmake/config.h
|
||||
/3rdparty/libusb_cmake/libusb-1.0.pc
|
||||
|
||||
# ssl certificate
|
||||
cacert.pem
|
||||
|
||||
+26
-6
@@ -1,6 +1,6 @@
|
||||
[submodule "rpcs3-ffmpeg"]
|
||||
path = 3rdparty/ffmpeg
|
||||
url = https://github.com/hrydgard/ppsspp-ffmpeg
|
||||
url = https://github.com/RPCS3/ffmpeg-core
|
||||
ignore = dirty
|
||||
[submodule "asmjit"]
|
||||
path = asmjit
|
||||
@@ -8,16 +8,23 @@
|
||||
ignore = dirty
|
||||
[submodule "llvm"]
|
||||
path = llvm
|
||||
url = https://github.com/RPCS3/llvm
|
||||
branch = release_60
|
||||
url = https://github.com/RPCS3/llvm-mirror
|
||||
ignore = dirty
|
||||
[submodule "Vulkan/glslang"]
|
||||
path = Vulkan/glslang
|
||||
url = https://github.com/KhronosGroup/glslang.git
|
||||
ignore = dirty
|
||||
[submodule "Vulkan/spirv-tools"]
|
||||
path = Vulkan/spirv-tools
|
||||
url = https://github.com/KhronosGroup/SPIRV-Tools.git
|
||||
ignore = dirty
|
||||
[submodule "Vulkan/spirv-headers"]
|
||||
path = Vulkan/spirv-headers
|
||||
url = https://github.com/KhronosGroup/SPIRV-Headers.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/cereal"]
|
||||
path = 3rdparty/cereal
|
||||
url = https://github.com/USCiLab/cereal.git
|
||||
url = https://github.com/RPCS3/cereal.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/zlib"]
|
||||
path = 3rdparty/zlib
|
||||
@@ -38,7 +45,7 @@
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/yaml-cpp"]
|
||||
path = 3rdparty/yaml-cpp
|
||||
url = https://github.com/jbeder/yaml-cpp.git
|
||||
url = https://github.com/RPCS3/yaml-cpp.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/libpng"]
|
||||
path = 3rdparty/libpng
|
||||
@@ -46,7 +53,7 @@
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/libusb"]
|
||||
path = 3rdparty/libusb
|
||||
url = https://github.com/RPCS3/libusb.git
|
||||
url = https://github.com/libusb/libusb.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/FAudio"]
|
||||
path = 3rdparty/FAudio
|
||||
@@ -55,3 +62,16 @@
|
||||
[submodule "3rdparty/span"]
|
||||
path = 3rdparty/span
|
||||
url = https://github.com/tcbrindle/span
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/curl"]
|
||||
path = 3rdparty/curl
|
||||
url = https://github.com/curl/curl.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/wolfssl"]
|
||||
path = 3rdparty/wolfssl
|
||||
url = https://github.com/wolfSSL/wolfssl.git
|
||||
ignore = dirty
|
||||
[submodule "3rdparty/flatbuffers"]
|
||||
path = 3rdparty/flatbuffers
|
||||
url = https://github.com/google/flatbuffers.git
|
||||
ignore = dirty
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
{
|
||||
"userBlacklist": ["AlexAltea", "tambry", "DHrpcs3"]
|
||||
}
|
||||
-41
@@ -1,41 +0,0 @@
|
||||
language: cpp
|
||||
matrix:
|
||||
include:
|
||||
# - os: linux
|
||||
# env:
|
||||
# - NAME="Linux build"
|
||||
# - COMPILER="gcc"
|
||||
# services: docker
|
||||
# cache: ccache
|
||||
# install: "docker pull rpcs3/rpcs3-travis-xenial:1.0"
|
||||
# script: 'travis_wait docker run -v $(pwd):/rpcs3 -v "$HOME/.ccache":/root/.ccache --env-file .travis/travis.env rpcs3/rpcs3-travis-xenial:1.0 /bin/bash -ex /rpcs3/.travis/build-linux.bash'
|
||||
- os: linux
|
||||
dist: xenial
|
||||
env:
|
||||
- NAME="Linux build"
|
||||
- COMPILER="clang"
|
||||
- DEPLOY_APPIMAGE="true"
|
||||
services: docker
|
||||
cache: ccache
|
||||
install: "docker pull rpcs3/rpcs3-travis-xenial:1.0"
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
- libsdl2-2.0
|
||||
- libsdl2-dev
|
||||
script: 'travis_wait docker run -v $(pwd):/rpcs3 -v "$HOME/.ccache":/root/.ccache --env-file .travis/travis.env rpcs3/rpcs3-travis-xenial:1.0 /bin/bash -ex /rpcs3/.travis/build-linux.bash'
|
||||
- os: osx
|
||||
osx_image: xcode10.2
|
||||
addons:
|
||||
homebrew:
|
||||
packages:
|
||||
- ccache
|
||||
- glew
|
||||
- ninja
|
||||
- qt
|
||||
script: "/bin/bash -ex .travis/build-mac.bash"
|
||||
cache: ccache
|
||||
|
||||
git:
|
||||
depth: false # Unshallow clone to obtain proper GIT_VERSION
|
||||
submodules: false
|
||||
@@ -1,35 +0,0 @@
|
||||
#!/bin/env bash -ex
|
||||
shopt -s nocasematch
|
||||
|
||||
# Setup Qt variables
|
||||
export QT_BASE_DIR=/opt/qt${QTVERMIN}
|
||||
export PATH=$QT_BASE_DIR/bin:$PATH
|
||||
export LD_LIBRARY_PATH=$QT_BASE_DIR/lib/x86_64-linux-gnu:$QT_BASE_DIR/lib
|
||||
|
||||
cd rpcs3
|
||||
|
||||
git submodule update --quiet --init asmjit 3rdparty/ffmpeg 3rdparty/pugixml 3rdparty/span 3rdparty/libpng 3rdparty/cereal 3rdparty/hidapi 3rdparty/xxHash 3rdparty/yaml-cpp 3rdparty/libusb 3rdparty/FAudio Vulkan/glslang
|
||||
|
||||
# Download pre-compiled llvm libs
|
||||
curl -sLO https://github.com/RPCS3/llvm/releases/download/continuous-linux-master/llvmlibs-linux.tar.gz
|
||||
mkdir llvmlibs
|
||||
tar -xzf ./llvmlibs-linux.tar.gz -C llvmlibs
|
||||
|
||||
mkdir build ; cd build
|
||||
|
||||
if [ $COMPILER = "gcc" ]; then
|
||||
# These are set in the dockerfile
|
||||
export CC=${GCC_BINARY}
|
||||
export CXX=${GXX_BINARY}
|
||||
else
|
||||
export CC=${CLANG_BINARY}
|
||||
export CXX=${CLANGXX_BINARY}
|
||||
fi
|
||||
|
||||
cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_LLVM_SUBMODULE=OFF -DLLVM_DIR=llvmlibs/lib/cmake/llvm/ -DUSE_NATIVE_INSTRUCTIONS=OFF -G Ninja
|
||||
|
||||
ninja; build_status=$?;
|
||||
|
||||
cd ..
|
||||
# If it compiled succesfully let's deploy
|
||||
if [ $build_status -eq 0 ] && [ -n "$GITHUB_TOKEN" ] && [ "$TRAVIS_BRANCH" = "master" ] && [ "$TRAVIS_PULL_REQUEST" = false ]; then /bin/bash -ex .travis/deploy-linux.bash ; fi
|
||||
@@ -1,53 +0,0 @@
|
||||
#!/bin/env bash -ex
|
||||
shopt -s nocasematch
|
||||
cd build
|
||||
if [ "$DEPLOY_APPIMAGE" = "true" ]; then
|
||||
DESTDIR=appdir ninja install
|
||||
curl -sLO "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage"
|
||||
chmod a+x linuxdeployqt*.AppImage
|
||||
./linuxdeployqt*.AppImage --appimage-extract
|
||||
./squashfs-root/AppRun ./appdir/usr/share/applications/*.desktop -bundle-non-qt-libs
|
||||
ls ./appdir/usr/lib/
|
||||
rm -r ./appdir/usr/share/doc
|
||||
rm ./appdir/usr/lib/libxcb*
|
||||
cp $(readlink -f /lib/x86_64-linux-gnu/libnsl.so.1) ./appdir/usr/lib/libnsl.so.1
|
||||
export PATH=/rpcs3/build/squashfs-root/usr/bin/:${PATH}
|
||||
|
||||
# Embed newer libstdc++ for distros that don't come with it (ubuntu 16.04)
|
||||
mkdir -p appdir/usr/optional/ ; mkdir -p appdir/usr/optional/libstdc++/
|
||||
cp /usr/lib/x86_64-linux-gnu/libstdc++.so.6 ./appdir/usr/optional/libstdc++/
|
||||
rm ./appdir/AppRun
|
||||
curl -sL https://github.com/RPCS3/AppImageKit-checkrt/releases/download/continuous2/AppRun-patched-x86_64 -o ./appdir/AppRun
|
||||
chmod a+x ./appdir/AppRun
|
||||
curl -sL https://github.com/RPCS3/AppImageKit-checkrt/releases/download/continuous2/exec-x86_64.so -o ./appdir/usr/optional/exec.so
|
||||
|
||||
# Compile checker binary for AppImageKit-checkrt
|
||||
|
||||
# This may need updating if you update the compiler or rpcs3 uses newer c++ features
|
||||
# See https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/config/abi/pre/gnu.ver
|
||||
# for which definitions correlate to which CXXABI version.
|
||||
printf "#include <memory>\nint main(){std::make_exception_ptr(0);}" | $CXX -x c++ -o ./appdir/usr/optional/checker -
|
||||
|
||||
# Package it up and send it off
|
||||
./squashfs-root/usr/bin/appimagetool /rpcs3/build/appdir
|
||||
ls
|
||||
COMM_TAG="$(grep 'version{.*}' ../rpcs3/rpcs3_version.cpp | awk -F[{,] '{printf "%d.%d.%d", $2, $3, $4}')"
|
||||
COMM_COUNT="$(git rev-list --count HEAD)"
|
||||
curl -sLO https://github.com/hcorion/uploadtool/raw/master/upload.sh
|
||||
|
||||
mv ./RPCS3*.AppImage rpcs3-v${COMM_TAG}-${COMM_COUNT}-${TRAVIS_COMMIT:0:8}_linux64.AppImage
|
||||
|
||||
FILESIZE=($(stat -c %s ./rpcs3*.AppImage))
|
||||
SHA256SUM=($(sha256sum ./rpcs3*.AppImage))
|
||||
|
||||
unset TRAVIS_REPO_SLUG
|
||||
REPO_SLUG=RPCS3/rpcs3-binaries-linux \
|
||||
UPLOADTOOL_BODY="$SHA256SUM;${FILESIZE}B"\
|
||||
RELEASE_NAME=build-${TRAVIS_COMMIT}\
|
||||
RELEASE_TITLE=${COMM_TAG}-${COMM_COUNT}\
|
||||
REPO_COMMIT=d812f1254a1157c80fd402f94446310560f54e5f\
|
||||
bash upload.sh rpcs3*.AppImage
|
||||
fi
|
||||
if [ "$DEPLOY_PPA" = "true" ]; then
|
||||
export DEBFULLNAME="RPCS3 Build Bot"
|
||||
fi
|
||||
@@ -1,9 +0,0 @@
|
||||
# Variables set by Travis CI
|
||||
TRAVIS_PULL_REQUEST
|
||||
TRAVIS_BRANCH
|
||||
TRAVIS_COMMIT
|
||||
# Variables for Travis build matrix
|
||||
COMPILER
|
||||
DEPLOY_APPIMAGE
|
||||
# Private Travis CI variables
|
||||
GITHUB_TOKEN
|
||||
Vendored
+3
-1
@@ -111,6 +111,9 @@
|
||||
</PropertyGroup>
|
||||
<Import Project="..\common_default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="..\common_default_macros.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
@@ -204,7 +207,6 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
|
||||
Vendored
+103
-33
@@ -1,14 +1,6 @@
|
||||
find_package(PkgConfig)
|
||||
include(ExternalProject)
|
||||
|
||||
if(APPLE)
|
||||
set(PLATFORM_ARCH "macosx/x86_64")
|
||||
elseif(WIN32)
|
||||
set(PLATFORM_ARCH "Windows/x86_64")
|
||||
else()
|
||||
set(PLATFORM_ARCH "linux/x86_64")
|
||||
endif()
|
||||
|
||||
# Dummy target to use when lib isn't available
|
||||
add_library(3rdparty_dummy_lib INTERFACE)
|
||||
|
||||
@@ -82,6 +74,9 @@ else()
|
||||
add_library(3rdparty_7z INTERFACE)
|
||||
endif()
|
||||
|
||||
add_library(3rdparty_flatbuffers INTERFACE)
|
||||
target_include_directories(3rdparty_flatbuffers INTERFACE flatbuffers/include)
|
||||
|
||||
# libPNG
|
||||
# Select the version of libpng to use, default is builtin
|
||||
if (NOT USE_SYSTEM_LIBPNG)
|
||||
@@ -111,6 +106,36 @@ endif()
|
||||
add_subdirectory(pugixml EXCLUDE_FROM_ALL)
|
||||
|
||||
|
||||
# libusb
|
||||
if(CMAKE_SYSTEM MATCHES "DragonFly|FreeBSD")
|
||||
pkg_check_modules(LIBUSB REQUIRED IMPORTED_TARGET libusb-1.0>=1.0 )
|
||||
CMAKE_DEPENDENT_OPTION( USE_SYS_LIBUSB "Use system libusb-1.0 as shared library" ON
|
||||
"LIBUSB_FOUND" OFF)
|
||||
else()
|
||||
pkg_check_modules(LIBUSB IMPORTED_TARGET libusb-1.0>=1.0 )
|
||||
CMAKE_DEPENDENT_OPTION( USE_SYS_LIBUSB "Use system libusb-1.0 as shared library" OFF
|
||||
"LIBUSB_FOUND" OFF)
|
||||
endif()
|
||||
if(CMAKE_SYSTEM MATCHES "DragonFly|FreeBSD")
|
||||
# Always use system libusb as reference implementation isn't supported
|
||||
add_library(usb-1.0-shared INTERFACE)
|
||||
target_link_libraries(usb-1.0-shared INTERFACE PkgConfig::LIBUSB)
|
||||
elseif(MSVC)
|
||||
# Windows time.h defines timespec but doesn't add any flag for it, which makes libusb attempt to define it again
|
||||
add_definitions(-DHAVE_STRUCT_TIMESPEC=1)
|
||||
add_subdirectory(libusb_cmake EXCLUDE_FROM_ALL)
|
||||
else()
|
||||
if(USE_SYS_LIBUSB)
|
||||
# we have the system libusb and have selected to use it
|
||||
add_library(usb-1.0-shared INTERFACE)
|
||||
target_link_libraries(usb-1.0-shared INTERFACE PkgConfig::LIBUSB)
|
||||
else()
|
||||
# we don't have the system libusb, so we compile from submodule
|
||||
add_subdirectory(libusb_cmake EXCLUDE_FROM_ALL)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
# hidapi
|
||||
add_library(3rdparty_hidapi INTERFACE)
|
||||
target_include_directories(3rdparty_hidapi INTERFACE hidapi/hidapi)
|
||||
@@ -138,24 +163,11 @@ else()
|
||||
endif()
|
||||
|
||||
|
||||
# libusb
|
||||
if(CMAKE_SYSTEM MATCHES "DragonFly|FreeBSD")
|
||||
# Always use system libusb as reference implementation isn't supported
|
||||
add_library(usb-1.0-static INTERFACE)
|
||||
target_link_libraries(usb-1.0-static INTERFACE usb)
|
||||
elseif(MSVC)
|
||||
# Windows time.h defines timespec but doesn't add any flag for it, which makes libusb attempt to define it again
|
||||
add_definitions(-DHAVE_STRUCT_TIMESPEC=1)
|
||||
add_subdirectory(libusb EXCLUDE_FROM_ALL)
|
||||
else()
|
||||
add_subdirectory(libusb EXCLUDE_FROM_ALL)
|
||||
endif()
|
||||
|
||||
|
||||
# yaml-cpp
|
||||
# We don't want to install yaml-cpp but its cmake file doesn't have option
|
||||
# to disable it...
|
||||
# So we just install it to a different directory
|
||||
set(YAML_CPP_INSTALL OFF CACHE BOOL "Don't install YAML")
|
||||
set(CMAKE_INSTALL_PREFIX_OLD ${CMAKE_INSTALL_PREFIX})
|
||||
set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR}/yaml-cpp_install)
|
||||
|
||||
@@ -169,6 +181,7 @@ set(CMAKE_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX_OLD})
|
||||
|
||||
# xxHash
|
||||
set(XXHASH_BUNDLED_MODE ON)
|
||||
set(XXHASH_BUILD_XXHSUM OFF)
|
||||
set(BUILD_SHARED_LIBS OFF CACHE BOOL "Make xxHash build static libs")
|
||||
add_subdirectory(xxHash/cmake_unofficial EXCLUDE_FROM_ALL)
|
||||
target_include_directories(xxhash INTERFACE xxHash)
|
||||
@@ -305,7 +318,7 @@ if(USE_VULKAN)
|
||||
if(VULKAN_FOUND)
|
||||
add_library(3rdparty_vulkan INTERFACE)
|
||||
target_compile_definitions(3rdparty_vulkan INTERFACE -DHAVE_VULKAN)
|
||||
target_link_libraries(3rdparty_vulkan INTERFACE SPIRV Vulkan::Vulkan)
|
||||
target_link_libraries(3rdparty_vulkan INTERFACE SPIRV SPIRV-Tools-opt Vulkan::Vulkan)
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
find_package(Wayland)
|
||||
@@ -345,6 +358,7 @@ if(USE_FAUDIO)
|
||||
if (NOT SDL2_FOUND OR SDL2_VERSION VERSION_LESS 2.0.9)
|
||||
message("-- RPCS3: FAudio requires SDL 2.0.9 or newer.")
|
||||
else()
|
||||
set(BUILD_SHARED_LIBS OFF CACHE BOOL "Build shared library")
|
||||
add_subdirectory(FAudio EXCLUDE_FROM_ALL)
|
||||
target_compile_definitions(FAudio INTERFACE -DHAVE_FAUDIO)
|
||||
set(FAUDIO_TARGET FAudio)
|
||||
@@ -362,8 +376,6 @@ if(USE_SYSTEM_FFMPEG)
|
||||
target_include_directories(3rdparty_ffmpeg INTERFACE ${FFMPEG_INCLUDE_DIR})
|
||||
target_link_libraries(3rdparty_ffmpeg INTERFACE ${FFMPEG_LIBRARIES})
|
||||
else()
|
||||
set(FFMPEG_PLATFORM_DIR "ffmpeg/${PLATFORM_ARCH}")
|
||||
|
||||
if (NOT MSVC AND WIN32)
|
||||
message("-- RPCS3: building ffmpeg submodule")
|
||||
|
||||
@@ -371,26 +383,36 @@ else()
|
||||
DOWNLOAD_COMMAND ""
|
||||
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/ffmpeg
|
||||
BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/ffmpeg
|
||||
CONFIGURE_COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ffmpeg/configure --prefix=./Windows/x86_64 --arch=x86_64 --disable-avdevice --disable-programs --disable-avfilter --disable-postproc --disable-doc --disable-pthreads --enable-w32threads --disable-network --disable-everything --disable-encoders --disable-muxers --disable-hwaccels --disable-parsers --disable-protocols --enable-dxva2 --enable-static --disable-shared --enable-decoder=aac --enable-decoder=aac_latm --enable-decoder=atrac3 --enable-decoder=atrac3p --enable-decoder=mp3 --enable-decoder=pcm_s16le --enable-decoder=pcm_s8 --enable-decoder=h264 --enable-decoder=mpeg4 --enable-decoder=mpeg2video --enable-decoder=mjpeg --enable-decoder=mjpegb --enable-encoder=pcm_s16le --enable-encoder=ffv1 --enable-encoder=mpeg4 --enable-parser=h264 --enable-parser=mpeg4video --enable-parser=mpegaudio --enable-parser=mpegvideo --enable-parser=mjpeg --enable-parser=aac --enable-parser=aac_latm --enable-muxer=avi --enable-demuxer=h264 --enable-demuxer=m4v --enable-demuxer=mp3 --enable-demuxer=mpegvideo --enable-demuxer=mpegps --enable-demuxer=mjpeg --enable-demuxer=avi --enable-demuxer=aac --enable-demuxer=pmp --enable-demuxer=oma --enable-demuxer=pcm_s16le --enable-demuxer=pcm_s8 --enable-demuxer=wav --enable-hwaccel=h264_dxva2 --enable-indev=dshow --enable-protocol=file
|
||||
CONFIGURE_COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ffmpeg/configure --prefix=./windows/x86_64 --arch=x86_64 --disable-avdevice --disable-programs --disable-avfilter --disable-postproc --disable-doc --disable-pthreads --enable-w32threads --disable-network --disable-everything --disable-encoders --disable-muxers --disable-hwaccels --disable-parsers --disable-protocols --enable-dxva2 --enable-static --disable-shared --enable-decoder=aac --enable-decoder=aac_latm --enable-decoder=atrac3 --enable-decoder=atrac3p --enable-decoder=mp3 --enable-decoder=pcm_s16le --enable-decoder=pcm_s8 --enable-decoder=h264 --enable-decoder=mpeg4 --enable-decoder=mpeg2video --enable-decoder=mjpeg --enable-decoder=mjpegb --enable-encoder=pcm_s16le --enable-encoder=ffv1 --enable-encoder=mpeg4 --enable-parser=h264 --enable-parser=mpeg4video --enable-parser=mpegaudio --enable-parser=mpegvideo --enable-parser=mjpeg --enable-parser=aac --enable-parser=aac_latm --enable-muxer=avi --enable-demuxer=h264 --enable-demuxer=m4v --enable-demuxer=mp3 --enable-demuxer=mpegvideo --enable-demuxer=mpegps --enable-demuxer=mjpeg --enable-demuxer=avi --enable-demuxer=aac --enable-demuxer=pmp --enable-demuxer=oma --enable-demuxer=pcm_s16le --enable-demuxer=pcm_s8 --enable-demuxer=wav --enable-hwaccel=h264_dxva2 --enable-indev=dshow --enable-protocol=file
|
||||
BUILD_COMMAND make -j 4
|
||||
INSTALL_COMMAND make install
|
||||
)
|
||||
|
||||
set(FFMPEG_LIB_AVFORMAT "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/${PLATFORM_ARCH}/lib/libavformat.a")
|
||||
set(FFMPEG_LIB_AVCODEC "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/${PLATFORM_ARCH}/lib/libavcodec.a")
|
||||
set(FFMPEG_LIB_AVUTIL "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/${PLATFORM_ARCH}/lib/libavutil.a")
|
||||
set(FFMPEG_LIB_SWSCALE "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/${PLATFORM_ARCH}/lib/libswscale.a")
|
||||
set(FFMPEG_LIB_AVFORMAT "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/windows/x86_64/lib/libavformat.a")
|
||||
set(FFMPEG_LIB_AVCODEC "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/windows/x86_64/lib/libavcodec.a")
|
||||
set(FFMPEG_LIB_AVUTIL "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/windows/x86_64/lib/libavutil.a")
|
||||
set(FFMPEG_LIB_SWSCALE "${CMAKE_CURRENT_BINARY_DIR}/ffmpeg/windows/x86_64/lib/libswscale.a")
|
||||
else()
|
||||
message("-- RPCS3: using builtin ffmpeg")
|
||||
|
||||
set(FFMPEG_LIB_DIR "${FFMPEG_PLATFORM_DIR}/lib")
|
||||
if (WIN32)
|
||||
set(FFMPEG_LIB_DIR "ffmpeg/windows/x86_64")
|
||||
target_link_libraries(3rdparty_ffmpeg INTERFACE "Bcrypt.lib")
|
||||
elseif(CMAKE_SYSTEM MATCHES "Linux")
|
||||
set(FFMPEG_LIB_DIR "ffmpeg/linux/x86_64")
|
||||
elseif(APPLE)
|
||||
set(FFMPEG_LIB_DIR "ffmpeg/macos/x86_64")
|
||||
else()
|
||||
message(FATAL_ERROR "Prebuilt ffmpeg is not available on this platform! Try USE_SYSTEM_FFMPEG=ON.")
|
||||
endif()
|
||||
|
||||
find_library(FFMPEG_LIB_AVFORMAT avformat PATHS ${FFMPEG_LIB_DIR} NO_DEFAULT_PATH)
|
||||
find_library(FFMPEG_LIB_AVCODEC avcodec PATHS ${FFMPEG_LIB_DIR} NO_DEFAULT_PATH)
|
||||
find_library(FFMPEG_LIB_AVUTIL avutil PATHS ${FFMPEG_LIB_DIR} NO_DEFAULT_PATH)
|
||||
find_library(FFMPEG_LIB_SWSCALE swscale PATHS ${FFMPEG_LIB_DIR} NO_DEFAULT_PATH)
|
||||
endif()
|
||||
|
||||
target_include_directories(3rdparty_ffmpeg INTERFACE "${FFMPEG_PLATFORM_DIR}/include")
|
||||
target_include_directories(3rdparty_ffmpeg INTERFACE "ffmpeg/include")
|
||||
|
||||
target_link_libraries(3rdparty_ffmpeg
|
||||
INTERFACE
|
||||
@@ -412,11 +434,57 @@ endif()
|
||||
# LLVM
|
||||
include(llvm.cmake)
|
||||
|
||||
# WOLFSSL
|
||||
if(USE_SYSTEM_WOLFSSL)
|
||||
message("-- RPCS3: using shared wolfssl")
|
||||
find_package(WolfSSL REQUIRED)
|
||||
add_library(wolfssl INTERFACE)
|
||||
target_link_libraries(wolfssl INTERFACE WolfSSL_LIBRARIES)
|
||||
target_include_directories(wolfssl INTERFACE WolfSSL_INCLUDE_DIRS)
|
||||
else()
|
||||
SET(BUILD_TESTS NO CACHE BOOL "Build test applications")
|
||||
add_compile_definitions(HAVE_FFDHE_2048 TFM_TIMING_RESISTANT ECC_TIMING_RESISTANT
|
||||
WC_RSA_BLINDING HAVE_AESGCM WOLFSSL_SHA512 WOLFSSL_SHA384 NO_DSA HAVE_ECC TFM_ECC256 ECC_SHAMIR
|
||||
NO_RC4 NO_HC128 NO_RABBIT WOLFSSL_SHA224 WOLFSSL_SHA3 WOLFSSL_SHAKE256 HAVE_POLY1305
|
||||
HAVE_ONE_TIME_AUTH HAVE_CHACHA HAVE_HASHDRBG HAVE_TLS_EXTENSIONS HAVE_SNI HAVE_SUPPORTED_CURVES
|
||||
HAVE_EXTENDED_MASTER NO_RC4 HAVE_ENCRYPT_THEN_MAC NO_PSK NO_MD4
|
||||
WC_NO_ASYNC_THREADING OPENSSL_EXTRA WOLFSSL_DES_ECB WC_NO_HARDEN)
|
||||
set(ENABLED_HARDEN OFF CACHE BOOL "Disable Harden")
|
||||
add_subdirectory(wolfssl EXCLUDE_FROM_ALL)
|
||||
target_include_directories(wolfssl INTERFACE "wolfssl/")
|
||||
# This is needed for CURL
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/wolfssl/wolfssl/options.h.in ${CMAKE_CURRENT_BINARY_DIR}/wolfssl/wolfssl/options.h)
|
||||
set(WolfSSL_LIBRARY "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/libwolfssl.a")
|
||||
set(WolfSSL_LIBRARIES "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/libwolfssl.a")
|
||||
set(WolfSSL_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/wolfssl/" "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/")
|
||||
set(WolfSSL_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/wolfssl/" "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/")
|
||||
endif()
|
||||
|
||||
# CURL
|
||||
if(USE_SYSTEM_CURL)
|
||||
message("-- RPCS3: using shared libcurl")
|
||||
find_package(CURL REQUIRED)
|
||||
add_library(libcurl INTERFACE)
|
||||
target_link_libraries(libcurl INTERFACE CURL::libcurl)
|
||||
else()
|
||||
message("-- RPCS3: building libcurl + wolfssl submodules")
|
||||
option(BUILD_CURL_EXE "Set to ON to build curl executable." OFF)
|
||||
option(CMAKE_USE_WOLFSSL "enable wolfSSL for SSL/TLS" ON)
|
||||
option(HTTP_ONLY "disables all protocols except HTTP (This overrides all CURL_DISABLE_* options)" ON)
|
||||
option(CURL_ZLIB "Set to ON to enable building curl with zlib support." OFF)
|
||||
set(CURL_CA_PATH "none" CACHE STRING "Location of default CA path. Set 'none' to disable or 'auto' for auto-detection. Defaults to 'auto'.")
|
||||
add_subdirectory(curl EXCLUDE_FROM_ALL)
|
||||
endif()
|
||||
|
||||
# add nice ALIAS targets for ease of use
|
||||
add_library(3rdparty::libusb ALIAS usb-1.0-static)
|
||||
if(USE_SYS_LIBUSB)
|
||||
add_library(3rdparty::libusb ALIAS usb-1.0-shared)
|
||||
else()
|
||||
add_library(3rdparty::libusb ALIAS usb-1.0-static)
|
||||
endif()
|
||||
add_library(3rdparty::zlib ALIAS 3rdparty_zlib)
|
||||
add_library(3rdparty::7z ALIAS 3rdparty_7z)
|
||||
add_library(3rdparty::flatbuffers ALIAS 3rdparty_flatbuffers)
|
||||
add_library(3rdparty::pugixml ALIAS pugixml)
|
||||
add_library(3rdparty::yaml-cpp ALIAS yaml-cpp)
|
||||
add_library(3rdparty::xxhash ALIAS xxhash)
|
||||
@@ -435,3 +503,5 @@ add_library(3rdparty::vulkan ALIAS ${VULKAN_TARGET})
|
||||
add_library(3rdparty::openal ALIAS 3rdparty_openal)
|
||||
add_library(3rdparty::ffmpeg ALIAS 3rdparty_ffmpeg)
|
||||
add_library(3rdparty::glew ALIAS 3rdparty_glew)
|
||||
add_library(3rdparty::wolfssl ALIAS wolfssl)
|
||||
add_library(3rdparty::libcurl ALIAS libcurl)
|
||||
|
||||
Vendored
+1
-1
Submodule 3rdparty/FAudio updated: f86adca2bd...9c7d2d1430
Vendored
+383
-77
@@ -1,12 +1,12 @@
|
||||
#ifndef __glext_h_
|
||||
#define __glext_h_ 1
|
||||
#ifndef __gl_glext_h_
|
||||
#define __gl_glext_h_ 1
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Copyright (c) 2013-2017 The Khronos Group Inc.
|
||||
** Copyright (c) 2013-2018 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
@@ -51,7 +51,9 @@ extern "C" {
|
||||
#define GLAPI extern
|
||||
#endif
|
||||
|
||||
#define GL_GLEXT_VERSION 20180114
|
||||
#define GL_GLEXT_VERSION 20200423
|
||||
|
||||
#include "khrplatform.h"
|
||||
|
||||
/* Generated C header for:
|
||||
* API: gl
|
||||
@@ -464,9 +466,8 @@ GLAPI void APIENTRY glBlendEquation (GLenum mode);
|
||||
|
||||
#ifndef GL_VERSION_1_5
|
||||
#define GL_VERSION_1_5 1
|
||||
#include <stddef.h>
|
||||
typedef ptrdiff_t GLsizeiptr;
|
||||
typedef ptrdiff_t GLintptr;
|
||||
typedef khronos_ssize_t GLsizeiptr;
|
||||
typedef khronos_intptr_t GLintptr;
|
||||
#define GL_BUFFER_SIZE 0x8764
|
||||
#define GL_BUFFER_USAGE 0x8765
|
||||
#define GL_QUERY_COUNTER_BITS 0x8864
|
||||
@@ -879,7 +880,7 @@ GLAPI void APIENTRY glUniformMatrix4x3fv (GLint location, GLsizei count, GLboole
|
||||
|
||||
#ifndef GL_VERSION_3_0
|
||||
#define GL_VERSION_3_0 1
|
||||
typedef unsigned short GLhalf;
|
||||
typedef khronos_uint16_t GLhalf;
|
||||
#define GL_COMPARE_REF_TO_TEXTURE 0x884E
|
||||
#define GL_CLIP_DISTANCE0 0x3000
|
||||
#define GL_CLIP_DISTANCE1 0x3001
|
||||
@@ -1383,45 +1384,8 @@ GLAPI void APIENTRY glUniformBlockBinding (GLuint program, GLuint uniformBlockIn
|
||||
#ifndef GL_VERSION_3_2
|
||||
#define GL_VERSION_3_2 1
|
||||
typedef struct __GLsync *GLsync;
|
||||
#ifndef GLEXT_64_TYPES_DEFINED
|
||||
/* This code block is duplicated in glxext.h, so must be protected */
|
||||
#define GLEXT_64_TYPES_DEFINED
|
||||
/* Define int32_t, int64_t, and uint64_t types for UST/MSC */
|
||||
/* (as used in the GL_EXT_timer_query extension). */
|
||||
#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
|
||||
#include <inttypes.h>
|
||||
#elif defined(__sun__) || defined(__digital__)
|
||||
#include <inttypes.h>
|
||||
#if defined(__STDC__)
|
||||
#if defined(__arch64__) || defined(_LP64)
|
||||
typedef long int int64_t;
|
||||
typedef unsigned long int uint64_t;
|
||||
#else
|
||||
typedef long long int int64_t;
|
||||
typedef unsigned long long int uint64_t;
|
||||
#endif /* __arch64__ */
|
||||
#endif /* __STDC__ */
|
||||
#elif defined( __VMS ) || defined(__sgi)
|
||||
#include <inttypes.h>
|
||||
#elif defined(__SCO__) || defined(__USLC__)
|
||||
#include <stdint.h>
|
||||
#elif defined(__UNIXOS2__) || defined(__SOL64__)
|
||||
typedef long int int32_t;
|
||||
typedef long long int int64_t;
|
||||
typedef unsigned long long int uint64_t;
|
||||
#elif defined(_WIN32) && defined(__GNUC__)
|
||||
#include <stdint.h>
|
||||
#elif defined(_WIN32)
|
||||
typedef __int32 int32_t;
|
||||
typedef __int64 int64_t;
|
||||
typedef unsigned __int64 uint64_t;
|
||||
#else
|
||||
/* Fallback if nothing above works */
|
||||
#include <inttypes.h>
|
||||
#endif
|
||||
#endif
|
||||
typedef uint64_t GLuint64;
|
||||
typedef int64_t GLint64;
|
||||
typedef khronos_uint64_t GLuint64;
|
||||
typedef khronos_int64_t GLint64;
|
||||
#define GL_CONTEXT_CORE_PROFILE_BIT 0x00000001
|
||||
#define GL_CONTEXT_COMPATIBILITY_PROFILE_BIT 0x00000002
|
||||
#define GL_LINES_ADJACENCY 0x000A
|
||||
@@ -1497,7 +1461,7 @@ typedef void (APIENTRYP PFNGLDELETESYNCPROC) (GLsync sync);
|
||||
typedef GLenum (APIENTRYP PFNGLCLIENTWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
typedef void (APIENTRYP PFNGLWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
typedef void (APIENTRYP PFNGLGETINTEGER64VPROC) (GLenum pname, GLint64 *data);
|
||||
typedef void (APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
typedef void (APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
typedef void (APIENTRYP PFNGLGETINTEGER64I_VPROC) (GLenum target, GLuint index, GLint64 *data);
|
||||
typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERI64VPROC) (GLenum target, GLenum pname, GLint64 *params);
|
||||
typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTUREPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level);
|
||||
@@ -1517,7 +1481,7 @@ GLAPI void APIENTRY glDeleteSync (GLsync sync);
|
||||
GLAPI GLenum APIENTRY glClientWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
GLAPI void APIENTRY glWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout);
|
||||
GLAPI void APIENTRY glGetInteger64v (GLenum pname, GLint64 *data);
|
||||
GLAPI void APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
GLAPI void APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
GLAPI void APIENTRY glGetInteger64i_v (GLenum target, GLuint index, GLint64 *data);
|
||||
GLAPI void APIENTRY glGetBufferParameteri64v (GLenum target, GLenum pname, GLint64 *params);
|
||||
GLAPI void APIENTRY glFramebufferTexture (GLenum target, GLenum attachment, GLuint texture, GLint level);
|
||||
@@ -1773,8 +1737,8 @@ typedef void (APIENTRYP PFNGLGETUNIFORMDVPROC) (GLuint program, GLint location,
|
||||
typedef GLint (APIENTRYP PFNGLGETSUBROUTINEUNIFORMLOCATIONPROC) (GLuint program, GLenum shadertype, const GLchar *name);
|
||||
typedef GLuint (APIENTRYP PFNGLGETSUBROUTINEINDEXPROC) (GLuint program, GLenum shadertype, const GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVESUBROUTINEUNIFORMIVPROC) (GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVESUBROUTINEUNIFORMNAMEPROC) (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVESUBROUTINENAMEPROC) (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVESUBROUTINEUNIFORMNAMEPROC) (GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVESUBROUTINENAMEPROC) (GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLUNIFORMSUBROUTINESUIVPROC) (GLenum shadertype, GLsizei count, const GLuint *indices);
|
||||
typedef void (APIENTRYP PFNGLGETUNIFORMSUBROUTINEUIVPROC) (GLenum shadertype, GLint location, GLuint *params);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMSTAGEIVPROC) (GLuint program, GLenum shadertype, GLenum pname, GLint *values);
|
||||
@@ -1820,8 +1784,8 @@ GLAPI void APIENTRY glGetUniformdv (GLuint program, GLint location, GLdouble *pa
|
||||
GLAPI GLint APIENTRY glGetSubroutineUniformLocation (GLuint program, GLenum shadertype, const GLchar *name);
|
||||
GLAPI GLuint APIENTRY glGetSubroutineIndex (GLuint program, GLenum shadertype, const GLchar *name);
|
||||
GLAPI void APIENTRY glGetActiveSubroutineUniformiv (GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
|
||||
GLAPI void APIENTRY glGetActiveSubroutineUniformName (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
|
||||
GLAPI void APIENTRY glGetActiveSubroutineName (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
|
||||
GLAPI void APIENTRY glGetActiveSubroutineUniformName (GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
GLAPI void APIENTRY glGetActiveSubroutineName (GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
GLAPI void APIENTRY glUniformSubroutinesuiv (GLenum shadertype, GLsizei count, const GLuint *indices);
|
||||
GLAPI void APIENTRY glGetUniformSubroutineuiv (GLenum shadertype, GLint location, GLuint *params);
|
||||
GLAPI void APIENTRY glGetProgramStageiv (GLuint program, GLenum shadertype, GLenum pname, GLint *values);
|
||||
@@ -2175,7 +2139,7 @@ GLAPI void APIENTRY glGetDoublei_v (GLenum target, GLuint index, GLdouble *data)
|
||||
typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
|
||||
typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
|
||||
typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLGETACTIVEATOMICCOUNTERBUFFERIVPROC) (GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLBINDIMAGETEXTUREPROC) (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
|
||||
typedef void (APIENTRYP PFNGLMEMORYBARRIERPROC) (GLbitfield barriers);
|
||||
@@ -2188,7 +2152,7 @@ typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC) (GLenum m
|
||||
GLAPI void APIENTRY glDrawArraysInstancedBaseInstance (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
|
||||
GLAPI void APIENTRY glDrawElementsInstancedBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
|
||||
GLAPI void APIENTRY glDrawElementsInstancedBaseVertexBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
|
||||
GLAPI void APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
GLAPI void APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params);
|
||||
GLAPI void APIENTRY glGetActiveAtomicCounterBufferiv (GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
|
||||
GLAPI void APIENTRY glBindImageTexture (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
|
||||
GLAPI void APIENTRY glMemoryBarrier (GLbitfield barriers);
|
||||
@@ -2469,7 +2433,7 @@ typedef void (APIENTRYP PFNGLDISPATCHCOMPUTEINDIRECTPROC) (GLintptr indirect);
|
||||
typedef void (APIENTRYP PFNGLCOPYIMAGESUBDATAPROC) (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
|
||||
typedef void (APIENTRYP PFNGLFRAMEBUFFERPARAMETERIPROC) (GLenum target, GLenum pname, GLint param);
|
||||
typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATI64VPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATI64VPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint64 *params);
|
||||
typedef void (APIENTRYP PFNGLINVALIDATETEXSUBIMAGEPROC) (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
|
||||
typedef void (APIENTRYP PFNGLINVALIDATETEXIMAGEPROC) (GLuint texture, GLint level);
|
||||
typedef void (APIENTRYP PFNGLINVALIDATEBUFFERSUBDATAPROC) (GLuint buffer, GLintptr offset, GLsizeiptr length);
|
||||
@@ -2481,7 +2445,7 @@ typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSINDIRECTPROC) (GLenum mode, GLenum
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMINTERFACEIVPROC) (GLuint program, GLenum programInterface, GLenum pname, GLint *params);
|
||||
typedef GLuint (APIENTRYP PFNGLGETPROGRAMRESOURCEINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCENAMEPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLint *params);
|
||||
typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONPROC) (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
typedef void (APIENTRYP PFNGLSHADERSTORAGEBLOCKBINDINGPROC) (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
|
||||
@@ -2513,7 +2477,7 @@ GLAPI void APIENTRY glDispatchComputeIndirect (GLintptr indirect);
|
||||
GLAPI void APIENTRY glCopyImageSubData (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
|
||||
GLAPI void APIENTRY glFramebufferParameteri (GLenum target, GLenum pname, GLint param);
|
||||
GLAPI void APIENTRY glGetFramebufferParameteriv (GLenum target, GLenum pname, GLint *params);
|
||||
GLAPI void APIENTRY glGetInternalformati64v (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
|
||||
GLAPI void APIENTRY glGetInternalformati64v (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint64 *params);
|
||||
GLAPI void APIENTRY glInvalidateTexSubImage (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
|
||||
GLAPI void APIENTRY glInvalidateTexImage (GLuint texture, GLint level);
|
||||
GLAPI void APIENTRY glInvalidateBufferSubData (GLuint buffer, GLintptr offset, GLsizeiptr length);
|
||||
@@ -2525,7 +2489,7 @@ GLAPI void APIENTRY glMultiDrawElementsIndirect (GLenum mode, GLenum type, const
|
||||
GLAPI void APIENTRY glGetProgramInterfaceiv (GLuint program, GLenum programInterface, GLenum pname, GLint *params);
|
||||
GLAPI GLuint APIENTRY glGetProgramResourceIndex (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
GLAPI void APIENTRY glGetProgramResourceName (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
|
||||
GLAPI void APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
|
||||
GLAPI void APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLint *params);
|
||||
GLAPI GLint APIENTRY glGetProgramResourceLocation (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
GLAPI GLint APIENTRY glGetProgramResourceLocationIndex (GLuint program, GLenum programInterface, const GLchar *name);
|
||||
GLAPI void APIENTRY glShaderStorageBlockBinding (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
|
||||
@@ -2936,7 +2900,7 @@ GLAPI void APIENTRY glPrimitiveBoundingBoxARB (GLfloat minX, GLfloat minY, GLflo
|
||||
|
||||
#ifndef GL_ARB_bindless_texture
|
||||
#define GL_ARB_bindless_texture 1
|
||||
typedef uint64_t GLuint64EXT;
|
||||
typedef khronos_uint64_t GLuint64EXT;
|
||||
#define GL_UNSIGNED_INT64_ARB 0x140F
|
||||
typedef GLuint64 (APIENTRYP PFNGLGETTEXTUREHANDLEARBPROC) (GLuint texture);
|
||||
typedef GLuint64 (APIENTRYP PFNGLGETTEXTURESAMPLERHANDLEARBPROC) (GLuint texture, GLuint sampler);
|
||||
@@ -3496,7 +3460,7 @@ GLAPI void APIENTRY glProgramUniform4ui64vARB (GLuint program, GLint location, G
|
||||
|
||||
#ifndef GL_ARB_half_float_pixel
|
||||
#define GL_ARB_half_float_pixel 1
|
||||
typedef unsigned short GLhalfARB;
|
||||
typedef khronos_uint16_t GLhalfARB;
|
||||
#define GL_HALF_FLOAT_ARB 0x140B
|
||||
#endif /* GL_ARB_half_float_pixel */
|
||||
|
||||
@@ -3666,6 +3630,25 @@ GLAPI void APIENTRY glVertexAttribDivisorARB (GLuint index, GLuint divisor);
|
||||
#ifndef GL_ARB_internalformat_query2
|
||||
#define GL_ARB_internalformat_query2 1
|
||||
#define GL_SRGB_DECODE_ARB 0x8299
|
||||
#define GL_VIEW_CLASS_EAC_R11 0x9383
|
||||
#define GL_VIEW_CLASS_EAC_RG11 0x9384
|
||||
#define GL_VIEW_CLASS_ETC2_RGB 0x9385
|
||||
#define GL_VIEW_CLASS_ETC2_RGBA 0x9386
|
||||
#define GL_VIEW_CLASS_ETC2_EAC_RGBA 0x9387
|
||||
#define GL_VIEW_CLASS_ASTC_4x4_RGBA 0x9388
|
||||
#define GL_VIEW_CLASS_ASTC_5x4_RGBA 0x9389
|
||||
#define GL_VIEW_CLASS_ASTC_5x5_RGBA 0x938A
|
||||
#define GL_VIEW_CLASS_ASTC_6x5_RGBA 0x938B
|
||||
#define GL_VIEW_CLASS_ASTC_6x6_RGBA 0x938C
|
||||
#define GL_VIEW_CLASS_ASTC_8x5_RGBA 0x938D
|
||||
#define GL_VIEW_CLASS_ASTC_8x6_RGBA 0x938E
|
||||
#define GL_VIEW_CLASS_ASTC_8x8_RGBA 0x938F
|
||||
#define GL_VIEW_CLASS_ASTC_10x5_RGBA 0x9390
|
||||
#define GL_VIEW_CLASS_ASTC_10x6_RGBA 0x9391
|
||||
#define GL_VIEW_CLASS_ASTC_10x8_RGBA 0x9392
|
||||
#define GL_VIEW_CLASS_ASTC_10x10_RGBA 0x9393
|
||||
#define GL_VIEW_CLASS_ASTC_12x10_RGBA 0x9394
|
||||
#define GL_VIEW_CLASS_ASTC_12x12_RGBA 0x9395
|
||||
#endif /* GL_ARB_internalformat_query2 */
|
||||
|
||||
#ifndef GL_ARB_invalidate_subdata
|
||||
@@ -4713,8 +4696,8 @@ GLAPI void APIENTRY glVertexBlendARB (GLint count);
|
||||
|
||||
#ifndef GL_ARB_vertex_buffer_object
|
||||
#define GL_ARB_vertex_buffer_object 1
|
||||
typedef ptrdiff_t GLsizeiptrARB;
|
||||
typedef ptrdiff_t GLintptrARB;
|
||||
typedef khronos_ssize_t GLsizeiptrARB;
|
||||
typedef khronos_intptr_t GLintptrARB;
|
||||
#define GL_BUFFER_SIZE_ARB 0x8764
|
||||
#define GL_BUFFER_USAGE_ARB 0x8765
|
||||
#define GL_ARRAY_BUFFER_ARB 0x8892
|
||||
@@ -4909,6 +4892,12 @@ GLAPI GLint APIENTRY glGetAttribLocationARB (GLhandleARB programObj, const GLcha
|
||||
|
||||
#ifndef GL_ARB_viewport_array
|
||||
#define GL_ARB_viewport_array 1
|
||||
typedef void (APIENTRYP PFNGLDEPTHRANGEARRAYDVNVPROC) (GLuint first, GLsizei count, const GLdouble *v);
|
||||
typedef void (APIENTRYP PFNGLDEPTHRANGEINDEXEDDNVPROC) (GLuint index, GLdouble n, GLdouble f);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glDepthRangeArraydvNV (GLuint first, GLsizei count, const GLdouble *v);
|
||||
GLAPI void APIENTRY glDepthRangeIndexeddNV (GLuint index, GLdouble n, GLdouble f);
|
||||
#endif
|
||||
#endif /* GL_ARB_viewport_array */
|
||||
|
||||
#ifndef GL_ARB_window_pos
|
||||
@@ -5009,6 +4998,22 @@ GLAPI void APIENTRY glMaxShaderCompilerThreadsKHR (GLuint count);
|
||||
#define GL_CONTEXT_ROBUST_ACCESS 0x90F3
|
||||
#endif /* GL_KHR_robustness */
|
||||
|
||||
#ifndef GL_KHR_shader_subgroup
|
||||
#define GL_KHR_shader_subgroup 1
|
||||
#define GL_SUBGROUP_SIZE_KHR 0x9532
|
||||
#define GL_SUBGROUP_SUPPORTED_STAGES_KHR 0x9533
|
||||
#define GL_SUBGROUP_SUPPORTED_FEATURES_KHR 0x9534
|
||||
#define GL_SUBGROUP_QUAD_ALL_STAGES_KHR 0x9535
|
||||
#define GL_SUBGROUP_FEATURE_BASIC_BIT_KHR 0x00000001
|
||||
#define GL_SUBGROUP_FEATURE_VOTE_BIT_KHR 0x00000002
|
||||
#define GL_SUBGROUP_FEATURE_ARITHMETIC_BIT_KHR 0x00000004
|
||||
#define GL_SUBGROUP_FEATURE_BALLOT_BIT_KHR 0x00000008
|
||||
#define GL_SUBGROUP_FEATURE_SHUFFLE_BIT_KHR 0x00000010
|
||||
#define GL_SUBGROUP_FEATURE_SHUFFLE_RELATIVE_BIT_KHR 0x00000020
|
||||
#define GL_SUBGROUP_FEATURE_CLUSTERED_BIT_KHR 0x00000040
|
||||
#define GL_SUBGROUP_FEATURE_QUAD_BIT_KHR 0x00000080
|
||||
#endif /* GL_KHR_shader_subgroup */
|
||||
|
||||
#ifndef GL_KHR_texture_compression_astc_hdr
|
||||
#define GL_KHR_texture_compression_astc_hdr 1
|
||||
#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0
|
||||
@@ -5115,7 +5120,7 @@ GLAPI void APIENTRY glVertex4bvOES (const GLbyte *coords);
|
||||
|
||||
#ifndef GL_OES_fixed_point
|
||||
#define GL_OES_fixed_point 1
|
||||
typedef GLint GLfixed;
|
||||
typedef khronos_int32_t GLfixed;
|
||||
#define GL_FIXED_OES 0x140C
|
||||
typedef void (APIENTRYP PFNGLALPHAFUNCXOESPROC) (GLenum func, GLfixed ref);
|
||||
typedef void (APIENTRYP PFNGLCLEARCOLORXOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
|
||||
@@ -5411,12 +5416,12 @@ typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severi
|
||||
typedef void (APIENTRYP PFNGLDEBUGMESSAGEENABLEAMDPROC) (GLenum category, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
|
||||
typedef void (APIENTRYP PFNGLDEBUGMESSAGEINSERTAMDPROC) (GLenum category, GLenum severity, GLuint id, GLsizei length, const GLchar *buf);
|
||||
typedef void (APIENTRYP PFNGLDEBUGMESSAGECALLBACKAMDPROC) (GLDEBUGPROCAMD callback, void *userParam);
|
||||
typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGAMDPROC) (GLuint count, GLsizei bufsize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
|
||||
typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGAMDPROC) (GLuint count, GLsizei bufSize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glDebugMessageEnableAMD (GLenum category, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
|
||||
GLAPI void APIENTRY glDebugMessageInsertAMD (GLenum category, GLenum severity, GLuint id, GLsizei length, const GLchar *buf);
|
||||
GLAPI void APIENTRY glDebugMessageCallbackAMD (GLDEBUGPROCAMD callback, void *userParam);
|
||||
GLAPI GLuint APIENTRY glGetDebugMessageLogAMD (GLuint count, GLsizei bufsize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
|
||||
GLAPI GLuint APIENTRY glGetDebugMessageLogAMD (GLuint count, GLsizei bufSize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
|
||||
#endif
|
||||
#endif /* GL_AMD_debug_output */
|
||||
|
||||
@@ -5440,6 +5445,22 @@ GLAPI void APIENTRY glBlendEquationSeparateIndexedAMD (GLuint buf, GLenum modeRG
|
||||
#endif
|
||||
#endif /* GL_AMD_draw_buffers_blend */
|
||||
|
||||
#ifndef GL_AMD_framebuffer_multisample_advanced
|
||||
#define GL_AMD_framebuffer_multisample_advanced 1
|
||||
#define GL_RENDERBUFFER_STORAGE_SAMPLES_AMD 0x91B2
|
||||
#define GL_MAX_COLOR_FRAMEBUFFER_SAMPLES_AMD 0x91B3
|
||||
#define GL_MAX_COLOR_FRAMEBUFFER_STORAGE_SAMPLES_AMD 0x91B4
|
||||
#define GL_MAX_DEPTH_STENCIL_FRAMEBUFFER_SAMPLES_AMD 0x91B5
|
||||
#define GL_NUM_SUPPORTED_MULTISAMPLE_MODES_AMD 0x91B6
|
||||
#define GL_SUPPORTED_MULTISAMPLE_MODES_AMD 0x91B7
|
||||
typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMDPROC) (GLenum target, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
typedef void (APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMDPROC) (GLuint renderbuffer, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glRenderbufferStorageMultisampleAdvancedAMD (GLenum target, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
GLAPI void APIENTRY glNamedRenderbufferStorageMultisampleAdvancedAMD (GLuint renderbuffer, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height);
|
||||
#endif
|
||||
#endif /* GL_AMD_framebuffer_multisample_advanced */
|
||||
|
||||
#ifndef GL_AMD_framebuffer_sample_positions
|
||||
#define GL_AMD_framebuffer_sample_positions 1
|
||||
#define GL_SUBSAMPLE_DISTANCE_AMD 0x883F
|
||||
@@ -5485,7 +5506,7 @@ GLAPI void APIENTRY glGetNamedFramebufferParameterfvAMD (GLuint framebuffer, GLe
|
||||
|
||||
#ifndef GL_AMD_gpu_shader_int64
|
||||
#define GL_AMD_gpu_shader_int64 1
|
||||
typedef int64_t GLint64EXT;
|
||||
typedef khronos_int64_t GLint64EXT;
|
||||
#define GL_INT64_NV 0x140E
|
||||
#define GL_UNSIGNED_INT64_NV 0x140F
|
||||
#define GL_INT8_NV 0x8FE0
|
||||
@@ -5704,6 +5725,10 @@ GLAPI void APIENTRY glSetMultisamplefvAMD (GLenum pname, GLuint index, const GLf
|
||||
#define GL_AMD_shader_explicit_vertex_parameter 1
|
||||
#endif /* GL_AMD_shader_explicit_vertex_parameter */
|
||||
|
||||
#ifndef GL_AMD_shader_gpu_shader_half_float_fetch
|
||||
#define GL_AMD_shader_gpu_shader_half_float_fetch 1
|
||||
#endif /* GL_AMD_shader_gpu_shader_half_float_fetch */
|
||||
|
||||
#ifndef GL_AMD_shader_image_load_store_lod
|
||||
#define GL_AMD_shader_image_load_store_lod 1
|
||||
#endif /* GL_AMD_shader_image_load_store_lod */
|
||||
@@ -6451,6 +6476,21 @@ GLAPI void APIENTRY glVertexBlendEnvfATI (GLenum pname, GLfloat param);
|
||||
#define GL_422_REV_AVERAGE_EXT 0x80CF
|
||||
#endif /* GL_EXT_422_pixels */
|
||||
|
||||
#ifndef GL_EXT_EGL_image_storage
|
||||
#define GL_EXT_EGL_image_storage 1
|
||||
typedef void *GLeglImageOES;
|
||||
typedef void (APIENTRYP PFNGLEGLIMAGETARGETTEXSTORAGEEXTPROC) (GLenum target, GLeglImageOES image, const GLint* attrib_list);
|
||||
typedef void (APIENTRYP PFNGLEGLIMAGETARGETTEXTURESTORAGEEXTPROC) (GLuint texture, GLeglImageOES image, const GLint* attrib_list);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glEGLImageTargetTexStorageEXT (GLenum target, GLeglImageOES image, const GLint* attrib_list);
|
||||
GLAPI void APIENTRY glEGLImageTargetTextureStorageEXT (GLuint texture, GLeglImageOES image, const GLint* attrib_list);
|
||||
#endif
|
||||
#endif /* GL_EXT_EGL_image_storage */
|
||||
|
||||
#ifndef GL_EXT_EGL_sync
|
||||
#define GL_EXT_EGL_sync 1
|
||||
#endif /* GL_EXT_EGL_sync */
|
||||
|
||||
#ifndef GL_EXT_abgr
|
||||
#define GL_EXT_abgr 1
|
||||
#define GL_ABGR_EXT 0x8000
|
||||
@@ -7780,6 +7820,18 @@ GLAPI void APIENTRY glSamplePatternEXT (GLenum pattern);
|
||||
#endif
|
||||
#endif /* GL_EXT_multisample */
|
||||
|
||||
#ifndef GL_EXT_multiview_tessellation_geometry_shader
|
||||
#define GL_EXT_multiview_tessellation_geometry_shader 1
|
||||
#endif /* GL_EXT_multiview_tessellation_geometry_shader */
|
||||
|
||||
#ifndef GL_EXT_multiview_texture_multisample
|
||||
#define GL_EXT_multiview_texture_multisample 1
|
||||
#endif /* GL_EXT_multiview_texture_multisample */
|
||||
|
||||
#ifndef GL_EXT_multiview_timer_query
|
||||
#define GL_EXT_multiview_timer_query 1
|
||||
#endif /* GL_EXT_multiview_timer_query */
|
||||
|
||||
#ifndef GL_EXT_packed_depth_stencil
|
||||
#define GL_EXT_packed_depth_stencil 1
|
||||
#define GL_DEPTH_STENCIL_EXT 0x84F9
|
||||
@@ -8049,6 +8101,19 @@ GLAPI GLuint APIENTRY glCreateShaderProgramEXT (GLenum type, const GLchar *strin
|
||||
#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA
|
||||
#endif /* GL_EXT_separate_specular_color */
|
||||
|
||||
#ifndef GL_EXT_shader_framebuffer_fetch
|
||||
#define GL_EXT_shader_framebuffer_fetch 1
|
||||
#define GL_FRAGMENT_SHADER_DISCARDS_SAMPLES_EXT 0x8A52
|
||||
#endif /* GL_EXT_shader_framebuffer_fetch */
|
||||
|
||||
#ifndef GL_EXT_shader_framebuffer_fetch_non_coherent
|
||||
#define GL_EXT_shader_framebuffer_fetch_non_coherent 1
|
||||
typedef void (APIENTRYP PFNGLFRAMEBUFFERFETCHBARRIEREXTPROC) (void);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glFramebufferFetchBarrierEXT (void);
|
||||
#endif
|
||||
#endif /* GL_EXT_shader_framebuffer_fetch_non_coherent */
|
||||
|
||||
#ifndef GL_EXT_shader_image_load_formatted
|
||||
#define GL_EXT_shader_image_load_formatted 1
|
||||
#endif /* GL_EXT_shader_image_load_formatted */
|
||||
@@ -8485,6 +8550,11 @@ GLAPI void APIENTRY glTextureNormalEXT (GLenum mode);
|
||||
#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F
|
||||
#endif /* GL_EXT_texture_sRGB */
|
||||
|
||||
#ifndef GL_EXT_texture_sRGB_R8
|
||||
#define GL_EXT_texture_sRGB_R8 1
|
||||
#define GL_SR8_EXT 0x8FBD
|
||||
#endif /* GL_EXT_texture_sRGB_R8 */
|
||||
|
||||
#ifndef GL_EXT_texture_sRGB_decode
|
||||
#define GL_EXT_texture_sRGB_decode 1
|
||||
#define GL_TEXTURE_SRGB_DECODE_EXT 0x8A48
|
||||
@@ -8492,6 +8562,10 @@ GLAPI void APIENTRY glTextureNormalEXT (GLenum mode);
|
||||
#define GL_SKIP_DECODE_EXT 0x8A4A
|
||||
#endif /* GL_EXT_texture_sRGB_decode */
|
||||
|
||||
#ifndef GL_EXT_texture_shadow_lod
|
||||
#define GL_EXT_texture_shadow_lod 1
|
||||
#endif /* GL_EXT_texture_shadow_lod */
|
||||
|
||||
#ifndef GL_EXT_texture_shared_exponent
|
||||
#define GL_EXT_texture_shared_exponent 1
|
||||
#define GL_RGB9_E5_EXT 0x8C3D
|
||||
@@ -9098,6 +9172,11 @@ GLAPI void APIENTRY glBlendFuncSeparateINGR (GLenum sfactorRGB, GLenum dfactorRG
|
||||
#define GL_INTERLACE_READ_INGR 0x8568
|
||||
#endif /* GL_INGR_interlace_read */
|
||||
|
||||
#ifndef GL_INTEL_blackhole_render
|
||||
#define GL_INTEL_blackhole_render 1
|
||||
#define GL_BLACKHOLE_RENDER_INTEL 0x83FC
|
||||
#endif /* GL_INTEL_blackhole_render */
|
||||
|
||||
#ifndef GL_INTEL_conservative_rasterization
|
||||
#define GL_INTEL_conservative_rasterization 1
|
||||
#define GL_CONSERVATIVE_RASTERIZATION_INTEL 0x83FE
|
||||
@@ -9206,6 +9285,27 @@ GLAPI void APIENTRY glGetPerfQueryInfoINTEL (GLuint queryId, GLuint queryNameLen
|
||||
#define GL_TEXTURE_2D_STACK_BINDING_MESAX 0x875E
|
||||
#endif /* GL_MESAX_texture_stack */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_flip_x
|
||||
#define GL_MESA_framebuffer_flip_x 1
|
||||
#define GL_FRAMEBUFFER_FLIP_X_MESA 0x8BBC
|
||||
#endif /* GL_MESA_framebuffer_flip_x */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_flip_y
|
||||
#define GL_MESA_framebuffer_flip_y 1
|
||||
#define GL_FRAMEBUFFER_FLIP_Y_MESA 0x8BBB
|
||||
typedef void (APIENTRYP PFNGLFRAMEBUFFERPARAMETERIMESAPROC) (GLenum target, GLenum pname, GLint param);
|
||||
typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVMESAPROC) (GLenum target, GLenum pname, GLint *params);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glFramebufferParameteriMESA (GLenum target, GLenum pname, GLint param);
|
||||
GLAPI void APIENTRY glGetFramebufferParameterivMESA (GLenum target, GLenum pname, GLint *params);
|
||||
#endif
|
||||
#endif /* GL_MESA_framebuffer_flip_y */
|
||||
|
||||
#ifndef GL_MESA_framebuffer_swap_xy
|
||||
#define GL_MESA_framebuffer_swap_xy 1
|
||||
#define GL_FRAMEBUFFER_SWAP_XY_MESA 0x8BBD
|
||||
#endif /* GL_MESA_framebuffer_swap_xy */
|
||||
|
||||
#ifndef GL_MESA_pack_invert
|
||||
#define GL_MESA_pack_invert 1
|
||||
#define GL_PACK_INVERT_MESA 0x8758
|
||||
@@ -9319,6 +9419,25 @@ GLAPI void APIENTRY glEndConditionalRenderNVX (void);
|
||||
#define GL_GPU_MEMORY_INFO_EVICTED_MEMORY_NVX 0x904B
|
||||
#endif /* GL_NVX_gpu_memory_info */
|
||||
|
||||
#ifndef GL_NVX_gpu_multicast2
|
||||
#define GL_NVX_gpu_multicast2 1
|
||||
#define GL_UPLOAD_GPU_MASK_NVX 0x954A
|
||||
typedef void (APIENTRYP PFNGLUPLOADGPUMASKNVXPROC) (GLbitfield mask);
|
||||
typedef void (APIENTRYP PFNGLMULTICASTVIEWPORTARRAYVNVXPROC) (GLuint gpu, GLuint first, GLsizei count, const GLfloat *v);
|
||||
typedef void (APIENTRYP PFNGLMULTICASTVIEWPORTPOSITIONWSCALENVXPROC) (GLuint gpu, GLuint index, GLfloat xcoeff, GLfloat ycoeff);
|
||||
typedef void (APIENTRYP PFNGLMULTICASTSCISSORARRAYVNVXPROC) (GLuint gpu, GLuint first, GLsizei count, const GLint *v);
|
||||
typedef GLuint (APIENTRYP PFNGLASYNCCOPYBUFFERSUBDATANVXPROC) (GLsizei waitSemaphoreCount, const GLuint *waitSemaphoreArray, const GLuint64 *fenceValueArray, GLuint readGpu, GLbitfield writeGpuMask, GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size, GLsizei signalSemaphoreCount, const GLuint *signalSemaphoreArray, const GLuint64 *signalValueArray);
|
||||
typedef GLuint (APIENTRYP PFNGLASYNCCOPYIMAGESUBDATANVXPROC) (GLsizei waitSemaphoreCount, const GLuint *waitSemaphoreArray, const GLuint64 *waitValueArray, GLuint srcGpu, GLbitfield dstGpuMask, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth, GLsizei signalSemaphoreCount, const GLuint *signalSemaphoreArray, const GLuint64 *signalValueArray);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glUploadGpuMaskNVX (GLbitfield mask);
|
||||
GLAPI void APIENTRY glMulticastViewportArrayvNVX (GLuint gpu, GLuint first, GLsizei count, const GLfloat *v);
|
||||
GLAPI void APIENTRY glMulticastViewportPositionWScaleNVX (GLuint gpu, GLuint index, GLfloat xcoeff, GLfloat ycoeff);
|
||||
GLAPI void APIENTRY glMulticastScissorArrayvNVX (GLuint gpu, GLuint first, GLsizei count, const GLint *v);
|
||||
GLAPI GLuint APIENTRY glAsyncCopyBufferSubDataNVX (GLsizei waitSemaphoreCount, const GLuint *waitSemaphoreArray, const GLuint64 *fenceValueArray, GLuint readGpu, GLbitfield writeGpuMask, GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size, GLsizei signalSemaphoreCount, const GLuint *signalSemaphoreArray, const GLuint64 *signalValueArray);
|
||||
GLAPI GLuint APIENTRY glAsyncCopyImageSubDataNVX (GLsizei waitSemaphoreCount, const GLuint *waitSemaphoreArray, const GLuint64 *waitValueArray, GLuint srcGpu, GLbitfield dstGpuMask, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth, GLsizei signalSemaphoreCount, const GLuint *signalSemaphoreArray, const GLuint64 *signalValueArray);
|
||||
#endif
|
||||
#endif /* GL_NVX_gpu_multicast2 */
|
||||
|
||||
#ifndef GL_NVX_linked_gpu_multicast
|
||||
#define GL_NVX_linked_gpu_multicast 1
|
||||
#define GL_LGPU_SEPARATE_STORAGE_BIT_NVX 0x0800
|
||||
@@ -9333,6 +9452,20 @@ GLAPI void APIENTRY glLGPUInterlockNVX (void);
|
||||
#endif
|
||||
#endif /* GL_NVX_linked_gpu_multicast */
|
||||
|
||||
#ifndef GL_NVX_progress_fence
|
||||
#define GL_NVX_progress_fence 1
|
||||
typedef GLuint (APIENTRYP PFNGLCREATEPROGRESSFENCENVXPROC) (void);
|
||||
typedef void (APIENTRYP PFNGLSIGNALSEMAPHOREUI64NVXPROC) (GLuint signalGpu, GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
typedef void (APIENTRYP PFNGLWAITSEMAPHOREUI64NVXPROC) (GLuint waitGpu, GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
typedef void (APIENTRYP PFNGLCLIENTWAITSEMAPHOREUI64NVXPROC) (GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI GLuint APIENTRY glCreateProgressFenceNVX (void);
|
||||
GLAPI void APIENTRY glSignalSemaphoreui64NVX (GLuint signalGpu, GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
GLAPI void APIENTRY glWaitSemaphoreui64NVX (GLuint waitGpu, GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
GLAPI void APIENTRY glClientWaitSemaphoreui64NVX (GLsizei fenceObjectCount, const GLuint *semaphoreArray, const GLuint64 *fenceValueArray);
|
||||
#endif
|
||||
#endif /* GL_NVX_progress_fence */
|
||||
|
||||
#ifndef GL_NV_alpha_to_coverage_dither_control
|
||||
#define GL_NV_alpha_to_coverage_dither_control 1
|
||||
#define GL_ALPHA_TO_COVERAGE_DITHER_DEFAULT_NV 0x934D
|
||||
@@ -9545,6 +9678,10 @@ GLAPI void APIENTRY glCallCommandListNV (GLuint list);
|
||||
#define GL_COMPUTE_PROGRAM_PARAMETER_BUFFER_NV 0x90FC
|
||||
#endif /* GL_NV_compute_program5 */
|
||||
|
||||
#ifndef GL_NV_compute_shader_derivatives
|
||||
#define GL_NV_compute_shader_derivatives 1
|
||||
#endif /* GL_NV_compute_shader_derivatives */
|
||||
|
||||
#ifndef GL_NV_conditional_render
|
||||
#define GL_NV_conditional_render 1
|
||||
#define GL_QUERY_WAIT_NV 0x8E13
|
||||
@@ -9843,6 +9980,10 @@ GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint id, GLsizei len, cons
|
||||
#define GL_NV_fragment_program_option 1
|
||||
#endif /* GL_NV_fragment_program_option */
|
||||
|
||||
#ifndef GL_NV_fragment_shader_barycentric
|
||||
#define GL_NV_fragment_shader_barycentric 1
|
||||
#endif /* GL_NV_fragment_shader_barycentric */
|
||||
|
||||
#ifndef GL_NV_fragment_shader_interlock
|
||||
#define GL_NV_fragment_shader_interlock 1
|
||||
#endif /* GL_NV_fragment_shader_interlock */
|
||||
@@ -9858,11 +9999,11 @@ GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint id, GLsizei len, cons
|
||||
#define GL_COVERAGE_MODULATION_NV 0x9332
|
||||
#define GL_COVERAGE_MODULATION_TABLE_SIZE_NV 0x9333
|
||||
typedef void (APIENTRYP PFNGLCOVERAGEMODULATIONTABLENVPROC) (GLsizei n, const GLfloat *v);
|
||||
typedef void (APIENTRYP PFNGLGETCOVERAGEMODULATIONTABLENVPROC) (GLsizei bufsize, GLfloat *v);
|
||||
typedef void (APIENTRYP PFNGLGETCOVERAGEMODULATIONTABLENVPROC) (GLsizei bufSize, GLfloat *v);
|
||||
typedef void (APIENTRYP PFNGLCOVERAGEMODULATIONNVPROC) (GLenum components);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glCoverageModulationTableNV (GLsizei n, const GLfloat *v);
|
||||
GLAPI void APIENTRY glGetCoverageModulationTableNV (GLsizei bufsize, GLfloat *v);
|
||||
GLAPI void APIENTRY glGetCoverageModulationTableNV (GLsizei bufSize, GLfloat *v);
|
||||
GLAPI void APIENTRY glCoverageModulationNV (GLenum components);
|
||||
#endif
|
||||
#endif /* GL_NV_framebuffer_mixed_samples */
|
||||
@@ -10115,9 +10256,9 @@ GLAPI void APIENTRY glVertexAttribs4hvNV (GLuint index, GLsizei n, const GLhalfN
|
||||
#define GL_SUPERSAMPLE_SCALE_X_NV 0x9372
|
||||
#define GL_SUPERSAMPLE_SCALE_Y_NV 0x9373
|
||||
#define GL_CONFORMANT_NV 0x9374
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATSAMPLEIVNVPROC) (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
typedef void (APIENTRYP PFNGLGETINTERNALFORMATSAMPLEIVNVPROC) (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei count, GLint *params);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glGetInternalformatSampleivNV (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei bufSize, GLint *params);
|
||||
GLAPI void APIENTRY glGetInternalformatSampleivNV (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei count, GLint *params);
|
||||
#endif
|
||||
#endif /* GL_NV_internalformat_sample_query */
|
||||
|
||||
@@ -10127,6 +10268,96 @@ GLAPI void APIENTRY glGetInternalformatSampleivNV (GLenum target, GLenum interna
|
||||
#define GL_MAX_SPOT_EXPONENT_NV 0x8505
|
||||
#endif /* GL_NV_light_max_exponent */
|
||||
|
||||
#ifndef GL_NV_memory_attachment
|
||||
#define GL_NV_memory_attachment 1
|
||||
#define GL_ATTACHED_MEMORY_OBJECT_NV 0x95A4
|
||||
#define GL_ATTACHED_MEMORY_OFFSET_NV 0x95A5
|
||||
#define GL_MEMORY_ATTACHABLE_ALIGNMENT_NV 0x95A6
|
||||
#define GL_MEMORY_ATTACHABLE_SIZE_NV 0x95A7
|
||||
#define GL_MEMORY_ATTACHABLE_NV 0x95A8
|
||||
#define GL_DETACHED_MEMORY_INCARNATION_NV 0x95A9
|
||||
#define GL_DETACHED_TEXTURES_NV 0x95AA
|
||||
#define GL_DETACHED_BUFFERS_NV 0x95AB
|
||||
#define GL_MAX_DETACHED_TEXTURES_NV 0x95AC
|
||||
#define GL_MAX_DETACHED_BUFFERS_NV 0x95AD
|
||||
typedef void (APIENTRYP PFNGLGETMEMORYOBJECTDETACHEDRESOURCESUIVNVPROC) (GLuint memory, GLenum pname, GLint first, GLsizei count, GLuint *params);
|
||||
typedef void (APIENTRYP PFNGLRESETMEMORYOBJECTPARAMETERNVPROC) (GLuint memory, GLenum pname);
|
||||
typedef void (APIENTRYP PFNGLTEXATTACHMEMORYNVPROC) (GLenum target, GLuint memory, GLuint64 offset);
|
||||
typedef void (APIENTRYP PFNGLBUFFERATTACHMEMORYNVPROC) (GLenum target, GLuint memory, GLuint64 offset);
|
||||
typedef void (APIENTRYP PFNGLTEXTUREATTACHMEMORYNVPROC) (GLuint texture, GLuint memory, GLuint64 offset);
|
||||
typedef void (APIENTRYP PFNGLNAMEDBUFFERATTACHMEMORYNVPROC) (GLuint buffer, GLuint memory, GLuint64 offset);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glGetMemoryObjectDetachedResourcesuivNV (GLuint memory, GLenum pname, GLint first, GLsizei count, GLuint *params);
|
||||
GLAPI void APIENTRY glResetMemoryObjectParameterNV (GLuint memory, GLenum pname);
|
||||
GLAPI void APIENTRY glTexAttachMemoryNV (GLenum target, GLuint memory, GLuint64 offset);
|
||||
GLAPI void APIENTRY glBufferAttachMemoryNV (GLenum target, GLuint memory, GLuint64 offset);
|
||||
GLAPI void APIENTRY glTextureAttachMemoryNV (GLuint texture, GLuint memory, GLuint64 offset);
|
||||
GLAPI void APIENTRY glNamedBufferAttachMemoryNV (GLuint buffer, GLuint memory, GLuint64 offset);
|
||||
#endif
|
||||
#endif /* GL_NV_memory_attachment */
|
||||
|
||||
#ifndef GL_NV_mesh_shader
|
||||
#define GL_NV_mesh_shader 1
|
||||
#define GL_MESH_SHADER_NV 0x9559
|
||||
#define GL_TASK_SHADER_NV 0x955A
|
||||
#define GL_MAX_MESH_UNIFORM_BLOCKS_NV 0x8E60
|
||||
#define GL_MAX_MESH_TEXTURE_IMAGE_UNITS_NV 0x8E61
|
||||
#define GL_MAX_MESH_IMAGE_UNIFORMS_NV 0x8E62
|
||||
#define GL_MAX_MESH_UNIFORM_COMPONENTS_NV 0x8E63
|
||||
#define GL_MAX_MESH_ATOMIC_COUNTER_BUFFERS_NV 0x8E64
|
||||
#define GL_MAX_MESH_ATOMIC_COUNTERS_NV 0x8E65
|
||||
#define GL_MAX_MESH_SHADER_STORAGE_BLOCKS_NV 0x8E66
|
||||
#define GL_MAX_COMBINED_MESH_UNIFORM_COMPONENTS_NV 0x8E67
|
||||
#define GL_MAX_TASK_UNIFORM_BLOCKS_NV 0x8E68
|
||||
#define GL_MAX_TASK_TEXTURE_IMAGE_UNITS_NV 0x8E69
|
||||
#define GL_MAX_TASK_IMAGE_UNIFORMS_NV 0x8E6A
|
||||
#define GL_MAX_TASK_UNIFORM_COMPONENTS_NV 0x8E6B
|
||||
#define GL_MAX_TASK_ATOMIC_COUNTER_BUFFERS_NV 0x8E6C
|
||||
#define GL_MAX_TASK_ATOMIC_COUNTERS_NV 0x8E6D
|
||||
#define GL_MAX_TASK_SHADER_STORAGE_BLOCKS_NV 0x8E6E
|
||||
#define GL_MAX_COMBINED_TASK_UNIFORM_COMPONENTS_NV 0x8E6F
|
||||
#define GL_MAX_MESH_WORK_GROUP_INVOCATIONS_NV 0x95A2
|
||||
#define GL_MAX_TASK_WORK_GROUP_INVOCATIONS_NV 0x95A3
|
||||
#define GL_MAX_MESH_TOTAL_MEMORY_SIZE_NV 0x9536
|
||||
#define GL_MAX_TASK_TOTAL_MEMORY_SIZE_NV 0x9537
|
||||
#define GL_MAX_MESH_OUTPUT_VERTICES_NV 0x9538
|
||||
#define GL_MAX_MESH_OUTPUT_PRIMITIVES_NV 0x9539
|
||||
#define GL_MAX_TASK_OUTPUT_COUNT_NV 0x953A
|
||||
#define GL_MAX_DRAW_MESH_TASKS_COUNT_NV 0x953D
|
||||
#define GL_MAX_MESH_VIEWS_NV 0x9557
|
||||
#define GL_MESH_OUTPUT_PER_VERTEX_GRANULARITY_NV 0x92DF
|
||||
#define GL_MESH_OUTPUT_PER_PRIMITIVE_GRANULARITY_NV 0x9543
|
||||
#define GL_MAX_MESH_WORK_GROUP_SIZE_NV 0x953B
|
||||
#define GL_MAX_TASK_WORK_GROUP_SIZE_NV 0x953C
|
||||
#define GL_MESH_WORK_GROUP_SIZE_NV 0x953E
|
||||
#define GL_TASK_WORK_GROUP_SIZE_NV 0x953F
|
||||
#define GL_MESH_VERTICES_OUT_NV 0x9579
|
||||
#define GL_MESH_PRIMITIVES_OUT_NV 0x957A
|
||||
#define GL_MESH_OUTPUT_TYPE_NV 0x957B
|
||||
#define GL_UNIFORM_BLOCK_REFERENCED_BY_MESH_SHADER_NV 0x959C
|
||||
#define GL_UNIFORM_BLOCK_REFERENCED_BY_TASK_SHADER_NV 0x959D
|
||||
#define GL_REFERENCED_BY_MESH_SHADER_NV 0x95A0
|
||||
#define GL_REFERENCED_BY_TASK_SHADER_NV 0x95A1
|
||||
#define GL_MESH_SHADER_BIT_NV 0x00000040
|
||||
#define GL_TASK_SHADER_BIT_NV 0x00000080
|
||||
#define GL_MESH_SUBROUTINE_NV 0x957C
|
||||
#define GL_TASK_SUBROUTINE_NV 0x957D
|
||||
#define GL_MESH_SUBROUTINE_UNIFORM_NV 0x957E
|
||||
#define GL_TASK_SUBROUTINE_UNIFORM_NV 0x957F
|
||||
#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_MESH_SHADER_NV 0x959E
|
||||
#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TASK_SHADER_NV 0x959F
|
||||
typedef void (APIENTRYP PFNGLDRAWMESHTASKSNVPROC) (GLuint first, GLuint count);
|
||||
typedef void (APIENTRYP PFNGLDRAWMESHTASKSINDIRECTNVPROC) (GLintptr indirect);
|
||||
typedef void (APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTNVPROC) (GLintptr indirect, GLsizei drawcount, GLsizei stride);
|
||||
typedef void (APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTCOUNTNVPROC) (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glDrawMeshTasksNV (GLuint first, GLuint count);
|
||||
GLAPI void APIENTRY glDrawMeshTasksIndirectNV (GLintptr indirect);
|
||||
GLAPI void APIENTRY glMultiDrawMeshTasksIndirectNV (GLintptr indirect, GLsizei drawcount, GLsizei stride);
|
||||
GLAPI void APIENTRY glMultiDrawMeshTasksIndirectCountNV (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride);
|
||||
#endif
|
||||
#endif /* GL_NV_mesh_shader */
|
||||
|
||||
#ifndef GL_NV_multisample_coverage
|
||||
#define GL_NV_multisample_coverage 1
|
||||
#endif /* GL_NV_multisample_coverage */
|
||||
@@ -10408,7 +10639,7 @@ typedef GLenum (APIENTRYP PFNGLPATHGLYPHINDEXRANGENVPROC) (GLenum fontTarget, co
|
||||
typedef GLenum (APIENTRYP PFNGLPATHGLYPHINDEXARRAYNVPROC) (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
|
||||
typedef GLenum (APIENTRYP PFNGLPATHMEMORYGLYPHINDEXARRAYNVPROC) (GLuint firstPathName, GLenum fontTarget, GLsizeiptr fontSize, const void *fontData, GLsizei faceIndex, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
|
||||
typedef void (APIENTRYP PFNGLPROGRAMPATHFRAGMENTINPUTGENNVPROC) (GLuint program, GLint location, GLenum genMode, GLint components, const GLfloat *coeffs);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEFVNVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLfloat *params);
|
||||
typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEFVNVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLfloat *params);
|
||||
typedef void (APIENTRYP PFNGLPATHCOLORGENNVPROC) (GLenum color, GLenum genMode, GLenum colorFormat, const GLfloat *coeffs);
|
||||
typedef void (APIENTRYP PFNGLPATHTEXGENNVPROC) (GLenum texCoordSet, GLenum genMode, GLint components, const GLfloat *coeffs);
|
||||
typedef void (APIENTRYP PFNGLPATHFOGGENNVPROC) (GLenum genMode);
|
||||
@@ -10473,7 +10704,7 @@ GLAPI GLenum APIENTRY glPathGlyphIndexRangeNV (GLenum fontTarget, const void *fo
|
||||
GLAPI GLenum APIENTRY glPathGlyphIndexArrayNV (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
|
||||
GLAPI GLenum APIENTRY glPathMemoryGlyphIndexArrayNV (GLuint firstPathName, GLenum fontTarget, GLsizeiptr fontSize, const void *fontData, GLsizei faceIndex, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
|
||||
GLAPI void APIENTRY glProgramPathFragmentInputGenNV (GLuint program, GLint location, GLenum genMode, GLint components, const GLfloat *coeffs);
|
||||
GLAPI void APIENTRY glGetProgramResourcefvNV (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLfloat *params);
|
||||
GLAPI void APIENTRY glGetProgramResourcefvNV (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLfloat *params);
|
||||
GLAPI void APIENTRY glPathColorGenNV (GLenum color, GLenum genMode, GLenum colorFormat, const GLfloat *coeffs);
|
||||
GLAPI void APIENTRY glPathTexGenNV (GLenum texCoordSet, GLenum genMode, GLint components, const GLfloat *coeffs);
|
||||
GLAPI void APIENTRY glPathFogGenNV (GLenum genMode);
|
||||
@@ -10562,9 +10793,9 @@ GLAPI void APIENTRY glPrimitiveRestartIndexNV (GLuint index);
|
||||
#define GL_QUERY_RESOURCE_TEXTURE_NV 0x9545
|
||||
#define GL_QUERY_RESOURCE_RENDERBUFFER_NV 0x9546
|
||||
#define GL_QUERY_RESOURCE_BUFFEROBJECT_NV 0x9547
|
||||
typedef GLint (APIENTRYP PFNGLQUERYRESOURCENVPROC) (GLenum queryType, GLint tagId, GLuint bufSize, GLint *buffer);
|
||||
typedef GLint (APIENTRYP PFNGLQUERYRESOURCENVPROC) (GLenum queryType, GLint tagId, GLuint count, GLint *buffer);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI GLint APIENTRY glQueryResourceNV (GLenum queryType, GLint tagId, GLuint bufSize, GLint *buffer);
|
||||
GLAPI GLint APIENTRY glQueryResourceNV (GLenum queryType, GLint tagId, GLuint count, GLint *buffer);
|
||||
#endif
|
||||
#endif /* GL_NV_query_resource */
|
||||
|
||||
@@ -10672,6 +10903,11 @@ GLAPI void APIENTRY glGetCombinerStageParameterfvNV (GLenum stage, GLenum pname,
|
||||
#endif
|
||||
#endif /* GL_NV_register_combiners2 */
|
||||
|
||||
#ifndef GL_NV_representative_fragment_test
|
||||
#define GL_NV_representative_fragment_test 1
|
||||
#define GL_REPRESENTATIVE_FRAGMENT_TEST_NV 0x937F
|
||||
#endif /* GL_NV_representative_fragment_test */
|
||||
|
||||
#ifndef GL_NV_robustness_video_memory_purge
|
||||
#define GL_NV_robustness_video_memory_purge 1
|
||||
#define GL_PURGED_CONTEXT_RESET_NV 0x92BB
|
||||
@@ -10701,6 +10937,18 @@ GLAPI void APIENTRY glResolveDepthValuesNV (void);
|
||||
#define GL_NV_sample_mask_override_coverage 1
|
||||
#endif /* GL_NV_sample_mask_override_coverage */
|
||||
|
||||
#ifndef GL_NV_scissor_exclusive
|
||||
#define GL_NV_scissor_exclusive 1
|
||||
#define GL_SCISSOR_TEST_EXCLUSIVE_NV 0x9555
|
||||
#define GL_SCISSOR_BOX_EXCLUSIVE_NV 0x9556
|
||||
typedef void (APIENTRYP PFNGLSCISSOREXCLUSIVENVPROC) (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
typedef void (APIENTRYP PFNGLSCISSOREXCLUSIVEARRAYVNVPROC) (GLuint first, GLsizei count, const GLint *v);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glScissorExclusiveNV (GLint x, GLint y, GLsizei width, GLsizei height);
|
||||
GLAPI void APIENTRY glScissorExclusiveArrayvNV (GLuint first, GLsizei count, const GLint *v);
|
||||
#endif
|
||||
#endif /* GL_NV_scissor_exclusive */
|
||||
|
||||
#ifndef GL_NV_shader_atomic_counters
|
||||
#define GL_NV_shader_atomic_counters 1
|
||||
#endif /* GL_NV_shader_atomic_counters */
|
||||
@@ -10765,6 +11013,15 @@ GLAPI void APIENTRY glProgramUniformui64vNV (GLuint program, GLint location, GLs
|
||||
#define GL_NV_shader_storage_buffer_object 1
|
||||
#endif /* GL_NV_shader_storage_buffer_object */
|
||||
|
||||
#ifndef GL_NV_shader_subgroup_partitioned
|
||||
#define GL_NV_shader_subgroup_partitioned 1
|
||||
#define GL_SUBGROUP_FEATURE_PARTITIONED_BIT_NV 0x00000100
|
||||
#endif /* GL_NV_shader_subgroup_partitioned */
|
||||
|
||||
#ifndef GL_NV_shader_texture_footprint
|
||||
#define GL_NV_shader_texture_footprint 1
|
||||
#endif /* GL_NV_shader_texture_footprint */
|
||||
|
||||
#ifndef GL_NV_shader_thread_group
|
||||
#define GL_NV_shader_thread_group 1
|
||||
#define GL_WARP_SIZE_NV 0x9339
|
||||
@@ -10776,6 +11033,47 @@ GLAPI void APIENTRY glProgramUniformui64vNV (GLuint program, GLint location, GLs
|
||||
#define GL_NV_shader_thread_shuffle 1
|
||||
#endif /* GL_NV_shader_thread_shuffle */
|
||||
|
||||
#ifndef GL_NV_shading_rate_image
|
||||
#define GL_NV_shading_rate_image 1
|
||||
#define GL_SHADING_RATE_IMAGE_NV 0x9563
|
||||
#define GL_SHADING_RATE_NO_INVOCATIONS_NV 0x9564
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_PIXEL_NV 0x9565
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_1X2_PIXELS_NV 0x9566
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_2X1_PIXELS_NV 0x9567
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_2X2_PIXELS_NV 0x9568
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_2X4_PIXELS_NV 0x9569
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_4X2_PIXELS_NV 0x956A
|
||||
#define GL_SHADING_RATE_1_INVOCATION_PER_4X4_PIXELS_NV 0x956B
|
||||
#define GL_SHADING_RATE_2_INVOCATIONS_PER_PIXEL_NV 0x956C
|
||||
#define GL_SHADING_RATE_4_INVOCATIONS_PER_PIXEL_NV 0x956D
|
||||
#define GL_SHADING_RATE_8_INVOCATIONS_PER_PIXEL_NV 0x956E
|
||||
#define GL_SHADING_RATE_16_INVOCATIONS_PER_PIXEL_NV 0x956F
|
||||
#define GL_SHADING_RATE_IMAGE_BINDING_NV 0x955B
|
||||
#define GL_SHADING_RATE_IMAGE_TEXEL_WIDTH_NV 0x955C
|
||||
#define GL_SHADING_RATE_IMAGE_TEXEL_HEIGHT_NV 0x955D
|
||||
#define GL_SHADING_RATE_IMAGE_PALETTE_SIZE_NV 0x955E
|
||||
#define GL_MAX_COARSE_FRAGMENT_SAMPLES_NV 0x955F
|
||||
#define GL_SHADING_RATE_SAMPLE_ORDER_DEFAULT_NV 0x95AE
|
||||
#define GL_SHADING_RATE_SAMPLE_ORDER_PIXEL_MAJOR_NV 0x95AF
|
||||
#define GL_SHADING_RATE_SAMPLE_ORDER_SAMPLE_MAJOR_NV 0x95B0
|
||||
typedef void (APIENTRYP PFNGLBINDSHADINGRATEIMAGENVPROC) (GLuint texture);
|
||||
typedef void (APIENTRYP PFNGLGETSHADINGRATEIMAGEPALETTENVPROC) (GLuint viewport, GLuint entry, GLenum *rate);
|
||||
typedef void (APIENTRYP PFNGLGETSHADINGRATESAMPLELOCATIONIVNVPROC) (GLenum rate, GLuint samples, GLuint index, GLint *location);
|
||||
typedef void (APIENTRYP PFNGLSHADINGRATEIMAGEBARRIERNVPROC) (GLboolean synchronize);
|
||||
typedef void (APIENTRYP PFNGLSHADINGRATEIMAGEPALETTENVPROC) (GLuint viewport, GLuint first, GLsizei count, const GLenum *rates);
|
||||
typedef void (APIENTRYP PFNGLSHADINGRATESAMPLEORDERNVPROC) (GLenum order);
|
||||
typedef void (APIENTRYP PFNGLSHADINGRATESAMPLEORDERCUSTOMNVPROC) (GLenum rate, GLuint samples, const GLint *locations);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glBindShadingRateImageNV (GLuint texture);
|
||||
GLAPI void APIENTRY glGetShadingRateImagePaletteNV (GLuint viewport, GLuint entry, GLenum *rate);
|
||||
GLAPI void APIENTRY glGetShadingRateSampleLocationivNV (GLenum rate, GLuint samples, GLuint index, GLint *location);
|
||||
GLAPI void APIENTRY glShadingRateImageBarrierNV (GLboolean synchronize);
|
||||
GLAPI void APIENTRY glShadingRateImagePaletteNV (GLuint viewport, GLuint first, GLsizei count, const GLenum *rates);
|
||||
GLAPI void APIENTRY glShadingRateSampleOrderNV (GLenum order);
|
||||
GLAPI void APIENTRY glShadingRateSampleOrderCustomNV (GLenum rate, GLuint samples, const GLint *locations);
|
||||
#endif
|
||||
#endif /* GL_NV_shading_rate_image */
|
||||
|
||||
#ifndef GL_NV_stereo_view_rendering
|
||||
#define GL_NV_stereo_view_rendering 1
|
||||
#endif /* GL_NV_stereo_view_rendering */
|
||||
@@ -11068,7 +11366,7 @@ typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACENVPROC) (const
|
||||
typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTEROUTPUTSURFACENVPROC) (const void *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
|
||||
typedef GLboolean (APIENTRYP PFNGLVDPAUISSURFACENVPROC) (GLvdpauSurfaceNV surface);
|
||||
typedef void (APIENTRYP PFNGLVDPAUUNREGISTERSURFACENVPROC) (GLvdpauSurfaceNV surface);
|
||||
typedef void (APIENTRYP PFNGLVDPAUGETSURFACEIVNVPROC) (GLvdpauSurfaceNV surface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
typedef void (APIENTRYP PFNGLVDPAUGETSURFACEIVNVPROC) (GLvdpauSurfaceNV surface, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
typedef void (APIENTRYP PFNGLVDPAUSURFACEACCESSNVPROC) (GLvdpauSurfaceNV surface, GLenum access);
|
||||
typedef void (APIENTRYP PFNGLVDPAUMAPSURFACESNVPROC) (GLsizei numSurfaces, const GLvdpauSurfaceNV *surfaces);
|
||||
typedef void (APIENTRYP PFNGLVDPAUUNMAPSURFACESNVPROC) (GLsizei numSurface, const GLvdpauSurfaceNV *surfaces);
|
||||
@@ -11079,13 +11377,21 @@ GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceNV (const void *vdpSu
|
||||
GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterOutputSurfaceNV (const void *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
|
||||
GLAPI GLboolean APIENTRY glVDPAUIsSurfaceNV (GLvdpauSurfaceNV surface);
|
||||
GLAPI void APIENTRY glVDPAUUnregisterSurfaceNV (GLvdpauSurfaceNV surface);
|
||||
GLAPI void APIENTRY glVDPAUGetSurfaceivNV (GLvdpauSurfaceNV surface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
|
||||
GLAPI void APIENTRY glVDPAUGetSurfaceivNV (GLvdpauSurfaceNV surface, GLenum pname, GLsizei count, GLsizei *length, GLint *values);
|
||||
GLAPI void APIENTRY glVDPAUSurfaceAccessNV (GLvdpauSurfaceNV surface, GLenum access);
|
||||
GLAPI void APIENTRY glVDPAUMapSurfacesNV (GLsizei numSurfaces, const GLvdpauSurfaceNV *surfaces);
|
||||
GLAPI void APIENTRY glVDPAUUnmapSurfacesNV (GLsizei numSurface, const GLvdpauSurfaceNV *surfaces);
|
||||
#endif
|
||||
#endif /* GL_NV_vdpau_interop */
|
||||
|
||||
#ifndef GL_NV_vdpau_interop2
|
||||
#define GL_NV_vdpau_interop2 1
|
||||
typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACEWITHPICTURESTRUCTURENVPROC) (const void *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames, GLboolean isFrameStructure);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceWithPictureStructureNV (const void *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames, GLboolean isFrameStructure);
|
||||
#endif
|
||||
#endif /* GL_NV_vdpau_interop2 */
|
||||
|
||||
#ifndef GL_NV_vertex_array_range
|
||||
#define GL_NV_vertex_array_range 1
|
||||
#define GL_VERTEX_ARRAY_RANGE_NV 0x851D
|
||||
|
||||
Vendored
+290
@@ -0,0 +1,290 @@
|
||||
#ifndef __khrplatform_h_
|
||||
#define __khrplatform_h_
|
||||
|
||||
/*
|
||||
** Copyright (c) 2008-2018 The Khronos Group Inc.
|
||||
**
|
||||
** Permission is hereby granted, free of charge, to any person obtaining a
|
||||
** copy of this software and/or associated documentation files (the
|
||||
** "Materials"), to deal in the Materials without restriction, including
|
||||
** without limitation the rights to use, copy, modify, merge, publish,
|
||||
** distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
** permit persons to whom the Materials are furnished to do so, subject to
|
||||
** the following conditions:
|
||||
**
|
||||
** The above copyright notice and this permission notice shall be included
|
||||
** in all copies or substantial portions of the Materials.
|
||||
**
|
||||
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
*/
|
||||
|
||||
/* Khronos platform-specific types and definitions.
|
||||
*
|
||||
* The master copy of khrplatform.h is maintained in the Khronos EGL
|
||||
* Registry repository at https://github.com/KhronosGroup/EGL-Registry
|
||||
* The last semantic modification to khrplatform.h was at commit ID:
|
||||
* 67a3e0864c2d75ea5287b9f3d2eb74a745936692
|
||||
*
|
||||
* Adopters may modify this file to suit their platform. Adopters are
|
||||
* encouraged to submit platform specific modifications to the Khronos
|
||||
* group so that they can be included in future versions of this file.
|
||||
* Please submit changes by filing pull requests or issues on
|
||||
* the EGL Registry repository linked above.
|
||||
*
|
||||
*
|
||||
* See the Implementer's Guidelines for information about where this file
|
||||
* should be located on your system and for more details of its use:
|
||||
* http://www.khronos.org/registry/implementers_guide.pdf
|
||||
*
|
||||
* This file should be included as
|
||||
* #include <KHR/khrplatform.h>
|
||||
* by Khronos client API header files that use its types and defines.
|
||||
*
|
||||
* The types in khrplatform.h should only be used to define API-specific types.
|
||||
*
|
||||
* Types defined in khrplatform.h:
|
||||
* khronos_int8_t signed 8 bit
|
||||
* khronos_uint8_t unsigned 8 bit
|
||||
* khronos_int16_t signed 16 bit
|
||||
* khronos_uint16_t unsigned 16 bit
|
||||
* khronos_int32_t signed 32 bit
|
||||
* khronos_uint32_t unsigned 32 bit
|
||||
* khronos_int64_t signed 64 bit
|
||||
* khronos_uint64_t unsigned 64 bit
|
||||
* khronos_intptr_t signed same number of bits as a pointer
|
||||
* khronos_uintptr_t unsigned same number of bits as a pointer
|
||||
* khronos_ssize_t signed size
|
||||
* khronos_usize_t unsigned size
|
||||
* khronos_float_t signed 32 bit floating point
|
||||
* khronos_time_ns_t unsigned 64 bit time in nanoseconds
|
||||
* khronos_utime_nanoseconds_t unsigned time interval or absolute time in
|
||||
* nanoseconds
|
||||
* khronos_stime_nanoseconds_t signed time interval in nanoseconds
|
||||
* khronos_boolean_enum_t enumerated boolean type. This should
|
||||
* only be used as a base type when a client API's boolean type is
|
||||
* an enum. Client APIs which use an integer or other type for
|
||||
* booleans cannot use this as the base type for their boolean.
|
||||
*
|
||||
* Tokens defined in khrplatform.h:
|
||||
*
|
||||
* KHRONOS_FALSE, KHRONOS_TRUE Enumerated boolean false/true values.
|
||||
*
|
||||
* KHRONOS_SUPPORT_INT64 is 1 if 64 bit integers are supported; otherwise 0.
|
||||
* KHRONOS_SUPPORT_FLOAT is 1 if floats are supported; otherwise 0.
|
||||
*
|
||||
* Calling convention macros defined in this file:
|
||||
* KHRONOS_APICALL
|
||||
* KHRONOS_APIENTRY
|
||||
* KHRONOS_APIATTRIBUTES
|
||||
*
|
||||
* These may be used in function prototypes as:
|
||||
*
|
||||
* KHRONOS_APICALL void KHRONOS_APIENTRY funcname(
|
||||
* int arg1,
|
||||
* int arg2) KHRONOS_APIATTRIBUTES;
|
||||
*/
|
||||
|
||||
#if defined(__SCITECH_SNAP__) && !defined(KHRONOS_STATIC)
|
||||
# define KHRONOS_STATIC 1
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
* Definition of KHRONOS_APICALL
|
||||
*-------------------------------------------------------------------------
|
||||
* This precedes the return type of the function in the function prototype.
|
||||
*/
|
||||
#if defined(KHRONOS_STATIC)
|
||||
/* If the preprocessor constant KHRONOS_STATIC is defined, make the
|
||||
* header compatible with static linking. */
|
||||
# define KHRONOS_APICALL
|
||||
#elif defined(_WIN32)
|
||||
# define KHRONOS_APICALL __declspec(dllimport)
|
||||
#elif defined (__SYMBIAN32__)
|
||||
# define KHRONOS_APICALL IMPORT_C
|
||||
#elif defined(__ANDROID__)
|
||||
# define KHRONOS_APICALL __attribute__((visibility("default")))
|
||||
#else
|
||||
# define KHRONOS_APICALL
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
* Definition of KHRONOS_APIENTRY
|
||||
*-------------------------------------------------------------------------
|
||||
* This follows the return type of the function and precedes the function
|
||||
* name in the function prototype.
|
||||
*/
|
||||
#if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(KHRONOS_STATIC)
|
||||
/* Win32 but not WinCE */
|
||||
# define KHRONOS_APIENTRY __stdcall
|
||||
#else
|
||||
# define KHRONOS_APIENTRY
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
* Definition of KHRONOS_APIATTRIBUTES
|
||||
*-------------------------------------------------------------------------
|
||||
* This follows the closing parenthesis of the function prototype arguments.
|
||||
*/
|
||||
#if defined (__ARMCC_2__)
|
||||
#define KHRONOS_APIATTRIBUTES __softfp
|
||||
#else
|
||||
#define KHRONOS_APIATTRIBUTES
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
* basic type definitions
|
||||
*-----------------------------------------------------------------------*/
|
||||
#if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || defined(__GNUC__) || defined(__SCO__) || defined(__USLC__)
|
||||
|
||||
|
||||
/*
|
||||
* Using <stdint.h>
|
||||
*/
|
||||
#include <stdint.h>
|
||||
typedef int32_t khronos_int32_t;
|
||||
typedef uint32_t khronos_uint32_t;
|
||||
typedef int64_t khronos_int64_t;
|
||||
typedef uint64_t khronos_uint64_t;
|
||||
#define KHRONOS_SUPPORT_INT64 1
|
||||
#define KHRONOS_SUPPORT_FLOAT 1
|
||||
|
||||
#elif defined(__VMS ) || defined(__sgi)
|
||||
|
||||
/*
|
||||
* Using <inttypes.h>
|
||||
*/
|
||||
#include <inttypes.h>
|
||||
typedef int32_t khronos_int32_t;
|
||||
typedef uint32_t khronos_uint32_t;
|
||||
typedef int64_t khronos_int64_t;
|
||||
typedef uint64_t khronos_uint64_t;
|
||||
#define KHRONOS_SUPPORT_INT64 1
|
||||
#define KHRONOS_SUPPORT_FLOAT 1
|
||||
|
||||
#elif defined(_WIN32) && !defined(__SCITECH_SNAP__)
|
||||
|
||||
/*
|
||||
* Win32
|
||||
*/
|
||||
typedef __int32 khronos_int32_t;
|
||||
typedef unsigned __int32 khronos_uint32_t;
|
||||
typedef __int64 khronos_int64_t;
|
||||
typedef unsigned __int64 khronos_uint64_t;
|
||||
#define KHRONOS_SUPPORT_INT64 1
|
||||
#define KHRONOS_SUPPORT_FLOAT 1
|
||||
|
||||
#elif defined(__sun__) || defined(__digital__)
|
||||
|
||||
/*
|
||||
* Sun or Digital
|
||||
*/
|
||||
typedef int khronos_int32_t;
|
||||
typedef unsigned int khronos_uint32_t;
|
||||
#if defined(__arch64__) || defined(_LP64)
|
||||
typedef long int khronos_int64_t;
|
||||
typedef unsigned long int khronos_uint64_t;
|
||||
#else
|
||||
typedef long long int khronos_int64_t;
|
||||
typedef unsigned long long int khronos_uint64_t;
|
||||
#endif /* __arch64__ */
|
||||
#define KHRONOS_SUPPORT_INT64 1
|
||||
#define KHRONOS_SUPPORT_FLOAT 1
|
||||
|
||||
#elif 0
|
||||
|
||||
/*
|
||||
* Hypothetical platform with no float or int64 support
|
||||
*/
|
||||
typedef int khronos_int32_t;
|
||||
typedef unsigned int khronos_uint32_t;
|
||||
#define KHRONOS_SUPPORT_INT64 0
|
||||
#define KHRONOS_SUPPORT_FLOAT 0
|
||||
|
||||
#else
|
||||
|
||||
/*
|
||||
* Generic fallback
|
||||
*/
|
||||
#include <stdint.h>
|
||||
typedef int32_t khronos_int32_t;
|
||||
typedef uint32_t khronos_uint32_t;
|
||||
typedef int64_t khronos_int64_t;
|
||||
typedef uint64_t khronos_uint64_t;
|
||||
#define KHRONOS_SUPPORT_INT64 1
|
||||
#define KHRONOS_SUPPORT_FLOAT 1
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* Types that are (so far) the same on all platforms
|
||||
*/
|
||||
typedef signed char khronos_int8_t;
|
||||
typedef unsigned char khronos_uint8_t;
|
||||
typedef signed short int khronos_int16_t;
|
||||
typedef unsigned short int khronos_uint16_t;
|
||||
|
||||
/*
|
||||
* Types that differ between LLP64 and LP64 architectures - in LLP64,
|
||||
* pointers are 64 bits, but 'long' is still 32 bits. Win64 appears
|
||||
* to be the only LLP64 architecture in current use.
|
||||
*/
|
||||
#ifdef _WIN64
|
||||
typedef signed long long int khronos_intptr_t;
|
||||
typedef unsigned long long int khronos_uintptr_t;
|
||||
typedef signed long long int khronos_ssize_t;
|
||||
typedef unsigned long long int khronos_usize_t;
|
||||
#else
|
||||
typedef signed long int khronos_intptr_t;
|
||||
typedef unsigned long int khronos_uintptr_t;
|
||||
typedef signed long int khronos_ssize_t;
|
||||
typedef unsigned long int khronos_usize_t;
|
||||
#endif
|
||||
|
||||
#if KHRONOS_SUPPORT_FLOAT
|
||||
/*
|
||||
* Float type
|
||||
*/
|
||||
typedef float khronos_float_t;
|
||||
#endif
|
||||
|
||||
#if KHRONOS_SUPPORT_INT64
|
||||
/* Time types
|
||||
*
|
||||
* These types can be used to represent a time interval in nanoseconds or
|
||||
* an absolute Unadjusted System Time. Unadjusted System Time is the number
|
||||
* of nanoseconds since some arbitrary system event (e.g. since the last
|
||||
* time the system booted). The Unadjusted System Time is an unsigned
|
||||
* 64 bit value that wraps back to 0 every 584 years. Time intervals
|
||||
* may be either signed or unsigned.
|
||||
*/
|
||||
typedef khronos_uint64_t khronos_utime_nanoseconds_t;
|
||||
typedef khronos_int64_t khronos_stime_nanoseconds_t;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Dummy value used to pad enum types to 32 bits.
|
||||
*/
|
||||
#ifndef KHRONOS_MAX_ENUM
|
||||
#define KHRONOS_MAX_ENUM 0x7FFFFFFF
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Enumerated boolean type
|
||||
*
|
||||
* Values other than zero should be considered to be true. Therefore
|
||||
* comparisons should not be made against KHRONOS_TRUE.
|
||||
*/
|
||||
typedef enum {
|
||||
KHRONOS_FALSE = 0,
|
||||
KHRONOS_TRUE = 1,
|
||||
KHRONOS_BOOLEAN_ENUM_FORCE_SIZE = KHRONOS_MAX_ENUM
|
||||
} khronos_boolean_enum_t;
|
||||
|
||||
#endif /* __khrplatform_h_ */
|
||||
Vendored
+2
-2
@@ -31,9 +31,9 @@ extern "C" {
|
||||
#define ALC_VERSION_0_1 1
|
||||
|
||||
/** Opaque device handle */
|
||||
typedef struct ALCdevice_struct ALCdevice;
|
||||
typedef struct ALCdevice ALCdevice;
|
||||
/** Opaque context handle */
|
||||
typedef struct ALCcontext_struct ALCcontext;
|
||||
typedef struct ALCcontext ALCcontext;
|
||||
|
||||
/** 8-bit boolean */
|
||||
typedef char ALCboolean;
|
||||
|
||||
Vendored
+21
@@ -509,6 +509,27 @@ ALC_API void ALC_APIENTRY alcGetInteger64vSOFT(ALCdevice *device, ALCenum pname,
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef AL_SOFT_direct_channels_remix
|
||||
#define AL_SOFT_direct_channels_remix 1
|
||||
#define AL_DROP_UNMATCHED_SOFT 0x0001
|
||||
#define AL_REMIX_UNMATCHED_SOFT 0x0002
|
||||
#endif
|
||||
|
||||
#ifndef AL_SOFT_bformat_ex
|
||||
#define AL_SOFT_bformat_ex 1
|
||||
#define AL_AMBISONIC_LAYOUT_SOFT 0x1997
|
||||
#define AL_AMBISONIC_SCALING_SOFT 0x1998
|
||||
|
||||
/* Ambisonic layouts */
|
||||
#define AL_FUMA_SOFT 0x0000
|
||||
#define AL_ACN_SOFT 0x0001
|
||||
|
||||
/* Ambisonic scalings (normalization) */
|
||||
/*#define AL_FUMA_SOFT*/
|
||||
#define AL_SN3D_SOFT 0x0001
|
||||
#define AL_N3D_SOFT 0x0002
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Vendored
+1
@@ -1,6 +1,7 @@
|
||||
#ifndef AL_EFX_H
|
||||
#define AL_EFX_H
|
||||
|
||||
#include <float.h>
|
||||
|
||||
#include "alc.h"
|
||||
#include "al.h"
|
||||
|
||||
BIN
Binary file not shown.
+127
-11
@@ -7,11 +7,31 @@
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma once
|
||||
#endif
|
||||
|
||||
#ifndef __XAUDIO2_INCLUDED__
|
||||
#define __XAUDIO2_INCLUDED__
|
||||
|
||||
#include <sdkddkver.h>
|
||||
|
||||
// Current name of the DLL shipped in the same SDK as this header.
|
||||
// The name reflects the current version
|
||||
#define XAUDIO2_DLL_A "xaudio2redist.dll"
|
||||
#define XAUDIO2_DLL_W L"xaudio2redist.dll"
|
||||
#define XAUDIO2D_DLL_A "xaudio2redist.dll"
|
||||
#define XAUDIO2D_DLL_W L"xaudio2redist.dll"
|
||||
|
||||
#ifdef UNICODE
|
||||
#define XAUDIO2_DLL XAUDIO2_DLL_W
|
||||
#define XAUDIO2D_DLL XAUDIO2D_DLL_W
|
||||
#else
|
||||
#define XAUDIO2_DLL XAUDIO2_DLL_A
|
||||
#define XAUDIO2D_DLL XAUDIO2D_DLL_A
|
||||
#endif
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* XAudio2 COM object class and interface IDs.
|
||||
@@ -20,8 +40,19 @@
|
||||
|
||||
#include <basetyps.h>
|
||||
|
||||
// XAudio 2.8
|
||||
interface __declspec(uuid("60d8dac8-5aa1-4e8e-b597-2f5e2883d484")) IXAudio2;
|
||||
#ifdef __cplusplus
|
||||
// XAudio 2.9
|
||||
interface __declspec(uuid("2B02E3CF-2E0B-4ec3-BE45-1B2A3FE7210D")) IXAudio2;
|
||||
interface __declspec(uuid("84ac29bb-d619-44d2-b197-e4acf7df3ed6")) IXAudio2Extension;
|
||||
EXTERN_C const GUID DECLSPEC_SELECTANY IID_IXAudio2Extension = __uuidof(IXAudio2Extension);
|
||||
EXTERN_C const GUID DECLSPEC_SELECTANY IID_IXAudio2 = __uuidof(IXAudio2);
|
||||
|
||||
#else // #ifdef __cplusplus
|
||||
// Compiling with C for Windows 10 and later
|
||||
DEFINE_GUID(IID_IXAudio2, 0x2B02E3CF, 0x2E0B, 0x4ec3, 0xBE, 0x45, 0x1B, 0x2A, 0x3F, 0xE7, 0x21, 0x0D);
|
||||
DEFINE_GUID(IID_IXAudio2Extension, 0x84ac29bb, 0xd619, 0x44d2, 0xb1, 0x97, 0xe4, 0xac, 0xf7, 0xdf, 0x3e, 0xd6);
|
||||
#endif // #ifdef __cplusplus
|
||||
|
||||
|
||||
// Ignore the rest of this header if only the GUID definitions were requested
|
||||
#ifndef GUID_DEFS_ONLY
|
||||
@@ -31,6 +62,31 @@ interface __declspec(uuid("60d8dac8-5aa1-4e8e-b597-2f5e2883d484")) IXAudio2;
|
||||
#include <mmreg.h> // Basic data types and constants for audio work
|
||||
#include <audiosessiontypes.h> // For AUDIO_STREAM_CATEGORY
|
||||
|
||||
// The Windows 7 version of audiosessiontypes.h does not define AUDIO_STREAM_CATEGORY, so if we are targeting
|
||||
// Windows 7 we might have to define it here, depending on which SDK is used.
|
||||
#if _WIN32_WINNT < _WIN32_WINNT_WIN8
|
||||
|
||||
// If we are compiling for Windows 7, we might be using the Windows 7 Platform SDK, which does not have AUDIO_STREAM_CATEGORY.
|
||||
// But we might be using a newer SDK (such as the Win8 Platform SDK), which has AUDIO_STREAM_CATEGORY.
|
||||
// Determine if we are using the Windows 7 Platform SDK by checking if WAVE_FORMAT_WM9_SPECTRUM_ANALYZER is defined.
|
||||
#ifndef WAVE_FORMAT_WM9_SPECTRUM_ANALYZER
|
||||
typedef enum _AUDIO_STREAM_CATEGORY
|
||||
{
|
||||
AudioCategory_Other = 0,
|
||||
AudioCategory_ForegroundOnlyMedia = 1,
|
||||
AudioCategory_Communications = 3,
|
||||
AudioCategory_Alerts = 4,
|
||||
AudioCategory_SoundEffects = 5,
|
||||
AudioCategory_GameEffects = 6,
|
||||
AudioCategory_GameMedia = 7,
|
||||
AudioCategory_GameChat = 8,
|
||||
AudioCategory_Speech = 9,
|
||||
AudioCategory_Movie = 10,
|
||||
AudioCategory_Media = 11,
|
||||
} AUDIO_STREAM_CATEGORY;
|
||||
#endif /* WAVE_FORMAT_WM9_SPECTRUM_ANALYZER */
|
||||
#endif /* NTDDI_VERSION < NTDDI_WIN8 */
|
||||
|
||||
// All structures defined in this file use tight field packing
|
||||
#pragma pack(push, 1)
|
||||
|
||||
@@ -83,7 +139,7 @@ interface __declspec(uuid("60d8dac8-5aa1-4e8e-b597-2f5e2883d484")) IXAudio2;
|
||||
#define XAUDIO2_VOICE_NOSAMPLESPLAYED 0x0100 // Used in IXAudio2SourceVoice::GetState
|
||||
#define XAUDIO2_STOP_ENGINE_WHEN_IDLE 0x2000 // Used in XAudio2Create to force the engine to Stop when no source voices are Started, and Start when a voice is Started
|
||||
#define XAUDIO2_1024_QUANTUM 0x8000 // Used in XAudio2Create to specify nondefault processing quantum of 21.33 ms (1024 samples at 48KHz)
|
||||
#define XAUDIO2_NO_VIRTUAL_AUDIO_CLIENT 0x10000 // Used in CreateMasteringVoice to create a virtual audio client
|
||||
#define XAUDIO2_NO_VIRTUAL_AUDIO_CLIENT 0x10000 // Used in CreateMasteringVoice to create a virtual audio client
|
||||
|
||||
// Default parameters for the built-in filter
|
||||
#define XAUDIO2_DEFAULT_FILTER_TYPE LowPassFilter
|
||||
@@ -99,10 +155,10 @@ interface __declspec(uuid("60d8dac8-5aa1-4e8e-b597-2f5e2883d484")) IXAudio2;
|
||||
|
||||
// XAudio2 error codes
|
||||
#define FACILITY_XAUDIO2 0x896
|
||||
#define XAUDIO2_E_INVALID_CALL 0x88960001 // An API call or one of its arguments was illegal
|
||||
#define XAUDIO2_E_XMA_DECODER_ERROR 0x88960002 // The XMA hardware suffered an unrecoverable error
|
||||
#define XAUDIO2_E_XAPO_CREATION_FAILED 0x88960003 // XAudio2 failed to initialize an XAPO effect
|
||||
#define XAUDIO2_E_DEVICE_INVALIDATED 0x88960004 // An audio device became unusable (unplugged, etc)
|
||||
#define XAUDIO2_E_INVALID_CALL ((HRESULT)0x88960001) // An API call or one of its arguments was illegal
|
||||
#define XAUDIO2_E_XMA_DECODER_ERROR ((HRESULT)0x88960002) // The XMA hardware suffered an unrecoverable error
|
||||
#define XAUDIO2_E_XAPO_CREATION_FAILED ((HRESULT)0x88960003) // XAudio2 failed to initialize an XAPO effect
|
||||
#define XAUDIO2_E_DEVICE_INVALIDATED ((HRESULT)0x88960004) // An audio device became unusable (unplugged, etc)
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
@@ -166,6 +222,13 @@ typedef UINT32 XAUDIO2_PROCESSOR;
|
||||
#define Processor31 0x40000000
|
||||
#define Processor32 0x80000000
|
||||
#define XAUDIO2_ANY_PROCESSOR 0xffffffff
|
||||
|
||||
// This value indicates that XAudio2 will choose the default processor by itself. The actual value chosen
|
||||
// may vary depending on the hardware platform.
|
||||
#define XAUDIO2_USE_DEFAULT_PROCESSOR 0x00000000
|
||||
|
||||
// This definition is included for backwards compatibilty. New implementations should use
|
||||
// XAUDIO2_USE_DEFAULT_PROCESSOR instead to let XAudio2 select the appropriate default processor for the hardware platform.
|
||||
#define XAUDIO2_DEFAULT_PROCESSOR Processor1
|
||||
|
||||
// Returned by IXAudio2Voice::GetVoiceDetails
|
||||
@@ -359,13 +422,13 @@ DECLARE_INTERFACE_(IXAudio2, IUnknown)
|
||||
{
|
||||
// NAME: IXAudio2::QueryInterface
|
||||
// DESCRIPTION: Queries for a given COM interface on the XAudio2 object.
|
||||
// Only IID_IUnknown and IID_IXAudio2 are supported.
|
||||
// Only IID_IUnknown, IID_IXAudio2 and IID_IXaudio2Extension are supported.
|
||||
//
|
||||
// ARGUMENTS:
|
||||
// riid - IID of the interface to be obtained.
|
||||
// ppvInterface - Returns a pointer to the requested interface.
|
||||
//
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, _Outptr_ void** ppvInterface) PURE;
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, _COM_Outptr_ void** ppvInterface) PURE;
|
||||
|
||||
// NAME: IXAudio2::AddRef
|
||||
// DESCRIPTION: Adds a reference to the XAudio2 object.
|
||||
@@ -489,6 +552,50 @@ DECLARE_INTERFACE_(IXAudio2, IUnknown)
|
||||
_Reserved_ void* pReserved X2DEFAULT(NULL)) PURE;
|
||||
};
|
||||
|
||||
// This interface extends IXAudio2 with additional functionality.
|
||||
// Use IXAudio2::QueryInterface to obtain a pointer to this interface.
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IXAudio2Extension
|
||||
DECLARE_INTERFACE_(IXAudio2Extension, IUnknown)
|
||||
{
|
||||
// NAME: IXAudio2Extension::QueryInterface
|
||||
// DESCRIPTION: Queries for a given COM interface on the XAudio2 object.
|
||||
// Only IID_IUnknown, IID_IXAudio2 and IID_IXaudio2Extension are supported.
|
||||
//
|
||||
// ARGUMENTS:
|
||||
// riid - IID of the interface to be obtained.
|
||||
// ppvInterface - Returns a pointer to the requested interface.
|
||||
//
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, _COM_Outptr_ void** ppvInterface) PURE;
|
||||
|
||||
// NAME: IXAudio2Extension::AddRef
|
||||
// DESCRIPTION: Adds a reference to the XAudio2 object.
|
||||
//
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
|
||||
// NAME: IXAudio2Extension::Release
|
||||
// DESCRIPTION: Releases a reference to the XAudio2 object.
|
||||
//
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
|
||||
// NAME: IXAudio2Extension::GetProcessingQuantum
|
||||
// DESCRIPTION: Returns the processing quantum
|
||||
// quantumMilliseconds = (1000.0f * quantumNumerator / quantumDenominator)
|
||||
//
|
||||
// ARGUMENTS:
|
||||
// quantumNumerator - Quantum numerator
|
||||
// quantumDenominator - Quantum denominator
|
||||
//
|
||||
STDMETHOD_(void, GetProcessingQuantum)(THIS_ _Out_ UINT32* quantumNumerator, _Out_range_(!= , 0) UINT32* quantumDenominator);
|
||||
|
||||
// NAME: IXAudio2Extension::GetProcessor
|
||||
// DESCRIPTION: Returns the number of the processor used by XAudio2
|
||||
//
|
||||
// ARGUMENTS:
|
||||
// processor - Non-zero Processor number
|
||||
//
|
||||
STDMETHOD_(void, GetProcessor)(THIS_ _Out_range_(!= , 0) XAUDIO2_PROCESSOR* processor);
|
||||
};
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
@@ -949,6 +1056,10 @@ DECLARE_INTERFACE(IXAudio2VoiceCallback)
|
||||
#define IXAudio2_GetPerformanceData(This,pPerfData) ((This)->lpVtbl->GetPerformanceData(This,pPerfData))
|
||||
#define IXAudio2_SetDebugConfiguration(This,pDebugConfiguration,pReserved) ((This)->lpVtbl->SetDebugConfiguration(This,pDebugConfiguration,pReserved))
|
||||
|
||||
// IXAudio2Extension
|
||||
#define IXAudio2Extension_GetProcessingQuantum(This,quantumNumerator,quantumDenominator) ((This)->lpVtbl->GetProcessingQuantum(This,quantumNumerator,quantumDenominator))
|
||||
#define IXAudio2Extension_GetProcessor(This,processor) ((This)->lpVtbl->GetProcessor(This,processor))
|
||||
|
||||
// IXAudio2Voice
|
||||
#define IXAudio2Voice_GetVoiceDetails(This,pVoiceDetails) ((This)->lpVtbl->GetVoiceDetails(This,pVoiceDetails))
|
||||
#define IXAudio2Voice_SetOutputVoices(This,pSendList) ((This)->lpVtbl->SetOutputVoices(This,pSendList))
|
||||
@@ -1143,12 +1254,16 @@ __inline float XAudio2CutoffFrequencyToOnePoleCoefficient(float CutoffFrequency,
|
||||
* will use. Note that XAudio2 supports concurrent processing on
|
||||
* multiple threads, using any combination of XAUDIO2_PROCESSOR
|
||||
* flags. The values are platform-specific; platform-independent
|
||||
* code can use XAUDIO2_DEFAULT_PROCESSOR to use the default on
|
||||
* code can use XAUDIO2_USE_DEFAULT_PROCESSOR to use the default on
|
||||
* each platform.
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
typedef HRESULT(*XAudio2Create)(_Outptr_ IXAudio2** ppXAudio2, UINT32 Flags, XAUDIO2_PROCESSOR XAudio2Processor);
|
||||
// We're an xaudio2 client
|
||||
#define XAUDIO2_STDAPI EXTERN_C DECLSPEC_IMPORT HRESULT STDAPICALLTYPE
|
||||
|
||||
XAUDIO2_STDAPI XAudio2Create(_Outptr_ IXAudio2** ppXAudio2, UINT32 Flags X2DEFAULT(0),
|
||||
XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_USE_DEFAULT_PROCESSOR));
|
||||
|
||||
// Undo the #pragma pack(push, 1) directive at the top of this file
|
||||
#pragma pack(pop)
|
||||
@@ -1156,3 +1271,4 @@ typedef HRESULT(*XAudio2Create)(_Outptr_ IXAudio2** ppXAudio2, UINT32 Flags, XAU
|
||||
#endif // #ifndef GUID_DEFS_ONLY
|
||||
|
||||
#endif // #ifndef __XAUDIO2_INCLUDED__
|
||||
|
||||
BIN
Binary file not shown.
Vendored
-1295
File diff suppressed because it is too large
Load Diff
Vendored
-263
@@ -1,263 +0,0 @@
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
*
|
||||
* File: audiodefs.h
|
||||
* Content: Basic constants and data types for audio work.
|
||||
*
|
||||
* Remarks: This header file defines all of the audio format constants and
|
||||
* structures required for XAudio2 and XACT work. Providing these
|
||||
* in a single location avoids certain dependency problems in the
|
||||
* legacy audio headers (mmreg.h, mmsystem.h, ksmedia.h).
|
||||
*
|
||||
* NOTE: Including the legacy headers after this one may cause a
|
||||
* compilation error, because they define some of the same types
|
||||
* defined here without preprocessor guards to avoid multiple
|
||||
* definitions. If a source file needs one of the old headers,
|
||||
* it must include it before including audiodefs.h.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __AUDIODEFS_INCLUDED__
|
||||
#define __AUDIODEFS_INCLUDED__
|
||||
|
||||
#include <windef.h> // For WORD, DWORD, etc.
|
||||
|
||||
#pragma pack(push, 1) // Pack structures to 1-byte boundaries
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* WAVEFORMATEX: Base structure for many audio formats. Format-specific
|
||||
* extensions can be defined for particular formats by using a non-zero
|
||||
* cbSize value and adding extra fields to the end of this structure.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _WAVEFORMATEX_
|
||||
|
||||
#define _WAVEFORMATEX_
|
||||
typedef struct tWAVEFORMATEX
|
||||
{
|
||||
WORD wFormatTag; // Integer identifier of the format
|
||||
WORD nChannels; // Number of audio channels
|
||||
DWORD nSamplesPerSec; // Audio sample rate
|
||||
DWORD nAvgBytesPerSec; // Bytes per second (possibly approximate)
|
||||
WORD nBlockAlign; // Size in bytes of a sample block (all channels)
|
||||
WORD wBitsPerSample; // Size in bits of a single per-channel sample
|
||||
WORD cbSize; // Bytes of extra data appended to this struct
|
||||
} WAVEFORMATEX;
|
||||
|
||||
#endif
|
||||
|
||||
// Defining pointer types outside of the #if block to make sure they are
|
||||
// defined even if mmreg.h or mmsystem.h is #included before this file
|
||||
|
||||
typedef WAVEFORMATEX *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX;
|
||||
typedef const WAVEFORMATEX *PCWAVEFORMATEX, *LPCWAVEFORMATEX;
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* WAVEFORMATEXTENSIBLE: Extended version of WAVEFORMATEX that should be
|
||||
* used as a basis for all new audio formats. The format tag is replaced
|
||||
* with a GUID, allowing new formats to be defined without registering a
|
||||
* format tag with Microsoft. There are also new fields that can be used
|
||||
* to specify the spatial positions for each channel and the bit packing
|
||||
* used for wide samples (e.g. 24-bit PCM samples in 32-bit containers).
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _WAVEFORMATEXTENSIBLE_
|
||||
|
||||
#define _WAVEFORMATEXTENSIBLE_
|
||||
typedef struct
|
||||
{
|
||||
WAVEFORMATEX Format; // Base WAVEFORMATEX data
|
||||
union
|
||||
{
|
||||
WORD wValidBitsPerSample; // Valid bits in each sample container
|
||||
WORD wSamplesPerBlock; // Samples per block of audio data; valid
|
||||
// if wBitsPerSample=0 (but rarely used).
|
||||
WORD wReserved; // Zero if neither case above applies.
|
||||
} Samples;
|
||||
DWORD dwChannelMask; // Positions of the audio channels
|
||||
GUID SubFormat; // Format identifier GUID
|
||||
} WAVEFORMATEXTENSIBLE;
|
||||
|
||||
#endif
|
||||
|
||||
typedef WAVEFORMATEXTENSIBLE *PWAVEFORMATEXTENSIBLE, *LPWAVEFORMATEXTENSIBLE;
|
||||
typedef const WAVEFORMATEXTENSIBLE *PCWAVEFORMATEXTENSIBLE, *LPCWAVEFORMATEXTENSIBLE;
|
||||
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* Define the most common wave format tags used in WAVEFORMATEX formats.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef WAVE_FORMAT_PCM // Pulse Code Modulation
|
||||
|
||||
// If WAVE_FORMAT_PCM is not defined, we need to define some legacy types
|
||||
// for compatibility with the Windows mmreg.h / mmsystem.h header files.
|
||||
|
||||
// Old general format structure (information common to all formats)
|
||||
typedef struct waveformat_tag
|
||||
{
|
||||
WORD wFormatTag;
|
||||
WORD nChannels;
|
||||
DWORD nSamplesPerSec;
|
||||
DWORD nAvgBytesPerSec;
|
||||
WORD nBlockAlign;
|
||||
} WAVEFORMAT, *PWAVEFORMAT, NEAR *NPWAVEFORMAT, FAR *LPWAVEFORMAT;
|
||||
|
||||
// Specific format structure for PCM data
|
||||
typedef struct pcmwaveformat_tag
|
||||
{
|
||||
WAVEFORMAT wf;
|
||||
WORD wBitsPerSample;
|
||||
} PCMWAVEFORMAT, *PPCMWAVEFORMAT, NEAR *NPPCMWAVEFORMAT, FAR *LPPCMWAVEFORMAT;
|
||||
|
||||
#define WAVE_FORMAT_PCM 0x0001
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_ADPCM // Microsoft Adaptive Differental PCM
|
||||
|
||||
// Replicate the Microsoft ADPCM type definitions from mmreg.h.
|
||||
|
||||
typedef struct adpcmcoef_tag
|
||||
{
|
||||
short iCoef1;
|
||||
short iCoef2;
|
||||
} ADPCMCOEFSET;
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4200) // Disable zero-sized array warnings
|
||||
|
||||
typedef struct adpcmwaveformat_tag {
|
||||
WAVEFORMATEX wfx;
|
||||
WORD wSamplesPerBlock;
|
||||
WORD wNumCoef;
|
||||
ADPCMCOEFSET aCoef[]; // Always 7 coefficient pairs for MS ADPCM
|
||||
} ADPCMWAVEFORMAT;
|
||||
|
||||
#pragma warning(pop)
|
||||
|
||||
#define WAVE_FORMAT_ADPCM 0x0002
|
||||
|
||||
#endif
|
||||
|
||||
// Other frequently used format tags
|
||||
|
||||
#ifndef WAVE_FORMAT_UNKNOWN
|
||||
#define WAVE_FORMAT_UNKNOWN 0x0000 // Unknown or invalid format tag
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_IEEE_FLOAT
|
||||
#define WAVE_FORMAT_IEEE_FLOAT 0x0003 // 32-bit floating-point
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_MPEGLAYER3
|
||||
#define WAVE_FORMAT_MPEGLAYER3 0x0055 // ISO/MPEG Layer3
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_DOLBY_AC3_SPDIF
|
||||
#define WAVE_FORMAT_DOLBY_AC3_SPDIF 0x0092 // Dolby Audio Codec 3 over S/PDIF
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_WMAUDIO2
|
||||
#define WAVE_FORMAT_WMAUDIO2 0x0161 // Windows Media Audio
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_WMAUDIO3
|
||||
#define WAVE_FORMAT_WMAUDIO3 0x0162 // Windows Media Audio Pro
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_WMASPDIF
|
||||
#define WAVE_FORMAT_WMASPDIF 0x0164 // Windows Media Audio over S/PDIF
|
||||
#endif
|
||||
|
||||
#ifndef WAVE_FORMAT_EXTENSIBLE
|
||||
#define WAVE_FORMAT_EXTENSIBLE 0xFFFE // All WAVEFORMATEXTENSIBLE formats
|
||||
#endif
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* Define the most common wave format GUIDs used in WAVEFORMATEXTENSIBLE
|
||||
* formats. Note that including the Windows ksmedia.h header after this
|
||||
* one will cause build problems; this cannot be avoided, since ksmedia.h
|
||||
* defines these macros without preprocessor guards.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifdef __cplusplus // uuid() and __uuidof() are only available in C++
|
||||
|
||||
#ifndef KSDATAFORMAT_SUBTYPE_PCM
|
||||
struct __declspec(uuid("00000001-0000-0010-8000-00aa00389b71")) KSDATAFORMAT_SUBTYPE_PCM_STRUCT;
|
||||
#define KSDATAFORMAT_SUBTYPE_PCM __uuidof(KSDATAFORMAT_SUBTYPE_PCM_STRUCT)
|
||||
#endif
|
||||
|
||||
#ifndef KSDATAFORMAT_SUBTYPE_ADPCM
|
||||
struct __declspec(uuid("00000002-0000-0010-8000-00aa00389b71")) KSDATAFORMAT_SUBTYPE_ADPCM_STRUCT;
|
||||
#define KSDATAFORMAT_SUBTYPE_ADPCM __uuidof(KSDATAFORMAT_SUBTYPE_ADPCM_STRUCT)
|
||||
#endif
|
||||
|
||||
#ifndef KSDATAFORMAT_SUBTYPE_IEEE_FLOAT
|
||||
struct __declspec(uuid("00000003-0000-0010-8000-00aa00389b71")) KSDATAFORMAT_SUBTYPE_IEEE_FLOAT_STRUCT;
|
||||
#define KSDATAFORMAT_SUBTYPE_IEEE_FLOAT __uuidof(KSDATAFORMAT_SUBTYPE_IEEE_FLOAT_STRUCT)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
* Speaker positions used in the WAVEFORMATEXTENSIBLE dwChannelMask field.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef SPEAKER_FRONT_LEFT
|
||||
#define SPEAKER_FRONT_LEFT 0x00000001
|
||||
#define SPEAKER_FRONT_RIGHT 0x00000002
|
||||
#define SPEAKER_FRONT_CENTER 0x00000004
|
||||
#define SPEAKER_LOW_FREQUENCY 0x00000008
|
||||
#define SPEAKER_BACK_LEFT 0x00000010
|
||||
#define SPEAKER_BACK_RIGHT 0x00000020
|
||||
#define SPEAKER_FRONT_LEFT_OF_CENTER 0x00000040
|
||||
#define SPEAKER_FRONT_RIGHT_OF_CENTER 0x00000080
|
||||
#define SPEAKER_BACK_CENTER 0x00000100
|
||||
#define SPEAKER_SIDE_LEFT 0x00000200
|
||||
#define SPEAKER_SIDE_RIGHT 0x00000400
|
||||
#define SPEAKER_TOP_CENTER 0x00000800
|
||||
#define SPEAKER_TOP_FRONT_LEFT 0x00001000
|
||||
#define SPEAKER_TOP_FRONT_CENTER 0x00002000
|
||||
#define SPEAKER_TOP_FRONT_RIGHT 0x00004000
|
||||
#define SPEAKER_TOP_BACK_LEFT 0x00008000
|
||||
#define SPEAKER_TOP_BACK_CENTER 0x00010000
|
||||
#define SPEAKER_TOP_BACK_RIGHT 0x00020000
|
||||
#define SPEAKER_RESERVED 0x7FFC0000
|
||||
#define SPEAKER_ALL 0x80000000
|
||||
#define _SPEAKER_POSITIONS_
|
||||
#endif
|
||||
|
||||
#ifndef SPEAKER_STEREO
|
||||
#define SPEAKER_MONO (SPEAKER_FRONT_CENTER)
|
||||
#define SPEAKER_STEREO (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT)
|
||||
#define SPEAKER_2POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_LOW_FREQUENCY)
|
||||
#define SPEAKER_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_BACK_CENTER)
|
||||
#define SPEAKER_QUAD (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT)
|
||||
#define SPEAKER_4POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_LOW_FREQUENCY | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT)
|
||||
#define SPEAKER_5POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT)
|
||||
#define SPEAKER_7POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT | SPEAKER_FRONT_LEFT_OF_CENTER | SPEAKER_FRONT_RIGHT_OF_CENTER)
|
||||
#define SPEAKER_5POINT1_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | SPEAKER_SIDE_LEFT | SPEAKER_SIDE_RIGHT)
|
||||
#define SPEAKER_7POINT1_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT | SPEAKER_SIDE_LEFT | SPEAKER_SIDE_RIGHT)
|
||||
#endif
|
||||
|
||||
|
||||
#pragma pack(pop)
|
||||
|
||||
#endif // #ifndef __AUDIODEFS_INCLUDED__
|
||||
Vendored
-65
@@ -1,65 +0,0 @@
|
||||
// comdecl.h: Macros to facilitate COM interface and GUID declarations.
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
#ifndef _COMDECL_H_
|
||||
#define _COMDECL_H_
|
||||
|
||||
#ifndef _XBOX
|
||||
#include <basetyps.h> // For standard COM interface macros
|
||||
#else
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4061)
|
||||
#include <xtl.h> // Required by xobjbase.h
|
||||
#include <xobjbase.h> // Special definitions for Xbox build
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
// The DEFINE_CLSID() and DEFINE_IID() macros defined below allow COM GUIDs to
|
||||
// be declared and defined in such a way that clients can obtain the GUIDs using
|
||||
// either the __uuidof() extension or the old-style CLSID_Foo / IID_IFoo names.
|
||||
// If using the latter approach, the client can also choose whether to get the
|
||||
// GUID definitions by defining the INITGUID preprocessor constant or by linking
|
||||
// to a GUID library. This works in either C or C++.
|
||||
|
||||
#ifndef _MSC_VER
|
||||
|
||||
#define DEFINE_UUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) __CRT_UUID_DECL(name, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8)
|
||||
#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) class className; DEFINE_UUID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)
|
||||
#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) struct interfaceName; DEFINE_UUID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)
|
||||
|
||||
#elif __cplusplus
|
||||
|
||||
#define DECLSPEC_UUID_WRAPPER(x) __declspec(uuid(#x))
|
||||
#ifdef INITGUID
|
||||
|
||||
#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
class DECLSPEC_UUID_WRAPPER(l##-##w1##-##w2##-##b1##b2##-##b3##b4##b5##b6##b7##b8) className; \
|
||||
EXTERN_C const GUID DECLSPEC_SELECTANY CLSID_##className = __uuidof(className)
|
||||
|
||||
#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
interface DECLSPEC_UUID_WRAPPER(l##-##w1##-##w2##-##b1##b2##-##b3##b4##b5##b6##b7##b8) interfaceName; \
|
||||
EXTERN_C const GUID DECLSPEC_SELECTANY IID_##interfaceName = __uuidof(interfaceName)
|
||||
|
||||
#else // INITGUID
|
||||
|
||||
#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
class DECLSPEC_UUID_WRAPPER(l##-##w1##-##w2##-##b1##b2##-##b3##b4##b5##b6##b7##b8) className; \
|
||||
EXTERN_C const GUID CLSID_##className
|
||||
|
||||
#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
interface DECLSPEC_UUID_WRAPPER(l##-##w1##-##w2##-##b1##b2##-##b3##b4##b5##b6##b7##b8) interfaceName; \
|
||||
EXTERN_C const GUID IID_##interfaceName
|
||||
|
||||
#endif // INITGUID
|
||||
|
||||
#else // __cplusplus
|
||||
|
||||
#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
DEFINE_GUID(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8)
|
||||
|
||||
#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
|
||||
DEFINE_GUID(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8)
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#endif // #ifndef _COMDECL_H_
|
||||
Vendored
-18
@@ -1,18 +0,0 @@
|
||||
/*==========================================================================;
|
||||
*
|
||||
*
|
||||
* File: dxsdkver.h
|
||||
* Content: DirectX SDK Version Include File
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef _DXSDKVER_H_
|
||||
#define _DXSDKVER_H_
|
||||
|
||||
#define _DXSDK_PRODUCT_MAJOR 9
|
||||
#define _DXSDK_PRODUCT_MINOR 29
|
||||
#define _DXSDK_BUILD_MAJOR 1962
|
||||
#define _DXSDK_BUILD_MINOR 0
|
||||
|
||||
#endif // _DXSDKVER_H_
|
||||
|
||||
Vendored
-718
@@ -1,718 +0,0 @@
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
*
|
||||
* File: xma2defs.h
|
||||
* Content: Constants, data types and functions for XMA2 compressed audio.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __XMA2DEFS_INCLUDED__
|
||||
#define __XMA2DEFS_INCLUDED__
|
||||
|
||||
#include <sal.h> // Markers for documenting API semantics
|
||||
#include <winerror.h> // For S_OK, E_FAIL
|
||||
#include <audiodefs.h> // Basic data types and constants for audio work
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* Overview
|
||||
***************************************************************************/
|
||||
|
||||
// A typical XMA2 file contains these RIFF chunks:
|
||||
//
|
||||
// 'fmt' or 'XMA2' chunk (or both): A description of the XMA data's structure
|
||||
// and characteristics (length, channels, sample rate, loops, block size, etc).
|
||||
//
|
||||
// 'seek' chunk: A seek table to help navigate the XMA data.
|
||||
//
|
||||
// 'data' chunk: The encoded XMA2 data.
|
||||
//
|
||||
// The encoded XMA2 data is structured as a set of BLOCKS, which contain PACKETS,
|
||||
// which contain FRAMES, which contain SUBFRAMES (roughly speaking). The frames
|
||||
// in a file may also be divided into several subsets, called STREAMS.
|
||||
//
|
||||
// FRAME: A variable-sized segment of XMA data that decodes to exactly 512 mono
|
||||
// or stereo PCM samples. This is the smallest unit of XMA data that can
|
||||
// be decoded in isolation. Frames are an arbitrary number of bits in
|
||||
// length, and need not be byte-aligned. See "XMA frame structure" below.
|
||||
//
|
||||
// SUBFRAME: A region of bits in an XMA frame that decodes to 128 mono or stereo
|
||||
// samples. The XMA decoder cannot decode a subframe in isolation; it needs
|
||||
// a whole frame to work with. However, it can begin emitting the frame's
|
||||
// decoded samples at any one of the four subframe boundaries. Subframes
|
||||
// can be addressed for seeking and looping purposes.
|
||||
//
|
||||
// PACKET: A 2Kb region containing a 32-bit header and some XMA frames. Frames
|
||||
// can (and usually do) span packets. A packet's header includes the offset
|
||||
// in bits of the first frame that begins within that packet. All of the
|
||||
// frames that begin in a given packet belong to the same "stream" (see the
|
||||
// Multichannel Audio section below).
|
||||
//
|
||||
// STREAM: A set of packets within an XMA file that all contain data for the
|
||||
// same mono or stereo component of a PCM file with more than two channels.
|
||||
// The packets comprising a given stream may be interleaved with each other
|
||||
// more or less arbitrarily; see Multichannel Audio.
|
||||
//
|
||||
// BLOCK: An array of XMA packets; or, to break it down differently, a series of
|
||||
// consecutive XMA frames, padded at the end with reserved data. A block
|
||||
// must contain at least one 2Kb packet per stream, and it can hold up to
|
||||
// 4095 packets (8190Kb), but its size is typically in the 32Kb-128Kb range.
|
||||
// (The size chosen involves a trade-off between memory use and efficiency
|
||||
// of reading from permanent storage.)
|
||||
//
|
||||
// XMA frames do not span blocks, so a block is guaranteed to begin with a
|
||||
// set of complete frames, one per stream. Also, a block in a multi-stream
|
||||
// XMA2 file always contains the same number of samples for each stream;
|
||||
// see Multichannel Audio.
|
||||
//
|
||||
// The 'data' chunk in an XMA2 file is an array of XMA2WAVEFORMAT.BlockCount XMA
|
||||
// blocks, all the same size (as specified in XMA2WAVEFORMAT.BlockSizeInBytes)
|
||||
// except for the last one, which may be shorter.
|
||||
|
||||
|
||||
// MULTICHANNEL AUDIO: the XMA decoder can only decode raw XMA data into either
|
||||
// mono or stereo PCM data. In order to encode a 6-channel file (say), the file
|
||||
// must be deinterleaved into 3 stereo streams that are encoded independently,
|
||||
// producing 3 encoded XMA data streams. Then the packets in these 3 streams
|
||||
// are interleaved to produce a single XMA2 file, and some information is added
|
||||
// to the file so that the original 6-channel audio can be reconstructed at
|
||||
// decode time. This works using the concept of an XMA stream (see above).
|
||||
//
|
||||
// The frames for all the streams in an XMA file are interleaved in an arbitrary
|
||||
// order. To locate a frame that belongs to a given stream in a given XMA block,
|
||||
// you must examine the first few packets in the block. Here (and only here) the
|
||||
// packets are guaranteed to be presented in stream order, so that all frames
|
||||
// beginning in packet 0 belong to stream 0 (the first stereo pair), etc.
|
||||
//
|
||||
// (This means that when decoding multi-stream XMA files, only entire XMA blocks
|
||||
// should be submitted to the decoder; otherwise it cannot know which frames
|
||||
// belong to which stream.)
|
||||
//
|
||||
// Once you have one frame that belongs to a given stream, you can find the next
|
||||
// one by looking at the frame's 'NextFrameOffsetBits' value (which is stored in
|
||||
// its first 15 bits; see XMAFRAME below). The GetXmaFrameBitPosition function
|
||||
// uses this technique.
|
||||
|
||||
|
||||
// SEEKING IN XMA2 FILES: Here is some pseudocode to find the byte position and
|
||||
// subframe in an XMA2 file which will contain sample S when decoded.
|
||||
//
|
||||
// 1. Traverse the seek table to find the XMA2 block containing sample S. The
|
||||
// seek table is an array of big-endian DWORDs, one per block in the file.
|
||||
// The Nth DWORD is the total number of PCM samples that would be obtained
|
||||
// by decoding the entire XMA file up to the end of block N. Hence, the
|
||||
// block we want is the first one whose seek table entry is greater than S.
|
||||
// (See the GetXmaBlockContainingSample helper function.)
|
||||
//
|
||||
// 2. Calculate which frame F within the block found above contains sample S.
|
||||
// Since each frame decodes to 512 samples, this is straightforward. The
|
||||
// first frame in the block produces samples X to X + 512, where X is the
|
||||
// seek table entry for the prior block. So F is (S - X) / 512.
|
||||
//
|
||||
// 3. Find the bit offset within the block where frame F starts. Since frames
|
||||
// are variable-sized, this can only be done by traversing all the frames in
|
||||
// the block until we reach frame F. (See GetXmaFrameBitPosition.)
|
||||
//
|
||||
// 4. Frame F has four 128-sample subframes. To find the subframe containing S,
|
||||
// we can use the formula (S % 512) / 128.
|
||||
//
|
||||
// In the case of multi-stream XMA files, sample S is a multichannel sample with
|
||||
// parts coming from several frames, one per stream. To find all these frames,
|
||||
// steps 2-4 need to be repeated for each stream N, using the knowledge that the
|
||||
// first packets in a block are presented in stream order. The frame traversal
|
||||
// in step 3 must be started at the first frame in the Nth packet of the block,
|
||||
// which will be the first frame for stream N. (And the packet header will tell
|
||||
// you the first frame's start position within the packet.)
|
||||
//
|
||||
// Step 1 can be performed using the GetXmaBlockContainingSample function below,
|
||||
// and steps 2-4 by calling GetXmaDecodePositionForSample once for each stream.
|
||||
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* XMA constants
|
||||
***************************************************************************/
|
||||
|
||||
// Size of the PCM samples produced by the XMA decoder
|
||||
#define XMA_OUTPUT_SAMPLE_BYTES 2u
|
||||
#define XMA_OUTPUT_SAMPLE_BITS (XMA_OUTPUT_SAMPLE_BYTES * 8u)
|
||||
|
||||
// Size of an XMA packet
|
||||
#define XMA_BYTES_PER_PACKET 2048u
|
||||
#define XMA_BITS_PER_PACKET (XMA_BYTES_PER_PACKET * 8u)
|
||||
|
||||
// Size of an XMA packet header
|
||||
#define XMA_PACKET_HEADER_BYTES 4u
|
||||
#define XMA_PACKET_HEADER_BITS (XMA_PACKET_HEADER_BYTES * 8u)
|
||||
|
||||
// Sample blocks in a decoded XMA frame
|
||||
#define XMA_SAMPLES_PER_FRAME 512u
|
||||
|
||||
// Sample blocks in a decoded XMA subframe
|
||||
#define XMA_SAMPLES_PER_SUBFRAME 128u
|
||||
|
||||
// Maximum encoded data that can be submitted to the XMA decoder at a time
|
||||
#define XMA_READBUFFER_MAX_PACKETS 4095u
|
||||
#define XMA_READBUFFER_MAX_BYTES (XMA_READBUFFER_MAX_PACKETS * XMA_BYTES_PER_PACKET)
|
||||
|
||||
// Maximum size allowed for the XMA decoder's output buffers
|
||||
#define XMA_WRITEBUFFER_MAX_BYTES (31u * 256u)
|
||||
|
||||
// Required byte alignment of the XMA decoder's output buffers
|
||||
#define XMA_WRITEBUFFER_BYTE_ALIGNMENT 256u
|
||||
|
||||
// Decode chunk sizes for the XMA_PLAYBACK_INIT.subframesToDecode field
|
||||
#define XMA_MIN_SUBFRAMES_TO_DECODE 1u
|
||||
#define XMA_MAX_SUBFRAMES_TO_DECODE 8u
|
||||
#define XMA_OPTIMAL_SUBFRAMES_TO_DECODE 4u
|
||||
|
||||
// LoopCount<255 means finite repetitions; LoopCount=255 means infinite looping
|
||||
#define XMA_MAX_LOOPCOUNT 254u
|
||||
#define XMA_INFINITE_LOOP 255u
|
||||
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* XMA format structures
|
||||
***************************************************************************/
|
||||
|
||||
// The currently recommended way to express format information for XMA2 files
|
||||
// is the XMA2WAVEFORMATEX structure. This structure is fully compliant with
|
||||
// the WAVEFORMATEX standard and contains all the information needed to parse
|
||||
// and manage XMA2 files in a compact way.
|
||||
|
||||
#define WAVE_FORMAT_XMA2 0x166
|
||||
|
||||
typedef struct XMA2WAVEFORMATEX
|
||||
{
|
||||
WAVEFORMATEX wfx;
|
||||
// Meaning of the WAVEFORMATEX fields here:
|
||||
// wFormatTag; // Audio format type; always WAVE_FORMAT_XMA2
|
||||
// nChannels; // Channel count of the decoded audio
|
||||
// nSamplesPerSec; // Sample rate of the decoded audio
|
||||
// nAvgBytesPerSec; // Used internally by the XMA encoder
|
||||
// nBlockAlign; // Decoded sample size; channels * wBitsPerSample / 8
|
||||
// wBitsPerSample; // Bits per decoded mono sample; always 16 for XMA
|
||||
// cbSize; // Size in bytes of the rest of this structure (34)
|
||||
|
||||
WORD NumStreams; // Number of audio streams (1 or 2 channels each)
|
||||
DWORD ChannelMask; // Spatial positions of the channels in this file,
|
||||
// stored as SPEAKER_xxx values (see audiodefs.h)
|
||||
DWORD SamplesEncoded; // Total number of PCM samples the file decodes to
|
||||
DWORD BytesPerBlock; // XMA block size (but the last one may be shorter)
|
||||
DWORD PlayBegin; // First valid sample in the decoded audio
|
||||
DWORD PlayLength; // Length of the valid part of the decoded audio
|
||||
DWORD LoopBegin; // Beginning of the loop region in decoded sample terms
|
||||
DWORD LoopLength; // Length of the loop region in decoded sample terms
|
||||
BYTE LoopCount; // Number of loop repetitions; 255 = infinite
|
||||
BYTE EncoderVersion; // Version of XMA encoder that generated the file
|
||||
WORD BlockCount; // XMA blocks in file (and entries in its seek table)
|
||||
} XMA2WAVEFORMATEX, *PXMA2WAVEFORMATEX;
|
||||
|
||||
|
||||
// The legacy XMA format structures are described here for reference, but they
|
||||
// should not be used in new content. XMAWAVEFORMAT was the structure used in
|
||||
// XMA version 1 files. XMA2WAVEFORMAT was used in early XMA2 files; it is not
|
||||
// placed in the usual 'fmt' RIFF chunk but in its own 'XMA2' chunk.
|
||||
|
||||
#ifndef WAVE_FORMAT_XMA
|
||||
#define WAVE_FORMAT_XMA 0x0165
|
||||
|
||||
// Values used in the ChannelMask fields below. Similar to the SPEAKER_xxx
|
||||
// values defined in audiodefs.h, but modified to fit in a single byte.
|
||||
#ifndef XMA_SPEAKER_LEFT
|
||||
#define XMA_SPEAKER_LEFT 0x01
|
||||
#define XMA_SPEAKER_RIGHT 0x02
|
||||
#define XMA_SPEAKER_CENTER 0x04
|
||||
#define XMA_SPEAKER_LFE 0x08
|
||||
#define XMA_SPEAKER_LEFT_SURROUND 0x10
|
||||
#define XMA_SPEAKER_RIGHT_SURROUND 0x20
|
||||
#define XMA_SPEAKER_LEFT_BACK 0x40
|
||||
#define XMA_SPEAKER_RIGHT_BACK 0x80
|
||||
#endif
|
||||
|
||||
|
||||
// Used in XMAWAVEFORMAT for per-stream data
|
||||
typedef struct XMASTREAMFORMAT
|
||||
{
|
||||
DWORD PsuedoBytesPerSec; // Used by the XMA encoder (typo preserved for legacy reasons)
|
||||
DWORD SampleRate; // The stream's decoded sample rate (in XMA2 files,
|
||||
// this is the same for all streams in the file).
|
||||
DWORD LoopStart; // Bit offset of the frame containing the loop start
|
||||
// point, relative to the beginning of the stream.
|
||||
DWORD LoopEnd; // Bit offset of the frame containing the loop end.
|
||||
BYTE SubframeData; // Two 4-bit numbers specifying the exact location of
|
||||
// the loop points within the frames that contain them.
|
||||
// SubframeEnd: Subframe of the loop end frame where
|
||||
// the loop ends. Ranges from 0 to 3.
|
||||
// SubframeSkip: Subframes to skip in the start frame to
|
||||
// reach the loop. Ranges from 0 to 4.
|
||||
BYTE Channels; // Number of channels in the stream (1 or 2)
|
||||
WORD ChannelMask; // Spatial positions of the channels in the stream
|
||||
} XMASTREAMFORMAT;
|
||||
|
||||
// Legacy XMA1 format structure
|
||||
typedef struct XMAWAVEFORMAT
|
||||
{
|
||||
WORD FormatTag; // Audio format type (always WAVE_FORMAT_XMA)
|
||||
WORD BitsPerSample; // Bit depth (currently required to be 16)
|
||||
WORD EncodeOptions; // Options for XMA encoder/decoder
|
||||
WORD LargestSkip; // Largest skip used in interleaving streams
|
||||
WORD NumStreams; // Number of interleaved audio streams
|
||||
BYTE LoopCount; // Number of loop repetitions; 255 = infinite
|
||||
BYTE Version; // XMA encoder version that generated the file.
|
||||
// Always 3 or higher for XMA2 files.
|
||||
XMASTREAMFORMAT XmaStreams[1]; // Per-stream format information; the actual
|
||||
// array length is in the NumStreams field.
|
||||
} XMAWAVEFORMAT;
|
||||
|
||||
|
||||
// Used in XMA2WAVEFORMAT for per-stream data
|
||||
typedef struct XMA2STREAMFORMAT
|
||||
{
|
||||
BYTE Channels; // Number of channels in the stream (1 or 2)
|
||||
BYTE RESERVED; // Reserved for future use
|
||||
WORD ChannelMask; // Spatial positions of the channels in the stream
|
||||
} XMA2STREAMFORMAT;
|
||||
|
||||
// Legacy XMA2 format structure (big-endian byte ordering)
|
||||
typedef struct XMA2WAVEFORMAT
|
||||
{
|
||||
BYTE Version; // XMA encoder version that generated the file.
|
||||
// Always 3 or higher for XMA2 files.
|
||||
BYTE NumStreams; // Number of interleaved audio streams
|
||||
BYTE RESERVED; // Reserved for future use
|
||||
BYTE LoopCount; // Number of loop repetitions; 255 = infinite
|
||||
DWORD LoopBegin; // Loop begin point, in samples
|
||||
DWORD LoopEnd; // Loop end point, in samples
|
||||
DWORD SampleRate; // The file's decoded sample rate
|
||||
DWORD EncodeOptions; // Options for the XMA encoder/decoder
|
||||
DWORD PsuedoBytesPerSec; // Used internally by the XMA encoder
|
||||
DWORD BlockSizeInBytes; // Size in bytes of this file's XMA blocks (except
|
||||
// possibly the last one). Always a multiple of
|
||||
// 2Kb, since XMA blocks are arrays of 2Kb packets.
|
||||
DWORD SamplesEncoded; // Total number of PCM samples encoded in this file
|
||||
DWORD SamplesInSource; // Actual number of PCM samples in the source
|
||||
// material used to generate this file
|
||||
DWORD BlockCount; // Number of XMA blocks in this file (and hence
|
||||
// also the number of entries in its seek table)
|
||||
XMA2STREAMFORMAT Streams[1]; // Per-stream format information; the actual
|
||||
// array length is in the NumStreams field.
|
||||
} XMA2WAVEFORMAT;
|
||||
|
||||
#endif // #ifndef WAVE_FORMAT_XMA
|
||||
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* XMA packet structure (in big-endian form)
|
||||
***************************************************************************/
|
||||
|
||||
typedef struct XMA2PACKET
|
||||
{
|
||||
int FrameCount : 6; // Number of XMA frames that begin in this packet
|
||||
int FrameOffsetInBits : 15; // Bit of XmaData where the first complete frame begins
|
||||
int PacketMetaData : 3; // Metadata stored in the packet (always 1 for XMA2)
|
||||
int PacketSkipCount : 8; // How many packets belonging to other streams must be
|
||||
// skipped to find the next packet belonging to this one
|
||||
BYTE XmaData[XMA_BYTES_PER_PACKET - sizeof(DWORD)]; // XMA encoded data
|
||||
} XMA2PACKET;
|
||||
|
||||
// E.g. if the first DWORD of a packet is 0x30107902:
|
||||
//
|
||||
// 001100 000001000001111 001 00000010
|
||||
// | | | |____ Skip 2 packets to find the next one for this stream
|
||||
// | | |___________ XMA2 signature (always 001)
|
||||
// | |_____________________ First frame starts 527 bits into packet
|
||||
// |________________________________ Packet contains 12 frames
|
||||
|
||||
|
||||
// Helper functions to extract the fields above from an XMA packet. (Note that
|
||||
// the bitfields cannot be read directly on little-endian architectures such as
|
||||
// the Intel x86, as they are laid out in big-endian form.)
|
||||
|
||||
__inline DWORD GetXmaPacketFrameCount(__in_bcount(1) const BYTE* pPacket)
|
||||
{
|
||||
return (DWORD)(pPacket[0] >> 2);
|
||||
}
|
||||
|
||||
__inline DWORD GetXmaPacketFirstFrameOffsetInBits(__in_bcount(3) const BYTE* pPacket)
|
||||
{
|
||||
return ((DWORD)(pPacket[0] & 0x3) << 13) |
|
||||
((DWORD)(pPacket[1]) << 5) |
|
||||
((DWORD)(pPacket[2]) >> 3);
|
||||
}
|
||||
|
||||
__inline DWORD GetXmaPacketMetadata(__in_bcount(3) const BYTE* pPacket)
|
||||
{
|
||||
return (DWORD)(pPacket[2] & 0x7);
|
||||
}
|
||||
|
||||
__inline DWORD GetXmaPacketSkipCount(__in_bcount(4) const BYTE* pPacket)
|
||||
{
|
||||
return (DWORD)(pPacket[3]);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* XMA frame structure
|
||||
***************************************************************************/
|
||||
|
||||
// There is no way to represent the XMA frame as a C struct, since it is a
|
||||
// variable-sized string of bits that need not be stored at a byte-aligned
|
||||
// position in memory. This is the layout:
|
||||
//
|
||||
// XMAFRAME
|
||||
// {
|
||||
// LengthInBits: A 15-bit number representing the length of this frame.
|
||||
// XmaData: Encoded XMA data; its size in bits is (LengthInBits - 15).
|
||||
// }
|
||||
|
||||
// Size in bits of the frame's initial LengthInBits field
|
||||
#define XMA_BITS_IN_FRAME_LENGTH_FIELD 15
|
||||
|
||||
// Special LengthInBits value that marks an invalid final frame
|
||||
#define XMA_FINAL_FRAME_MARKER 0x7FFF
|
||||
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
* XMA helper functions
|
||||
***************************************************************************/
|
||||
|
||||
// We define a local ASSERT macro to equal the global one if it exists.
|
||||
// You can define XMA2DEFS_ASSERT in advance to override this default.
|
||||
#ifndef XMA2DEFS_ASSERT
|
||||
#ifdef ASSERT
|
||||
#define XMA2DEFS_ASSERT ASSERT
|
||||
#else
|
||||
#define XMA2DEFS_ASSERT(a) /* No-op by default */
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
// GetXmaBlockContainingSample: Use a given seek table to find the XMA block
|
||||
// containing a given decoded sample. Note that the seek table entries in an
|
||||
// XMA file are stored in big-endian form and may need to be converted prior
|
||||
// to calling this function.
|
||||
|
||||
__inline HRESULT GetXmaBlockContainingSample
|
||||
(
|
||||
DWORD nBlockCount, // Blocks in the file (= seek table entries)
|
||||
__in_ecount(nBlockCount) const DWORD* pSeekTable, // Pointer to the seek table data
|
||||
DWORD nDesiredSample, // Decoded sample to locate
|
||||
__out DWORD* pnBlockContainingSample, // Index of the block containing the sample
|
||||
__out DWORD* pnSampleOffsetWithinBlock // Position of the sample in this block
|
||||
)
|
||||
{
|
||||
DWORD nPreviousTotalSamples = 0;
|
||||
DWORD nBlock;
|
||||
DWORD nTotalSamplesSoFar;
|
||||
|
||||
XMA2DEFS_ASSERT(pSeekTable);
|
||||
XMA2DEFS_ASSERT(pnBlockContainingSample);
|
||||
XMA2DEFS_ASSERT(pnSampleOffsetWithinBlock);
|
||||
|
||||
for (nBlock = 0; nBlock < nBlockCount; ++nBlock)
|
||||
{
|
||||
nTotalSamplesSoFar = pSeekTable[nBlock];
|
||||
if (nTotalSamplesSoFar > nDesiredSample)
|
||||
{
|
||||
*pnBlockContainingSample = nBlock;
|
||||
*pnSampleOffsetWithinBlock = nDesiredSample - nPreviousTotalSamples;
|
||||
return S_OK;
|
||||
}
|
||||
nPreviousTotalSamples = nTotalSamplesSoFar;
|
||||
}
|
||||
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
// GetXmaFrameLengthInBits: Reads a given frame's LengthInBits field.
|
||||
|
||||
__inline DWORD GetXmaFrameLengthInBits
|
||||
(
|
||||
__in_bcount(nBitPosition / 8 + 3)
|
||||
__in const BYTE* pPacket, // Pointer to XMA packet[s] containing the frame
|
||||
DWORD nBitPosition // Bit offset of the frame within this packet
|
||||
)
|
||||
{
|
||||
DWORD nRegion;
|
||||
DWORD nBytePosition = nBitPosition / 8;
|
||||
DWORD nBitOffset = nBitPosition % 8;
|
||||
|
||||
if (nBitOffset < 2) // Only need to read 2 bytes (and might not be safe to read more)
|
||||
{
|
||||
nRegion = (DWORD)(pPacket[nBytePosition+0]) << 8 |
|
||||
(DWORD)(pPacket[nBytePosition+1]);
|
||||
return (nRegion >> (1 - nBitOffset)) & 0x7FFF; // Last 15 bits
|
||||
}
|
||||
else // Need to read 3 bytes
|
||||
{
|
||||
nRegion = (DWORD)(pPacket[nBytePosition+0]) << 16 |
|
||||
(DWORD)(pPacket[nBytePosition+1]) << 8 |
|
||||
(DWORD)(pPacket[nBytePosition+2]);
|
||||
return (nRegion >> (9 - nBitOffset)) & 0x7FFF; // Last 15 bits
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// GetXmaFrameBitPosition: Calculates the bit offset of a given frame within
|
||||
// an XMA block or set of blocks. Returns 0 on failure.
|
||||
|
||||
__inline DWORD GetXmaFrameBitPosition
|
||||
(
|
||||
__in_bcount(nXmaDataBytes) const BYTE* pXmaData, // Pointer to XMA block[s]
|
||||
DWORD nXmaDataBytes, // Size of pXmaData in bytes
|
||||
DWORD nStreamIndex, // Stream within which to seek
|
||||
DWORD nDesiredFrame // Frame sought
|
||||
)
|
||||
{
|
||||
const BYTE* pCurrentPacket;
|
||||
DWORD nPacketsExamined = 0;
|
||||
DWORD nFrameCountSoFar = 0;
|
||||
DWORD nFramesToSkip;
|
||||
DWORD nFrameBitOffset;
|
||||
|
||||
XMA2DEFS_ASSERT(pXmaData);
|
||||
XMA2DEFS_ASSERT(nXmaDataBytes % XMA_BYTES_PER_PACKET == 0);
|
||||
|
||||
// Get the first XMA packet belonging to the desired stream, relying on the
|
||||
// fact that the first packets for each stream are in consecutive order at
|
||||
// the beginning of an XMA block.
|
||||
|
||||
pCurrentPacket = pXmaData + nStreamIndex * XMA_BYTES_PER_PACKET;
|
||||
for (;;)
|
||||
{
|
||||
// If we have exceeded the size of the XMA data, return failure
|
||||
if (pCurrentPacket + XMA_BYTES_PER_PACKET > pXmaData + nXmaDataBytes)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
// If the current packet contains the frame we are looking for...
|
||||
if (nFrameCountSoFar + GetXmaPacketFrameCount(pCurrentPacket) > nDesiredFrame)
|
||||
{
|
||||
// See how many frames in this packet we need to skip to get to it
|
||||
XMA2DEFS_ASSERT(nDesiredFrame >= nFrameCountSoFar);
|
||||
nFramesToSkip = nDesiredFrame - nFrameCountSoFar;
|
||||
|
||||
// Get the bit offset of the first frame in this packet
|
||||
nFrameBitOffset = XMA_PACKET_HEADER_BITS + GetXmaPacketFirstFrameOffsetInBits(pCurrentPacket);
|
||||
|
||||
// Advance nFrameBitOffset to the frame of interest
|
||||
while (nFramesToSkip--)
|
||||
{
|
||||
nFrameBitOffset += GetXmaFrameLengthInBits(pCurrentPacket, nFrameBitOffset);
|
||||
}
|
||||
|
||||
// The bit offset to return is the number of bits from pXmaData to
|
||||
// pCurrentPacket plus the bit offset of the frame of interest
|
||||
return (DWORD)(pCurrentPacket - pXmaData) * 8 + nFrameBitOffset;
|
||||
}
|
||||
|
||||
// If we haven't found the right packet yet, advance our counters
|
||||
++nPacketsExamined;
|
||||
nFrameCountSoFar += GetXmaPacketFrameCount(pCurrentPacket);
|
||||
|
||||
// And skip to the next packet belonging to the same stream
|
||||
pCurrentPacket += XMA_BYTES_PER_PACKET * (GetXmaPacketSkipCount(pCurrentPacket) + 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// GetLastXmaFrameBitPosition: Calculates the bit offset of the last complete
|
||||
// frame in an XMA block or set of blocks.
|
||||
|
||||
__inline DWORD GetLastXmaFrameBitPosition
|
||||
(
|
||||
__in_bcount(nXmaDataBytes) const BYTE* pXmaData, // Pointer to XMA block[s]
|
||||
DWORD nXmaDataBytes, // Size of pXmaData in bytes
|
||||
DWORD nStreamIndex // Stream within which to seek
|
||||
)
|
||||
{
|
||||
const BYTE* pLastPacket;
|
||||
DWORD nBytesToNextPacket;
|
||||
DWORD nFrameBitOffset;
|
||||
DWORD nFramesInLastPacket;
|
||||
|
||||
XMA2DEFS_ASSERT(pXmaData);
|
||||
XMA2DEFS_ASSERT(nXmaDataBytes % XMA_BYTES_PER_PACKET == 0);
|
||||
XMA2DEFS_ASSERT(nXmaDataBytes >= XMA_BYTES_PER_PACKET * (nStreamIndex + 1));
|
||||
|
||||
// Get the first XMA packet belonging to the desired stream, relying on the
|
||||
// fact that the first packets for each stream are in consecutive order at
|
||||
// the beginning of an XMA block.
|
||||
pLastPacket = pXmaData + nStreamIndex * XMA_BYTES_PER_PACKET;
|
||||
|
||||
// Search for the last packet belonging to the desired stream
|
||||
for (;;)
|
||||
{
|
||||
nBytesToNextPacket = XMA_BYTES_PER_PACKET * (GetXmaPacketSkipCount(pLastPacket) + 1);
|
||||
XMA2DEFS_ASSERT(nBytesToNextPacket);
|
||||
if (pLastPacket + nBytesToNextPacket + XMA_BYTES_PER_PACKET > pXmaData + nXmaDataBytes)
|
||||
{
|
||||
break; // The next packet would extend beyond the end of pXmaData
|
||||
}
|
||||
pLastPacket += nBytesToNextPacket;
|
||||
}
|
||||
|
||||
// The last packet can sometimes have no seekable frames, in which case we
|
||||
// have to use the previous one
|
||||
if (GetXmaPacketFrameCount(pLastPacket) == 0)
|
||||
{
|
||||
pLastPacket -= nBytesToNextPacket;
|
||||
}
|
||||
|
||||
// Found the last packet. Get the bit offset of its first frame.
|
||||
nFrameBitOffset = XMA_PACKET_HEADER_BITS + GetXmaPacketFirstFrameOffsetInBits(pLastPacket);
|
||||
|
||||
// Traverse frames until we reach the last one
|
||||
nFramesInLastPacket = GetXmaPacketFrameCount(pLastPacket);
|
||||
while (--nFramesInLastPacket)
|
||||
{
|
||||
nFrameBitOffset += GetXmaFrameLengthInBits(pLastPacket, nFrameBitOffset);
|
||||
}
|
||||
|
||||
// The bit offset to return is the number of bits from pXmaData to
|
||||
// pLastPacket plus the offset of the last frame in this packet.
|
||||
return (DWORD)(pLastPacket - pXmaData) * 8 + nFrameBitOffset;
|
||||
}
|
||||
|
||||
|
||||
// GetXmaDecodePositionForSample: Obtains the information needed to make the
|
||||
// decoder generate audio starting at a given sample position relative to the
|
||||
// beginning of the given XMA block: the bit offset of the appropriate frame,
|
||||
// and the right subframe within that frame. This data can be passed directly
|
||||
// to the XMAPlaybackSetDecodePosition function.
|
||||
|
||||
__inline HRESULT GetXmaDecodePositionForSample
|
||||
(
|
||||
__in_bcount(nXmaDataBytes) const BYTE* pXmaData, // Pointer to XMA block[s]
|
||||
DWORD nXmaDataBytes, // Size of pXmaData in bytes
|
||||
DWORD nStreamIndex, // Stream within which to seek
|
||||
DWORD nDesiredSample, // Sample sought
|
||||
__out DWORD* pnBitOffset, // Returns the bit offset within pXmaData of
|
||||
// the frame containing the sample sought
|
||||
__out DWORD* pnSubFrame // Returns the subframe containing the sample
|
||||
)
|
||||
{
|
||||
DWORD nDesiredFrame = nDesiredSample / XMA_SAMPLES_PER_FRAME;
|
||||
DWORD nSubFrame = (nDesiredSample % XMA_SAMPLES_PER_FRAME) / XMA_SAMPLES_PER_SUBFRAME;
|
||||
DWORD nBitOffset = GetXmaFrameBitPosition(pXmaData, nXmaDataBytes, nStreamIndex, nDesiredFrame);
|
||||
|
||||
XMA2DEFS_ASSERT(pnBitOffset);
|
||||
XMA2DEFS_ASSERT(pnSubFrame);
|
||||
|
||||
if (nBitOffset)
|
||||
{
|
||||
*pnBitOffset = nBitOffset;
|
||||
*pnSubFrame = nSubFrame;
|
||||
return S_OK;
|
||||
}
|
||||
else
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// GetXmaSampleRate: Obtains the legal XMA sample rate (24, 32, 44.1 or 48Khz)
|
||||
// corresponding to a generic sample rate.
|
||||
|
||||
__inline DWORD GetXmaSampleRate(DWORD dwGeneralRate)
|
||||
{
|
||||
DWORD dwXmaRate = 48000; // Default XMA rate for all rates above 44100Hz
|
||||
|
||||
if (dwGeneralRate <= 24000) dwXmaRate = 24000;
|
||||
else if (dwGeneralRate <= 32000) dwXmaRate = 32000;
|
||||
else if (dwGeneralRate <= 44100) dwXmaRate = 44100;
|
||||
|
||||
return dwXmaRate;
|
||||
}
|
||||
|
||||
|
||||
// Functions to convert between WAVEFORMATEXTENSIBLE channel masks (combinations
|
||||
// of the SPEAKER_xxx flags defined in audiodefs.h) and XMA channel masks (which
|
||||
// are limited to eight possible speaker positions: left, right, center, low
|
||||
// frequency, side left, side right, back left and back right).
|
||||
|
||||
__inline DWORD GetStandardChannelMaskFromXmaMask(BYTE bXmaMask)
|
||||
{
|
||||
DWORD dwStandardMask = 0;
|
||||
|
||||
if (bXmaMask & XMA_SPEAKER_LEFT) dwStandardMask |= SPEAKER_FRONT_LEFT;
|
||||
if (bXmaMask & XMA_SPEAKER_RIGHT) dwStandardMask |= SPEAKER_FRONT_RIGHT;
|
||||
if (bXmaMask & XMA_SPEAKER_CENTER) dwStandardMask |= SPEAKER_FRONT_CENTER;
|
||||
if (bXmaMask & XMA_SPEAKER_LFE) dwStandardMask |= SPEAKER_LOW_FREQUENCY;
|
||||
if (bXmaMask & XMA_SPEAKER_LEFT_SURROUND) dwStandardMask |= SPEAKER_SIDE_LEFT;
|
||||
if (bXmaMask & XMA_SPEAKER_RIGHT_SURROUND) dwStandardMask |= SPEAKER_SIDE_RIGHT;
|
||||
if (bXmaMask & XMA_SPEAKER_LEFT_BACK) dwStandardMask |= SPEAKER_BACK_LEFT;
|
||||
if (bXmaMask & XMA_SPEAKER_RIGHT_BACK) dwStandardMask |= SPEAKER_BACK_RIGHT;
|
||||
|
||||
return dwStandardMask;
|
||||
}
|
||||
|
||||
__inline BYTE GetXmaChannelMaskFromStandardMask(DWORD dwStandardMask)
|
||||
{
|
||||
BYTE bXmaMask = 0;
|
||||
|
||||
if (dwStandardMask & SPEAKER_FRONT_LEFT) bXmaMask |= XMA_SPEAKER_LEFT;
|
||||
if (dwStandardMask & SPEAKER_FRONT_RIGHT) bXmaMask |= XMA_SPEAKER_RIGHT;
|
||||
if (dwStandardMask & SPEAKER_FRONT_CENTER) bXmaMask |= XMA_SPEAKER_CENTER;
|
||||
if (dwStandardMask & SPEAKER_LOW_FREQUENCY) bXmaMask |= XMA_SPEAKER_LFE;
|
||||
if (dwStandardMask & SPEAKER_SIDE_LEFT) bXmaMask |= XMA_SPEAKER_LEFT_SURROUND;
|
||||
if (dwStandardMask & SPEAKER_SIDE_RIGHT) bXmaMask |= XMA_SPEAKER_RIGHT_SURROUND;
|
||||
if (dwStandardMask & SPEAKER_BACK_LEFT) bXmaMask |= XMA_SPEAKER_LEFT_BACK;
|
||||
if (dwStandardMask & SPEAKER_BACK_RIGHT) bXmaMask |= XMA_SPEAKER_RIGHT_BACK;
|
||||
|
||||
return bXmaMask;
|
||||
}
|
||||
|
||||
|
||||
// LocalizeXma2Format: Modifies a XMA2WAVEFORMATEX structure in place to comply
|
||||
// with the current platform's byte-ordering rules (little- or big-endian).
|
||||
|
||||
__inline HRESULT LocalizeXma2Format(__inout XMA2WAVEFORMATEX* pXma2Format)
|
||||
{
|
||||
#define XMASWAP2BYTES(n) ((WORD)(((n) >> 8) | (((n) & 0xff) << 8)))
|
||||
#define XMASWAP4BYTES(n) ((DWORD)((n) >> 24 | (n) << 24 | ((n) & 0xff00) << 8 | ((n) & 0xff0000) >> 8))
|
||||
|
||||
if (pXma2Format->wfx.wFormatTag == WAVE_FORMAT_XMA2)
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
else if (XMASWAP2BYTES(pXma2Format->wfx.wFormatTag) == WAVE_FORMAT_XMA2)
|
||||
{
|
||||
pXma2Format->wfx.wFormatTag = XMASWAP2BYTES(pXma2Format->wfx.wFormatTag);
|
||||
pXma2Format->wfx.nChannels = XMASWAP2BYTES(pXma2Format->wfx.nChannels);
|
||||
pXma2Format->wfx.nSamplesPerSec = XMASWAP4BYTES(pXma2Format->wfx.nSamplesPerSec);
|
||||
pXma2Format->wfx.nAvgBytesPerSec = XMASWAP4BYTES(pXma2Format->wfx.nAvgBytesPerSec);
|
||||
pXma2Format->wfx.nBlockAlign = XMASWAP2BYTES(pXma2Format->wfx.nBlockAlign);
|
||||
pXma2Format->wfx.wBitsPerSample = XMASWAP2BYTES(pXma2Format->wfx.wBitsPerSample);
|
||||
pXma2Format->wfx.cbSize = XMASWAP2BYTES(pXma2Format->wfx.cbSize);
|
||||
pXma2Format->NumStreams = XMASWAP2BYTES(pXma2Format->NumStreams);
|
||||
pXma2Format->ChannelMask = XMASWAP4BYTES(pXma2Format->ChannelMask);
|
||||
pXma2Format->SamplesEncoded = XMASWAP4BYTES(pXma2Format->SamplesEncoded);
|
||||
pXma2Format->BytesPerBlock = XMASWAP4BYTES(pXma2Format->BytesPerBlock);
|
||||
pXma2Format->PlayBegin = XMASWAP4BYTES(pXma2Format->PlayBegin);
|
||||
pXma2Format->PlayLength = XMASWAP4BYTES(pXma2Format->PlayLength);
|
||||
pXma2Format->LoopBegin = XMASWAP4BYTES(pXma2Format->LoopBegin);
|
||||
pXma2Format->LoopLength = XMASWAP4BYTES(pXma2Format->LoopLength);
|
||||
pXma2Format->BlockCount = XMASWAP2BYTES(pXma2Format->BlockCount);
|
||||
return S_OK;
|
||||
}
|
||||
else
|
||||
{
|
||||
return E_FAIL; // Not a recognizable XMA2 format
|
||||
}
|
||||
|
||||
#undef XMASWAP2BYTES
|
||||
#undef XMASWAP4BYTES
|
||||
}
|
||||
|
||||
|
||||
#endif // #ifndef __XMA2DEFS_INCLUDED__
|
||||
Vendored
+1
-1
Submodule 3rdparty/cereal updated: 42a45b6e15...60c69df968
+1
Submodule 3rdparty/curl added at 9d954e49bc
+40
@@ -0,0 +1,40 @@
|
||||
/* options.h.in
|
||||
*
|
||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
||||
*
|
||||
* This file is part of wolfSSL.
|
||||
*
|
||||
* wolfSSL 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 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* wolfSSL 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, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||
*/
|
||||
|
||||
|
||||
/* default blank options for autoconf */
|
||||
|
||||
#ifndef WOLFSSL_OPTIONS_H
|
||||
#define WOLFSSL_OPTIONS_H
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* WOLFSSL_OPTIONS_H */
|
||||
|
||||
+10
-10
@@ -1,17 +1,17 @@
|
||||
#pragma once
|
||||
|
||||
#if defined(DISCORD_DYNAMIC_LIB)
|
||||
# if defined(_WIN32)
|
||||
# if defined(DISCORD_BUILDING_SDK)
|
||||
# define DISCORD_EXPORT __declspec(dllexport)
|
||||
# else
|
||||
# define DISCORD_EXPORT __declspec(dllimport)
|
||||
# endif
|
||||
# else
|
||||
# define DISCORD_EXPORT __attribute__((visibility("default")))
|
||||
# endif
|
||||
#if defined(_WIN32)
|
||||
#if defined(DISCORD_BUILDING_SDK)
|
||||
#define DISCORD_EXPORT __declspec(dllexport)
|
||||
#else
|
||||
# define DISCORD_EXPORT
|
||||
#define DISCORD_EXPORT __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define DISCORD_EXPORT __attribute__((visibility("default")))
|
||||
#endif
|
||||
#else
|
||||
#define DISCORD_EXPORT
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
+4
-4
@@ -41,20 +41,20 @@ typedef struct DiscordRichPresence {
|
||||
int8_t instance;
|
||||
} DiscordRichPresence;
|
||||
|
||||
typedef struct DiscordJoinRequest {
|
||||
typedef struct DiscordUser {
|
||||
const char* userId;
|
||||
const char* username;
|
||||
const char* discriminator;
|
||||
const char* avatar;
|
||||
} DiscordJoinRequest;
|
||||
} DiscordUser;
|
||||
|
||||
typedef struct DiscordEventHandlers {
|
||||
void (*ready)(void);
|
||||
void (*ready)(const DiscordUser* request);
|
||||
void (*disconnected)(int errorCode, const char* message);
|
||||
void (*errored)(int errorCode, const char* message);
|
||||
void (*joinGame)(const char* joinSecret);
|
||||
void (*spectateGame)(const char* spectateSecret);
|
||||
void (*joinRequest)(const DiscordJoinRequest* request);
|
||||
void (*joinRequest)(const DiscordUser* request);
|
||||
} DiscordEventHandlers;
|
||||
|
||||
#define DISCORD_REPLY_NO 0
|
||||
|
||||
BIN
Binary file not shown.
Vendored
+1
-1
Submodule 3rdparty/ffmpeg updated: 7b7ae7b067...e5fb13bbb0
+1
Submodule 3rdparty/flatbuffers added at 9e7e8cbe9f
Vendored
+1
-1
Submodule 3rdparty/hidapi updated: 9220f5e77c...8961cf86eb
Vendored
+3
-1
@@ -27,6 +27,9 @@
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
@@ -55,7 +58,6 @@
|
||||
<AdditionalIncludeDirectories>hidapi\hidapi;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
|
||||
Vendored
+385
@@ -0,0 +1,385 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug - LLVM|x64">
|
||||
<Configuration>Debug - LLVM</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release - LLVM|x64">
|
||||
<Configuration>Release - LLVM</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{DA6F56B4-06A4-441D-AD70-AC5A7D51FADB}</ProjectGuid>
|
||||
<RootNamespace>libcurl</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<Import Project="..\common_default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="..\common_default_macros.props" />
|
||||
<PropertyGroup Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
|
||||
<OutDir>$(SolutionDir)lib\$(Configuration)-$(Platform)\</OutDir>
|
||||
<IntDir>$(SolutionDir)tmp\$(ProjectName)-$(Configuration)-$(Platform)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<Midl>
|
||||
<TargetEnvironment>X64</TargetEnvironment>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
<AdditionalIncludeDirectories>curl\include;curl\lib;curl_extra;wolfssl;wolfssl\wolfssl;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>HAVE_SNI;NDEBUG;BUILDING_LIBCURL;CURL_STATICLIB;USE_WOLFSSL;USE_IPV6;SIZEOF_LONG=4;SIZEOF_LONG_LONG=8;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<StringPooling>true</StringPooling>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Lib>
|
||||
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
||||
<TargetMachine>MachineX64</TargetMachine>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="curl\lib\altsvc.c" />
|
||||
<ClCompile Include="curl\lib\amigaos.c" />
|
||||
<ClCompile Include="curl\lib\asyn-ares.c" />
|
||||
<ClCompile Include="curl\lib\asyn-thread.c" />
|
||||
<ClCompile Include="curl\lib\base64.c" />
|
||||
<ClCompile Include="curl\lib\conncache.c" />
|
||||
<ClCompile Include="curl\lib\connect.c" />
|
||||
<ClCompile Include="curl\lib\content_encoding.c" />
|
||||
<ClCompile Include="curl\lib\cookie.c" />
|
||||
<ClCompile Include="curl\lib\curl_addrinfo.c" />
|
||||
<ClCompile Include="curl\lib\curl_ctype.c" />
|
||||
<ClCompile Include="curl\lib\curl_des.c" />
|
||||
<ClCompile Include="curl\lib\curl_endian.c" />
|
||||
<ClCompile Include="curl\lib\curl_fnmatch.c" />
|
||||
<ClCompile Include="curl\lib\curl_gethostname.c" />
|
||||
<ClCompile Include="curl\lib\curl_get_line.c" />
|
||||
<ClCompile Include="curl\lib\curl_gssapi.c" />
|
||||
<ClCompile Include="curl\lib\curl_memrchr.c" />
|
||||
<ClCompile Include="curl\lib\curl_multibyte.c" />
|
||||
<ClCompile Include="curl\lib\curl_ntlm_core.c" />
|
||||
<ClCompile Include="curl\lib\curl_ntlm_wb.c" />
|
||||
<ClCompile Include="curl\lib\curl_path.c" />
|
||||
<ClCompile Include="curl\lib\curl_range.c" />
|
||||
<ClCompile Include="curl\lib\curl_rtmp.c" />
|
||||
<ClCompile Include="curl\lib\curl_sasl.c" />
|
||||
<ClCompile Include="curl\lib\curl_sspi.c" />
|
||||
<ClCompile Include="curl\lib\curl_threads.c" />
|
||||
<ClCompile Include="curl\lib\dict.c" />
|
||||
<ClCompile Include="curl\lib\doh.c" />
|
||||
<ClCompile Include="curl\lib\dotdot.c" />
|
||||
<ClCompile Include="curl\lib\dynbuf.c" />
|
||||
<ClCompile Include="curl\lib\easy.c" />
|
||||
<ClCompile Include="curl\lib\escape.c" />
|
||||
<ClCompile Include="curl\lib\file.c" />
|
||||
<ClCompile Include="curl\lib\fileinfo.c" />
|
||||
<ClCompile Include="curl\lib\formdata.c" />
|
||||
<ClCompile Include="curl\lib\ftp.c" />
|
||||
<ClCompile Include="curl\lib\ftplistparser.c" />
|
||||
<ClCompile Include="curl\lib\getenv.c" />
|
||||
<ClCompile Include="curl\lib\getinfo.c" />
|
||||
<ClCompile Include="curl\lib\gopher.c" />
|
||||
<ClCompile Include="curl\lib\hash.c" />
|
||||
<ClCompile Include="curl\lib\hmac.c" />
|
||||
<ClCompile Include="curl\lib\hostasyn.c" />
|
||||
<ClCompile Include="curl\lib\hostcheck.c" />
|
||||
<ClCompile Include="curl\lib\hostip.c" />
|
||||
<ClCompile Include="curl\lib\hostip4.c" />
|
||||
<ClCompile Include="curl\lib\hostip6.c" />
|
||||
<ClCompile Include="curl\lib\hostsyn.c" />
|
||||
<ClCompile Include="curl\lib\http.c" />
|
||||
<ClCompile Include="curl\lib\http2.c" />
|
||||
<ClCompile Include="curl\lib\http_chunks.c" />
|
||||
<ClCompile Include="curl\lib\http_digest.c" />
|
||||
<ClCompile Include="curl\lib\http_negotiate.c" />
|
||||
<ClCompile Include="curl\lib\http_ntlm.c" />
|
||||
<ClCompile Include="curl\lib\http_proxy.c" />
|
||||
<ClCompile Include="curl\lib\idn_win32.c" />
|
||||
<ClCompile Include="curl\lib\if2ip.c" />
|
||||
<ClCompile Include="curl\lib\imap.c" />
|
||||
<ClCompile Include="curl\lib\inet_ntop.c" />
|
||||
<ClCompile Include="curl\lib\inet_pton.c" />
|
||||
<ClCompile Include="curl\lib\krb5.c" />
|
||||
<ClCompile Include="curl\lib\ldap.c" />
|
||||
<ClCompile Include="curl\lib\llist.c" />
|
||||
<ClCompile Include="curl\lib\md4.c" />
|
||||
<ClCompile Include="curl\lib\md5.c" />
|
||||
<ClCompile Include="curl\lib\memdebug.c" />
|
||||
<ClCompile Include="curl\lib\mime.c" />
|
||||
<ClCompile Include="curl\lib\mprintf.c" />
|
||||
<ClCompile Include="curl\lib\mqtt.c" />
|
||||
<ClCompile Include="curl\lib\multi.c" />
|
||||
<ClCompile Include="curl\lib\netrc.c" />
|
||||
<ClCompile Include="curl\lib\non-ascii.c" />
|
||||
<ClCompile Include="curl\lib\nonblock.c" />
|
||||
<ClCompile Include="curl\lib\nwlib.c" />
|
||||
<ClCompile Include="curl\lib\nwos.c" />
|
||||
<ClCompile Include="curl\lib\openldap.c" />
|
||||
<ClCompile Include="curl\lib\parsedate.c" />
|
||||
<ClCompile Include="curl\lib\pingpong.c" />
|
||||
<ClCompile Include="curl\lib\pop3.c" />
|
||||
<ClCompile Include="curl\lib\progress.c" />
|
||||
<ClCompile Include="curl\lib\psl.c" />
|
||||
<ClCompile Include="curl\lib\rand.c" />
|
||||
<ClCompile Include="curl\lib\rename.c" />
|
||||
<ClCompile Include="curl\lib\rtsp.c" />
|
||||
<ClCompile Include="curl\lib\security.c" />
|
||||
<ClCompile Include="curl\lib\select.c" />
|
||||
<ClCompile Include="curl\lib\sendf.c" />
|
||||
<ClCompile Include="curl\lib\setopt.c" />
|
||||
<ClCompile Include="curl\lib\sha256.c" />
|
||||
<ClCompile Include="curl\lib\share.c" />
|
||||
<ClCompile Include="curl\lib\slist.c" />
|
||||
<ClCompile Include="curl\lib\smb.c" />
|
||||
<ClCompile Include="curl\lib\smtp.c" />
|
||||
<ClCompile Include="curl\lib\socketpair.c" />
|
||||
<ClCompile Include="curl\lib\socks.c" />
|
||||
<ClCompile Include="curl\lib\socks_gssapi.c" />
|
||||
<ClCompile Include="curl\lib\socks_sspi.c" />
|
||||
<ClCompile Include="curl\lib\speedcheck.c" />
|
||||
<ClCompile Include="curl\lib\splay.c" />
|
||||
<ClCompile Include="curl\lib\strcase.c" />
|
||||
<ClCompile Include="curl\lib\strdup.c" />
|
||||
<ClCompile Include="curl\lib\strerror.c" />
|
||||
<ClCompile Include="curl\lib\strtok.c" />
|
||||
<ClCompile Include="curl\lib\strtoofft.c" />
|
||||
<ClCompile Include="curl\lib\system_win32.c" />
|
||||
<ClCompile Include="curl\lib\telnet.c" />
|
||||
<ClCompile Include="curl\lib\tftp.c" />
|
||||
<ClCompile Include="curl\lib\timeval.c" />
|
||||
<ClCompile Include="curl\lib\transfer.c" />
|
||||
<ClCompile Include="curl\lib\url.c" />
|
||||
<ClCompile Include="curl\lib\urlapi.c" />
|
||||
<ClCompile Include="curl\lib\version.c" />
|
||||
<ClCompile Include="curl\lib\version_win32.c" />
|
||||
<ClCompile Include="curl\lib\warnless.c" />
|
||||
<ClCompile Include="curl\lib\wildcard.c" />
|
||||
<ClCompile Include="curl\lib\x509asn1.c" />
|
||||
<ClCompile Include="curl\lib\vauth\cleartext.c" />
|
||||
<ClCompile Include="curl\lib\vauth\cram.c" />
|
||||
<ClCompile Include="curl\lib\vauth\digest.c" />
|
||||
<ClCompile Include="curl\lib\vauth\digest_sspi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\krb5_gssapi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\krb5_sspi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\ntlm.c" />
|
||||
<ClCompile Include="curl\lib\vauth\ntlm_sspi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\oauth2.c" />
|
||||
<ClCompile Include="curl\lib\vauth\spnego_gssapi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\spnego_sspi.c" />
|
||||
<ClCompile Include="curl\lib\vauth\vauth.c" />
|
||||
<ClCompile Include="curl\lib\vquic\ngtcp2.c" />
|
||||
<ClCompile Include="curl\lib\vquic\quiche.c" />
|
||||
<ClCompile Include="curl\lib\vquic\vquic.c" />
|
||||
<ClCompile Include="curl\lib\vssh\libssh.c" />
|
||||
<ClCompile Include="curl\lib\vssh\libssh2.c" />
|
||||
<ClCompile Include="curl\lib\vssh\wolfssh.c" />
|
||||
<ClCompile Include="curl\lib\vtls\bearssl.c" />
|
||||
<ClCompile Include="curl\lib\vtls\gskit.c" />
|
||||
<ClCompile Include="curl\lib\vtls\gtls.c" />
|
||||
<ClCompile Include="curl\lib\vtls\keylog.c" />
|
||||
<ClCompile Include="curl\lib\vtls\mbedtls.c" />
|
||||
<ClCompile Include="curl\lib\vtls\mbedtls_threadlock.c" />
|
||||
<ClCompile Include="curl\lib\vtls\mesalink.c" />
|
||||
<ClCompile Include="curl\lib\vtls\nss.c" />
|
||||
<ClCompile Include="curl\lib\vtls\openssl.c" />
|
||||
<ClCompile Include="curl\lib\vtls\schannel.c" />
|
||||
<ClCompile Include="curl\lib\vtls\schannel_verify.c" />
|
||||
<ClCompile Include="curl\lib\vtls\sectransp.c" />
|
||||
<ClCompile Include="curl\lib\vtls\vtls.c" />
|
||||
<ClCompile Include="curl\lib\vtls\wolfssl.c" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="curl\include\curl\curl.h" />
|
||||
<ClInclude Include="curl\include\curl\curlver.h" />
|
||||
<ClInclude Include="curl\include\curl\easy.h" />
|
||||
<ClInclude Include="curl\include\curl\mprintf.h" />
|
||||
<ClInclude Include="curl\include\curl\multi.h" />
|
||||
<ClInclude Include="curl\include\curl\stdcheaders.h" />
|
||||
<ClInclude Include="curl\include\curl\system.h" />
|
||||
<ClInclude Include="curl\include\curl\typecheck-gcc.h" />
|
||||
<ClInclude Include="curl\include\curl\urlapi.h" />
|
||||
<ClInclude Include="curl\lib\altsvc.h" />
|
||||
<ClInclude Include="curl\lib\amigaos.h" />
|
||||
<ClInclude Include="curl\lib\arpa_telnet.h" />
|
||||
<ClInclude Include="curl\lib\asyn.h" />
|
||||
<ClInclude Include="curl\lib\config-amigaos.h" />
|
||||
<ClInclude Include="curl\lib\config-dos.h" />
|
||||
<ClInclude Include="curl\lib\config-mac.h" />
|
||||
<ClInclude Include="curl\lib\config-os400.h" />
|
||||
<ClInclude Include="curl\lib\config-plan9.h" />
|
||||
<ClInclude Include="curl\lib\config-riscos.h" />
|
||||
<ClInclude Include="curl\lib\config-symbian.h" />
|
||||
<ClInclude Include="curl\lib\config-tpf.h" />
|
||||
<ClInclude Include="curl\lib\config-vxworks.h" />
|
||||
<ClInclude Include="curl\lib\config-win32.h" />
|
||||
<ClInclude Include="curl\lib\config-win32ce.h" />
|
||||
<ClInclude Include="curl\lib\conncache.h" />
|
||||
<ClInclude Include="curl\lib\connect.h" />
|
||||
<ClInclude Include="curl\lib\content_encoding.h" />
|
||||
<ClInclude Include="curl\lib\cookie.h" />
|
||||
<ClInclude Include="curl\lib\curlx.h" />
|
||||
<ClInclude Include="curl\lib\curl_addrinfo.h" />
|
||||
<ClInclude Include="curl\lib\curl_base64.h" />
|
||||
<ClInclude Include="curl\lib\curl_ctype.h" />
|
||||
<ClInclude Include="curl\lib\curl_des.h" />
|
||||
<ClInclude Include="curl\lib\curl_endian.h" />
|
||||
<ClInclude Include="curl\lib\curl_fnmatch.h" />
|
||||
<ClInclude Include="curl\lib\curl_gethostname.h" />
|
||||
<ClInclude Include="curl\lib\curl_get_line.h" />
|
||||
<ClInclude Include="curl\lib\curl_gssapi.h" />
|
||||
<ClInclude Include="curl\lib\curl_hmac.h" />
|
||||
<ClInclude Include="curl\lib\curl_ldap.h" />
|
||||
<ClInclude Include="curl\lib\curl_md4.h" />
|
||||
<ClInclude Include="curl\lib\curl_md5.h" />
|
||||
<ClInclude Include="curl\lib\curl_memory.h" />
|
||||
<ClInclude Include="curl\lib\curl_memrchr.h" />
|
||||
<ClInclude Include="curl\lib\curl_multibyte.h" />
|
||||
<ClInclude Include="curl\lib\curl_ntlm_core.h" />
|
||||
<ClInclude Include="curl\lib\curl_ntlm_wb.h" />
|
||||
<ClInclude Include="curl\lib\curl_path.h" />
|
||||
<ClInclude Include="curl\lib\curl_printf.h" />
|
||||
<ClInclude Include="curl\lib\curl_range.h" />
|
||||
<ClInclude Include="curl\lib\curl_rtmp.h" />
|
||||
<ClInclude Include="curl\lib\curl_sasl.h" />
|
||||
<ClInclude Include="curl\lib\curl_sec.h" />
|
||||
<ClInclude Include="curl\lib\curl_setup.h" />
|
||||
<ClInclude Include="curl\lib\curl_setup_once.h" />
|
||||
<ClInclude Include="curl\lib\curl_sha256.h" />
|
||||
<ClInclude Include="curl\lib\curl_sspi.h" />
|
||||
<ClInclude Include="curl\lib\curl_threads.h" />
|
||||
<ClInclude Include="curl\lib\dict.h" />
|
||||
<ClInclude Include="curl\lib\doh.h" />
|
||||
<ClInclude Include="curl\lib\dotdot.h" />
|
||||
<ClInclude Include="curl\lib\dynbuf.h" />
|
||||
<ClInclude Include="curl\lib\easyif.h" />
|
||||
<ClInclude Include="curl\lib\escape.h" />
|
||||
<ClInclude Include="curl\lib\file.h" />
|
||||
<ClInclude Include="curl\lib\fileinfo.h" />
|
||||
<ClInclude Include="curl\lib\formdata.h" />
|
||||
<ClInclude Include="curl\lib\ftp.h" />
|
||||
<ClInclude Include="curl\lib\ftplistparser.h" />
|
||||
<ClInclude Include="curl\lib\getinfo.h" />
|
||||
<ClInclude Include="curl\lib\gopher.h" />
|
||||
<ClInclude Include="curl\lib\hash.h" />
|
||||
<ClInclude Include="curl\lib\hostcheck.h" />
|
||||
<ClInclude Include="curl\lib\hostip.h" />
|
||||
<ClInclude Include="curl\lib\http.h" />
|
||||
<ClInclude Include="curl\lib\http2.h" />
|
||||
<ClInclude Include="curl\lib\http_chunks.h" />
|
||||
<ClInclude Include="curl\lib\http_digest.h" />
|
||||
<ClInclude Include="curl\lib\http_negotiate.h" />
|
||||
<ClInclude Include="curl\lib\http_ntlm.h" />
|
||||
<ClInclude Include="curl\lib\http_proxy.h" />
|
||||
<ClInclude Include="curl\lib\if2ip.h" />
|
||||
<ClInclude Include="curl\lib\imap.h" />
|
||||
<ClInclude Include="curl\lib\inet_ntop.h" />
|
||||
<ClInclude Include="curl\lib\inet_pton.h" />
|
||||
<ClInclude Include="curl\lib\llist.h" />
|
||||
<ClInclude Include="curl\lib\memdebug.h" />
|
||||
<ClInclude Include="curl\lib\mime.h" />
|
||||
<ClInclude Include="curl\lib\mqtt.h" />
|
||||
<ClInclude Include="curl\lib\multihandle.h" />
|
||||
<ClInclude Include="curl\lib\multiif.h" />
|
||||
<ClInclude Include="curl\lib\netrc.h" />
|
||||
<ClInclude Include="curl\lib\non-ascii.h" />
|
||||
<ClInclude Include="curl\lib\nonblock.h" />
|
||||
<ClInclude Include="curl\lib\parsedate.h" />
|
||||
<ClInclude Include="curl\lib\pingpong.h" />
|
||||
<ClInclude Include="curl\lib\pop3.h" />
|
||||
<ClInclude Include="curl\lib\progress.h" />
|
||||
<ClInclude Include="curl\lib\psl.h" />
|
||||
<ClInclude Include="curl\lib\quic.h" />
|
||||
<ClInclude Include="curl\lib\rand.h" />
|
||||
<ClInclude Include="curl\lib\rename.h" />
|
||||
<ClInclude Include="curl\lib\rtsp.h" />
|
||||
<ClInclude Include="curl\lib\select.h" />
|
||||
<ClInclude Include="curl\lib\sendf.h" />
|
||||
<ClInclude Include="curl\lib\setopt.h" />
|
||||
<ClInclude Include="curl\lib\setup-os400.h" />
|
||||
<ClInclude Include="curl\lib\setup-vms.h" />
|
||||
<ClInclude Include="curl\lib\setup-win32.h" />
|
||||
<ClInclude Include="curl\lib\share.h" />
|
||||
<ClInclude Include="curl\lib\sigpipe.h" />
|
||||
<ClInclude Include="curl\lib\slist.h" />
|
||||
<ClInclude Include="curl\lib\smb.h" />
|
||||
<ClInclude Include="curl\lib\smtp.h" />
|
||||
<ClInclude Include="curl\lib\sockaddr.h" />
|
||||
<ClInclude Include="curl\lib\socketpair.h" />
|
||||
<ClInclude Include="curl\lib\socks.h" />
|
||||
<ClInclude Include="curl\lib\speedcheck.h" />
|
||||
<ClInclude Include="curl\lib\splay.h" />
|
||||
<ClInclude Include="curl\lib\strcase.h" />
|
||||
<ClInclude Include="curl\lib\strdup.h" />
|
||||
<ClInclude Include="curl\lib\strerror.h" />
|
||||
<ClInclude Include="curl\lib\strtok.h" />
|
||||
<ClInclude Include="curl\lib\strtoofft.h" />
|
||||
<ClInclude Include="curl\lib\system_win32.h" />
|
||||
<ClInclude Include="curl\lib\telnet.h" />
|
||||
<ClInclude Include="curl\lib\tftp.h" />
|
||||
<ClInclude Include="curl\lib\timeval.h" />
|
||||
<ClInclude Include="curl\lib\transfer.h" />
|
||||
<ClInclude Include="curl\lib\url.h" />
|
||||
<ClInclude Include="curl\lib\urlapi-int.h" />
|
||||
<ClInclude Include="curl\lib\urldata.h" />
|
||||
<ClInclude Include="curl\lib\version_win32.h" />
|
||||
<ClInclude Include="curl\lib\warnless.h" />
|
||||
<ClInclude Include="curl\lib\wildcard.h" />
|
||||
<ClInclude Include="curl\lib\x509asn1.h" />
|
||||
<ClInclude Include="curl\lib\vauth\digest.h" />
|
||||
<ClInclude Include="curl\lib\vauth\ntlm.h" />
|
||||
<ClInclude Include="curl\lib\vauth\vauth.h" />
|
||||
<ClInclude Include="curl\lib\vquic\ngtcp2.h" />
|
||||
<ClInclude Include="curl\lib\vquic\quiche.h" />
|
||||
<ClInclude Include="curl\lib\vquic\vquic.h" />
|
||||
<ClInclude Include="curl\lib\vssh\ssh.h" />
|
||||
<ClInclude Include="curl\lib\vssh\wolfssh.h" />
|
||||
<ClInclude Include="curl\lib\vtls\bearssl.h" />
|
||||
<ClInclude Include="curl\lib\vtls\gskit.h" />
|
||||
<ClInclude Include="curl\lib\vtls\gtls.h" />
|
||||
<ClInclude Include="curl\lib\vtls\keylog.h" />
|
||||
<ClInclude Include="curl\lib\vtls\mbedtls.h" />
|
||||
<ClInclude Include="curl\lib\vtls\mbedtls_threadlock.h" />
|
||||
<ClInclude Include="curl\lib\vtls\mesalink.h" />
|
||||
<ClInclude Include="curl\lib\vtls\nssg.h" />
|
||||
<ClInclude Include="curl\lib\vtls\openssl.h" />
|
||||
<ClInclude Include="curl\lib\vtls\schannel.h" />
|
||||
<ClInclude Include="curl\lib\vtls\sectransp.h" />
|
||||
<ClInclude Include="curl\lib\vtls\vtls.h" />
|
||||
<ClInclude Include="curl\lib\vtls\wolfssl.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="curl\lib\libcurl.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
Vendored
+911
@@ -0,0 +1,911 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hh;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files">
|
||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="curl\lib\altsvc.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\amigaos.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\asyn-ares.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\asyn-thread.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\base64.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\conncache.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\connect.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\content_encoding.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\cookie.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_addrinfo.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_ctype.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_des.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_endian.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_fnmatch.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_gethostname.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_get_line.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_gssapi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_memrchr.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_multibyte.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_ntlm_core.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_ntlm_wb.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_path.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_range.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_rtmp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_sasl.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\curl_threads.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\dict.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\doh.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\dotdot.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\easy.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\escape.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\file.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\fileinfo.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\formdata.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\ftp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\ftplistparser.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\getenv.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\getinfo.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\gopher.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hash.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hmac.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostasyn.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostcheck.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostip.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostip4.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostip6.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\hostsyn.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http2.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http_chunks.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http_digest.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http_negotiate.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http_ntlm.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\http_proxy.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\idn_win32.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\if2ip.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\imap.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\inet_ntop.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\inet_pton.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\krb5.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\ldap.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\llist.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\md4.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\md5.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\memdebug.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\mime.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\mprintf.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\multi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\netrc.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\non-ascii.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\nonblock.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\nwlib.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\nwos.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\openldap.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\parsedate.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\pingpong.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\pop3.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\progress.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\psl.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\rand.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\rename.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\rtsp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\security.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\select.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\sendf.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\setopt.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\sha256.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\share.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\slist.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\smb.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\smtp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\socketpair.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\socks.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\socks_gssapi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\socks_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\speedcheck.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\splay.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\strcase.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\strdup.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\strerror.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\strtok.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\strtoofft.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\system_win32.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\telnet.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\tftp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\timeval.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\transfer.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\url.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\urlapi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\version.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\warnless.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\wildcard.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\x509asn1.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\cleartext.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\cram.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\digest.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\digest_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\krb5_gssapi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\krb5_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\ntlm.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\ntlm_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\oauth2.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\spnego_gssapi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\spnego_sspi.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vauth\vauth.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vquic\ngtcp2.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vquic\quiche.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vssh\libssh.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vssh\libssh2.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vssh\wolfssh.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\bearssl.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\gskit.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\gtls.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\mbedtls.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\mbedtls_threadlock.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\mesalink.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\nss.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\openssl.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\schannel.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\schannel_verify.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\sectransp.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\vtls.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="curl\lib\vtls\wolfssl.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="curl\include\curl\curl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\curlver.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\easy.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\mprintf.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\multi.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\stdcheaders.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\system.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\typecheck-gcc.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\include\curl\urlapi.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\altsvc.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\amigaos.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\arpa_telnet.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\asyn.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-amigaos.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-dos.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-mac.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-os400.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-plan9.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-riscos.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-symbian.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-tpf.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-vxworks.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-win32.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\config-win32ce.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\conncache.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\connect.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\content_encoding.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\cookie.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curlx.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_addrinfo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_base64.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_ctype.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_des.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_endian.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_fnmatch.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_gethostname.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_get_line.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_gssapi.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_hmac.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_ldap.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_md4.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_md5.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_memory.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_memrchr.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_multibyte.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_ntlm_core.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_ntlm_wb.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_path.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_printf.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_range.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_rtmp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_sasl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_sec.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_setup.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_setup_once.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_sha256.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_sspi.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\curl_threads.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\dict.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\doh.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\dotdot.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\easyif.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\escape.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\file.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\fileinfo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\formdata.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\ftp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\ftplistparser.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\getinfo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\gopher.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\hash.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\hostcheck.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\hostip.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http2.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http_chunks.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http_digest.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http_negotiate.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http_ntlm.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\http_proxy.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\if2ip.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\imap.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\inet_ntop.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\inet_pton.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\llist.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\memdebug.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\mime.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\multihandle.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\multiif.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\netrc.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\non-ascii.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\nonblock.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\parsedate.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\pingpong.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\pop3.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\progress.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\psl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\quic.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\rand.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\rename.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\rtsp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\select.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\sendf.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\setopt.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\setup-os400.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\setup-vms.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\share.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\sigpipe.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\slist.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\smb.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\smtp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\sockaddr.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\socketpair.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\socks.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\speedcheck.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\splay.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\strcase.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\strdup.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\strerror.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\strtok.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\strtoofft.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\system_win32.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\telnet.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\tftp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\timeval.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\transfer.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\url.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\urlapi-int.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\urldata.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\warnless.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\wildcard.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\x509asn1.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vauth\digest.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vauth\ntlm.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vauth\vauth.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vquic\ngtcp2.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vquic\quiche.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vssh\ssh.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vssh\wolfssh.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\bearssl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\gskit.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\gtls.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\mbedtls.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\mbedtls_threadlock.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\mesalink.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\nssg.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\openssl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\schannel.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\sectransp.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\vtls.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="curl\lib\vtls\wolfssl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="curl\lib\libcurl.rc">
|
||||
<Filter>Resource Files</Filter>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
Vendored
+4
-1
@@ -28,6 +28,9 @@
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|x64'" Label="PropertySheets">
|
||||
@@ -97,7 +100,7 @@
|
||||
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
|
||||
<Optimization>Full</Optimization>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
|
||||
Vendored
+1
-1
Submodule 3rdparty/libusb updated: 7cfa00e9d7...c33990a300
Vendored
+25
@@ -0,0 +1,25 @@
|
||||
cmake_minimum_required(VERSION 2.8.4)
|
||||
|
||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules")
|
||||
|
||||
set(LIBUSB_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../libusb/)
|
||||
|
||||
project(libusb)
|
||||
|
||||
option(WITH_DEBUG_LOG "enable debug logging" OFF)
|
||||
# if debug logging is enabled, by default enable logging
|
||||
option(WITH_LOGGING "if false, disable all logging" ON)
|
||||
option(WITHOUT_PTHREADS "force pthreads to not be used. if on, then they are used based on detection logic" OFF)
|
||||
|
||||
set(LIBUSB_MAJOR 1)
|
||||
set(LIBUSB_MINOR 0)
|
||||
set(LIBUSB_MICRO 23)
|
||||
|
||||
macro(append_compiler_flags)
|
||||
foreach(FLAG IN ITEMS ${ARGN})
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${FLAG}")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAG}")
|
||||
endforeach()
|
||||
endmacro()
|
||||
|
||||
include(libusb.cmake)
|
||||
@@ -0,0 +1,17 @@
|
||||
# CoreFoundation_INCLUDE_DIR
|
||||
# CoreFoundation_LIBRARIES
|
||||
# CoreFoundation_FOUND
|
||||
include(LibFindMacros)
|
||||
|
||||
find_path(CoreFoundation_INCLUDE_DIR
|
||||
CoreFoundation.h
|
||||
PATH_SUFFIXES CoreFoundation
|
||||
)
|
||||
|
||||
find_library(CoreFoundation_LIBRARY
|
||||
NAMES CoreFoundation
|
||||
)
|
||||
|
||||
set(CoreFoundation_PROCESS_INCLUDES CoreFoundation_INCLUDE_DIR)
|
||||
set(CoreFoundation_PROCESS_LIBS CoreFoundation_LIBRARY)
|
||||
libfind_process(CoreFoundation)
|
||||
@@ -0,0 +1,20 @@
|
||||
# IOKit_INCLUDE_DIR
|
||||
# IOKit_LIBRARIES
|
||||
# IOKit_FOUND
|
||||
include(LibFindMacros)
|
||||
|
||||
# IOKit depends on CoreFoundation
|
||||
find_package(CoreFoundation REQUIRED)
|
||||
|
||||
find_path(IOKit_INCLUDE_DIR
|
||||
IOKitLib.h
|
||||
PATH_SUFFIXES IOKit
|
||||
)
|
||||
|
||||
find_library(IOKit_LIBRARY
|
||||
NAMES IOKit
|
||||
)
|
||||
|
||||
set(IOKit_PROCESS_INCLUDES IOKit_INCLUDE_DIR CoreFoundation_INCLUDE_DIR)
|
||||
set(IOKit_PROCESS_LIBS IOKit_LIBRARY CoreFoundation_LIBRARIES)
|
||||
libfind_process(IOKit)
|
||||
@@ -0,0 +1,99 @@
|
||||
# Works the same as find_package, but forwards the "REQUIRED" and "QUIET" arguments
|
||||
# used for the current package. For this to work, the first parameter must be the
|
||||
# prefix of the current package, then the prefix of the new package etc, which are
|
||||
# passed to find_package.
|
||||
macro (libfind_package PREFIX)
|
||||
set (LIBFIND_PACKAGE_ARGS ${ARGN})
|
||||
if (${PREFIX}_FIND_QUIETLY)
|
||||
set (LIBFIND_PACKAGE_ARGS ${LIBFIND_PACKAGE_ARGS} QUIET)
|
||||
endif (${PREFIX}_FIND_QUIETLY)
|
||||
if (${PREFIX}_FIND_REQUIRED)
|
||||
set (LIBFIND_PACKAGE_ARGS ${LIBFIND_PACKAGE_ARGS} REQUIRED)
|
||||
endif (${PREFIX}_FIND_REQUIRED)
|
||||
find_package(${LIBFIND_PACKAGE_ARGS})
|
||||
endmacro (libfind_package)
|
||||
|
||||
# CMake developers made the UsePkgConfig system deprecated in the same release (2.6)
|
||||
# where they added pkg_check_modules. Consequently I need to support both in my scripts
|
||||
# to avoid those deprecated warnings. Here's a helper that does just that.
|
||||
# Works identically to pkg_check_modules, except that no checks are needed prior to use.
|
||||
macro (libfind_pkg_check_modules PREFIX PKGNAME)
|
||||
if (${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} EQUAL 4)
|
||||
include(UsePkgConfig)
|
||||
pkgconfig(${PKGNAME} ${PREFIX}_INCLUDE_DIRS ${PREFIX}_LIBRARY_DIRS ${PREFIX}_LDFLAGS ${PREFIX}_CFLAGS)
|
||||
else (${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} EQUAL 4)
|
||||
find_package(PkgConfig)
|
||||
if (PKG_CONFIG_FOUND)
|
||||
pkg_check_modules(${PREFIX} ${PKGNAME})
|
||||
endif (PKG_CONFIG_FOUND)
|
||||
endif (${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} EQUAL 4)
|
||||
endmacro (libfind_pkg_check_modules)
|
||||
|
||||
# Do the final processing once the paths have been detected.
|
||||
# If include dirs are needed, ${PREFIX}_PROCESS_INCLUDES should be set to contain
|
||||
# all the variables, each of which contain one include directory.
|
||||
# Ditto for ${PREFIX}_PROCESS_LIBS and library files.
|
||||
# Will set ${PREFIX}_FOUND, ${PREFIX}_INCLUDE_DIRS and ${PREFIX}_LIBRARIES.
|
||||
# Also handles errors in case library detection was required, etc.
|
||||
macro (libfind_process PREFIX)
|
||||
# Skip processing if already processed during this run
|
||||
if (NOT ${PREFIX}_FOUND)
|
||||
# Start with the assumption that the library was found
|
||||
set (${PREFIX}_FOUND TRUE)
|
||||
|
||||
# Process all includes and set _FOUND to false if any are missing
|
||||
foreach (i ${${PREFIX}_PROCESS_INCLUDES})
|
||||
if (${i})
|
||||
set (${PREFIX}_INCLUDE_DIRS ${${PREFIX}_INCLUDE_DIRS} ${${i}})
|
||||
mark_as_advanced(${i})
|
||||
else (${i})
|
||||
set (${PREFIX}_FOUND FALSE)
|
||||
endif (${i})
|
||||
endforeach (i)
|
||||
|
||||
# Process all libraries and set _FOUND to false if any are missing
|
||||
foreach (i ${${PREFIX}_PROCESS_LIBS})
|
||||
if (${i})
|
||||
set (${PREFIX}_LIBRARIES ${${PREFIX}_LIBRARIES} ${${i}})
|
||||
mark_as_advanced(${i})
|
||||
else (${i})
|
||||
set (${PREFIX}_FOUND FALSE)
|
||||
endif (${i})
|
||||
endforeach (i)
|
||||
|
||||
# Print message and/or exit on fatal error
|
||||
if (${PREFIX}_FOUND)
|
||||
if (NOT ${PREFIX}_FIND_QUIETLY)
|
||||
message (STATUS "Found ${PREFIX} ${${PREFIX}_VERSION}")
|
||||
endif (NOT ${PREFIX}_FIND_QUIETLY)
|
||||
else (${PREFIX}_FOUND)
|
||||
if (${PREFIX}_FIND_REQUIRED)
|
||||
foreach (i ${${PREFIX}_PROCESS_INCLUDES} ${${PREFIX}_PROCESS_LIBS})
|
||||
message("${i}=${${i}}")
|
||||
endforeach (i)
|
||||
message (FATAL_ERROR "Required library ${PREFIX} NOT FOUND.\nInstall the library (dev version) and try again. If the library is already installed, use ccmake to set the missing variables manually.")
|
||||
endif (${PREFIX}_FIND_REQUIRED)
|
||||
endif (${PREFIX}_FOUND)
|
||||
endif (NOT ${PREFIX}_FOUND)
|
||||
endmacro (libfind_process)
|
||||
|
||||
macro(libfind_library PREFIX basename)
|
||||
set(TMP "")
|
||||
if(MSVC80)
|
||||
set(TMP -vc80)
|
||||
endif(MSVC80)
|
||||
if(MSVC90)
|
||||
set(TMP -vc90)
|
||||
endif(MSVC90)
|
||||
set(${PREFIX}_LIBNAMES ${basename}${TMP})
|
||||
if(${ARGC} GREATER 2)
|
||||
set(${PREFIX}_LIBNAMES ${basename}${TMP}-${ARGV2})
|
||||
string(REGEX REPLACE "\\." "_" TMP ${${PREFIX}_LIBNAMES})
|
||||
set(${PREFIX}_LIBNAMES ${${PREFIX}_LIBNAMES} ${TMP})
|
||||
endif(${ARGC} GREATER 2)
|
||||
find_library(${PREFIX}_LIBRARY
|
||||
NAMES ${${PREFIX}_LIBNAMES}
|
||||
PATHS ${${PREFIX}_PKGCONF_LIBRARY_DIRS}
|
||||
)
|
||||
endmacro(libfind_library)
|
||||
|
||||
Vendored
+96
@@ -0,0 +1,96 @@
|
||||
include(CheckCXXCompilerFlag)
|
||||
include(CheckIncludeFiles)
|
||||
include(CheckTypeSize)
|
||||
|
||||
if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
|
||||
if (NOT OS_WINDOWS)
|
||||
# mingw appears to print a bunch of warnings about this
|
||||
check_cxx_compiler_flag("-fvisibility=hidden" HAVE_VISIBILITY)
|
||||
endif()
|
||||
check_cxx_compiler_flag("-Wno-pointer-sign" HAVE_WARN_NO_POINTER_SIGN)
|
||||
|
||||
set(_GNU_SOURCE 1 CACHE INTERNAL "" FORCE)
|
||||
|
||||
unset(ADDITIONAL_CC_FLAGS)
|
||||
|
||||
if (HAVE_VISIBILITY)
|
||||
list(APPEND ADDITIONAL_CC_FLAGS -fvisibility=hidden)
|
||||
endif()
|
||||
|
||||
if (HAVE_WARN_NO_POINTER_SIGN)
|
||||
list(APPEND ADDITIONAL_CC_FLAGS -Wno-pointer-sign)
|
||||
endif()
|
||||
|
||||
append_compiler_flags(
|
||||
-std=gnu99
|
||||
-Wall
|
||||
-Wundef
|
||||
-Wunused
|
||||
-Wstrict-prototypes
|
||||
-Werror-implicit-function-declaration
|
||||
-Wshadow
|
||||
${ADDITIONAL_CC_FLAGS}
|
||||
)
|
||||
elseif(MSVC)
|
||||
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
|
||||
endif()
|
||||
|
||||
check_include_files(sys/timerfd.h USBI_TIMERFD_AVAILABLE)
|
||||
#check_type_size(struct timespec STRUCT_TIMESPEC)
|
||||
|
||||
if (HAVE_VISIBILITY)
|
||||
set(DEFAULT_VISIBILITY "__attribute__((visibility(\"default\")))" CACHE INTERNAL "visibility attribute to function decl" FORCE)
|
||||
else()
|
||||
set(DEFAULT_VISIBILITY "" CACHE INTERNAL "visibility attribute to function decl" FORCE)
|
||||
endif()
|
||||
|
||||
if (NOT WITHOUT_POLL_H)
|
||||
check_include_files(poll.h HAVE_POLL_H)
|
||||
else()
|
||||
set(HAVE_POLL_H FALSE CACHE INTERNAL "poll.h explicitely disabled" FORCE)
|
||||
endif()
|
||||
|
||||
if (HAVE_POLL_H)
|
||||
list(APPEND CMAKE_EXTRA_INCLUDE_FILES "poll.h")
|
||||
check_type_size(nfds_t NFDS_T)
|
||||
unset(CMAKE_EXTRA_INCLUDE_FILES)
|
||||
else()
|
||||
set(HAVE_NFDS_T FALSE CACHE INTERNAL "poll.h not found - assuming no nfds_t (windows)" FORCE)
|
||||
set(NFDS_T "" CACHE INTERNAL "" FORCE)
|
||||
endif()
|
||||
|
||||
if (HAVE_NFDS_T)
|
||||
set(POLL_NFDS_TYPE nfds_t CACHE INTERNAL "the poll nfds types for this platform" FORCE)
|
||||
else()
|
||||
set(POLL_NFDS_TYPE "unsigned int" CACHE INTERNAL "the poll nfds for this platform" FORCE)
|
||||
endif()
|
||||
|
||||
if (OS_WINDOWS)
|
||||
macro(copy_header_if_missing HEADER VARIABLE ALTERNATIVE_DIR)
|
||||
check_include_files(${HEADER} ${VARIABLE})
|
||||
if (NOT ${VARIABLE})
|
||||
message(STATUS "Missing ${HEADER} - grabbing from ${ALTERNATIVE_DIR}")
|
||||
file(COPY "${ALTERNATIVE_DIR}/${HEADER}" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
# Only VS 2010 has stdint.h
|
||||
copy_header_if_missing(stdint.h HAVE_STDINT_H ../msvc)
|
||||
copy_header_if_missing(inttypes.h HAVE_INTTYPES_H ../msvc)
|
||||
endif()
|
||||
|
||||
set(ENABLE_DEBUG_LOGGING ${WITH_DEBUG_LOG} CACHE INTERNAL "enable debug logging (WITH_DEBUG_LOGGING)" FORCE)
|
||||
set(ENABLE_LOGGING ${WITH_LOGGING} CACHE INTERNAL "enable logging (WITH_LOGGING)" FORCE)
|
||||
set(PACKAGE "libusb" CACHE INTERNAL "The package name" FORCE)
|
||||
set(PACKAGE_BUGREPORT "libusb-devel@lists.sourceforge.net" CACHE INTERNAL "Where to send bug reports" FORCE)
|
||||
set(PACKAGE_VERSION "${LIBUSB_MAJOR}.${LIBUSB_MINOR}.${LIBUSB_MICRO}" CACHE INTERNAL "package version" FORCE)
|
||||
set(PACKAGE_STRING "${PACKAGE} ${PACKAGE_VERSION}" CACHE INTERNAL "package string" FORCE)
|
||||
set(PACKAGE_URL "http://www.libusb.org" CACHE INTERNAL "package url" FORCE)
|
||||
set(PACKAGE_TARNAME "libusb" CACHE INTERNAL "tarball name" FORCE)
|
||||
set(VERSION "${PACKAGE_VERSION}" CACHE INTERNAL "version" FORCE)
|
||||
|
||||
configure_file(config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h @ONLY)
|
||||
message(STATUS "Generated configuration file in ${CMAKE_CURRENT_BINARY_DIR}/config.h")
|
||||
|
||||
# for generated config.h
|
||||
include_directories(${CMAKE_CURRENT_BINARY_DIR})
|
||||
Vendored
+37
@@ -0,0 +1,37 @@
|
||||
#ifndef LIBUSB_CONFIG_H
|
||||
#define LIBUSB_CONFIG_H
|
||||
|
||||
#define DEFAULT_VISIBILITY @DEFAULT_VISIBILITY@
|
||||
|
||||
#cmakedefine ENABLE_DEBUG_LOGGING
|
||||
|
||||
#cmakedefine ENABLE_LOGGING
|
||||
|
||||
#define LIBUSB_MAJOR @LIBUSB_MAJOR@
|
||||
|
||||
#define LIBUSB_MINOR @LIBUSB_MINOR@
|
||||
|
||||
#define LIBUSB_MICRO @LIBUSB_MINOR@
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
|
||||
#define PACKAGE @PACKAGE@
|
||||
#define PACKAGE_BUGREPORT @PACKAGE_BUGREPORT@
|
||||
#define PACKAGE_STRING @PACKAGE_STRING@
|
||||
#define PACKAGE_URL @PACKAGE_URL@
|
||||
#define PACKAGE_VERSION @PACKAGE_VERSION@
|
||||
#define PACKAGE_TARNAME @PACKAGE_TARNAME@
|
||||
|
||||
#define VERSION @VERSION@
|
||||
|
||||
#cmakedefine OS_LINUX
|
||||
#cmakedefine OS_DARWIN
|
||||
#cmakedefine OS_WINDOWS
|
||||
#cmakedefine THREADS_POSIX
|
||||
#cmakedefine USBI_TIMERFD_AVAILABLE
|
||||
#cmakedefine HAVE_STRUCT_TIMESPEC
|
||||
#cmakedefine HAVE_POLL_H
|
||||
#cmakedefine HAVE_SYS_TIME_H
|
||||
#define POLL_NFDS_TYPE @POLL_NFDS_TYPE@
|
||||
|
||||
#endif /* LIBUSB_CONFIG_H */
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
prefix=@CMAKE_INSTALL_PREFIX@
|
||||
libdir=@CMAKE_INSTALL_PREFIX@/lib@
|
||||
includedir=@CMAKE_INSTALL_PREFIX@/include@
|
||||
|
||||
Name: libusb-1.0
|
||||
Description: C API for USB device access from Linux, Mac OS X and Windows userspace
|
||||
Version: @VERSION@
|
||||
Libs: -L${libdir} -lusb-1.0
|
||||
Libs.private: @LIBUSB_LIB_DEPENDS@
|
||||
Cflags: -I${includedir}/libusb-1.0
|
||||
|
||||
Vendored
+76
@@ -0,0 +1,76 @@
|
||||
include(os.cmake)
|
||||
|
||||
include(config.cmake)
|
||||
include(FindThreads)
|
||||
|
||||
set (LIBUSB_COMMON
|
||||
core.c
|
||||
descriptor.c
|
||||
io.c
|
||||
sync.c
|
||||
hotplug.c
|
||||
strerror.c
|
||||
libusb-1.0.rc
|
||||
libusb-1.0.def
|
||||
)
|
||||
|
||||
foreach(SRC IN LISTS LIBUSB_COMMON)
|
||||
list(APPEND LIBUSB_COMMON_FINAL ${LIBUSB_SOURCE_DIR}/libusb/${SRC})
|
||||
endforeach()
|
||||
|
||||
|
||||
include_directories(${LIBUSB_SOURCE_DIR}/libusb)
|
||||
include_directories(${LIBUSB_SOURCE_DIR}/libusb/os)
|
||||
|
||||
if (CMAKE_THREAD_LIBS_INIT)
|
||||
list(APPEND LIBUSB_LIBRARIES ${CMAKE_THREAD_LIBS_INIT})
|
||||
endif()
|
||||
|
||||
add_library(usb-1.0-static
|
||||
STATIC
|
||||
${LIBUSB_COMMON_FINAL}
|
||||
${LIBUSB_PLATFORM}
|
||||
)
|
||||
|
||||
target_include_directories(usb-1.0-static PUBLIC $<BUILD_INTERFACE:${LIBUSB_SOURCE_DIR}/libusb>)
|
||||
|
||||
set_target_properties(usb-1.0-static PROPERTIES
|
||||
PREFIX "lib"
|
||||
OUTPUT_NAME "usb-1.0"
|
||||
CLEAN_DIRECT_OUTPUT 1
|
||||
PUBLIC_HEADER libusb.h
|
||||
VERSION "${LIBUSB_MAJOR}.${LIBUSB_MINOR}.${LIBUSB_MICRO}"
|
||||
SOVERSION "${LIBUSB_MAJOR}.${LIBUSB_MINOR}.${LIBUSB_MICRO}"
|
||||
)
|
||||
|
||||
if (DEFINED LIBUSB_LIBRARIES)
|
||||
target_link_libraries(usb-1.0-static
|
||||
${LIBUSB_LIBRARIES}
|
||||
)
|
||||
endif()
|
||||
|
||||
list(APPEND LIBUSB_LIBTARGETS usb-1.0-static)
|
||||
|
||||
install(TARGETS ${LIBUSB_LIBTARGETS} EXPORT libusb-1
|
||||
PUBLIC_HEADER DESTINATION include/libusb-1.0
|
||||
ARCHIVE DESTINATION lib
|
||||
LIBRARY DESTINATION lib
|
||||
RUNTIME DESTINATION lib
|
||||
)
|
||||
install(EXPORT libusb-1 DESTINATION lib/libusb)
|
||||
|
||||
foreach(LIB IN LISTS LIBUSB_LIBRARIES)
|
||||
if (LIB MATCHES .framework$)
|
||||
get_filename_component(LIB "${LIB}" NAME)
|
||||
set(LIB "-Wl,-framework,${LIB}")
|
||||
elseif (LIB MATCHES .dylib$)
|
||||
get_filename_component(LIBDIR "${LIB}" PATH)
|
||||
get_filename_component(LIB "${LIB}" NAME)
|
||||
string(REGEX REPLACE "lib(.*).dylib$" "\\1" LIB "${LIB}")
|
||||
set(LIB "-L${LIBDIR} -l${LIB}")
|
||||
endif()
|
||||
set(LIBUSB_LIB_DEPENDS "${LIBUSB_LIB_DEPENDS} ${LIB}")
|
||||
endforeach()
|
||||
|
||||
configure_file(libusb-1.0.pc.cmake "${CMAKE_CURRENT_BINARY_DIR}/libusb-1.0.pc" @ONLY)
|
||||
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/libusb-1.0.pc" DESTINATION lib/pkgconfig)
|
||||
Vendored
+110
@@ -0,0 +1,110 @@
|
||||
include(FindThreads)
|
||||
|
||||
set(PTHREADS_ENABLED FALSE)
|
||||
if (CMAKE_USE_PTHREADS_INIT)
|
||||
set(PTHREADS_ENABLED TRUE)
|
||||
endif()
|
||||
|
||||
if (WIN32 OR "${CMAKE_SYSTEM_NAME}" STREQUAL "CYGWIN")
|
||||
add_compile_definitions(PLATFORM_WINDOWS=1)
|
||||
set(OS_WINDOWS 1 CACHE INTERNAL "controls config.h macro definition" FORCE)
|
||||
|
||||
# Enable MingW support for RC language (for CMake pre-2.8)
|
||||
if (MINGW)
|
||||
set(CMAKE_RC_COMPILER_INIT windres)
|
||||
set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> <FLAGS> -O coff <DEFINES> -i <SOURCE> -o <OBJECT>")
|
||||
endif()
|
||||
enable_language(RC)
|
||||
|
||||
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "CYGWIN")
|
||||
message(STATUS "Detected cygwin")
|
||||
set(PTHREADS_ENABLED TRUE)
|
||||
set(WITHOUT_POLL_H TRUE CACHE INTERNAL "Disable using poll.h even if it's available - use windows poll instead fo cygwin's" FORCE)
|
||||
endif()
|
||||
|
||||
list(APPEND PLATFORM_SRC
|
||||
events_windows.c
|
||||
windows_usbdk.c
|
||||
windows_common.c
|
||||
windows_winusb.c
|
||||
threads_windows.c
|
||||
)
|
||||
|
||||
if (PTHREADS_ENABLED AND NOT WITHOUT_PTHREADS)
|
||||
list(APPEND PLATFORM_SRC threads_posix)
|
||||
else()
|
||||
list(APPEND PLATFORM_SRC threads_windows.c)
|
||||
endif()
|
||||
elseif (APPLE)
|
||||
# Apple != OSX alone
|
||||
add_compile_definitions(PLATFORM_POSIX=1 HAVE_CLOCK_GETTIME)
|
||||
set(OS_DARWIN 1 CACHE INTERNAL "controls config.h macro definition" FORCE)
|
||||
|
||||
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Darwin")
|
||||
set(PLATFORM_SRC
|
||||
darwin_usb.c
|
||||
threads_posix.c
|
||||
events_posix.c
|
||||
)
|
||||
|
||||
find_package(IOKit REQUIRED)
|
||||
list(APPEND LIBUSB_LIBRARIES ${IOKit_LIBRARIES})
|
||||
|
||||
# Currently only objc_registerThreadWithCollector requires linking against it
|
||||
# which is only for MAC_OS_X_VERSION_MIN_REQUIRED >= 1060
|
||||
include(CheckCSourceCompiles)
|
||||
check_c_source_compiles(
|
||||
"#include <AvailabilityMacros.h>
|
||||
int main()
|
||||
{
|
||||
#if !(MAC_OS_X_VERSION_MIN_REQUIRED >= 1060)
|
||||
#error \"Don't need objc\"
|
||||
#endif
|
||||
}
|
||||
" NEED_OBJC_REGISTER_THREAD_WITH_COLLECTOR)
|
||||
|
||||
if (NEED_OBJC_REGISTER_THREAD_WITH_COLLECTOR)
|
||||
find_library(LIBOBJC objc)
|
||||
if (NOT LIBOBJC)
|
||||
message(SEND_ERROR "Need objc library but can't find it")
|
||||
else()
|
||||
list(APPEND LIBUSB_LIBRARIES ${LIBOBJC})
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
elseif (UNIX)
|
||||
# Unix is for all *NIX systems including OSX
|
||||
add_compile_definitions(PLATFORM_POSIX=1 HAVE_CLOCK_GETTIME)
|
||||
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")
|
||||
set(OS_LINUX 1 CACHE INTERNAL "controls config.h macro definition" FORCE)
|
||||
|
||||
set(PLATFORM_SRC
|
||||
linux_usbfs.c
|
||||
linux_netlink.c
|
||||
threads_posix.c
|
||||
events_posix.c
|
||||
)
|
||||
|
||||
list(APPEND LIBUSB_LIBRARIES rt)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if (NOT PLATFORM_SRC)
|
||||
message(FATAL_ERROR "Unsupported platform ${CMAKE_SYSTEM_NAME}. Currently only support Windows, OSX, & Linux.")
|
||||
endif()
|
||||
|
||||
# the paths are relative to this directory but used in the parent directory,
|
||||
# so we have to adjust the paths
|
||||
foreach(SRC IN LISTS PLATFORM_SRC)
|
||||
list(APPEND LIBUSB_PLATFORM ${LIBUSB_SOURCE_DIR}/libusb/os/${SRC})
|
||||
endforeach()
|
||||
|
||||
# export one level up so that the generic
|
||||
# libusb parts know what the platform bits are supposed to be
|
||||
set(LIBUSB_PLATFORM ${LIBUSB_PLATFORM} PARENT_SCOPE)
|
||||
set(LIBUSB_LIBRARIES ${LIBUSB_LIBRARIES} PARENT_SCOPE)
|
||||
|
||||
if (WITHOUT_PTHREADS)
|
||||
set(PTHREADS_ENABLED FALSE)
|
||||
endif()
|
||||
set(THREADS_POSIX ${PTHREADS_ENABLED} CACHE INTERNAL "use pthreads" FORCE)
|
||||
Vendored
+8
-6
@@ -24,6 +24,9 @@
|
||||
<WholeProgramOptimization Condition="'$(Configuration)'=='Release'">true</WholeProgramOptimization>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets">
|
||||
@@ -38,8 +41,9 @@
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<AdditionalOptions>/utf-8 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalIncludeDirectories>libusb\msvc;libusb\libusb;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WINVER=0x0501;_WIN32_WINNT=0x0501;_LIB;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>WINVER=0x0600;_WIN32_WINNT=0x0600;_LIB;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
</ClCompile>
|
||||
@@ -61,11 +65,11 @@
|
||||
<ClCompile Include="libusb\libusb\descriptor.c" />
|
||||
<ClCompile Include="libusb\libusb\hotplug.c" />
|
||||
<ClCompile Include="libusb\libusb\io.c" />
|
||||
<ClCompile Include="libusb\libusb\os\poll_windows.c" />
|
||||
<ClCompile Include="libusb\libusb\os\events_windows.c" />
|
||||
<ClCompile Include="libusb\libusb\strerror.c" />
|
||||
<ClCompile Include="libusb\libusb\sync.c" />
|
||||
<ClCompile Include="libusb\libusb\os\threads_windows.c" />
|
||||
<ClCompile Include="libusb\libusb\os\windows_nt_common.c" />
|
||||
<ClCompile Include="libusb\libusb\os\windows_common.c" />
|
||||
<ClCompile Include="libusb\libusb\os\windows_usbdk.c" />
|
||||
<ClCompile Include="libusb\libusb\os\windows_winusb.c" />
|
||||
</ItemGroup>
|
||||
@@ -74,13 +78,11 @@
|
||||
<ClInclude Include="libusb\libusb\hotplug.h" />
|
||||
<ClInclude Include="libusb\libusb\libusb.h" />
|
||||
<ClInclude Include="libusb\libusb\libusbi.h" />
|
||||
<ClInclude Include="libusb\libusb\os\poll_windows.h" />
|
||||
<ClInclude Include="libusb\libusb\os\events_windows.h" />
|
||||
<ClInclude Include="libusb\libusb\os\threads_windows.h" />
|
||||
<ClInclude Include="libusb\libusb\version.h" />
|
||||
<ClInclude Include="libusb\libusb\version_nano.h" />
|
||||
<ClInclude Include="libusb\libusb\os\windows_common.h" />
|
||||
<ClInclude Include="libusb\libusb\os\windows_nt_common.h" />
|
||||
<ClInclude Include="libusb\libusb\os\windows_nt_shared_types.h" />
|
||||
<ClInclude Include="libusb\libusb\os\windows_usbdk.h" />
|
||||
<ClInclude Include="libusb\libusb\os\windows_winusb.h" />
|
||||
</ItemGroup>
|
||||
|
||||
Vendored
+5
-6
@@ -11,8 +11,7 @@ if(WITH_LLVM)
|
||||
option(LLVM_INCLUDE_TESTS OFF)
|
||||
option(LLVM_INCLUDE_TOOLS OFF)
|
||||
option(LLVM_INCLUDE_UTILS OFF)
|
||||
option(WITH_POLLY OFF)
|
||||
option(LLVM_ENABLE_CXX1Z TRUE)
|
||||
option(LLVM_CCACHE_BUILD ON)
|
||||
|
||||
set(CXX_FLAGS_OLD ${CMAKE_CXX_FLAGS})
|
||||
|
||||
@@ -27,7 +26,7 @@ if(WITH_LLVM)
|
||||
set(CMAKE_CXX_FLAGS ${CXX_FLAGS_OLD})
|
||||
|
||||
# now tries to find LLVM again
|
||||
find_package(LLVM 10.0 CONFIG)
|
||||
find_package(LLVM 11.0 CONFIG)
|
||||
if(NOT LLVM_FOUND)
|
||||
message(FATAL_ERROR "Couldn't build LLVM from the submodule. You might need to run `git submodule update --init`")
|
||||
endif()
|
||||
@@ -40,11 +39,11 @@ if(WITH_LLVM)
|
||||
set(LLVM_DIR ${CMAKE_SOURCE_DIR}/${LLVM_DIR})
|
||||
endif()
|
||||
|
||||
find_package(LLVM 10.0 CONFIG)
|
||||
find_package(LLVM 11.0 CONFIG)
|
||||
|
||||
if (NOT LLVM_FOUND)
|
||||
if (LLVM_VERSION AND LLVM_VERSION_MAJOR LESS 9)
|
||||
message(FATAL_ERROR "Found LLVM version ${LLVM_VERSION}. Required version 9.0. \
|
||||
if (LLVM_VERSION AND LLVM_VERSION_MAJOR LESS 11)
|
||||
message(FATAL_ERROR "Found LLVM version ${LLVM_VERSION}. Required version 11.0. \
|
||||
Enable BUILD_LLVM_SUBMODULE option to build LLVM from included as a git submodule.")
|
||||
endif()
|
||||
|
||||
|
||||
Vendored
+3
@@ -21,6 +21,9 @@
|
||||
</PropertyGroup>
|
||||
<Import Project="$(SolutionDir)\3rdparty\zlib.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
|
||||
Vendored
+12
-14
@@ -1,31 +1,29 @@
|
||||
add_library(3rdparty_qt5 INTERFACE)
|
||||
|
||||
find_package(Qt5 5.11 CONFIG COMPONENTS Widgets Network Qml Concurrent)
|
||||
set(QT_MIN_VER 5.15.2)
|
||||
|
||||
find_package(Qt5 ${QT_MIN_VER} CONFIG COMPONENTS Widgets Concurrent)
|
||||
if(WIN32)
|
||||
find_package(Qt5 5.11 COMPONENTS WinExtras REQUIRED)
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::WinExtras Qt5::Network Qt5::Qml Qt5::Concurrent)
|
||||
find_package(Qt5 ${QT_MIN_VER} COMPONENTS WinExtras REQUIRED)
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::WinExtras Qt5::Concurrent)
|
||||
else()
|
||||
find_package(Qt5 5.11 COMPONENTS DBus Gui)
|
||||
find_package(Qt5 ${QT_MIN_VER} COMPONENTS DBus Gui)
|
||||
if(Qt5DBus_FOUND)
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::DBus Qt5::Network Qt5::Qml Qt5::Concurrent)
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::DBus Qt5::Concurrent)
|
||||
target_compile_definitions(3rdparty_qt5 INTERFACE -DHAVE_QTDBUS)
|
||||
else()
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::Network Qt5::Qml Qt5::Concurrent)
|
||||
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::Concurrent)
|
||||
endif()
|
||||
target_include_directories(3rdparty_qt5 INTERFACE ${Qt5Gui_PRIVATE_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
if(NOT Qt5Widgets_FOUND)
|
||||
if(Qt5Widgets_VERSION VERSION_LESS 5.11.0)
|
||||
message("Minimum supported Qt5 version is 5.11.0! You have version ${Qt5Widgets_VERSION} installed, please upgrade!")
|
||||
if(Qt5Widgets_VERSION VERSION_LESS ${QT_MIN_VER})
|
||||
message("Minimum supported Qt5 version is ${QT_MIN_VER}! You have version ${Qt5Widgets_VERSION} installed, please upgrade!")
|
||||
if(CMAKE_SYSTEM MATCHES "Linux")
|
||||
message(FATAL_ERROR "Most distros do not provide an up-to-date version of Qt.
|
||||
If you're on Ubuntu or Linux Mint, there are PPAs you can use to install one of the latest qt5 versions.
|
||||
https://launchpad.net/~beineri/+archive/ubuntu/opt-qt-5.11.0-bionic
|
||||
https://launchpad.net/~beineri/+archive/ubuntu/opt-qt-5.11.0-xenial
|
||||
just make sure to run
|
||||
source /opt/qt511/bin/qt511-env.sh
|
||||
before re-running cmake")
|
||||
Find the correct ppa at https://launchpad.net/~beineri and follow the instructions.")
|
||||
elseif(WIN32)
|
||||
message(FATAL_ERROR "You can download the latest version of Qt5 here: https://www.qt.io/download-open-source/")
|
||||
else()
|
||||
@@ -35,7 +33,7 @@ before re-running cmake")
|
||||
|
||||
message("CMake was unable to find Qt5!")
|
||||
if(WIN32)
|
||||
message(FATAL_ERROR "Make sure the QTDIR env variable has been set properly. (for example C:\\Qt\\5.11.1\\msvc2017_64\\)
|
||||
message(FATAL_ERROR "Make sure the QTDIR env variable has been set properly. (for example C:\\Qt\\${QT_MIN_VER}\\msvc2019_64\\)
|
||||
You can also try setting the Qt5_DIR preprocessor definiton.")
|
||||
elseif(CMAKE_SYSTEM MATCHES "Linux")
|
||||
message(FATAL_ERROR "Make sure to install your distro's qt5 package!")
|
||||
|
||||
+1
Submodule 3rdparty/wolfssl added at 39b5448601
Vendored
+165
@@ -0,0 +1,165 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{73973223-5EE8-41CA-8E88-1D60E89A237B}</ProjectGuid>
|
||||
<RootNamespace>wolfssl</RootNamespace>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
</PropertyGroup>
|
||||
<Import Project="..\common_default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="..\common_default_macros.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<OutDir>$(SolutionDir)lib\$(Configuration)-$(Platform)\</OutDir>
|
||||
<IntDir>$(SolutionDir)tmp\$(ProjectName)-$(Configuration)-$(Platform)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>./wolfssl;./wolfssl/IDE/WIN;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WOLFSSL_LIB;WOLFSSL_DES_ECB;HAVE_FFDHE_2048;TFM_TIMING_RESISTANT;ECC_TIMING_RESISTANT;WC_RSA_BLINDING;HAVE_AESGCM;WOLFSSL_SHA512;WOLFSSL_SHA384;NO_DSA;HAVE_ECC;TFM_ECC256;ECC_SHAMIR;NO_RC4;NO_HC128;NO_RABBIT;WOLFSSL_SHA224;WOLFSSL_SHA3;WOLFSSL_SHAKE256;HAVE_POLY1305;HAVE_ONE_TIME_AUTH;HAVE_CHACHA;HAVE_HASHDRBG;HAVE_TLS_EXTENSIONS;HAVE_SNI;HAVE_SUPPORTED_CURVES;HAVE_EXTENDED_MASTER;NO_RC4;HAVE_ENCRYPT_THEN_MAC;NO_PSK;NO_MD4;WC_NO_ASYNC_THREADING;OPENSSL_EXTRA;WOLFSSL_USER_SETTINGS;CYASSL_USER_SETTINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4206;4214;4706;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>./wolfssl;./wolfssl/IDE/WIN;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WOLFSSL_LIB;WOLFSSL_DES_ECB;HAVE_FFDHE_2048;TFM_TIMING_RESISTANT;NO_DSA;TFM_ECC256;NO_RC4;NO_HC128;NO_RABBIT;WOLFSSL_SHA224;WOLFSSL_SHA3;WOLFSSL_SHAKE256;HAVE_POLY1305;HAVE_ONE_TIME_AUTH;HAVE_CHACHA;HAVE_HASHDRBG;HAVE_SNI;HAVE_ENCRYPT_THEN_MAC;NO_MD4;WC_NO_ASYNC_THREADING;WOLFSSL_USER_SETTINGS;CYASSL_USER_SETTINGS;WC_NO_HARDEN;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="wolfssl\src\crl.c" />
|
||||
<ClCompile Include="wolfssl\src\internal.c" />
|
||||
<ClCompile Include="wolfssl\src\wolfio.c" />
|
||||
<ClCompile Include="wolfssl\src\keys.c" />
|
||||
<ClCompile Include="wolfssl\src\ocsp.c" />
|
||||
<ClCompile Include="wolfssl\src\ssl.c" />
|
||||
<ClCompile Include="wolfssl\src\tls.c" />
|
||||
<ClCompile Include="wolfssl\src\tls13.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\aes.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\arc4.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\asn.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\blake2b.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\blake2s.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\camellia.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\chacha.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\chacha20_poly1305.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\cmac.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\coding.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\curve25519.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\cpuid.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\des3.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\dh.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\dsa.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\ecc.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\ed25519.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\error.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\fe_operations.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\ge_low_mem.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\ge_operations.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\hash.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\hc128.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\hmac.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\idea.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\integer.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\logging.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\md2.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\md4.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\md5.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\memory.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\pkcs7.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\pkcs12.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\poly1305.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\pwdbased.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\rabbit.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\random.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\ripemd.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\rsa.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sha.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sha256.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sha3.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sha512.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\signature.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sp_c32.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sp_c64.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sp_int.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\sp_x86_64.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\srp.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\tfm.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\wc_encrypt.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\wc_pkcs11.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\wc_port.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\wolfmath.c" />
|
||||
<ClCompile Include="wolfssl\wolfcrypt\src\wolfevent.c" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="wolfssl\resource.h" />
|
||||
<CustomBuild Include="wolfssl\wolfcrypt\src\aes_asm.asm">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'">false</ExcludedFromBuild>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">ml64.exe /c /Zi /Fo"$(OutDir)%(Filename).obj" %(Identity)</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'">ml64.exe /c /Zi /Fo"$(IntDir)%(Filename).obj" %(Identity)</Command>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(OutDir)%(Filename).obj</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'">$(IntDir)%(Filename).obj</Outputs>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'">false</ExcludedFromBuild>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">ml64.exe /c /Zi /Fo"$(OutDir)%(Filename).obj" %(Identity)</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'">ml64.exe /c /Zi /Fo"$(IntDir)%(Filename).obj" %(Identity)</Command>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(OutDir)%(Filename).obj</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'">$(IntDir)%(Filename).obj</Outputs>
|
||||
</CustomBuild>
|
||||
<ClInclude Include="wolfssl\IDE\WIN\user_settings.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="wolfssl\wolfssl.rc">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
Vendored
+1
-1
Submodule 3rdparty/xxHash updated: 7cc9639699...94e5f23e73
Vendored
+7
-1
@@ -27,6 +27,9 @@
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets">
|
||||
@@ -41,7 +44,10 @@
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup />
|
||||
<ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="xxHash/xxhash.c" />
|
||||
|
||||
Vendored
+1
-1
Submodule 3rdparty/yaml-cpp updated: eca9cfd648...6a211f0bc7
Vendored
+9
@@ -22,6 +22,9 @@
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="Shared">
|
||||
@@ -37,6 +40,12 @@
|
||||
<Import Project="..\rpcs3_release.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Release|x64'">MaxSpeed</Optimization>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="yaml-cpp\src\binary.cpp">
|
||||
</ClCompile>
|
||||
|
||||
Vendored
+4
-1
@@ -31,6 +31,9 @@
|
||||
<Import Project="$(SolutionDir)\3rdparty\zlib.props" />
|
||||
<Import Project="..\common_default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="..\common_default_macros.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
@@ -79,7 +82,7 @@
|
||||
<ClCompile>
|
||||
<WarningLevel>$(WarningLevel)</WarningLevel>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<Optimization>Full</Optimization>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<BufferSecurityCheck>false</BufferSecurityCheck>
|
||||
|
||||
+40
-29
@@ -9,20 +9,20 @@ Other instructions may be found [here](https://wiki.rpcs3.net/index.php?title=Bu
|
||||
|
||||
* [CMake 3.14.1+](https://www.cmake.org/download/) (add to PATH)
|
||||
* [Python 3.3+](https://www.python.org/downloads/) (add to PATH)
|
||||
* [Qt 5.11+](https://www.qt.io/download-qt-installer) (Avoid 5.11.1, due to a bug)
|
||||
* [Qt 5.15.2](https://www.qt.io/download-qt-installer)
|
||||
* [Visual Studio 2019](https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=Community)
|
||||
* [Vulkan SDK 1.1.97.0+](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/windows/getting_started.html))
|
||||
* [Vulkan SDK 1.1.126+](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/windows/getting_started.html))
|
||||
|
||||
**Either add the** `QTDIR` **environment variable, e.g.** `<QtInstallFolder>\5.11.0\msvc2017_64\` **, or use the [Visual Studio Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.QtVisualStudioTools-19123)**
|
||||
**Either add the** `QTDIR` **environment variable, e.g.** `<QtInstallFolder>\5.15.2\msvc2019_64\` **, or use the [Visual Studio Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.QtVisualStudioTools2019)**
|
||||
|
||||
### Linux
|
||||
|
||||
These are the essentials tools to build RPCS3 on Linux. Some of them can be installed through your favorite package manager.
|
||||
|
||||
* Clang 5.0+ or GCC 8.1+
|
||||
* [CMake 3.8.2+](https://www.cmake.org/download/)
|
||||
* [Qt 5.11+](https://www.qt.io/download-qt-installer) (Avoid 5.11.1, due to a bug)
|
||||
* [Vulkan SDK 1.1.97.0+](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/linux/getting_started.html))
|
||||
* Clang 11+ or GCC 9+
|
||||
* [CMake 3.14.1+](https://www.cmake.org/download/)
|
||||
* [Qt 5.15.2](https://www.qt.io/download-qt-installer)
|
||||
* [Vulkan SDK 1.1.126+](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/linux/getting_started.html))
|
||||
* [SDL2](https://www.libsdl.org/download-2.0.php) (for the FAudio backend)
|
||||
|
||||
**If you have an NVIDIA GPU, you may need to install the libglvnd package.**
|
||||
@@ -33,45 +33,56 @@ These are the essentials tools to build RPCS3 on Linux. Some of them can be inst
|
||||
|
||||
#### Debian & Ubuntu
|
||||
|
||||
sudo apt-get install cmake build-essential libasound2-dev libpulse-dev libopenal-dev libglew-dev zlib1g-dev libedit-dev libvulkan-dev libudev-dev git qt5-default libevdev-dev qtdeclarative5-dev qtbase5-private-dev libsdl2-2.0 libsdl2-dev
|
||||
sudo apt-get install build-essential libasound2-dev libpulse-dev libopenal-dev libglew-dev zlib1g-dev libedit-dev libvulkan-dev libudev-dev git libevdev-dev libsdl2-2.0 libsdl2-dev
|
||||
|
||||
##### GCC 8.x installation
|
||||
Ubuntu is usually horrendously out of date, and some packages need to be downloaded by hand. This part is for Qt, GCC, Vulkan, and CMake
|
||||
##### Qt PPA
|
||||
|
||||
If the `gcc-8` package is not available on your system, use the following command
|
||||
Ubuntu usually does not have a new enough Qt package to suit rpcs3's needs. There is a PPA available to work around this. Run the following:
|
||||
```
|
||||
. /etc/os-release
|
||||
sudo add-apt-repository ppa:beineri/opt-qt-5.15.2-$UBUNTU_CODENAME
|
||||
sudo apt-get update
|
||||
sudo apt-get install qt515-meta-minimal qt515svg
|
||||
. /opt/qt515/bin/qt515-env.sh >/dev/null 2>&1
|
||||
```
|
||||
|
||||
##### GCC 9.x installation
|
||||
|
||||
If the `gcc-9` package is not available on your system, use the following commands
|
||||
```
|
||||
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
|
||||
```
|
||||
Then
|
||||
```
|
||||
sudo apt-get update
|
||||
sudo apt-get install gcc-8 g++-8
|
||||
sudo apt-get install gcc-9 g++-9
|
||||
```
|
||||
|
||||
You can either use `update-alternatives` to setup `gcc-8`/`g++-8` as your default compilers or prefix any `cmake` command by `CXX=g++-8 CC=gcc-8 ` to use it.
|
||||
You can either use `update-alternatives` to setup `gcc-9`/`g++-9` as your default compilers or prefix any `cmake` command by `CXX=g++-9 CC=gcc-9 ` to use it.
|
||||
|
||||
##### Vulkan SDK
|
||||
|
||||
For Ubuntu systems, it is strongly recommended to use the PPA from [LunarG](https://packages.lunarg.com/) which will provide a compatible Vulkan SDK to compile RPCS3. If your Vulkan SDK is older, it can lead to compilation errors.
|
||||
|
||||
Ubuntu 18.04 (Bionic Beaver)
|
||||
```
|
||||
wget -qO - http://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
|
||||
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.1.106-bionic.list http://packages.lunarg.com/vulkan/1.1.106/lunarg-vulkan-1.1.106-bionic.list
|
||||
. /etc/os-release
|
||||
wget -qO - https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
|
||||
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.2.148-$UBUNTU_CODENAME.list https://packages.lunarg.com/vulkan/1.2.148/lunarg-vulkan-1.2.148-$UBUNTU_CODENAME.list
|
||||
sudo apt update
|
||||
sudo apt install vulkan-sdk
|
||||
```
|
||||
|
||||
Ubuntu 16.04 (Xenial Xerus)
|
||||
##### CMake
|
||||
```
|
||||
wget -qO - http://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
|
||||
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.1.106-xenial.list http://packages.lunarg.com/vulkan/1.1.106/lunarg-vulkan-1.1.106-xenial.list
|
||||
sudo apt update
|
||||
sudo apt install vulkan-sdk
|
||||
. /etc/os-release
|
||||
wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add -
|
||||
sudo apt-add-repository "deb https://apt.kitware.com/ubuntu/ $UBUNTU_CODENAME main"
|
||||
sudo apt-get update
|
||||
sudo apt-get install kitware-archive-keyring
|
||||
sudo apt-key --keyring /etc/apt/trusted.gpg del C1F34CDD40CD72DA
|
||||
sudo apt-get install cmake
|
||||
```
|
||||
|
||||
#### Fedora
|
||||
|
||||
sudo dnf install alsa-lib-devel cmake glew glew-devel libatomic libevdev-devel libudev-devel openal-devel qt5-devel vulkan-devel
|
||||
sudo dnf install alsa-lib-devel cmake glew glew-devel libatomic libevdev-devel libudev-devel openal-devel qt5-devel qt5-qtbase-private-devel vulkan-devel
|
||||
|
||||
#### OpenSUSE
|
||||
|
||||
@@ -92,16 +103,16 @@ git submodule update --init
|
||||
#### Configuring the Qt plugin (if used)
|
||||
|
||||
1) Go to the Qt5 menu and edit Qt5 options.
|
||||
2) Add the path to your Qt installation with compiler e.g. `<QtInstallFolder>\5.11.0\msvc2017_64`.
|
||||
2) Add the path to your Qt installation with compiler e.g. `<QtInstallFolder>\5.15.2\msvc2019_64`.
|
||||
3) While selecting the rpcs3qt project, go to Qt5->Project Setting and select the version you added.
|
||||
|
||||
#### Building the projects
|
||||
|
||||
Open `rpcs3.sln`. The recommended build configuration is `Release - LLVM` for all purposes.
|
||||
|
||||
You may want to download precompiled [LLVM libs](https://github.com/RPCS3/llvm/releases/download/continuous-master/llvmlibs.7z) and extract to root rpcs3 folder (which contains `rpcs3.sln`), as well as download and extract [additional libs](https://drive.google.com/uc?export=download&id=1A2eOMmCO714i0U7J0qI4aEMKnuWl8l_R) to `lib\%CONFIGURATION%-x64\` to speed up compilation time (unoptimised/debug libs are currently not available precompiled).
|
||||
You may want to download the precompiled [LLVM libs](https://github.com/RPCS3/llvm-mirror/releases/download/custom-build-win/llvmlibs_mt.7z) and extract them to the root rpcs3 folder (which contains `rpcs3.sln`), as well as download and extract the [additional libs](https://github.com/RPCS3/glslang/releases/download/custom-build-win/glslanglibs_mt.7z) to `lib\%CONFIGURATION%-x64\` to speed up compilation time (unoptimised/debug libs are currently not available precompiled).
|
||||
|
||||
If you're not using precompiled libs, build the projects in *__BUILD_BEFORE* folder: right-click on every project > *Build*.
|
||||
If you're not using the precompiled libs, build the projects in *__BUILD_BEFORE* folder: right-click on every project > *Build*.
|
||||
|
||||
`Build > Build Solution`
|
||||
|
||||
@@ -110,7 +121,7 @@ If you're not using precompiled libs, build the projects in *__BUILD_BEFORE* fol
|
||||
While still in the project root:
|
||||
|
||||
1) `cd .. && mkdir rpcs3_build && cd rpcs3_build`
|
||||
2) `cmake ../rpcs3/ && make` or `CXX=g++-8 CC=gcc-8 cmake ../rpcs3/ && make` to force these compilers
|
||||
2) `cmake ../rpcs3/ && make` or `CXX=g++-9 CC=gcc-9 cmake ../rpcs3/ && make` to force these compilers
|
||||
3) Run RPCS3 with `./bin/rpcs3`
|
||||
|
||||
When using GDB, configure it to ignore SIGSEGV signal (`handle SIGSEGV nostop noprint`).
|
||||
|
||||
+8
-7
@@ -1,14 +1,14 @@
|
||||
cmake_minimum_required(VERSION 3.8.2)
|
||||
cmake_minimum_required(VERSION 3.14.1)
|
||||
|
||||
project(rpcs3)
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 8)
|
||||
message(FATAL_ERROR "RPCS3 requires at least gcc-8.")
|
||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9)
|
||||
message(FATAL_ERROR "RPCS3 requires at least gcc-9.")
|
||||
endif()
|
||||
elseif(${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
|
||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0)
|
||||
message(FATAL_ERROR "RPCS3 requires at least clang-5.0.")
|
||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 11.0)
|
||||
message(FATAL_ERROR "RPCS3 requires at least clang-11.0.")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -22,10 +22,11 @@ option(USE_LIBEVDEV "libevdev-based joystick support" ON)
|
||||
option(USE_DISCORD_RPC "Discord rich presence integration" ON)
|
||||
option(USE_SYSTEM_ZLIB "Prefer system ZLIB instead of the builtin one" ON)
|
||||
option(USE_VULKAN "Vulkan render backend" ON)
|
||||
option(USE_PRECOMPILED_HEADERS "Use precompiled headers" OFF)
|
||||
|
||||
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/rpcs3/cmake_modules")
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
include(CheckCXXCompilerFlag)
|
||||
|
||||
if (NOT CMAKE_BUILD_TYPE)
|
||||
@@ -63,7 +64,7 @@ set(CMAKE_C_FLAGS -w)
|
||||
set(LLVM_ENABLE_WARNINGS OFF CACHE BOOL "")
|
||||
|
||||
if(MSVC)
|
||||
add_compile_options(/wd4530) # C++ exception handler used, but unwind semantics are not enabled
|
||||
add_compile_options(/wd4530 /utf-8) # C++ exception handler used, but unwind semantics are not enabled
|
||||
endif()
|
||||
|
||||
add_subdirectory(Vulkan EXCLUDE_FROM_ALL)
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
RPCS3
|
||||
=====
|
||||
|
||||
[](https://travis-ci.org/RPCS3/rpcs3)
|
||||
[](https://ci.appveyor.com/project/rpcs3/rpcs3/branch/master)
|
||||
[](https://dev.azure.com/nekotekina/nekotekina/_build?definitionId=4&branchName=master)
|
||||
[&logo=cirrus-ci)](https://cirrus-ci.com/github/RPCS3/rpcs3)
|
||||
[](https://discord.me/rpcs3)
|
||||
|
||||
The world's first free and open-source PlayStation 3 emulator/debugger, written in C++ for Windows and Linux.
|
||||
|
||||
@@ -32,7 +33,7 @@ See [BUILDING.md](BUILDING.md) for more information about how to setup an enviro
|
||||
|
||||
Check our friendly [quickstart](https://rpcs3.net/quickstart) guide to make sure your computer meets the minimum system requirements to run RPCS3.
|
||||
|
||||
Don't forget to have your graphics driver up to date and to install the [Visual C++ Redistributable Packages for Visual Studio 2017](https://go.microsoft.com/fwlink/?LinkId=746572) if you are a Windows user.
|
||||
Don't forget to have your graphics driver up to date and to install the [Visual C++ Redistributable Packages for Visual Studio 2019](https://aka.ms/vs/16/release/VC_redist.x64.exe) if you are a Windows user.
|
||||
|
||||
## License
|
||||
|
||||
|
||||
@@ -1,441 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/endian.hpp"
|
||||
#include <cstring>
|
||||
|
||||
// 128-bit vector type and also se_storage<> storage type
|
||||
union alignas(16) v128
|
||||
{
|
||||
char _bytes[16];
|
||||
|
||||
template <typename T, std::size_t N, std::size_t M>
|
||||
struct masked_array_t // array type accessed as (index ^ M)
|
||||
{
|
||||
T m_data[N];
|
||||
|
||||
public:
|
||||
T& operator[](std::size_t index)
|
||||
{
|
||||
return m_data[index ^ M];
|
||||
}
|
||||
|
||||
const T& operator[](std::size_t index) const
|
||||
{
|
||||
return m_data[index ^ M];
|
||||
}
|
||||
};
|
||||
|
||||
#if IS_LE_MACHINE == 1
|
||||
template <typename T, std::size_t N = 16 / sizeof(T)>
|
||||
using normal_array_t = masked_array_t<T, N, 0>;
|
||||
template <typename T, std::size_t N = 16 / sizeof(T)>
|
||||
using reversed_array_t = masked_array_t<T, N, N - 1>;
|
||||
#endif
|
||||
|
||||
normal_array_t<u64> _u64;
|
||||
normal_array_t<s64> _s64;
|
||||
reversed_array_t<u64> u64r;
|
||||
reversed_array_t<s64> s64r;
|
||||
|
||||
normal_array_t<u32> _u32;
|
||||
normal_array_t<s32> _s32;
|
||||
reversed_array_t<u32> u32r;
|
||||
reversed_array_t<s32> s32r;
|
||||
|
||||
normal_array_t<u16> _u16;
|
||||
normal_array_t<s16> _s16;
|
||||
reversed_array_t<u16> u16r;
|
||||
reversed_array_t<s16> s16r;
|
||||
|
||||
normal_array_t<u8> _u8;
|
||||
normal_array_t<s8> _s8;
|
||||
reversed_array_t<u8> u8r;
|
||||
reversed_array_t<s8> s8r;
|
||||
|
||||
normal_array_t<f32> _f;
|
||||
normal_array_t<f64> _d;
|
||||
reversed_array_t<f32> fr;
|
||||
reversed_array_t<f64> dr;
|
||||
|
||||
__m128 vf;
|
||||
__m128i vi;
|
||||
__m128d vd;
|
||||
|
||||
struct bit_array_128
|
||||
{
|
||||
u64 m_data[2];
|
||||
|
||||
public:
|
||||
class bit_element
|
||||
{
|
||||
u64& data;
|
||||
const u64 mask;
|
||||
|
||||
public:
|
||||
bit_element(u64& data, const u64 mask)
|
||||
: data(data)
|
||||
, mask(mask)
|
||||
{
|
||||
}
|
||||
|
||||
operator bool() const
|
||||
{
|
||||
return (data & mask) != 0;
|
||||
}
|
||||
|
||||
bit_element& operator=(const bool right)
|
||||
{
|
||||
if (right)
|
||||
{
|
||||
data |= mask;
|
||||
}
|
||||
else
|
||||
{
|
||||
data &= ~mask;
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
bit_element& operator=(const bit_element& right)
|
||||
{
|
||||
if (right)
|
||||
{
|
||||
data |= mask;
|
||||
}
|
||||
else
|
||||
{
|
||||
data &= ~mask;
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
};
|
||||
|
||||
// Index 0 returns the MSB and index 127 returns the LSB
|
||||
bit_element operator[](u32 index)
|
||||
{
|
||||
#if IS_LE_MACHINE == 1
|
||||
return bit_element(m_data[1 - (index >> 6)], 0x8000000000000000ull >> (index & 0x3F));
|
||||
#endif
|
||||
}
|
||||
|
||||
// Index 0 returns the MSB and index 127 returns the LSB
|
||||
bool operator[](u32 index) const
|
||||
{
|
||||
#if IS_LE_MACHINE == 1
|
||||
return (m_data[1 - (index >> 6)] & (0x8000000000000000ull >> (index & 0x3F))) != 0;
|
||||
#endif
|
||||
}
|
||||
} _bit;
|
||||
|
||||
static v128 from64(u64 _0, u64 _1 = 0)
|
||||
{
|
||||
v128 ret;
|
||||
ret._u64[0] = _0;
|
||||
ret._u64[1] = _1;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 from64r(u64 _1, u64 _0 = 0)
|
||||
{
|
||||
return from64(_0, _1);
|
||||
}
|
||||
|
||||
static v128 from32(u32 _0, u32 _1 = 0, u32 _2 = 0, u32 _3 = 0)
|
||||
{
|
||||
v128 ret;
|
||||
ret._u32[0] = _0;
|
||||
ret._u32[1] = _1;
|
||||
ret._u32[2] = _2;
|
||||
ret._u32[3] = _3;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 from32r(u32 _3, u32 _2 = 0, u32 _1 = 0, u32 _0 = 0)
|
||||
{
|
||||
return from32(_0, _1, _2, _3);
|
||||
}
|
||||
|
||||
static v128 from32p(u32 value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vi = _mm_set1_epi32(static_cast<s32>(value));
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 from16p(u16 value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vi = _mm_set1_epi16(static_cast<s16>(value));
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 from8p(u8 value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vi = _mm_set1_epi8(static_cast<s8>(value));
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 fromBit(u32 bit)
|
||||
{
|
||||
v128 ret = {};
|
||||
ret._bit[bit] = true;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 fromV(__m128i value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vi = value;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 fromF(__m128 value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vf = value;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static v128 fromD(__m128d value)
|
||||
{
|
||||
v128 ret;
|
||||
ret.vd = value;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static inline v128 add8(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_add_epi8(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 add16(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_add_epi16(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 add32(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_add_epi32(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 addfs(const v128& left, const v128& right)
|
||||
{
|
||||
return fromF(_mm_add_ps(left.vf, right.vf));
|
||||
}
|
||||
|
||||
static inline v128 addfd(const v128& left, const v128& right)
|
||||
{
|
||||
return fromD(_mm_add_pd(left.vd, right.vd));
|
||||
}
|
||||
|
||||
static inline v128 sub8(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_sub_epi8(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 sub16(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_sub_epi16(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 sub32(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_sub_epi32(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 subfs(const v128& left, const v128& right)
|
||||
{
|
||||
return fromF(_mm_sub_ps(left.vf, right.vf));
|
||||
}
|
||||
|
||||
static inline v128 subfd(const v128& left, const v128& right)
|
||||
{
|
||||
return fromD(_mm_sub_pd(left.vd, right.vd));
|
||||
}
|
||||
|
||||
static inline v128 maxu8(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_max_epu8(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 minu8(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_min_epu8(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 eq8(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_cmpeq_epi8(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 eq16(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_cmpeq_epi16(left.vi, right.vi));
|
||||
}
|
||||
|
||||
static inline v128 eq32(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_cmpeq_epi32(left.vi, right.vi));
|
||||
}
|
||||
|
||||
bool operator==(const v128& right) const
|
||||
{
|
||||
return _u64[0] == right._u64[0] && _u64[1] == right._u64[1];
|
||||
}
|
||||
|
||||
bool operator!=(const v128& right) const
|
||||
{
|
||||
return _u64[0] != right._u64[0] || _u64[1] != right._u64[1];
|
||||
}
|
||||
|
||||
// result = (~left) & (right)
|
||||
static inline v128 andnot(const v128& left, const v128& right)
|
||||
{
|
||||
return fromV(_mm_andnot_si128(left.vi, right.vi));
|
||||
}
|
||||
|
||||
void clear()
|
||||
{
|
||||
_u64[0] = 0;
|
||||
_u64[1] = 0;
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T, std::size_t N, std::size_t M>
|
||||
struct offset32_array<v128::masked_array_t<T, N, M>>
|
||||
{
|
||||
template <typename Arg>
|
||||
static inline u32 index32(const Arg& arg)
|
||||
{
|
||||
return u32{sizeof(T)} * (static_cast<u32>(arg) ^ static_cast<u32>(M));
|
||||
}
|
||||
};
|
||||
|
||||
inline v128 operator|(const v128& left, const v128& right)
|
||||
{
|
||||
return v128::fromV(_mm_or_si128(left.vi, right.vi));
|
||||
}
|
||||
|
||||
inline v128 operator&(const v128& left, const v128& right)
|
||||
{
|
||||
return v128::fromV(_mm_and_si128(left.vi, right.vi));
|
||||
}
|
||||
|
||||
inline v128 operator^(const v128& left, const v128& right)
|
||||
{
|
||||
return v128::fromV(_mm_xor_si128(left.vi, right.vi));
|
||||
}
|
||||
|
||||
inline v128 operator~(const v128& other)
|
||||
{
|
||||
return v128::from64(~other._u64[0], ~other._u64[1]);
|
||||
}
|
||||
|
||||
using stx::se_t;
|
||||
using stx::se_storage;
|
||||
|
||||
// se_t<> with native endianness
|
||||
template <typename T, std::size_t Align = alignof(T)>
|
||||
using nse_t = se_t<T, false, Align>;
|
||||
|
||||
#if IS_LE_MACHINE == 1
|
||||
template <typename T, std::size_t Align = alignof(T)>
|
||||
using be_t = se_t<T, true, Align>;
|
||||
template <typename T, std::size_t Align = alignof(T)>
|
||||
using le_t = se_t<T, false, Align>;
|
||||
#endif
|
||||
|
||||
// Type converter: converts native endianness arithmetic/enum types to appropriate se_t<> type
|
||||
template <typename T, bool Se, typename = void>
|
||||
struct to_se
|
||||
{
|
||||
template <typename T2, typename = void>
|
||||
struct to_se_
|
||||
{
|
||||
using type = T2;
|
||||
};
|
||||
|
||||
template <typename T2>
|
||||
struct to_se_<T2, std::enable_if_t<std::is_arithmetic<T2>::value || std::is_enum<T2>::value>>
|
||||
{
|
||||
using type = std::conditional_t<(sizeof(T2) > 1), se_t<T2, Se>, T2>;
|
||||
};
|
||||
|
||||
// Convert arithmetic and enum types
|
||||
using type = typename to_se_<T>::type;
|
||||
};
|
||||
|
||||
template <bool Se>
|
||||
struct to_se<v128, Se>
|
||||
{
|
||||
using type = se_t<v128, Se>;
|
||||
};
|
||||
|
||||
template <bool Se>
|
||||
struct to_se<u128, Se>
|
||||
{
|
||||
using type = se_t<u128, Se>;
|
||||
};
|
||||
|
||||
template <bool Se>
|
||||
struct to_se<s128, Se>
|
||||
{
|
||||
using type = se_t<s128, Se>;
|
||||
};
|
||||
|
||||
template <typename T, bool Se>
|
||||
struct to_se<const T, Se, std::enable_if_t<!std::is_array<T>::value>>
|
||||
{
|
||||
// Move const qualifier
|
||||
using type = const typename to_se<T, Se>::type;
|
||||
};
|
||||
|
||||
template <typename T, bool Se>
|
||||
struct to_se<volatile T, Se, std::enable_if_t<!std::is_array<T>::value && !std::is_const<T>::value>>
|
||||
{
|
||||
// Move volatile qualifier
|
||||
using type = volatile typename to_se<T, Se>::type;
|
||||
};
|
||||
|
||||
template <typename T, bool Se>
|
||||
struct to_se<T[], Se>
|
||||
{
|
||||
// Move array qualifier
|
||||
using type = typename to_se<T, Se>::type[];
|
||||
};
|
||||
|
||||
template <typename T, bool Se, std::size_t N>
|
||||
struct to_se<T[N], Se>
|
||||
{
|
||||
// Move array qualifier
|
||||
using type = typename to_se<T, Se>::type[N];
|
||||
};
|
||||
|
||||
// BE/LE aliases for to_se<>
|
||||
#if IS_LE_MACHINE == 1
|
||||
template <typename T>
|
||||
using to_be_t = typename to_se<T, true>::type;
|
||||
template <typename T>
|
||||
using to_le_t = typename to_se<T, false>::type;
|
||||
#endif
|
||||
|
||||
// BE/LE aliases for atomic_t
|
||||
#if IS_LE_MACHINE == 1
|
||||
template <typename T>
|
||||
using atomic_be_t = atomic_t<be_t<T>>;
|
||||
template <typename T>
|
||||
using atomic_le_t = atomic_t<le_t<T>>;
|
||||
#endif
|
||||
|
||||
template <typename T, bool Se, std::size_t Align>
|
||||
struct fmt_unveil<se_t<T, Se, Align>, void>
|
||||
{
|
||||
using type = typename fmt_unveil<T>::type;
|
||||
|
||||
static inline auto get(const se_t<T, Se, Align>& arg)
|
||||
{
|
||||
return fmt_unveil<T>::get(arg);
|
||||
}
|
||||
};
|
||||
@@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "Utilities/StrFmt.h"
|
||||
|
||||
template<typename T, uint N>
|
||||
struct bf_base
|
||||
@@ -11,7 +12,7 @@ struct bf_base
|
||||
|
||||
// Datatype bitsize
|
||||
static constexpr uint bitmax = sizeof(T) * 8; static_assert(N - 1 < bitmax, "bf_base<> error: N out of bounds");
|
||||
|
||||
|
||||
// Field bitsize
|
||||
static constexpr uint bitsize = N;
|
||||
|
||||
@@ -96,7 +97,7 @@ struct bf_t : bf_base<T, N>
|
||||
// Optimized bool conversion (must be removed if inappropriate)
|
||||
explicit constexpr operator bool() const
|
||||
{
|
||||
return unshifted() != 0;
|
||||
return unshifted() != 0u;
|
||||
}
|
||||
|
||||
// Store bitfield value
|
||||
@@ -147,7 +148,7 @@ struct bf_t : bf_base<T, N>
|
||||
|
||||
bf_t& operator &=(vtype right)
|
||||
{
|
||||
this->m_data &= static_cast<vtype>((static_cast<utype>(right) & bf_t::vmask) << bitpos);
|
||||
this->m_data &= static_cast<vtype>(((static_cast<utype>(right) & bf_t::vmask) << bitpos) | ~(bf_t::vmask << bitpos));
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include <Utilities/types.h>
|
||||
#include "util/types.hpp"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "windows.h"
|
||||
@@ -176,7 +176,7 @@ public:
|
||||
};
|
||||
u_int miblen = std::size(mib);
|
||||
struct kinfo_proc info;
|
||||
size_t size = sizeof(info);
|
||||
usz size = sizeof(info);
|
||||
if (sysctl(mib, miblen, &info, &size, NULL, 0))
|
||||
{
|
||||
return 0;
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
u_int miblen = std::size(mib);
|
||||
|
||||
// get number of structs
|
||||
size_t size;
|
||||
usz size;
|
||||
if (sysctl(mib, miblen, NULL, &size, NULL, 0))
|
||||
{
|
||||
return 0;
|
||||
|
||||
+70
-23
@@ -1,11 +1,14 @@
|
||||
#include "stdafx.h"
|
||||
#include "Config.h"
|
||||
#include "util/types.hpp"
|
||||
|
||||
#include "yaml-cpp/yaml.h"
|
||||
#include "util/yaml.hpp"
|
||||
|
||||
#include <typeinfo>
|
||||
#include <charconv>
|
||||
|
||||
LOG_CHANNEL(cfg_log, "CFG");
|
||||
|
||||
namespace cfg
|
||||
{
|
||||
_base::_base(type _type)
|
||||
@@ -13,7 +16,7 @@ namespace cfg
|
||||
{
|
||||
if (_type != type::node)
|
||||
{
|
||||
fmt::throw_exception("Invalid root node" HERE);
|
||||
cfg_log.fatal("Invalid root node");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,7 +27,7 @@ namespace cfg
|
||||
{
|
||||
if (pair.first == name)
|
||||
{
|
||||
fmt::throw_exception("Node already exists: %s" HERE, name);
|
||||
cfg_log.fatal("Node already exists: %s", name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,12 +36,12 @@ namespace cfg
|
||||
|
||||
bool _base::from_string(const std::string&, bool)
|
||||
{
|
||||
fmt::throw_exception("from_string() purecall" HERE);
|
||||
fmt::throw_exception("from_string() purecall");
|
||||
}
|
||||
|
||||
bool _base::from_list(std::vector<std::string>&&)
|
||||
{
|
||||
fmt::throw_exception("from_list() purecall" HERE);
|
||||
fmt::throw_exception("from_list() purecall");
|
||||
}
|
||||
|
||||
// Emit YAML
|
||||
@@ -60,6 +63,52 @@ bool cfg::try_to_int64(s64* out, const std::string& value, s64 min, s64 max)
|
||||
const char* start = &value.front();
|
||||
const char* end = &value.back() + 1;
|
||||
int base = 10;
|
||||
int sign = +1;
|
||||
|
||||
if (start[0] == '-')
|
||||
{
|
||||
sign = -1;
|
||||
start += 1;
|
||||
}
|
||||
|
||||
if (start[0] == '0' && (start[1] == 'x' || start[1] == 'X'))
|
||||
{
|
||||
// Limited hex support
|
||||
base = 16;
|
||||
start += 2;
|
||||
}
|
||||
|
||||
const auto ret = std::from_chars(start, end, result, base);
|
||||
|
||||
if (ret.ec != std::errc() || ret.ptr != end || (start[0] == '-' && sign < 0))
|
||||
{
|
||||
if (out) cfg_log.error("cfg::try_to_int64('%s'): invalid integer", value);
|
||||
return false;
|
||||
}
|
||||
|
||||
result *= sign;
|
||||
|
||||
if (result < min || result > max)
|
||||
{
|
||||
if (out) cfg_log.error("cfg::try_to_int64('%s'): out of bounds (%d..%d)", value, min, max);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (out) *out = result;
|
||||
return true;
|
||||
}
|
||||
|
||||
std::vector<std::string> cfg::make_uint_range(u64 min, u64 max)
|
||||
{
|
||||
return {std::to_string(min), std::to_string(max)};
|
||||
}
|
||||
|
||||
bool cfg::try_to_uint64(u64* out, const std::string& value, u64 min, u64 max)
|
||||
{
|
||||
u64 result;
|
||||
const char* start = &value.front();
|
||||
const char* end = &value.back() + 1;
|
||||
int base = 10;
|
||||
|
||||
if (start[0] == '0' && (start[1] == 'x' || start[1] == 'X'))
|
||||
{
|
||||
@@ -72,13 +121,13 @@ bool cfg::try_to_int64(s64* out, const std::string& value, s64 min, s64 max)
|
||||
|
||||
if (ret.ec != std::errc() || ret.ptr != end)
|
||||
{
|
||||
if (out) LOG_ERROR(GENERAL, "cfg::try_to_int('%s'): invalid integer", value);
|
||||
if (out) cfg_log.error("cfg::try_to_uint64('%s'): invalid integer", value);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (result < min || result > max)
|
||||
{
|
||||
if (out) LOG_ERROR(GENERAL, "cfg::try_to_int('%s'): out of bounds (%lld..%lld)", value, min, max);
|
||||
if (out) cfg_log.error("cfg::try_to_uint64('%s'): out of bounds (%u..%u)", value, min, max);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -127,13 +176,13 @@ bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) f
|
||||
|
||||
if (ret.ec != std::errc() || ret.ptr != end)
|
||||
{
|
||||
if (out) LOG_ERROR(GENERAL, "cfg::try_to_enum_value('%s'): invalid enum or integer", value);
|
||||
if (out) cfg_log.error("cfg::try_to_enum_value('%s'): invalid enum or integer", value);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (result > max)
|
||||
{
|
||||
if (out) LOG_ERROR(GENERAL, "cfg::try_to_enum_value('%s'): out of bounds(0..%u)", value, max);
|
||||
if (out) cfg_log.error("cfg::try_to_enum_value('%s'): out of bounds(0..%u)", value, max);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -284,7 +333,7 @@ void cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic)
|
||||
|
||||
if (YAML::convert<std::string>::decode(data, value))
|
||||
{
|
||||
rhs.from_string(value);
|
||||
rhs.from_string(value, dynamic);
|
||||
}
|
||||
|
||||
break; // ???
|
||||
@@ -300,14 +349,17 @@ std::string cfg::node::to_string() const
|
||||
return {out.c_str(), out.size()};
|
||||
}
|
||||
|
||||
bool cfg::node::from_string(const std::string& value, bool dynamic) try
|
||||
bool cfg::node::from_string(const std::string& value, bool dynamic)
|
||||
{
|
||||
cfg::decode(YAML::Load(value), *this, dynamic);
|
||||
return true;
|
||||
}
|
||||
catch (const std::exception& e)
|
||||
{
|
||||
LOG_FATAL(GENERAL, "%s thrown: %s", typeid(e).name(), e.what());
|
||||
auto [result, error] = yaml_load(value);
|
||||
|
||||
if (error.empty())
|
||||
{
|
||||
cfg::decode(result, *this, dynamic);
|
||||
return true;
|
||||
}
|
||||
|
||||
cfg_log.fatal("Failed to load node: %s", error);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -336,12 +388,7 @@ void cfg::set_entry::from_default()
|
||||
|
||||
void cfg::log_entry::set_map(std::map<std::string, logs::level>&& map)
|
||||
{
|
||||
logs::reset();
|
||||
|
||||
for (auto&& pair : (m_map = std::move(map)))
|
||||
{
|
||||
logs::set_level(pair.first, pair.second);
|
||||
}
|
||||
m_map = std::move(map);
|
||||
}
|
||||
|
||||
void cfg::log_entry::from_default()
|
||||
|
||||
+128
-34
@@ -1,8 +1,10 @@
|
||||
#pragma once
|
||||
#pragma once
|
||||
|
||||
#include "Utilities/types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "util/atomic.hpp"
|
||||
#include "util/shared_ptr.hpp"
|
||||
|
||||
#include <utility>
|
||||
#include <string>
|
||||
@@ -18,6 +20,12 @@ namespace cfg
|
||||
// Convert string to signed integer
|
||||
bool try_to_int64(s64* out, const std::string& value, s64 min, s64 max);
|
||||
|
||||
// Format min and max unsigned values
|
||||
std::vector<std::string> make_uint_range(u64 min, u64 max);
|
||||
|
||||
// Convert string to unsigned integer
|
||||
bool try_to_uint64(u64* out, const std::string& value, u64 min, u64 max);
|
||||
|
||||
// Internal hack
|
||||
bool try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) func, const std::string&);
|
||||
|
||||
@@ -25,12 +33,13 @@ namespace cfg
|
||||
std::vector<std::string> try_to_enum_list(decltype(&fmt_class_string<int>::format) func);
|
||||
|
||||
// Config tree entry type.
|
||||
enum class type : uint
|
||||
enum class type : unsigned
|
||||
{
|
||||
node = 0, // cfg::node type
|
||||
_bool, // cfg::_bool type
|
||||
_enum, // cfg::_enum type
|
||||
_int, // cfg::_int type
|
||||
uint, // cfg::uint type
|
||||
string, // cfg::string type
|
||||
set, // cfg::set_entry type
|
||||
log,
|
||||
@@ -48,7 +57,7 @@ namespace cfg
|
||||
_base(type _type);
|
||||
|
||||
// Owned entry constructor
|
||||
_base(type _type, class node* owner, const std::string& name, bool dynamic = true);
|
||||
_base(type _type, class node* owner, const std::string& name, bool dynamic);
|
||||
|
||||
public:
|
||||
_base(const _base&) = delete;
|
||||
@@ -121,7 +130,7 @@ namespace cfg
|
||||
|
||||
class _bool final : public _base
|
||||
{
|
||||
bool m_value;
|
||||
atomic_t<bool> m_value;
|
||||
|
||||
public:
|
||||
bool def;
|
||||
@@ -138,7 +147,7 @@ namespace cfg
|
||||
return m_value;
|
||||
}
|
||||
|
||||
const bool& get() const
|
||||
bool get() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
@@ -172,7 +181,7 @@ namespace cfg
|
||||
template <typename T>
|
||||
class _enum final : public _base
|
||||
{
|
||||
T m_value;
|
||||
atomic_t<T> m_value;
|
||||
|
||||
public:
|
||||
const T def;
|
||||
@@ -189,11 +198,16 @@ namespace cfg
|
||||
return m_value;
|
||||
}
|
||||
|
||||
const T& get() const
|
||||
T get() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
|
||||
void set(T value)
|
||||
{
|
||||
m_value = value;
|
||||
}
|
||||
|
||||
void from_default() override
|
||||
{
|
||||
m_value = def;
|
||||
@@ -202,7 +216,7 @@ namespace cfg
|
||||
std::string to_string() const override
|
||||
{
|
||||
std::string result;
|
||||
fmt_class_string<T>::format(result, fmt_unveil<T>::get(m_value));
|
||||
fmt_class_string<T>::format(result, fmt_unveil<T>::get(m_value.load()));
|
||||
return result; // TODO: ???
|
||||
}
|
||||
|
||||
@@ -235,7 +249,7 @@ namespace cfg
|
||||
// Prefer 32 bit type if possible
|
||||
using int_type = std::conditional_t<Min >= INT32_MIN && Max <= INT32_MAX, s32, s64>;
|
||||
|
||||
int_type m_value;
|
||||
atomic_t<int_type> m_value;
|
||||
|
||||
public:
|
||||
int_type def;
|
||||
@@ -256,7 +270,7 @@ namespace cfg
|
||||
return m_value;
|
||||
}
|
||||
|
||||
const int_type& get() const
|
||||
int_type get() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
@@ -300,48 +314,128 @@ namespace cfg
|
||||
// Alias for 64 bit int
|
||||
using int64 = _int<INT64_MIN, INT64_MAX>;
|
||||
|
||||
// Simple string entry with mutex
|
||||
class string final : public _base
|
||||
// Unsigned 32/64-bit integer entry with custom Min/Max range.
|
||||
template <u64 Min, u64 Max>
|
||||
class uint final : public _base
|
||||
{
|
||||
std::string m_name;
|
||||
std::string m_value;
|
||||
static_assert(Min < Max, "Invalid cfg::uint range");
|
||||
|
||||
// Prefer 32 bit type if possible
|
||||
using int_type = std::conditional_t<Max <= UINT32_MAX, u32, u64>;
|
||||
|
||||
atomic_t<int_type> m_value;
|
||||
|
||||
public:
|
||||
std::string def;
|
||||
int_type def;
|
||||
|
||||
string(node* owner, const std::string& name, const std::string& def = {}, bool dynamic = false)
|
||||
: _base(type::string, owner, name, dynamic)
|
||||
, m_name(name)
|
||||
// Expose range
|
||||
static const u64 max = Max;
|
||||
static const u64 min = Min;
|
||||
|
||||
uint(node* owner, const std::string& name, int_type def = std::max<int_type>(Min, 0), bool dynamic = false)
|
||||
: _base(type::uint, owner, name, dynamic)
|
||||
, m_value(def)
|
||||
, def(def)
|
||||
{
|
||||
}
|
||||
|
||||
operator int_type() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
|
||||
int_type get() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
|
||||
void from_default() override
|
||||
{
|
||||
m_value = def;
|
||||
}
|
||||
|
||||
std::string to_string() const override
|
||||
{
|
||||
return std::to_string(m_value);
|
||||
}
|
||||
|
||||
bool from_string(const std::string& value, bool /*dynamic*/ = false) override
|
||||
{
|
||||
u64 result;
|
||||
if (try_to_uint64(&result, value, Min, Max))
|
||||
{
|
||||
m_value = static_cast<int_type>(result);
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
void set(const u64& value)
|
||||
{
|
||||
m_value = static_cast<int_type>(value);
|
||||
}
|
||||
|
||||
std::vector<std::string> to_list() const override
|
||||
{
|
||||
return make_uint_range(Min, Max);
|
||||
}
|
||||
};
|
||||
|
||||
// Alias for 32 bit uint
|
||||
using uint32 = uint<0, UINT32_MAX>;
|
||||
|
||||
// Alias for 64 bit int
|
||||
using uint64 = uint<0, UINT64_MAX>;
|
||||
|
||||
// Simple string entry with mutex
|
||||
class string : public _base
|
||||
{
|
||||
const std::string m_name;
|
||||
|
||||
atomic_ptr<std::string> m_value;
|
||||
|
||||
public:
|
||||
std::string def;
|
||||
|
||||
string(node* owner, std::string name, std::string def = {}, bool dynamic = false)
|
||||
: _base(type::string, owner, name, dynamic)
|
||||
, m_name(std::move(name))
|
||||
, m_value(def)
|
||||
, def(std::move(def))
|
||||
{
|
||||
}
|
||||
|
||||
operator std::string() const
|
||||
{
|
||||
return m_value;
|
||||
return *m_value.load().get();
|
||||
}
|
||||
|
||||
const std::string& get() const
|
||||
std::pair<const std::string&, shared_ptr<std::string>> get() const
|
||||
{
|
||||
return m_value;
|
||||
auto v = m_value.load();
|
||||
|
||||
if (auto s = v.get())
|
||||
{
|
||||
return {*s, std::move(v)};
|
||||
}
|
||||
else
|
||||
{
|
||||
static const std::string _empty;
|
||||
return {_empty, {}};
|
||||
}
|
||||
}
|
||||
|
||||
std::string get_name() const
|
||||
const std::string& get_name() const
|
||||
{
|
||||
return m_name;
|
||||
}
|
||||
|
||||
std::size_t size() const
|
||||
{
|
||||
return m_value.size();
|
||||
}
|
||||
|
||||
void from_default() override;
|
||||
|
||||
std::string to_string() const override
|
||||
{
|
||||
return m_value;
|
||||
return *m_value.load().get();
|
||||
}
|
||||
|
||||
bool from_string(const std::string& value, bool /*dynamic*/ = false) override
|
||||
@@ -351,15 +445,15 @@ namespace cfg
|
||||
}
|
||||
};
|
||||
|
||||
// Simple set entry with mutex (TODO: template for various types)
|
||||
// Simple set entry (TODO: template for various types)
|
||||
class set_entry final : public _base
|
||||
{
|
||||
std::set<std::string> m_set;
|
||||
|
||||
public:
|
||||
// Default value is empty list in current implementation
|
||||
set_entry(node* owner, const std::string& name, bool dynamic = false)
|
||||
: _base(type::set, owner, name, dynamic)
|
||||
set_entry(node* owner, const std::string& name)
|
||||
: _base(type::set, owner, name, false)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -394,7 +488,7 @@ namespace cfg
|
||||
|
||||
public:
|
||||
log_entry(node* owner, const std::string& name)
|
||||
: _base(type::log, owner, name)
|
||||
: _base(type::log, owner, name, true)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
+263
-177
@@ -1,7 +1,6 @@
|
||||
#include "File.h"
|
||||
#include "File.h"
|
||||
#include "mutex.h"
|
||||
#include "StrFmt.h"
|
||||
#include "BEType.h"
|
||||
#include "Crypto/sha1.h"
|
||||
|
||||
#include <unordered_map>
|
||||
@@ -11,6 +10,8 @@
|
||||
#include <typeinfo>
|
||||
#include <map>
|
||||
|
||||
#include "util/asm.hpp"
|
||||
|
||||
using namespace std::literals::string_literals;
|
||||
|
||||
#ifdef _WIN32
|
||||
@@ -21,10 +22,10 @@ using namespace std::literals::string_literals;
|
||||
static std::unique_ptr<wchar_t[]> to_wchar(const std::string& source)
|
||||
{
|
||||
// String size + null terminator
|
||||
const std::size_t buf_size = source.size() + 1;
|
||||
const usz buf_size = source.size() + 1;
|
||||
|
||||
// Safe size
|
||||
const int size = narrow<int>(buf_size, "to_wchar" HERE);
|
||||
const int size = narrow<int>(buf_size);
|
||||
|
||||
// Buffer for max possible output length
|
||||
std::unique_ptr<wchar_t[]> buffer(new wchar_t[buf_size + 8 + 32768]);
|
||||
@@ -41,10 +42,10 @@ static std::unique_ptr<wchar_t[]> to_wchar(const std::string& source)
|
||||
std::memcpy(buffer.get() + 32768 + 4, L"UNC\\", 4 * sizeof(wchar_t));
|
||||
}
|
||||
|
||||
verify("to_wchar" HERE), MultiByteToWideChar(CP_UTF8, 0, source.c_str(), size, buffer.get() + 32768 + (unc ? 8 : 4), size);
|
||||
ensure(MultiByteToWideChar(CP_UTF8, 0, source.c_str(), size, buffer.get() + 32768 + (unc ? 8 : 4), size)); // "to_wchar"
|
||||
|
||||
// Canonicalize wide path (replace '/', ".", "..", \\ repetitions, etc)
|
||||
verify("to_wchar" HERE), GetFullPathNameW(buffer.get() + 32768, 32768, buffer.get(), nullptr) - 1 < 32768 - 1;
|
||||
ensure(GetFullPathNameW(buffer.get() + 32768, 32768, buffer.get(), nullptr) - 1 < 32768 - 1); // "to_wchar"
|
||||
|
||||
return buffer;
|
||||
}
|
||||
@@ -52,10 +53,10 @@ static std::unique_ptr<wchar_t[]> to_wchar(const std::string& source)
|
||||
static void to_utf8(std::string& out, const wchar_t* source)
|
||||
{
|
||||
// String size
|
||||
const std::size_t length = std::wcslen(source);
|
||||
const usz length = std::wcslen(source);
|
||||
|
||||
// Safe buffer size for max possible output length (including null terminator)
|
||||
const int buf_size = narrow<int>(length * 3 + 1, "to_utf8" HERE);
|
||||
const int buf_size = narrow<int>(length * 3 + 1);
|
||||
|
||||
// Resize buffer
|
||||
out.resize(buf_size - 1);
|
||||
@@ -63,7 +64,7 @@ static void to_utf8(std::string& out, const wchar_t* source)
|
||||
const int result = WideCharToMultiByte(CP_UTF8, 0, source, static_cast<int>(length) + 1, &out.front(), buf_size, NULL, NULL);
|
||||
|
||||
// Fix the size
|
||||
out.resize(verify("to_utf8" HERE, result) - 1);
|
||||
out.resize(ensure(result) - 1);
|
||||
}
|
||||
|
||||
static time_t to_time(const ULARGE_INTEGER& ft)
|
||||
@@ -129,8 +130,8 @@ static fs::error to_error(DWORD e)
|
||||
case ERROR_DIR_NOT_EMPTY: return fs::error::notempty;
|
||||
case ERROR_NOT_READY: return fs::error::noent;
|
||||
case ERROR_FILENAME_EXCED_RANGE: return fs::error::toolong;
|
||||
//case ERROR_INVALID_PARAMETER: return fs::error::inval;
|
||||
default: fmt::throw_exception("Unknown Win32 error: %u.", e);
|
||||
case ERROR_DISK_FULL: return fs::error::nospace;
|
||||
default: return fs::error::unknown;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -171,7 +172,8 @@ static fs::error to_error(int e)
|
||||
case ENOTEMPTY: return fs::error::notempty;
|
||||
case EROFS: return fs::error::readonly;
|
||||
case EISDIR: return fs::error::isdir;
|
||||
default: fmt::throw_exception("Unknown system error: %d.", e);
|
||||
case ENOSPC: return fs::error::nospace;
|
||||
default: return fs::error::unknown;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -181,7 +183,7 @@ static std::string path_append(std::string_view path, std::string_view more)
|
||||
{
|
||||
std::string result;
|
||||
|
||||
if (const size_t src_slash_pos = path.find_last_not_of('/'); src_slash_pos != path.npos)
|
||||
if (const usz src_slash_pos = path.find_last_not_of('/'); src_slash_pos != path.npos)
|
||||
{
|
||||
path.remove_suffix(path.length() - src_slash_pos - 1);
|
||||
result = path;
|
||||
@@ -189,7 +191,7 @@ static std::string path_append(std::string_view path, std::string_view more)
|
||||
|
||||
result.push_back('/');
|
||||
|
||||
if (const size_t dst_slash_pos = more.find_first_not_of('/'); dst_slash_pos != more.npos)
|
||||
if (const usz dst_slash_pos = more.find_first_not_of('/'); dst_slash_pos != more.npos)
|
||||
{
|
||||
more.remove_prefix(dst_slash_pos);
|
||||
result.append(more);
|
||||
@@ -304,7 +306,7 @@ std::shared_ptr<fs::device_base> fs::device_manager::set_device(const std::strin
|
||||
std::shared_ptr<fs::device_base> fs::get_virtual_device(const std::string& path)
|
||||
{
|
||||
// Every virtual device path must have "//" at the beginning
|
||||
if (path.size() > 2 && reinterpret_cast<const u16&>(path.front()) == "//"_u16)
|
||||
if (path.starts_with("//"))
|
||||
{
|
||||
return get_device_manager().get_device(path);
|
||||
}
|
||||
@@ -314,33 +316,19 @@ std::shared_ptr<fs::device_base> fs::get_virtual_device(const std::string& path)
|
||||
|
||||
std::shared_ptr<fs::device_base> fs::set_virtual_device(const std::string& name, const std::shared_ptr<device_base>& device)
|
||||
{
|
||||
verify(HERE), name.size() > 2, name[0] == '/', name[1] == '/', name.find('/', 2) == -1;
|
||||
ensure(name.starts_with("//") && name[2] != '/');
|
||||
|
||||
return get_device_manager().set_device(name, device);
|
||||
}
|
||||
|
||||
std::string fs::get_parent_dir(const std::string& path)
|
||||
{
|
||||
// Search upper bound (set to the last character, npos for empty string)
|
||||
auto last = path.size() - 1;
|
||||
// Get (basically) processed path
|
||||
const auto real_path = fs::escape_path(path);
|
||||
|
||||
#ifdef _WIN32
|
||||
const auto& delim = "/\\";
|
||||
#else
|
||||
const auto& delim = "/";
|
||||
#endif
|
||||
const auto pos = real_path.find_last_of(delim);
|
||||
|
||||
while (true)
|
||||
{
|
||||
const auto pos = path.find_last_of(delim, last, sizeof(delim) - 1);
|
||||
|
||||
// Contiguous slashes are ignored at the end
|
||||
if (std::exchange(last, pos - 1) != pos)
|
||||
{
|
||||
// Return empty string if the path doesn't contain at least 2 elements
|
||||
return path.substr(0, pos != -1 && path.find_last_not_of(delim, pos, sizeof(delim) - 1) != -1 ? pos : 0);
|
||||
}
|
||||
}
|
||||
return real_path.substr(0, pos == umax ? 0 : pos);
|
||||
}
|
||||
|
||||
bool fs::stat(const std::string& path, stat_t& info)
|
||||
@@ -351,16 +339,83 @@ bool fs::stat(const std::string& path, stat_t& info)
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
WIN32_FILE_ATTRIBUTE_DATA attrs;
|
||||
if (!GetFileAttributesExW(to_wchar(path).get(), GetFileExInfoStandard, &attrs))
|
||||
std::string_view epath = path;
|
||||
|
||||
// '/' and '\\' Not allowed by FindFirstFileExW at the end of path but we should allow it
|
||||
if (auto not_del = epath.find_last_not_of(delim); not_del != umax && not_del != epath.size() - 1)
|
||||
{
|
||||
epath.remove_suffix(epath.size() - 1 - not_del);
|
||||
}
|
||||
|
||||
// Handle drives specially
|
||||
if (epath.find_first_of(delim) == umax && epath.ends_with(':'))
|
||||
{
|
||||
WIN32_FILE_ATTRIBUTE_DATA attrs;
|
||||
|
||||
// Must end with a delimiter
|
||||
if (!GetFileAttributesExW(to_wchar(std::string(epath) + '/').get(), GetFileExInfoStandard, &attrs))
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
return false;
|
||||
}
|
||||
|
||||
info.is_directory = true; // Handle drives as directories
|
||||
info.is_writable = (attrs.dwFileAttributes & FILE_ATTRIBUTE_READONLY) == 0;
|
||||
info.size = attrs.nFileSizeLow | (u64{attrs.nFileSizeHigh} << 32);
|
||||
info.atime = to_time(attrs.ftLastAccessTime);
|
||||
info.mtime = to_time(attrs.ftLastWriteTime);
|
||||
info.ctime = info.mtime;
|
||||
|
||||
if (info.atime < info.mtime)
|
||||
info.atime = info.mtime;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
WIN32_FIND_DATA attrs;
|
||||
|
||||
// Allowed by FindFirstFileExW but we should not allow it
|
||||
if (epath.ends_with("*"))
|
||||
{
|
||||
g_tls_error = fs::error::noent;
|
||||
return false;
|
||||
}
|
||||
|
||||
const auto wchar_ptr = to_wchar(std::string(epath));
|
||||
const std::wstring_view wpath_view = wchar_ptr.get();
|
||||
|
||||
const HANDLE handle = FindFirstFileExW(wpath_view.data(), FindExInfoStandard, &attrs, FindExSearchNameMatch, nullptr, FIND_FIRST_EX_CASE_SENSITIVE);
|
||||
|
||||
if (handle == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
return false;
|
||||
}
|
||||
|
||||
struct close_t
|
||||
{
|
||||
HANDLE handle;
|
||||
~close_t() { FindClose(handle); }
|
||||
};
|
||||
|
||||
for (close_t find_manage{handle}; attrs.cFileName != wpath_view.substr(wpath_view.find_last_of(wdelim) + 1);)
|
||||
{
|
||||
if (!FindNextFileW(handle, &attrs))
|
||||
{
|
||||
if (const DWORD err = GetLastError(); err != ERROR_NO_MORE_FILES)
|
||||
{
|
||||
g_tls_error = to_error(err);
|
||||
return false;
|
||||
}
|
||||
|
||||
g_tls_error = fs::error::noent;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
info.is_directory = (attrs.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0;
|
||||
info.is_writable = (attrs.dwFileAttributes & FILE_ATTRIBUTE_READONLY) == 0;
|
||||
info.size = (u64)attrs.nFileSizeLow | ((u64)attrs.nFileSizeHigh << 32);
|
||||
info.size = attrs.nFileSizeLow | (u64{attrs.nFileSizeHigh} << 32);
|
||||
info.atime = to_time(attrs.ftLastAccessTime);
|
||||
info.mtime = to_time(attrs.ftLastWriteTime);
|
||||
info.ctime = info.mtime;
|
||||
@@ -388,73 +443,19 @@ bool fs::stat(const std::string& path, stat_t& info)
|
||||
|
||||
bool fs::exists(const std::string& path)
|
||||
{
|
||||
if (auto device = get_virtual_device(path))
|
||||
{
|
||||
stat_t info;
|
||||
return device->stat(path, info);
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
if (GetFileAttributesW(to_wchar(path).get()) == INVALID_FILE_ATTRIBUTES)
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
#else
|
||||
struct ::stat file_info;
|
||||
if (::stat(path.c_str(), &file_info) != 0)
|
||||
{
|
||||
g_tls_error = to_error(errno);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
#endif
|
||||
fs::stat_t info{};
|
||||
return fs::stat(path, info);
|
||||
}
|
||||
|
||||
bool fs::is_file(const std::string& path)
|
||||
{
|
||||
if (auto device = get_virtual_device(path))
|
||||
fs::stat_t info{};
|
||||
if (!fs::stat(path, info))
|
||||
{
|
||||
stat_t info;
|
||||
if (!device->stat(path, info))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (info.is_directory)
|
||||
{
|
||||
g_tls_error = error::exist;
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
const DWORD attrs = GetFileAttributesW(to_wchar(path).get());
|
||||
if (attrs == INVALID_FILE_ATTRIBUTES)
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
return false;
|
||||
}
|
||||
#else
|
||||
struct ::stat file_info;
|
||||
if (::stat(path.c_str(), &file_info) != 0)
|
||||
{
|
||||
g_tls_error = to_error(errno);
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
// TODO: correct file type check
|
||||
#ifdef _WIN32
|
||||
if ((attrs & FILE_ATTRIBUTE_DIRECTORY) != 0)
|
||||
#else
|
||||
if (S_ISDIR(file_info.st_mode))
|
||||
#endif
|
||||
if (info.is_directory)
|
||||
{
|
||||
g_tls_error = error::exist;
|
||||
return false;
|
||||
@@ -465,44 +466,13 @@ bool fs::is_file(const std::string& path)
|
||||
|
||||
bool fs::is_dir(const std::string& path)
|
||||
{
|
||||
if (auto device = get_virtual_device(path))
|
||||
fs::stat_t info{};
|
||||
if (!fs::stat(path, info))
|
||||
{
|
||||
stat_t info;
|
||||
if (!device->stat(path, info))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (info.is_directory == false)
|
||||
{
|
||||
g_tls_error = error::exist;
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
const DWORD attrs = GetFileAttributesW(to_wchar(path).get());
|
||||
if (attrs == INVALID_FILE_ATTRIBUTES)
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
return false;
|
||||
}
|
||||
#else
|
||||
struct ::stat file_info;
|
||||
if (::stat(path.c_str(), &file_info) != 0)
|
||||
{
|
||||
g_tls_error = to_error(errno);
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
if ((attrs & FILE_ATTRIBUTE_DIRECTORY) == 0)
|
||||
#else
|
||||
if (!S_ISDIR(file_info.st_mode))
|
||||
#endif
|
||||
if (!info.is_directory)
|
||||
{
|
||||
g_tls_error = error::exist;
|
||||
return false;
|
||||
@@ -537,7 +507,7 @@ bool fs::statfs(const std::string& path, fs::device_stat& info)
|
||||
// Keep cutting path from right until it's short enough
|
||||
while (str.size() > 256)
|
||||
{
|
||||
if (std::size_t x = str.find_last_of('\\') + 1)
|
||||
if (usz x = str.find_last_of('\\') + 1)
|
||||
str.resize(x - 1);
|
||||
else
|
||||
break;
|
||||
@@ -780,7 +750,7 @@ bool fs::copy_file(const std::string& from, const std::string& to, bool overwrit
|
||||
// sendfile will work with non-socket output (i.e. regular file) on Linux 2.6.33+
|
||||
off_t bytes_copied = 0;
|
||||
struct ::stat fileinfo = { 0 };
|
||||
if (::fstat(input, &fileinfo) || ::sendfile(output, input, &bytes_copied, fileinfo.st_size))
|
||||
if (::fstat(input, &fileinfo) == -1 || ::sendfile(output, input, &bytes_copied, fileinfo.st_size) == -1)
|
||||
#else
|
||||
#error "Native file copy implementation is missing"
|
||||
#endif
|
||||
@@ -898,7 +868,7 @@ bool fs::utime(const std::string& path, s64 atime, s64 mtime)
|
||||
|
||||
#ifdef _WIN32
|
||||
// Open the file
|
||||
const auto handle = CreateFileW(to_wchar(path).get(), FILE_WRITE_ATTRIBUTES, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
const auto handle = CreateFileW(to_wchar(path).get(), FILE_WRITE_ATTRIBUTES, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS | FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
if (handle == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
g_tls_error = to_error(GetLastError());
|
||||
@@ -931,14 +901,19 @@ bool fs::utime(const std::string& path, s64 atime, s64 mtime)
|
||||
#endif
|
||||
}
|
||||
|
||||
void fs::file::xnull() const
|
||||
[[noreturn]] void fs::xnull(const src_loc& loc)
|
||||
{
|
||||
fmt::throw_exception("fs::file is null");
|
||||
fmt::throw_exception("Null object.%s", loc);
|
||||
}
|
||||
|
||||
void fs::file::xfail() const
|
||||
[[noreturn]] void fs::xfail(const src_loc& loc)
|
||||
{
|
||||
fmt::throw_exception("Unexpected fs::error %s", g_tls_error);
|
||||
fmt::throw_exception("Unexpected fs::error %s%s", g_tls_error, loc);
|
||||
}
|
||||
|
||||
[[noreturn]] void fs::xovfl()
|
||||
{
|
||||
fmt::throw_exception("Stream overflow.");
|
||||
}
|
||||
|
||||
fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
@@ -984,7 +959,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
disp = mode & fs::trunc ? TRUNCATE_EXISTING : OPEN_EXISTING;
|
||||
}
|
||||
|
||||
DWORD share = 0;
|
||||
DWORD share = FILE_SHARE_DELETE;
|
||||
if (!(mode & fs::unread) || !(mode & fs::write))
|
||||
{
|
||||
share |= FILE_SHARE_READ;
|
||||
@@ -992,7 +967,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
|
||||
if (!(mode & (fs::lock + fs::unread)) || !(mode & fs::write))
|
||||
{
|
||||
share |= FILE_SHARE_WRITE | FILE_SHARE_DELETE;
|
||||
share |= FILE_SHARE_WRITE;
|
||||
}
|
||||
|
||||
const HANDLE handle = CreateFileW(to_wchar(path).get(), access, share, NULL, disp, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
@@ -1021,7 +996,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
stat_t stat() override
|
||||
{
|
||||
FILE_BASIC_INFO basic_info;
|
||||
verify("file::stat" HERE), GetFileInformationByHandleEx(m_handle, FileBasicInfo, &basic_info, sizeof(FILE_BASIC_INFO));
|
||||
ensure(GetFileInformationByHandleEx(m_handle, FileBasicInfo, &basic_info, sizeof(FILE_BASIC_INFO))); // "file::stat"
|
||||
|
||||
stat_t info;
|
||||
info.is_directory = (basic_info.FileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0;
|
||||
@@ -1039,7 +1014,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
|
||||
void sync() override
|
||||
{
|
||||
verify("file::sync" HERE), FlushFileBuffers(m_handle);
|
||||
ensure(FlushFileBuffers(m_handle)); // "file::sync"
|
||||
}
|
||||
|
||||
bool trunc(u64 length) override
|
||||
@@ -1059,10 +1034,10 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 read(void* buffer, u64 count) override
|
||||
{
|
||||
// TODO (call ReadFile multiple times if count is too big)
|
||||
const int size = narrow<int>(count, "file::read" HERE);
|
||||
const int size = narrow<int>(count);
|
||||
|
||||
DWORD nread;
|
||||
verify("file::read" HERE), ReadFile(m_handle, buffer, size, &nread, NULL);
|
||||
ensure(ReadFile(m_handle, buffer, size, &nread, NULL)); // "file::read"
|
||||
|
||||
return nread;
|
||||
}
|
||||
@@ -1070,10 +1045,10 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 write(const void* buffer, u64 count) override
|
||||
{
|
||||
// TODO (call WriteFile multiple times if count is too big)
|
||||
const int size = narrow<int>(count, "file::write" HERE);
|
||||
const int size = narrow<int>(count);
|
||||
|
||||
DWORD nwritten;
|
||||
verify("file::write" HERE), WriteFile(m_handle, buffer, size, &nwritten, NULL);
|
||||
ensure(WriteFile(m_handle, buffer, size, &nwritten, NULL)); // "file::write"
|
||||
|
||||
return nwritten;
|
||||
}
|
||||
@@ -1087,7 +1062,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
whence == seek_set ? FILE_BEGIN :
|
||||
whence == seek_cur ? FILE_CURRENT :
|
||||
whence == seek_end ? FILE_END :
|
||||
(fmt::throw_exception("Invalid whence (0x%x)" HERE, whence), 0);
|
||||
(fmt::throw_exception("Invalid whence (0x%x)", whence), 0);
|
||||
|
||||
if (!SetFilePointerEx(m_handle, pos, &pos, mode))
|
||||
{
|
||||
@@ -1101,7 +1076,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 size() override
|
||||
{
|
||||
LARGE_INTEGER size;
|
||||
verify("file::size" HERE), GetFileSizeEx(m_handle, &size);
|
||||
ensure(GetFileSizeEx(m_handle, &size)); // "file::size"
|
||||
|
||||
return size.QuadPart;
|
||||
}
|
||||
@@ -1147,10 +1122,10 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
return;
|
||||
}
|
||||
|
||||
if (mode & fs::trunc && mode & (fs::lock + fs::unread))
|
||||
if (mode & fs::trunc && mode & (fs::lock + fs::unread) && mode & fs::write)
|
||||
{
|
||||
// Postpone truncation in order to avoid using O_TRUNC on a locked file
|
||||
verify(HERE), ::ftruncate(fd, 0) == 0;
|
||||
ensure(::ftruncate(fd, 0) == 0);
|
||||
}
|
||||
|
||||
class unix_file final : public file_base
|
||||
@@ -1171,7 +1146,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
stat_t stat() override
|
||||
{
|
||||
struct ::stat file_info;
|
||||
verify("file::stat" HERE), ::fstat(m_fd, &file_info) == 0;
|
||||
ensure(::fstat(m_fd, &file_info) == 0); // "file::stat"
|
||||
|
||||
stat_t info;
|
||||
info.is_directory = S_ISDIR(file_info.st_mode);
|
||||
@@ -1189,7 +1164,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
|
||||
void sync() override
|
||||
{
|
||||
verify("file::sync" HERE), ::fsync(m_fd) == 0;
|
||||
ensure(::fsync(m_fd) == 0); // "file::sync"
|
||||
}
|
||||
|
||||
bool trunc(u64 length) override
|
||||
@@ -1206,7 +1181,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 read(void* buffer, u64 count) override
|
||||
{
|
||||
const auto result = ::read(m_fd, buffer, count);
|
||||
verify("file::read" HERE), result != -1;
|
||||
ensure(result != -1); // "file::read"
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -1214,7 +1189,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 write(const void* buffer, u64 count) override
|
||||
{
|
||||
const auto result = ::write(m_fd, buffer, count);
|
||||
verify("file::write" HERE), result != -1;
|
||||
ensure(result != -1); // "file::write"
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -1225,7 +1200,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
whence == seek_set ? SEEK_SET :
|
||||
whence == seek_cur ? SEEK_CUR :
|
||||
whence == seek_end ? SEEK_END :
|
||||
(fmt::throw_exception("Invalid whence (0x%x)" HERE, whence), 0);
|
||||
(fmt::throw_exception("Invalid whence (0x%x)", whence), 0);
|
||||
|
||||
const auto result = ::lseek(m_fd, offset, mode);
|
||||
|
||||
@@ -1241,7 +1216,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
u64 size() override
|
||||
{
|
||||
struct ::stat file_info;
|
||||
verify("file::size" HERE), ::fstat(m_fd, &file_info) == 0;
|
||||
ensure(::fstat(m_fd, &file_info) == 0); // "file::size"
|
||||
|
||||
return file_info.st_size;
|
||||
}
|
||||
@@ -1257,7 +1232,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
static_assert(offsetof(iovec, iov_len) == offsetof(iovec_clone, iov_len), "Weird iovec::iov_len offset");
|
||||
|
||||
const auto result = ::writev(m_fd, reinterpret_cast<const iovec*>(buffers), buf_count);
|
||||
verify("file::write_gather" HERE), result != -1;
|
||||
ensure(result != -1); // "file::write_gather"
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -1267,7 +1242,7 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
|
||||
#endif
|
||||
}
|
||||
|
||||
fs::file::file(const void* ptr, std::size_t size)
|
||||
fs::file::file(const void* ptr, usz size)
|
||||
{
|
||||
class memory_stream : public file_base
|
||||
{
|
||||
@@ -1314,8 +1289,7 @@ fs::file::file(const void* ptr, std::size_t size)
|
||||
const s64 new_pos =
|
||||
whence == fs::seek_set ? offset :
|
||||
whence == fs::seek_cur ? offset + m_pos :
|
||||
whence == fs::seek_end ? offset + size() :
|
||||
(fmt::raw_error("fs::file::memory_stream::seek(): invalid whence"), 0);
|
||||
whence == fs::seek_end ? offset + size() : -1;
|
||||
|
||||
if (new_pos < 0)
|
||||
{
|
||||
@@ -1350,11 +1324,6 @@ fs::native_handle fs::file::get_handle() const
|
||||
#endif
|
||||
}
|
||||
|
||||
void fs::dir::xnull() const
|
||||
{
|
||||
fmt::throw_exception("fs::dir is null");
|
||||
}
|
||||
|
||||
bool fs::dir::open(const std::string& path)
|
||||
{
|
||||
if (path.empty())
|
||||
@@ -1388,7 +1357,7 @@ bool fs::dir::open(const std::string& path)
|
||||
class windows_dir final : public dir_base
|
||||
{
|
||||
std::vector<dir_entry> m_entries;
|
||||
std::size_t m_pos = 0;
|
||||
usz m_pos = 0;
|
||||
|
||||
void add_entry(const WIN32_FIND_DATAW& found)
|
||||
{
|
||||
@@ -1418,7 +1387,7 @@ bool fs::dir::open(const std::string& path)
|
||||
add_entry(found);
|
||||
}
|
||||
|
||||
verify("dir::read" HERE), ERROR_NO_MORE_FILES == GetLastError();
|
||||
ensure(ERROR_NO_MORE_FILES == GetLastError()); // "dir::read"
|
||||
FindClose(handle);
|
||||
}
|
||||
|
||||
@@ -1605,15 +1574,14 @@ bool fs::remove_all(const std::string& path, bool remove_root)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (entry.is_directory == false)
|
||||
if (!entry.is_directory)
|
||||
{
|
||||
if (!remove_file(path_append(path, entry.name)))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (entry.is_directory == true)
|
||||
else
|
||||
{
|
||||
if (!remove_all(path_append(path, entry.name)))
|
||||
{
|
||||
@@ -1635,25 +1603,142 @@ bool fs::remove_all(const std::string& path, bool remove_root)
|
||||
return true;
|
||||
}
|
||||
|
||||
std::string fs::escape_path(std::string_view path)
|
||||
{
|
||||
std::string real; real.resize(path.size());
|
||||
|
||||
auto get_char = [&](usz& from, usz& to, usz count)
|
||||
{
|
||||
std::memcpy(&real[to], &path[from], count);
|
||||
from += count, to += count;
|
||||
};
|
||||
|
||||
usz i = 0, j = -1, pos_nondelim = 0, after_delim = 0;
|
||||
|
||||
if (i < path.size())
|
||||
{
|
||||
j = 0;
|
||||
}
|
||||
|
||||
for (; i < path.size();)
|
||||
{
|
||||
real[j] = path[i];
|
||||
#ifdef _Win32
|
||||
if (real[j] == '\\')
|
||||
{
|
||||
real[j] = '/';
|
||||
}
|
||||
#endif
|
||||
// If the current character was preceeded by a delimiter special treatment is required:
|
||||
// If another deleimiter is encountered, remove it (do not write it to output string)
|
||||
// Otherwise test if it is a "." or ".." sequence.
|
||||
if (std::exchange(after_delim, path[i] == delim[0] || path[i] == delim[1]))
|
||||
{
|
||||
if (!after_delim)
|
||||
{
|
||||
if (real[j] == '.')
|
||||
{
|
||||
if (i + 1 == path.size())
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
get_char(i, j, 1);
|
||||
|
||||
switch (real[j])
|
||||
{
|
||||
case '.':
|
||||
{
|
||||
bool remove_element = true;
|
||||
usz k = 1;
|
||||
|
||||
for (; k + i != path.size(); k++)
|
||||
{
|
||||
switch (path[i + k])
|
||||
{
|
||||
case '.': continue;
|
||||
case delim[0]: case delim[1]: break;
|
||||
default: remove_element = false; break;
|
||||
}
|
||||
}
|
||||
|
||||
if (remove_element)
|
||||
{
|
||||
if (i == 1u)
|
||||
{
|
||||
j = pos_nondelim;
|
||||
real[j] = '\0';// Ensure termination at this posistion
|
||||
after_delim = true;
|
||||
i += k;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
get_char(i, j, k);
|
||||
continue;
|
||||
}
|
||||
case '/':
|
||||
{
|
||||
i++;
|
||||
after_delim = true;
|
||||
continue;
|
||||
}
|
||||
default: get_char(i, j, 1); continue;
|
||||
}
|
||||
}
|
||||
|
||||
pos_nondelim = j;
|
||||
get_char(i, j, 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
i++;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
get_char(i, j, 1);
|
||||
}
|
||||
}
|
||||
|
||||
if (j != umax && (real[j] == delim[0] || real[j] == delim[1])) j--; // Do not include a delmiter at the end
|
||||
|
||||
real.resize(j + 1);
|
||||
return real;
|
||||
}
|
||||
|
||||
u64 fs::get_dir_size(const std::string& path, u64 rounding_alignment)
|
||||
{
|
||||
u64 result = 0;
|
||||
|
||||
for (const auto entry : dir(path))
|
||||
const auto root_dir = dir(path);
|
||||
|
||||
if (!root_dir)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
for (const auto& entry : root_dir)
|
||||
{
|
||||
if (entry.name == "." || entry.name == "..")
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (entry.is_directory == false)
|
||||
if (!entry.is_directory)
|
||||
{
|
||||
result += ::align(entry.size, rounding_alignment);
|
||||
result += utils::align(entry.size, rounding_alignment);
|
||||
}
|
||||
|
||||
if (entry.is_directory == true)
|
||||
else
|
||||
{
|
||||
result += get_dir_size(path_append(path, entry.name), rounding_alignment);
|
||||
const u64 size = get_dir_size(path_append(path, entry.name), rounding_alignment);
|
||||
|
||||
if (size == umax)
|
||||
{
|
||||
return size;
|
||||
}
|
||||
|
||||
result += size;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1752,8 +1837,7 @@ fs::file fs::make_gather(std::vector<fs::file> files)
|
||||
const s64 new_pos =
|
||||
whence == fs::seek_set ? offset :
|
||||
whence == fs::seek_cur ? offset + pos :
|
||||
whence == fs::seek_end ? offset + end :
|
||||
(fmt::raw_error("fs::gather_stream::seek(): invalid whence"), 0);
|
||||
whence == fs::seek_end ? offset + end : -1;
|
||||
|
||||
if (new_pos < 0)
|
||||
{
|
||||
@@ -1809,6 +1893,8 @@ void fmt_class_string<fs::error>::format(std::string& out, u64 arg)
|
||||
case fs::error::readonly: return "Read only";
|
||||
case fs::error::isdir: return "Is a directory";
|
||||
case fs::error::toolong: return "Path too long";
|
||||
case fs::error::nospace: return "Not enough space on the device";
|
||||
case fs::error::unknown: return "Unknown system error";
|
||||
}
|
||||
|
||||
return unknown;
|
||||
|
||||
+174
-70
@@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
#pragma once // No BOM and only basic ASCII in this header, or a neko will die
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "bit_set.h"
|
||||
|
||||
#include <memory>
|
||||
@@ -8,12 +8,15 @@
|
||||
#include <vector>
|
||||
#include <algorithm>
|
||||
|
||||
|
||||
namespace fs
|
||||
{
|
||||
#ifdef _WIN32
|
||||
static constexpr auto& delim = "/\\";
|
||||
static constexpr auto& wdelim = L"/\\";
|
||||
using native_handle = void*;
|
||||
#else
|
||||
static constexpr auto& delim = "/";
|
||||
static constexpr auto& wdelim = L"/";
|
||||
using native_handle = int;
|
||||
#endif
|
||||
|
||||
@@ -70,7 +73,7 @@ namespace fs
|
||||
struct iovec_clone
|
||||
{
|
||||
const void* iov_base;
|
||||
std::size_t iov_len;
|
||||
usz iov_len;
|
||||
};
|
||||
|
||||
// File handle base
|
||||
@@ -131,6 +134,12 @@ namespace fs
|
||||
virtual std::unique_ptr<dir_base> open_dir(const std::string& path) = 0;
|
||||
};
|
||||
|
||||
[[noreturn]] void xnull(const src_loc&);
|
||||
[[noreturn]] void xfail(const src_loc&);
|
||||
[[noreturn]] void xovfl();
|
||||
|
||||
constexpr struct pod_tag_t{} pod_tag;
|
||||
|
||||
// Get virtual device for specified path (nullptr for real path)
|
||||
std::shared_ptr<device_base> get_virtual_device(const std::string& path);
|
||||
|
||||
@@ -183,9 +192,6 @@ namespace fs
|
||||
{
|
||||
std::unique_ptr<file_base> m_file;
|
||||
|
||||
[[noreturn]] void xnull() const;
|
||||
[[noreturn]] void xfail() const;
|
||||
|
||||
public:
|
||||
// Default constructor
|
||||
file() = default;
|
||||
@@ -194,7 +200,7 @@ namespace fs
|
||||
explicit file(const std::string& path, bs_t<open_mode> mode = ::fs::read);
|
||||
|
||||
// Open memory for read
|
||||
explicit file(const void* ptr, std::size_t size);
|
||||
explicit file(const void* ptr, usz size);
|
||||
|
||||
// Open file with specified args (forward to constructor)
|
||||
template <typename... Args>
|
||||
@@ -227,144 +233,227 @@ namespace fs
|
||||
}
|
||||
|
||||
// Change file size (possibly appending zero bytes)
|
||||
bool trunc(u64 length) const
|
||||
bool trunc(u64 length,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->trunc(length);
|
||||
}
|
||||
|
||||
// Get file information
|
||||
stat_t stat() const
|
||||
stat_t stat(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->stat();
|
||||
}
|
||||
|
||||
// Sync file buffers
|
||||
void sync() const
|
||||
void sync(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->sync();
|
||||
}
|
||||
|
||||
// Read the data from the file and return the amount of data written in buffer
|
||||
u64 read(void* buffer, u64 count) const
|
||||
u64 read(void* buffer, u64 count,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->read(buffer, count);
|
||||
}
|
||||
|
||||
// Write the data to the file and return the amount of data actually written
|
||||
u64 write(const void* buffer, u64 count) const
|
||||
u64 write(const void* buffer, u64 count,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->write(buffer, count);
|
||||
}
|
||||
|
||||
// Change current position, returns resulting position
|
||||
u64 seek(s64 offset, seek_mode whence = seek_set) const
|
||||
u64 seek(s64 offset, seek_mode whence = seek_set,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->seek(offset, whence);
|
||||
}
|
||||
|
||||
// Get file size
|
||||
u64 size() const
|
||||
u64 size(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->size();
|
||||
}
|
||||
|
||||
// Get current position
|
||||
u64 pos() const
|
||||
u64 pos(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->seek(0, seek_cur);
|
||||
}
|
||||
|
||||
// Write std::string unconditionally
|
||||
const file& write(const std::string& str) const
|
||||
// Write std::basic_string unconditionally
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, const file&> write(const std::basic_string<T>& str,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (write(str.data(), str.size()) != str.size()) xfail();
|
||||
if (write(str.data(), str.size() * sizeof(T), line, col, file, func) != str.size() * sizeof(T)) xfail({line, col, file, func});
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Write POD unconditionally
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, const file&> write(const T& data) const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, const file&> write(const T& data,
|
||||
pod_tag_t = pod_tag,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (write(std::addressof(data), sizeof(T)) != sizeof(T)) xfail();
|
||||
if (write(std::addressof(data), sizeof(T), line, col, file, func) != sizeof(T)) xfail({line, col, file, func});
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Write POD std::vector unconditionally
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, const file&> write(const std::vector<T>& vec) const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, const file&> write(const std::vector<T>& vec,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (write(vec.data(), vec.size() * sizeof(T)) != vec.size() * sizeof(T)) xfail();
|
||||
if (write(vec.data(), vec.size() * sizeof(T), line, col, file, func) != vec.size() * sizeof(T)) xfail({line, col, file, func});
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Read std::string, size must be set by resize() method
|
||||
bool read(std::string& str) const
|
||||
// Read std::basic_string, size must be set by resize() method
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, bool> read(std::basic_string<T>& str,
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION(),
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN()) const
|
||||
{
|
||||
return read(&str[0], str.size()) == str.size();
|
||||
return read(&str[0], str.size() * sizeof(T), line, col, file, func) == str.size() * sizeof(T);
|
||||
}
|
||||
|
||||
// Read std::string
|
||||
bool read(std::string& str, std::size_t size) const
|
||||
// Read std::basic_string
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, bool> read(std::basic_string<T>& str, usz size,
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION(),
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN()) const
|
||||
{
|
||||
str.resize(size);
|
||||
return read(&str[0], size) == size;
|
||||
return read(&str[0], size * sizeof(T), line, col, file, func) == size * sizeof(T);
|
||||
}
|
||||
|
||||
// Read POD, sizeof(T) is used
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, bool> read(T& data) const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, bool> read(T& data,
|
||||
pod_tag_t = pod_tag,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
return read(&data, sizeof(T)) == sizeof(T);
|
||||
return read(&data, sizeof(T), line, col, file, func) == sizeof(T);
|
||||
}
|
||||
|
||||
// Read POD std::vector, size must be set by resize() method
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, bool> read(std::vector<T>& vec) const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, bool> read(std::vector<T>& vec,
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION(),
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN()) const
|
||||
{
|
||||
return read(vec.data(), sizeof(T) * vec.size()) == sizeof(T) * vec.size();
|
||||
return read(vec.data(), sizeof(T) * vec.size(), line, col, file, func) == sizeof(T) * vec.size();
|
||||
}
|
||||
|
||||
// Read POD std::vector
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, bool> read(std::vector<T>& vec, std::size_t size) const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, bool> read(std::vector<T>& vec, usz size,
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION(),
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN()) const
|
||||
{
|
||||
vec.resize(size);
|
||||
return read(vec.data(), sizeof(T) * size) == sizeof(T) * size;
|
||||
return read(vec.data(), sizeof(T) * size, line, col, file, func) == sizeof(T) * size;
|
||||
}
|
||||
|
||||
// Read POD (experimental)
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, T> read() const
|
||||
template <typename T>
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, T> read(
|
||||
pod_tag_t = pod_tag,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
T result;
|
||||
if (!read(result)) xfail();
|
||||
if (!read(result, pod_tag, line, col, file, func)) xfail({line, col, file, func});
|
||||
return result;
|
||||
}
|
||||
|
||||
// Read full file to std::string
|
||||
std::string to_string() const
|
||||
// Read full file to std::basic_string
|
||||
template <typename T = char>
|
||||
std::basic_string<T> to_string(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
std::string result;
|
||||
result.resize(size());
|
||||
if (seek(0), !read(result)) xfail();
|
||||
std::basic_string<T> result;
|
||||
result.resize(size() / sizeof(T));
|
||||
if (seek(0), !read(result, file, func, line, col)) xfail({line, col, file, func});
|
||||
return result;
|
||||
}
|
||||
|
||||
// Read full file to std::vector
|
||||
template<typename T>
|
||||
std::enable_if_t<std::is_pod<T>::value && !std::is_pointer<T>::value, std::vector<T>> to_vector() const
|
||||
std::enable_if_t<std::is_trivially_copyable_v<T> && !std::is_pointer_v<T>, std::vector<T>> to_vector(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
std::vector<T> result;
|
||||
result.resize(size() / sizeof(T));
|
||||
if (seek(0), !read(result)) xfail();
|
||||
if (seek(0), !read(result, file, func, line, col)) xfail({line, col, file, func});
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -372,9 +461,13 @@ namespace fs
|
||||
native_handle get_handle() const;
|
||||
|
||||
// Gathered write
|
||||
u64 write_gather(const iovec_clone* buffers, u64 buf_count) const
|
||||
u64 write_gather(const iovec_clone* buffers, u64 buf_count,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_file) xnull();
|
||||
if (!m_file) xnull({line, col, file, func});
|
||||
return m_file->write_gather(buffers, buf_count);
|
||||
}
|
||||
};
|
||||
@@ -383,8 +476,6 @@ namespace fs
|
||||
{
|
||||
std::unique_ptr<dir_base> m_dir;
|
||||
|
||||
[[noreturn]] void xnull() const;
|
||||
|
||||
public:
|
||||
dir() = default;
|
||||
|
||||
@@ -420,16 +511,24 @@ namespace fs
|
||||
}
|
||||
|
||||
// Get next directory entry
|
||||
bool read(dir_entry& out) const
|
||||
bool read(dir_entry& out,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_dir) xnull();
|
||||
if (!m_dir) xnull({line, col, file, func});
|
||||
return m_dir->read(out);
|
||||
}
|
||||
|
||||
// Reset to the beginning
|
||||
void rewind() const
|
||||
void rewind(
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION()) const
|
||||
{
|
||||
if (!m_dir) xnull();
|
||||
if (!m_dir) xnull({line, col, file, func});
|
||||
return m_dir->rewind();
|
||||
}
|
||||
|
||||
@@ -498,6 +597,9 @@ namespace fs
|
||||
// Get common cache directory
|
||||
const std::string& get_cache_dir();
|
||||
|
||||
// Get real path for comparisons (TODO: investigate std::filesystem::path::compare implementation)
|
||||
std::string escape_path(std::string_view path);
|
||||
|
||||
// Delete directory and all its contents recursively
|
||||
bool remove_all(const std::string& path, bool remove_root = true);
|
||||
|
||||
@@ -516,6 +618,8 @@ namespace fs
|
||||
readonly,
|
||||
isdir,
|
||||
toolong,
|
||||
nospace,
|
||||
unknown
|
||||
};
|
||||
|
||||
// Error code returned
|
||||
@@ -570,7 +674,7 @@ namespace fs
|
||||
|
||||
if (old_size + size < old_size)
|
||||
{
|
||||
fmt::raw_error("fs::container_stream<>::write(): overflow");
|
||||
xovfl();
|
||||
}
|
||||
|
||||
if (pos > old_size)
|
||||
@@ -597,8 +701,7 @@ namespace fs
|
||||
const s64 new_pos =
|
||||
whence == fs::seek_set ? offset :
|
||||
whence == fs::seek_cur ? offset + pos :
|
||||
whence == fs::seek_end ? offset + size() :
|
||||
(fmt::raw_error("fs::container_stream<>::seek(): invalid whence"), 0);
|
||||
whence == fs::seek_end ? offset + size() : -1;
|
||||
|
||||
if (new_pos < 0)
|
||||
{
|
||||
@@ -627,7 +730,8 @@ namespace fs
|
||||
template <typename... Args>
|
||||
bool write_file(const std::string& path, bs_t<fs::open_mode> mode, const Args&... args)
|
||||
{
|
||||
if (fs::file f{path, mode})
|
||||
// Always use write flag, remove read flag
|
||||
if (fs::file f{path, mode + fs::write - fs::read})
|
||||
{
|
||||
// Write args sequentially
|
||||
(f.write(args), ...);
|
||||
|
||||
+213
-645
File diff suppressed because it is too large
Load Diff
+73
-24
@@ -41,7 +41,7 @@ struct jit_runtime final : asmjit::HostRuntime
|
||||
asmjit::Error _release(void* p) noexcept override;
|
||||
|
||||
// Allocate memory
|
||||
static u8* alloc(std::size_t size, uint align, bool exec = true) noexcept;
|
||||
static u8* alloc(usz size, uint align, bool exec = true) noexcept;
|
||||
|
||||
// Should be called at least once after global initialization
|
||||
static void initialize();
|
||||
@@ -53,18 +53,77 @@ struct jit_runtime final : asmjit::HostRuntime
|
||||
namespace asmjit
|
||||
{
|
||||
// Should only be used to build global functions
|
||||
asmjit::JitRuntime& get_global_runtime();
|
||||
asmjit::Runtime& get_global_runtime();
|
||||
|
||||
// Emit xbegin and adjacent loop, return label at xbegin
|
||||
void build_transaction_enter(X86Assembler& c, Label fallback, const X86Gp& ctr, uint less_than);
|
||||
// Emit xbegin and adjacent loop, return label at xbegin (don't use xabort please)
|
||||
template <typename F>
|
||||
[[nodiscard]] inline asmjit::Label build_transaction_enter(asmjit::X86Assembler& c, asmjit::Label fallback, F func)
|
||||
{
|
||||
Label fall = c.newLabel();
|
||||
Label begin = c.newLabel();
|
||||
c.jmp(begin);
|
||||
c.bind(fall);
|
||||
|
||||
// Emit xabort
|
||||
void build_transaction_abort(X86Assembler& c, unsigned char code);
|
||||
// Don't repeat on zero status (may indicate syscall or interrupt)
|
||||
c.test(x86::eax, x86::eax);
|
||||
c.jz(fallback);
|
||||
|
||||
// First invoked after failure (can fallback to proceed, or jump anywhere else)
|
||||
func();
|
||||
|
||||
// Other bad statuses are ignored regardless of repeat flag (TODO)
|
||||
c.align(kAlignCode, 16);
|
||||
c.bind(begin);
|
||||
return fall;
|
||||
|
||||
// xbegin should be issued manually, allows to add more check before entering transaction
|
||||
}
|
||||
|
||||
// Helper to spill RDX (EDX) register for RDTSC
|
||||
inline void build_swap_rdx_with(asmjit::X86Assembler& c, std::array<X86Gp, 4>& args, const asmjit::X86Gp& with)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
c.xchg(args[1], with);
|
||||
args[1] = with;
|
||||
#else
|
||||
c.xchg(args[2], with);
|
||||
args[2] = with;
|
||||
#endif
|
||||
}
|
||||
|
||||
// Get full RDTSC value into chosen register (clobbers rax/rdx or saves only rax with other target)
|
||||
inline void build_get_tsc(asmjit::X86Assembler& c, const asmjit::X86Gp& to = asmjit::x86::rax)
|
||||
{
|
||||
if (&to != &x86::rax && &to != &x86::rdx)
|
||||
{
|
||||
// Swap to save its contents
|
||||
c.xchg(x86::rax, to);
|
||||
}
|
||||
|
||||
c.rdtsc();
|
||||
c.shl(x86::rdx, 32);
|
||||
|
||||
if (&to == &x86::rax)
|
||||
{
|
||||
c.or_(x86::rax, x86::rdx);
|
||||
}
|
||||
else if (&to == &x86::rdx)
|
||||
{
|
||||
c.or_(x86::rdx, x86::rax);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Swap back, maybe there is more effective way to do it
|
||||
c.xchg(x86::rax, to);
|
||||
c.mov(to.r32(), to.r32());
|
||||
c.or_(to.r64(), x86::rdx);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Build runtime function with asmjit::X86Assembler
|
||||
template <typename FT, typename F>
|
||||
FT build_function_asm(F&& builder)
|
||||
inline FT build_function_asm(F&& builder)
|
||||
{
|
||||
using namespace asmjit;
|
||||
|
||||
@@ -89,6 +148,7 @@ FT build_function_asm(F&& builder)
|
||||
|
||||
X86Assembler compiler(&code);
|
||||
builder(std::ref(compiler), args);
|
||||
ensure(compiler.getLastError() == 0);
|
||||
|
||||
FT result;
|
||||
|
||||
@@ -107,10 +167,9 @@ FT build_function_asm(F&& builder)
|
||||
#include <string_view>
|
||||
#include <unordered_map>
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "mutex.h"
|
||||
|
||||
#include "restore_new.h"
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(push, 0)
|
||||
#else
|
||||
@@ -127,7 +186,6 @@ FT build_function_asm(F&& builder)
|
||||
#else
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
#include "define_new_memleakdetect.h"
|
||||
|
||||
// Temporary compiler interface
|
||||
class jit_compiler final
|
||||
@@ -135,15 +193,9 @@ class jit_compiler final
|
||||
// Local LLVM context
|
||||
llvm::LLVMContext m_context;
|
||||
|
||||
// JIT Event Listener
|
||||
std::unique_ptr<struct EventListener> m_jit_el;
|
||||
|
||||
// Execution instance
|
||||
std::unique_ptr<llvm::ExecutionEngine> m_engine;
|
||||
|
||||
// Link table
|
||||
std::unordered_map<std::string, u64> m_link;
|
||||
|
||||
// Arch
|
||||
std::string m_cpu;
|
||||
|
||||
@@ -163,14 +215,17 @@ public:
|
||||
}
|
||||
|
||||
// Add module (path to obj cache dir)
|
||||
void add(std::unique_ptr<llvm::Module> module, const std::string& path);
|
||||
void add(std::unique_ptr<llvm::Module> _module, const std::string& path);
|
||||
|
||||
// Add module (not cached)
|
||||
void add(std::unique_ptr<llvm::Module> module);
|
||||
void add(std::unique_ptr<llvm::Module> _module);
|
||||
|
||||
// Add object (path to obj file)
|
||||
void add(const std::string& path);
|
||||
|
||||
// Check object file
|
||||
static bool check(const std::string& path);
|
||||
|
||||
// Finalize
|
||||
void fin();
|
||||
|
||||
@@ -179,12 +234,6 @@ public:
|
||||
|
||||
// Get CPU info
|
||||
static std::string cpu(const std::string& _cpu);
|
||||
|
||||
// Check JIT purpose
|
||||
bool is_primary() const
|
||||
{
|
||||
return !m_link.empty();
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
-123
@@ -1,123 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/atomic.hpp"
|
||||
#include "StrFmt.h"
|
||||
#include <climits>
|
||||
|
||||
namespace logs
|
||||
{
|
||||
enum class level : uint
|
||||
{
|
||||
always, // Highest log severity (unused, cannot be disabled)
|
||||
fatal,
|
||||
error,
|
||||
todo,
|
||||
success,
|
||||
warning,
|
||||
notice,
|
||||
trace, // Lowest severity (usually disabled)
|
||||
|
||||
_uninit = UINT_MAX, // Special value for delayed initialization
|
||||
};
|
||||
|
||||
struct channel;
|
||||
|
||||
// Message information
|
||||
struct message
|
||||
{
|
||||
channel* ch;
|
||||
level sev;
|
||||
|
||||
private:
|
||||
// Send log message to global logger instance
|
||||
void broadcast(const char*, const fmt_type_info*, ...) const;
|
||||
|
||||
friend struct channel;
|
||||
};
|
||||
|
||||
class listener
|
||||
{
|
||||
// Next listener (linked list)
|
||||
atomic_t<listener*> m_next{};
|
||||
|
||||
friend struct message;
|
||||
|
||||
public:
|
||||
constexpr listener() = default;
|
||||
|
||||
virtual ~listener();
|
||||
|
||||
// Process log message
|
||||
virtual void log(u64 stamp, const message& msg, const std::string& prefix, const std::string& text) = 0;
|
||||
|
||||
// Add new listener
|
||||
static void add(listener*);
|
||||
};
|
||||
|
||||
struct channel
|
||||
{
|
||||
// Channel prefix (added to every log message)
|
||||
const char* const name;
|
||||
|
||||
// The lowest logging level enabled for this channel (used for early filtering)
|
||||
atomic_t<level> enabled;
|
||||
|
||||
// Constant initialization: channel name
|
||||
constexpr channel(const char* name)
|
||||
: name(name)
|
||||
, enabled(level::_uninit)
|
||||
{
|
||||
}
|
||||
|
||||
#define GEN_LOG_METHOD(_sev)\
|
||||
const message msg_##_sev{this, level::_sev};\
|
||||
template <std::size_t N, typename... Args>\
|
||||
void _sev(const char(&fmt)[N], const Args&... args)\
|
||||
{\
|
||||
if (UNLIKELY(level::_sev <= enabled))\
|
||||
{\
|
||||
static constexpr fmt_type_info type_list[sizeof...(Args) + 1]{fmt_type_info::make<fmt_unveil_t<Args>>()...};\
|
||||
msg_##_sev.broadcast(fmt, type_list, u64{fmt_unveil<Args>::get(args)}...);\
|
||||
}\
|
||||
}
|
||||
|
||||
GEN_LOG_METHOD(fatal)
|
||||
GEN_LOG_METHOD(error)
|
||||
GEN_LOG_METHOD(todo)
|
||||
GEN_LOG_METHOD(success)
|
||||
GEN_LOG_METHOD(warning)
|
||||
GEN_LOG_METHOD(notice)
|
||||
GEN_LOG_METHOD(trace)
|
||||
|
||||
#undef GEN_LOG_METHOD
|
||||
};
|
||||
|
||||
/* Small set of predefined channels */
|
||||
|
||||
extern channel GENERAL;
|
||||
extern channel LOADER;
|
||||
extern channel MEMORY;
|
||||
extern channel RSX;
|
||||
extern channel HLE;
|
||||
extern channel PPU;
|
||||
extern channel SPU;
|
||||
|
||||
// Log level control: set all channels to level::notice
|
||||
void reset();
|
||||
|
||||
// Log level control: register channel if necessary, set channel level
|
||||
void set_level(const std::string&, level);
|
||||
}
|
||||
|
||||
#define LOG_CHANNEL(ch, ...) ::logs::channel ch(#ch, ##__VA_ARGS__)
|
||||
|
||||
// Legacy:
|
||||
|
||||
#define LOG_SUCCESS(ch, fmt, ...) logs::ch.success("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_NOTICE(ch, fmt, ...) logs::ch.notice ("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_WARNING(ch, fmt, ...) logs::ch.warning("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_ERROR(ch, fmt, ...) logs::ch.error ("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_TODO(ch, fmt, ...) logs::ch.todo ("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_TRACE(ch, fmt, ...) logs::ch.trace ("" fmt, ##__VA_ARGS__)
|
||||
#define LOG_FATAL(ch, fmt, ...) logs::ch.fatal ("" fmt, ##__VA_ARGS__)
|
||||
+133
-77
@@ -1,10 +1,13 @@
|
||||
#include "StrFmt.h"
|
||||
#include "BEType.h"
|
||||
#include "StrUtil.h"
|
||||
#include "cfmt.h"
|
||||
#include "util/endian.hpp"
|
||||
#include "util/logs.hpp"
|
||||
#include "util/v128.hpp"
|
||||
|
||||
#include <algorithm>
|
||||
#include <string_view>
|
||||
#include "Thread.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <Windows.h>
|
||||
@@ -12,6 +15,47 @@
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
std::string wchar_to_utf8(wchar_t *src)
|
||||
{
|
||||
std::string utf8_string;
|
||||
const auto tmp_size = WideCharToMultiByte(CP_UTF8, 0, src, -1, nullptr, 0, nullptr, nullptr);
|
||||
utf8_string.resize(tmp_size);
|
||||
WideCharToMultiByte(CP_UTF8, 0, src, -1, utf8_string.data(), tmp_size, nullptr, nullptr);
|
||||
return utf8_string;
|
||||
}
|
||||
|
||||
std::string wchar_path_to_ansi_path(const std::wstring& src)
|
||||
{
|
||||
std::wstring buf_short;
|
||||
std::string buf_final;
|
||||
|
||||
// Get the short path from the wide char path(short path should only contain ansi characters)
|
||||
auto tmp_size = GetShortPathNameW(src.data(), nullptr, 0);
|
||||
buf_short.resize(tmp_size);
|
||||
GetShortPathNameW(src.data(), buf_short.data(), tmp_size);
|
||||
|
||||
// Convert wide char to ansi
|
||||
tmp_size = WideCharToMultiByte(CP_ACP, 0, buf_short.data(), -1, nullptr, 0, nullptr, nullptr);
|
||||
buf_final.resize(tmp_size);
|
||||
WideCharToMultiByte(CP_ACP, 0, buf_short.data(), -1, buf_final.data(), tmp_size, nullptr, nullptr);
|
||||
|
||||
return buf_final;
|
||||
}
|
||||
|
||||
std::string utf8_path_to_ansi_path(const std::string& src)
|
||||
{
|
||||
std::wstring buf_wide;
|
||||
|
||||
// Converts the utf-8 path to wide char
|
||||
const auto tmp_size = MultiByteToWideChar(CP_UTF8, 0, src.c_str(), -1, nullptr, 0);
|
||||
buf_wide.resize(tmp_size);
|
||||
MultiByteToWideChar(CP_UTF8, 0, src.c_str(), -1, buf_wide.data(), tmp_size);
|
||||
|
||||
return wchar_path_to_ansi_path(buf_wide);
|
||||
}
|
||||
#endif
|
||||
|
||||
template <>
|
||||
void fmt_class_string<std::pair<const fmt_type_info*, u64>>::format(std::string& out, u64 arg)
|
||||
{
|
||||
@@ -35,14 +79,14 @@ void fmt_class_string<fmt::base57>::format(std::string& out, u64 arg)
|
||||
static constexpr u8 s_tail[8] = {0, 2, 3, 5, 6, 7, 9, 10};
|
||||
|
||||
// Get full output size
|
||||
const std::size_t out_size = _arg.size / 8 * 11 + s_tail[_arg.size % 8];
|
||||
const usz out_size = _arg.size / 8 * 11 + s_tail[_arg.size % 8];
|
||||
|
||||
out.resize(out.size() + out_size);
|
||||
|
||||
const auto ptr = &out.front() + (out.size() - out_size);
|
||||
|
||||
// Each 8 bytes of input data produce 11 bytes of base57 output
|
||||
for (std::size_t i = 0, p = 0; i < _arg.size; i += 8, p += 11)
|
||||
for (usz i = 0, p = 0; i < _arg.size; i += 8, p += 11)
|
||||
{
|
||||
// Load up to 8 bytes
|
||||
be_t<u64> be_value;
|
||||
@@ -192,6 +236,12 @@ void fmt_class_string<bool>::format(std::string& out, u64 arg)
|
||||
out += arg ? "true" : "false";
|
||||
}
|
||||
|
||||
template <>
|
||||
void fmt_class_string<b8>::format(std::string& out, u64 arg)
|
||||
{
|
||||
out += get_object(arg) ? "true" : "false";
|
||||
}
|
||||
|
||||
template <>
|
||||
void fmt_class_string<v128>::format(std::string& out, u64 arg)
|
||||
{
|
||||
@@ -199,71 +249,77 @@ void fmt_class_string<v128>::format(std::string& out, u64 arg)
|
||||
fmt::append(out, "0x%016llx%016llx", vec._u64[1], vec._u64[0]);
|
||||
}
|
||||
|
||||
template <>
|
||||
void fmt_class_string<u128>::format(std::string& out, u64 arg)
|
||||
{
|
||||
// TODO: it should be supported as full-fledged integral type (with %u, %d, etc, fmt)
|
||||
const u128& num = get_object(arg);
|
||||
#ifdef _MSC_VER
|
||||
fmt::append(out, "0x%016llx%016llx", num.hi, num.lo);
|
||||
#else
|
||||
fmt::append(out, "0x%016llx%016llx", static_cast<u64>(num >> 64), static_cast<u64>(num));
|
||||
#endif
|
||||
}
|
||||
|
||||
template <>
|
||||
void fmt_class_string<src_loc>::format(std::string& out, u64 arg)
|
||||
{
|
||||
const src_loc& loc = get_object(arg);
|
||||
|
||||
if (loc.col != umax)
|
||||
{
|
||||
fmt::append(out, "\n(in file %s:%u[:%u]", loc.file, loc.line, loc.col);
|
||||
}
|
||||
else
|
||||
{
|
||||
fmt::append(out, "\n(in file %s:%u", loc.file, loc.line);
|
||||
}
|
||||
|
||||
if (loc.func && *loc.func)
|
||||
{
|
||||
fmt::append(out, ", in function %s)", loc.func);
|
||||
}
|
||||
else
|
||||
{
|
||||
out += ')';
|
||||
}
|
||||
|
||||
// Print error code (may be irrelevant)
|
||||
#ifdef _WIN32
|
||||
if (DWORD error = GetLastError())
|
||||
{
|
||||
fmt::append(out, " (e=0x%08x[%u])", error, error);
|
||||
}
|
||||
#else
|
||||
if (int error = errno)
|
||||
{
|
||||
fmt::append(out, " (errno=%d)", error);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
namespace fmt
|
||||
{
|
||||
void raw_error(const char* msg)
|
||||
{
|
||||
throw std::runtime_error{msg};
|
||||
}
|
||||
|
||||
void raw_verify_error(const char* msg, const fmt_type_info* sup, u64 arg)
|
||||
[[noreturn]] void raw_verify_error(const src_loc& loc)
|
||||
{
|
||||
std::string out{"Verification failed"};
|
||||
|
||||
// Print error code (may be irrelevant)
|
||||
#ifdef _WIN32
|
||||
if (DWORD error = GetLastError())
|
||||
{
|
||||
fmt::append(out, " (e=%#x)", error);
|
||||
}
|
||||
#else
|
||||
if (int error = errno)
|
||||
{
|
||||
fmt::append(out, " (e=%d)", error);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (sup)
|
||||
{
|
||||
out += " (";
|
||||
sup->fmt_string(out, arg); // Print value
|
||||
out += ")";
|
||||
}
|
||||
|
||||
if (msg)
|
||||
{
|
||||
out += ": ";
|
||||
out += msg;
|
||||
}
|
||||
|
||||
throw std::runtime_error{out};
|
||||
fmt::append(out, "%s", loc);
|
||||
thread_ctrl::emergency_exit(out);
|
||||
}
|
||||
|
||||
void raw_narrow_error(const char* msg, const fmt_type_info* sup, u64 arg)
|
||||
[[noreturn]] void raw_narrow_error(const src_loc& loc)
|
||||
{
|
||||
std::string out{"Narrow error"};
|
||||
|
||||
if (sup)
|
||||
{
|
||||
out += " (";
|
||||
sup->fmt_string(out, arg); // Print value
|
||||
out += ")";
|
||||
}
|
||||
|
||||
if (msg)
|
||||
{
|
||||
out += ": ";
|
||||
out += msg;
|
||||
}
|
||||
|
||||
throw std::range_error{out};
|
||||
std::string out{"Narrowing error"};
|
||||
fmt::append(out, "%s", loc);
|
||||
thread_ctrl::emergency_exit(out);
|
||||
}
|
||||
|
||||
void raw_throw_exception(const char* fmt, const fmt_type_info* sup, const u64* args)
|
||||
[[noreturn]] void raw_throw_exception(const src_loc& loc, const char* fmt, const fmt_type_info* sup, const u64* args)
|
||||
{
|
||||
std::string out;
|
||||
raw_append(out, fmt, sup, args);
|
||||
throw std::runtime_error{out};
|
||||
fmt::append(out, "%s", loc);
|
||||
thread_ctrl::emergency_exit(out);
|
||||
}
|
||||
|
||||
struct cfmt_src;
|
||||
@@ -275,7 +331,7 @@ struct fmt::cfmt_src
|
||||
const fmt_type_info* sup;
|
||||
const u64* args;
|
||||
|
||||
bool test(std::size_t index) const
|
||||
bool test(usz index) const
|
||||
{
|
||||
if (!sup[index].fmt_string)
|
||||
{
|
||||
@@ -286,26 +342,26 @@ struct fmt::cfmt_src
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
T get(std::size_t index) const
|
||||
T get(usz index) const
|
||||
{
|
||||
return *reinterpret_cast<const T*>(reinterpret_cast<const u8*>(args + index));
|
||||
}
|
||||
|
||||
void skip(std::size_t extra)
|
||||
void skip(usz extra)
|
||||
{
|
||||
sup += extra + 1;
|
||||
args += extra + 1;
|
||||
}
|
||||
|
||||
std::size_t fmt_string(std::string& out, std::size_t extra) const
|
||||
usz fmt_string(std::string& out, usz extra) const
|
||||
{
|
||||
const std::size_t start = out.size();
|
||||
const usz start = out.size();
|
||||
sup[extra].fmt_string(out, args[extra]);
|
||||
return out.size() - start;
|
||||
}
|
||||
|
||||
// Returns type size (0 if unknown, pointer, unsigned, assumed max)
|
||||
std::size_t type(std::size_t extra) const
|
||||
usz type(usz extra) const
|
||||
{
|
||||
// Hack: use known function pointers to determine type
|
||||
#define TYPE(type) \
|
||||
@@ -323,14 +379,14 @@ struct fmt::cfmt_src
|
||||
return 0;
|
||||
}
|
||||
|
||||
static constexpr std::size_t size_char = 1;
|
||||
static constexpr std::size_t size_short = 2;
|
||||
static constexpr std::size_t size_int = 0;
|
||||
static constexpr std::size_t size_long = sizeof(ulong);
|
||||
static constexpr std::size_t size_llong = sizeof(ullong);
|
||||
static constexpr std::size_t size_size = sizeof(std::size_t);
|
||||
static constexpr std::size_t size_max = sizeof(std::uintmax_t);
|
||||
static constexpr std::size_t size_diff = sizeof(std::ptrdiff_t);
|
||||
static constexpr usz size_char = 1;
|
||||
static constexpr usz size_short = 2;
|
||||
static constexpr usz size_int = 0;
|
||||
static constexpr usz size_long = sizeof(ulong);
|
||||
static constexpr usz size_llong = sizeof(ullong);
|
||||
static constexpr usz size_size = sizeof(usz);
|
||||
static constexpr usz size_max = sizeof(std::uintmax_t);
|
||||
static constexpr usz size_diff = sizeof(std::ptrdiff_t);
|
||||
};
|
||||
|
||||
void fmt::raw_append(std::string& out, const char* fmt, const fmt_type_info* sup, const u64* args) noexcept
|
||||
@@ -342,7 +398,7 @@ std::string fmt::replace_first(const std::string& src, const std::string& from,
|
||||
{
|
||||
auto pos = src.find(from);
|
||||
|
||||
if (pos == std::string::npos)
|
||||
if (pos == umax)
|
||||
{
|
||||
return src;
|
||||
}
|
||||
@@ -353,7 +409,7 @@ std::string fmt::replace_first(const std::string& src, const std::string& from,
|
||||
std::string fmt::replace_all(const std::string& src, const std::string& from, const std::string& to)
|
||||
{
|
||||
std::string target = src;
|
||||
for (auto pos = target.find(from); pos != std::string::npos; pos = target.find(from, pos + 1))
|
||||
for (auto pos = target.find(from); pos != umax; pos = target.find(from, pos + 1))
|
||||
{
|
||||
target = (pos ? target.substr(0, pos) + to : to) + std::string(target.c_str() + pos + from.length());
|
||||
pos += to.length();
|
||||
@@ -366,9 +422,9 @@ std::vector<std::string> fmt::split(const std::string& source, std::initializer_
|
||||
{
|
||||
std::vector<std::string> result;
|
||||
|
||||
size_t cursor_begin = 0;
|
||||
usz cursor_begin = 0;
|
||||
|
||||
for (size_t cursor_end = 0; cursor_end < source.length(); ++cursor_end)
|
||||
for (usz cursor_end = 0; cursor_end < source.length(); ++cursor_end)
|
||||
{
|
||||
for (auto& separator : separators)
|
||||
{
|
||||
@@ -395,7 +451,7 @@ std::vector<std::string> fmt::split(const std::string& source, std::initializer_
|
||||
|
||||
std::string fmt::trim(const std::string& source, const std::string& values)
|
||||
{
|
||||
std::size_t begin = source.find_first_not_of(values);
|
||||
usz begin = source.find_first_not_of(values);
|
||||
|
||||
if (begin == source.npos)
|
||||
return {};
|
||||
@@ -421,7 +477,7 @@ std::string fmt::to_lower(const std::string& string)
|
||||
|
||||
bool fmt::match(const std::string& source, const std::string& mask)
|
||||
{
|
||||
std::size_t source_position = 0, mask_position = 0;
|
||||
usz source_position = 0, mask_position = 0;
|
||||
|
||||
for (; source_position < source.size() && mask_position < mask.size(); ++mask_position, ++source_position)
|
||||
{
|
||||
@@ -430,7 +486,7 @@ bool fmt::match(const std::string& source, const std::string& mask)
|
||||
case '?': break;
|
||||
|
||||
case '*':
|
||||
for (std::size_t test_source_position = source_position; test_source_position < source.size(); ++test_source_position)
|
||||
for (usz test_source_position = source_position; test_source_position < source.size(); ++test_source_position)
|
||||
{
|
||||
if (match(source.substr(test_source_position), mask.substr(mask_position + 1)))
|
||||
{
|
||||
|
||||
+43
-43
@@ -1,18 +1,16 @@
|
||||
#pragma once
|
||||
#pragma once // No BOM and only basic ASCII in this header, or a neko will die
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
|
||||
#include <exception>
|
||||
#include <stdexcept>
|
||||
#include <string>
|
||||
|
||||
namespace fmt
|
||||
{
|
||||
template <typename... Args>
|
||||
static std::string format(const char*, const Args&...);
|
||||
template <typename CharT, usz N, typename... Args>
|
||||
static std::string format(const CharT(&)[N], const Args&...);
|
||||
}
|
||||
|
||||
template <typename T, typename>
|
||||
template <typename T, typename = void>
|
||||
struct fmt_unveil
|
||||
{
|
||||
static_assert(sizeof(T) > 0, "fmt_unveil<> error: incomplete type");
|
||||
@@ -21,7 +19,7 @@ struct fmt_unveil
|
||||
|
||||
static inline u64 get(const T& arg)
|
||||
{
|
||||
return reinterpret_cast<std::uintptr_t>(&arg);
|
||||
return reinterpret_cast<uptr>(&arg);
|
||||
}
|
||||
|
||||
// Temporary value container (can possibly be created by other fmt_unveil<> specializations)
|
||||
@@ -32,7 +30,7 @@ struct fmt_unveil
|
||||
// Allow implicit conversion
|
||||
operator u64() const
|
||||
{
|
||||
return reinterpret_cast<std::uintptr_t>(&arg);
|
||||
return reinterpret_cast<uptr>(&arg);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -66,17 +64,6 @@ struct fmt_unveil<T, std::enable_if_t<std::is_floating_point<T>::value && sizeof
|
||||
}
|
||||
};
|
||||
|
||||
template <>
|
||||
struct fmt_unveil<f16, void>
|
||||
{
|
||||
using type = f16;
|
||||
|
||||
static inline u64 get(const f16& arg)
|
||||
{
|
||||
return fmt_unveil<f64>::get(arg.operator float());
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
struct fmt_unveil<T, std::enable_if_t<std::is_enum<T>::value>>
|
||||
{
|
||||
@@ -95,29 +82,29 @@ struct fmt_unveil<T*, void>
|
||||
|
||||
static inline u64 get(type arg)
|
||||
{
|
||||
return reinterpret_cast<std::uintptr_t>(arg);
|
||||
return reinterpret_cast<uptr>(arg);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T, std::size_t N>
|
||||
template <typename T, usz N>
|
||||
struct fmt_unveil<T[N], void>
|
||||
{
|
||||
using type = std::add_const_t<T>*;
|
||||
|
||||
static inline u64 get(type arg)
|
||||
{
|
||||
return reinterpret_cast<std::uintptr_t>(arg);
|
||||
return reinterpret_cast<uptr>(arg);
|
||||
}
|
||||
};
|
||||
|
||||
template <>
|
||||
struct fmt_unveil<b8, void>
|
||||
template <typename T, bool Se, usz Align>
|
||||
struct fmt_unveil<se_t<T, Se, Align>, void>
|
||||
{
|
||||
using type = bool;
|
||||
using type = typename fmt_unveil<T>::type;
|
||||
|
||||
static inline u64 get(const b8& value)
|
||||
static inline auto get(const se_t<T, Se, Align>& arg)
|
||||
{
|
||||
return fmt_unveil<bool>::get(value);
|
||||
return fmt_unveil<T>::get(arg);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -134,7 +121,7 @@ struct fmt_class_string
|
||||
// Helper function (converts arg to object reference)
|
||||
static SAFE_BUFFERS FORCE_INLINE const T& get_object(u64 arg)
|
||||
{
|
||||
return *reinterpret_cast<const T*>(static_cast<std::uintptr_t>(arg));
|
||||
return *reinterpret_cast<const T*>(static_cast<uptr>(arg));
|
||||
}
|
||||
|
||||
// Enum -> string function type
|
||||
@@ -236,13 +223,16 @@ struct fmt_type_info
|
||||
template <typename... Args>
|
||||
using fmt_args_t = const u64(&&)[sizeof...(Args) + 1];
|
||||
|
||||
template <typename Arg>
|
||||
using fmt_unveil_t = typename fmt_unveil<Arg>::type;
|
||||
|
||||
namespace fmt
|
||||
{
|
||||
// Base-57 format helper
|
||||
struct base57
|
||||
{
|
||||
const uchar* data;
|
||||
std::size_t size;
|
||||
usz size;
|
||||
|
||||
template <typename T>
|
||||
base57(const T& arg)
|
||||
@@ -251,7 +241,7 @@ namespace fmt
|
||||
{
|
||||
}
|
||||
|
||||
base57(const uchar* data, std::size_t size)
|
||||
base57(const uchar* data, usz size)
|
||||
: data(data)
|
||||
, size(size)
|
||||
{
|
||||
@@ -274,30 +264,40 @@ namespace fmt
|
||||
void raw_append(std::string& out, const char*, const fmt_type_info*, const u64*) noexcept;
|
||||
|
||||
// Formatting function
|
||||
template <typename... Args>
|
||||
SAFE_BUFFERS FORCE_INLINE void append(std::string& out, const char* fmt, const Args&... args)
|
||||
template <typename CharT, usz N, typename... Args>
|
||||
SAFE_BUFFERS FORCE_INLINE void append(std::string& out, const CharT(&fmt)[N], const Args&... args)
|
||||
{
|
||||
static constexpr fmt_type_info type_list[sizeof...(Args) + 1]{fmt_type_info::make<fmt_unveil_t<Args>>()...};
|
||||
raw_append(out, fmt, type_list, fmt_args_t<Args...>{fmt_unveil<Args>::get(args)...});
|
||||
raw_append(out, reinterpret_cast<const char*>(fmt), type_list, fmt_args_t<Args...>{fmt_unveil<Args>::get(args)...});
|
||||
}
|
||||
|
||||
// Formatting function
|
||||
template <typename... Args>
|
||||
SAFE_BUFFERS FORCE_INLINE std::string format(const char* fmt, const Args&... args)
|
||||
template <typename CharT, usz N, typename... Args>
|
||||
SAFE_BUFFERS FORCE_INLINE std::string format(const CharT(&fmt)[N], const Args&... args)
|
||||
{
|
||||
std::string result;
|
||||
append<Args...>(result, fmt, args...);
|
||||
append(result, fmt, args...);
|
||||
return result;
|
||||
}
|
||||
|
||||
// Internal exception message formatting template, must be explicitly specialized or instantiated in cpp to minimize code bloat
|
||||
[[noreturn]] void raw_throw_exception(const char*, const fmt_type_info*, const u64*);
|
||||
[[noreturn]] void raw_throw_exception(const src_loc&, const char*, const fmt_type_info*, const u64*);
|
||||
|
||||
// Throw exception with formatting
|
||||
template <typename... Args>
|
||||
[[noreturn]] SAFE_BUFFERS FORCE_INLINE void throw_exception(const char* fmt, const Args&... args)
|
||||
template <typename CharT, usz N, typename... Args>
|
||||
struct throw_exception
|
||||
{
|
||||
static constexpr fmt_type_info type_list[sizeof...(Args) + 1]{fmt_type_info::make<fmt_unveil_t<Args>>()...};
|
||||
raw_throw_exception(fmt, type_list, fmt_args_t<Args...>{fmt_unveil<Args>::get(args)...});
|
||||
}
|
||||
[[noreturn]] SAFE_BUFFERS FORCE_INLINE throw_exception(const CharT(&fmt)[N], const Args&... args,
|
||||
u32 line = __builtin_LINE(),
|
||||
u32 col = __builtin_COLUMN(),
|
||||
const char* file = __builtin_FILE(),
|
||||
const char* func = __builtin_FUNCTION())
|
||||
{
|
||||
static constexpr fmt_type_info type_list[sizeof...(Args) + 1]{fmt_type_info::make<fmt_unveil_t<Args>>()...};
|
||||
raw_throw_exception({line, col, file, func}, reinterpret_cast<const char*>(fmt), type_list, fmt_args_t<Args...>{fmt_unveil<Args>::get(args)...});
|
||||
}
|
||||
};
|
||||
|
||||
template <typename CharT, usz N, typename... Args>
|
||||
throw_exception(const CharT(&)[N], const Args&...) -> throw_exception<CharT, N, Args...>;
|
||||
}
|
||||
|
||||
+20
-29
@@ -7,28 +7,19 @@
|
||||
#include <functional>
|
||||
#include <string_view>
|
||||
|
||||
// Copy null-terminated string from std::string to char array with truncation
|
||||
template <std::size_t N>
|
||||
inline void strcpy_trunc(char (&dst)[N], const std::string& src)
|
||||
{
|
||||
const std::size_t count = src.size() >= N ? N - 1 : src.size();
|
||||
std::memcpy(dst, src.c_str(), count);
|
||||
std::memset(dst + count, 0, N - count);
|
||||
}
|
||||
#ifdef _WIN32
|
||||
std::string wchar_to_utf8(wchar_t *src);
|
||||
std::string wchar_path_to_ansi_path(const std::wstring& src);
|
||||
std::string utf8_path_to_ansi_path(const std::string& src);
|
||||
#endif
|
||||
|
||||
// Copy null-terminated string from char array to another char array with truncation
|
||||
template <std::size_t N, std::size_t N2>
|
||||
inline void strcpy_trunc(char (&dst)[N], const char (&src)[N2])
|
||||
// Copy null-terminated string from a std::string or a char array to a char array with truncation
|
||||
template <typename D, typename T>
|
||||
inline void strcpy_trunc(D& dst, const T& src)
|
||||
{
|
||||
const std::size_t count = N2 >= N ? N - 1 : N2;
|
||||
std::memcpy(dst, src, count);
|
||||
std::memset(dst + count, 0, N - count);
|
||||
}
|
||||
|
||||
template <std::size_t N>
|
||||
inline bool ends_with(const std::string& src, const char (&end)[N])
|
||||
{
|
||||
return src.size() >= N - 1 && src.compare(src.size() - (N - 1), N - 1, end, N - 1) == 0;
|
||||
const usz count = std::size(src) >= std::size(dst) ? std::size(dst) - 1 : std::size(src);
|
||||
std::memcpy(std::data(dst), std::data(src), count);
|
||||
std::memset(std::data(dst) + count, 0, std::size(dst) - count);
|
||||
}
|
||||
|
||||
namespace fmt
|
||||
@@ -36,14 +27,14 @@ namespace fmt
|
||||
std::string replace_first(const std::string& src, const std::string& from, const std::string& to);
|
||||
std::string replace_all(const std::string& src, const std::string& from, const std::string& to);
|
||||
|
||||
template <size_t list_size>
|
||||
template <usz list_size>
|
||||
std::string replace_all(std::string src, const std::pair<std::string, std::string> (&list)[list_size])
|
||||
{
|
||||
for (size_t pos = 0; pos < src.length(); ++pos)
|
||||
for (usz pos = 0; pos < src.length(); ++pos)
|
||||
{
|
||||
for (size_t i = 0; i < list_size; ++i)
|
||||
for (usz i = 0; i < list_size; ++i)
|
||||
{
|
||||
const size_t comp_length = list[i].first.length();
|
||||
const usz comp_length = list[i].first.length();
|
||||
|
||||
if (src.length() - pos < comp_length)
|
||||
continue;
|
||||
@@ -60,14 +51,14 @@ namespace fmt
|
||||
return src;
|
||||
}
|
||||
|
||||
template <size_t list_size>
|
||||
template <usz list_size>
|
||||
std::string replace_all(std::string src, const std::pair<std::string, std::function<std::string()>> (&list)[list_size])
|
||||
{
|
||||
for (size_t pos = 0; pos < src.length(); ++pos)
|
||||
for (usz pos = 0; pos < src.length(); ++pos)
|
||||
{
|
||||
for (size_t i = 0; i < list_size; ++i)
|
||||
for (usz i = 0; i < list_size; ++i)
|
||||
{
|
||||
const size_t comp_length = list[i].first.length();
|
||||
const usz comp_length = list[i].first.length();
|
||||
|
||||
if (src.length() - pos < comp_length)
|
||||
continue;
|
||||
@@ -90,7 +81,7 @@ namespace fmt
|
||||
template <typename T>
|
||||
std::string merge(const T& source, const std::string& separator)
|
||||
{
|
||||
if (!source.size())
|
||||
if (source.empty())
|
||||
{
|
||||
return {};
|
||||
}
|
||||
|
||||
+915
-306
File diff suppressed because it is too large
Load Diff
+208
-197
@@ -1,22 +1,16 @@
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "util/atomic.hpp"
|
||||
#include "util/shared_ptr.hpp"
|
||||
|
||||
#include <string>
|
||||
#include <memory>
|
||||
#include <string_view>
|
||||
|
||||
#include "mutex.h"
|
||||
#include "cond.h"
|
||||
#include "lockless.h"
|
||||
|
||||
// Report error and call std::abort(), defined in main.cpp
|
||||
[[noreturn]] void report_fatal_error(const std::string&);
|
||||
|
||||
// Will report exception and call std::abort() if put in catch(...)
|
||||
[[noreturn]] void catch_all_exceptions();
|
||||
|
||||
// Hardware core layout
|
||||
enum class native_core_arrangement : u32
|
||||
{
|
||||
@@ -36,18 +30,23 @@ enum class thread_class : u32
|
||||
|
||||
enum class thread_state : u32
|
||||
{
|
||||
created, // Initial state
|
||||
detached, // The thread has been detached to destroy its own named_thread object (can be dangerously misused)
|
||||
aborting, // The thread has been joined in the destructor or explicitly aborted (mutually exclusive with detached)
|
||||
finished // Final state, always set at the end of thread execution
|
||||
created = 0, // Initial state
|
||||
aborting = 1, // The thread has been joined in the destructor or explicitly aborted
|
||||
errored = 2, // Set after the emergency_exit call
|
||||
finished = 3, // Final state, always set at the end of thread execution
|
||||
mask = 3
|
||||
};
|
||||
|
||||
class need_wakeup {};
|
||||
|
||||
template <class Context>
|
||||
class named_thread;
|
||||
|
||||
template <typename T>
|
||||
struct result_storage
|
||||
{
|
||||
static_assert(std::is_default_constructible_v<T> && noexcept(T()));
|
||||
|
||||
alignas(T) std::byte data[sizeof(T)];
|
||||
|
||||
static constexpr bool empty = false;
|
||||
@@ -81,27 +80,6 @@ struct result_storage<void>
|
||||
template <class Context, typename... Args>
|
||||
using result_storage_t = result_storage<std::invoke_result_t<Context, Args...>>;
|
||||
|
||||
// Detect on_abort() method (should return void)
|
||||
template <typename T, typename = void>
|
||||
struct thread_on_abort : std::bool_constant<false> {};
|
||||
|
||||
template <typename T>
|
||||
struct thread_on_abort<T, decltype(std::declval<named_thread<T>&>().on_abort())> : std::bool_constant<true> {};
|
||||
|
||||
// Detect on_cleanup() static member function (should return void) (in C++20 can use destroying delete instead)
|
||||
template <typename T, typename = void>
|
||||
struct thread_on_cleanup : std::bool_constant<false> {};
|
||||
|
||||
template <typename T>
|
||||
struct thread_on_cleanup<T, decltype(named_thread<T>::on_cleanup(std::declval<named_thread<T>*>()))> : std::bool_constant<true> {};
|
||||
|
||||
// Detect on_wait() method (should return bool)
|
||||
template <typename T, typename = bool>
|
||||
struct thread_on_wait : std::bool_constant<false> {};
|
||||
|
||||
template <typename T>
|
||||
struct thread_on_wait<T, decltype(std::declval<named_thread<T>&>().on_wait())> : std::bool_constant<true> {};
|
||||
|
||||
template <typename T, typename = void>
|
||||
struct thread_thread_name : std::bool_constant<false> {};
|
||||
|
||||
@@ -111,6 +89,7 @@ struct thread_thread_name<T, std::void_t<decltype(named_thread<T>::thread_name)>
|
||||
// Thread base class
|
||||
class thread_base
|
||||
{
|
||||
public:
|
||||
// Native thread entry point function type
|
||||
#ifdef _WIN32
|
||||
using native_entry = uint(__stdcall*)(void* arg);
|
||||
@@ -118,49 +97,35 @@ class thread_base
|
||||
using native_entry = void*(*)(void* arg);
|
||||
#endif
|
||||
|
||||
#ifdef __linux__
|
||||
// Linux thread timer
|
||||
int m_timer = -1;
|
||||
#endif
|
||||
const native_entry entry_point;
|
||||
|
||||
private:
|
||||
// Thread handle (platform-specific)
|
||||
atomic_t<std::uintptr_t> m_thread{0};
|
||||
atomic_t<u64> m_thread{0};
|
||||
|
||||
// Thread mutex
|
||||
mutable shared_mutex m_mutex;
|
||||
|
||||
// Thread condition variable
|
||||
cond_variable m_cond;
|
||||
|
||||
// Thread flags
|
||||
atomic_t<u32> m_signal{0};
|
||||
|
||||
// Thread state
|
||||
atomic_t<thread_state> m_state = thread_state::created;
|
||||
|
||||
// Thread state notification info
|
||||
atomic_t<const void*> m_state_notifier{nullptr};
|
||||
// Thread state and cycles
|
||||
atomic_t<u64> m_sync{0};
|
||||
|
||||
// Thread name
|
||||
lf_value<std::string> m_name;
|
||||
|
||||
//
|
||||
atomic_t<u64> m_cycles = 0;
|
||||
atomic_ptr<std::string> m_tname;
|
||||
|
||||
// Start thread
|
||||
void start(native_entry);
|
||||
void start();
|
||||
|
||||
// Called at the thread start
|
||||
void initialize(bool(*wait_cb)(const void*));
|
||||
void initialize(void (*error_cb)());
|
||||
|
||||
// May be called in destructor
|
||||
void notify_abort() noexcept;
|
||||
|
||||
// Called at the thread end, returns true if needs destruction
|
||||
bool finalize(int) noexcept;
|
||||
// Called at the thread end, returns self handle
|
||||
u64 finalize(thread_state result) noexcept;
|
||||
|
||||
// Cleanup after possibly deleting the thread instance
|
||||
static void finalize() noexcept;
|
||||
static native_entry finalize(u64 _self) noexcept;
|
||||
|
||||
// Set name for debugger
|
||||
static void set_name(std::string);
|
||||
|
||||
// Make entry point
|
||||
static native_entry make_trampoline(u64(*)(thread_base*));
|
||||
|
||||
friend class thread_ctrl;
|
||||
|
||||
@@ -168,7 +133,7 @@ class thread_base
|
||||
friend class named_thread;
|
||||
|
||||
protected:
|
||||
thread_base(std::string_view name);
|
||||
thread_base(native_entry, std::string_view name);
|
||||
|
||||
~thread_base();
|
||||
|
||||
@@ -177,10 +142,13 @@ public:
|
||||
u64 get_cycles();
|
||||
|
||||
// Wait for the thread (it does NOT change thread state, and can be called from multiple threads)
|
||||
void join() const;
|
||||
bool join(bool dtor = false) const;
|
||||
|
||||
// Notify the thread
|
||||
void notify();
|
||||
|
||||
// Get thread id
|
||||
u64 get_native_id() const;
|
||||
};
|
||||
|
||||
// Collection of global function for current thread
|
||||
@@ -189,6 +157,9 @@ class thread_ctrl final
|
||||
// Current thread
|
||||
static thread_local thread_base* g_tls_this_thread;
|
||||
|
||||
// Error handling details
|
||||
static thread_local void(*g_tls_error_callback)();
|
||||
|
||||
// Target cpu core layout
|
||||
static atomic_t<native_core_arrangement> g_native_core_layout;
|
||||
|
||||
@@ -197,31 +168,34 @@ class thread_ctrl final
|
||||
|
||||
friend class thread_base;
|
||||
|
||||
// Optimized get_name() for logging
|
||||
static std::string get_name_cached();
|
||||
|
||||
public:
|
||||
// Get current thread name
|
||||
static std::string_view get_name()
|
||||
static std::string get_name()
|
||||
{
|
||||
return g_tls_this_thread->m_name.get();
|
||||
return *g_tls_this_thread->m_tname.load();
|
||||
}
|
||||
|
||||
// Get thread name
|
||||
template <typename T>
|
||||
static std::string_view get_name(const named_thread<T>& thread)
|
||||
static std::string get_name(const named_thread<T>& thread)
|
||||
{
|
||||
return static_cast<const thread_base&>(thread).m_name.get();
|
||||
return *static_cast<const thread_base&>(thread).m_tname.load();
|
||||
}
|
||||
|
||||
// Set current thread name (not recommended)
|
||||
static void set_name(std::string_view name)
|
||||
{
|
||||
g_tls_this_thread->m_name.assign(name);
|
||||
g_tls_this_thread->m_tname.store(make_single<std::string>(name));
|
||||
}
|
||||
|
||||
// Set thread name (not recommended)
|
||||
template <typename T>
|
||||
static void set_name(named_thread<T>& thread, std::string_view name)
|
||||
{
|
||||
static_cast<thread_base&>(thread).m_name.assign(name);
|
||||
static_cast<thread_base&>(thread).m_tname.store(make_single<std::string>(name));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
@@ -236,10 +210,16 @@ public:
|
||||
static_cast<thread_base&>(thread).notify();
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
static u64 get_native_id(named_thread<T>& thread)
|
||||
{
|
||||
return static_cast<thread_base&>(thread).get_native_id();
|
||||
}
|
||||
|
||||
// Read current state
|
||||
static inline thread_state state()
|
||||
{
|
||||
return g_tls_this_thread->m_state;
|
||||
return static_cast<thread_state>(g_tls_this_thread->m_sync & 3);
|
||||
}
|
||||
|
||||
// Wait once with timeout. May spuriously return false.
|
||||
@@ -254,20 +234,8 @@ public:
|
||||
_wait_for(-1, true);
|
||||
}
|
||||
|
||||
// Wait until pred().
|
||||
template <typename F, typename RT = std::invoke_result_t<F>>
|
||||
static inline RT wait(F&& pred)
|
||||
{
|
||||
while (true)
|
||||
{
|
||||
if (RT result = pred())
|
||||
{
|
||||
return result;
|
||||
}
|
||||
|
||||
_wait_for(-1, true);
|
||||
}
|
||||
}
|
||||
// Exit.
|
||||
[[noreturn]] static void emergency_exit(std::string_view reason);
|
||||
|
||||
// Get current thread (may be nullptr)
|
||||
static thread_base* get_current()
|
||||
@@ -287,12 +255,18 @@ public:
|
||||
// Sets the preferred affinity mask for this thread
|
||||
static void set_thread_affinity_mask(u64 mask);
|
||||
|
||||
// Spawn a detached named thread
|
||||
template <typename F>
|
||||
[[deprecated]] static void spawn(std::string_view name, F&& func)
|
||||
{
|
||||
new named_thread<F>(thread_state::detached, name, std::forward<F>(func));
|
||||
}
|
||||
// Get process affinity mask
|
||||
static u64 get_process_affinity_mask();
|
||||
|
||||
// Miscellaneous
|
||||
static u64 get_thread_affinity_mask();
|
||||
|
||||
// Get current thread stack addr and size
|
||||
static std::pair<void*, usz> get_thread_stack();
|
||||
|
||||
private:
|
||||
// Miscellaneous
|
||||
static const u64 process_affinity_mask;
|
||||
};
|
||||
|
||||
// Derived from the callable object Context, possibly a lambda
|
||||
@@ -302,79 +276,20 @@ class named_thread final : public Context, result_storage_t<Context>, thread_bas
|
||||
using result = result_storage_t<Context>;
|
||||
using thread = thread_base;
|
||||
|
||||
// Type-erased thread entry point
|
||||
#ifdef _WIN32
|
||||
static inline uint __stdcall entry_point(void* arg) try
|
||||
#else
|
||||
static inline void* entry_point(void* arg) try
|
||||
#endif
|
||||
static u64 entry_point(thread_base* _base)
|
||||
{
|
||||
const auto _this = static_cast<named_thread*>(static_cast<thread*>(arg));
|
||||
|
||||
// Perform self-cleanup if necessary
|
||||
if (_this->entry_point())
|
||||
{
|
||||
// Call on_cleanup() static member function if it's available
|
||||
if constexpr (thread_on_cleanup<Context>())
|
||||
{
|
||||
Context::on_cleanup(_this);
|
||||
}
|
||||
else
|
||||
{
|
||||
delete _this;
|
||||
}
|
||||
}
|
||||
|
||||
thread::finalize();
|
||||
return 0;
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
catch_all_exceptions();
|
||||
return static_cast<named_thread*>(_base)->entry_point2();
|
||||
}
|
||||
|
||||
bool entry_point()
|
||||
u64 entry_point2()
|
||||
{
|
||||
thread::initialize([](const void* data)
|
||||
thread::initialize([]()
|
||||
{
|
||||
const auto _this = thread_ctrl::get_current();
|
||||
|
||||
if (_this->m_state >= thread_state::aborting)
|
||||
if constexpr (!result::empty)
|
||||
{
|
||||
return false;
|
||||
// Construct using default constructor in the case of failure
|
||||
new (static_cast<result*>(static_cast<named_thread*>(thread_ctrl::get_current()))->get()) typename result::type();
|
||||
}
|
||||
|
||||
if constexpr (thread_on_wait<Context>())
|
||||
{
|
||||
if (!static_cast<named_thread*>(_this)->on_wait())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
_this->m_state_notifier.release(data);
|
||||
|
||||
if (!data)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
if (_this->m_state >= thread_state::aborting)
|
||||
{
|
||||
_this->m_state_notifier.release(nullptr);
|
||||
return false;
|
||||
}
|
||||
|
||||
if constexpr (thread_on_wait<Context>())
|
||||
{
|
||||
if (!static_cast<named_thread*>(_this)->on_wait())
|
||||
{
|
||||
_this->m_state_notifier.release(nullptr);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
});
|
||||
|
||||
if constexpr (result::empty)
|
||||
@@ -388,57 +303,38 @@ class named_thread final : public Context, result_storage_t<Context>, thread_bas
|
||||
new (result::get()) typename result::type(Context::operator()());
|
||||
}
|
||||
|
||||
return thread::finalize(0);
|
||||
return thread::finalize(thread_state::finished);
|
||||
}
|
||||
|
||||
static decltype(auto) get_default_thread_name()
|
||||
{
|
||||
if constexpr (thread_thread_name<Context>())
|
||||
{
|
||||
return Context::thread_name;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "Unnamed Thread";
|
||||
}
|
||||
}
|
||||
|
||||
// Detached thread constructor
|
||||
named_thread(thread_state s, std::string_view name, Context&& f)
|
||||
: Context(std::forward<Context>(f))
|
||||
, thread(name)
|
||||
{
|
||||
thread::m_state.raw() = s;
|
||||
thread::start(&named_thread::entry_point);
|
||||
}
|
||||
static inline thread::native_entry trampoline = thread::make_trampoline(entry_point);
|
||||
|
||||
friend class thread_ctrl;
|
||||
|
||||
public:
|
||||
// Default constructor
|
||||
template <bool Valid = std::is_default_constructible_v<Context>, typename = std::enable_if_t<Valid>>
|
||||
template <bool Valid = std::is_default_constructible_v<Context> && thread_thread_name<Context>(), typename = std::enable_if_t<Valid>>
|
||||
named_thread()
|
||||
: Context()
|
||||
, thread(get_default_thread_name())
|
||||
, thread(trampoline, Context::thread_name)
|
||||
{
|
||||
thread::start(&named_thread::entry_point);
|
||||
thread::start();
|
||||
}
|
||||
|
||||
// Normal forwarding constructor
|
||||
template <typename... Args, typename = std::enable_if_t<std::is_constructible_v<Context, Args&&...>>>
|
||||
named_thread(std::string_view name, Args&&... args)
|
||||
: Context(std::forward<Args>(args)...)
|
||||
, thread(name)
|
||||
, thread(trampoline, name)
|
||||
{
|
||||
thread::start(&named_thread::entry_point);
|
||||
thread::start();
|
||||
}
|
||||
|
||||
// Lambda constructor, also the implicit deduction guide candidate
|
||||
named_thread(std::string_view name, Context&& f)
|
||||
: Context(std::forward<Context>(f))
|
||||
, thread(name)
|
||||
, thread(trampoline, name)
|
||||
{
|
||||
thread::start(&named_thread::entry_point);
|
||||
thread::start();
|
||||
}
|
||||
|
||||
named_thread(const named_thread&) = delete;
|
||||
@@ -470,23 +366,22 @@ public:
|
||||
// Access thread state
|
||||
operator thread_state() const
|
||||
{
|
||||
return thread::m_state.load();
|
||||
return static_cast<thread_state>(thread::m_sync.load() & 3);
|
||||
}
|
||||
|
||||
// Try to abort/detach
|
||||
// Try to abort by assigning thread_state::aborting (UB if assigning different state)
|
||||
named_thread& operator=(thread_state s)
|
||||
{
|
||||
if (s < thread_state::finished && thread::m_state.compare_and_swap_test(thread_state::created, s))
|
||||
if (s == thread_state::aborting && thread::m_sync.fetch_op([](u64& v){ return !(v & 3) && (v |= 1); }).second)
|
||||
{
|
||||
if (s == thread_state::aborting)
|
||||
{
|
||||
// Call on_abort() method if it's available
|
||||
if constexpr (thread_on_abort<Context>())
|
||||
{
|
||||
Context::on_abort();
|
||||
}
|
||||
thread::m_sync.notify_one(1);
|
||||
}
|
||||
|
||||
thread::notify_abort();
|
||||
if constexpr (std::is_base_of_v<need_wakeup, Context>)
|
||||
{
|
||||
this->wake_up();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -496,8 +391,9 @@ public:
|
||||
// Context type doesn't need virtual destructor
|
||||
~named_thread()
|
||||
{
|
||||
// Assign aborting state forcefully
|
||||
operator=(thread_state::aborting);
|
||||
thread::join();
|
||||
thread::join(true);
|
||||
|
||||
if constexpr (!result::empty)
|
||||
{
|
||||
@@ -505,3 +401,118 @@ public:
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
// Group of named threads, similar to named_thread
|
||||
template <class Context>
|
||||
class named_thread_group final
|
||||
{
|
||||
using Thread = named_thread<Context>;
|
||||
|
||||
const u32 m_count;
|
||||
|
||||
Thread* m_threads;
|
||||
|
||||
void init_threads()
|
||||
{
|
||||
m_threads = static_cast<Thread*>(::operator new(sizeof(Thread) * m_count, std::align_val_t{alignof(Thread)}));
|
||||
}
|
||||
|
||||
public:
|
||||
// Lambda constructor, also the implicit deduction guide candidate
|
||||
named_thread_group(std::string_view name, u32 count, const Context& f)
|
||||
: m_count(count)
|
||||
, m_threads(nullptr)
|
||||
{
|
||||
if (count == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
init_threads();
|
||||
|
||||
// Create all threads
|
||||
for (u32 i = 0; i < m_count; i++)
|
||||
{
|
||||
new (static_cast<void*>(m_threads + i)) Thread(std::string(name) + std::to_string(i + 1), f);
|
||||
}
|
||||
}
|
||||
|
||||
// Default constructor
|
||||
named_thread_group(std::string_view name, u32 count)
|
||||
: m_count(count)
|
||||
, m_threads(nullptr)
|
||||
{
|
||||
if (count == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
init_threads();
|
||||
|
||||
// Create all threads
|
||||
for (u32 i = 0; i < m_count; i++)
|
||||
{
|
||||
new (static_cast<void*>(m_threads + i)) Thread(std::string(name) + std::to_string(i + 1));
|
||||
}
|
||||
}
|
||||
|
||||
named_thread_group(const named_thread_group&) = delete;
|
||||
|
||||
named_thread_group& operator=(const named_thread_group&) = delete;
|
||||
|
||||
// Wait for completion
|
||||
bool join() const
|
||||
{
|
||||
bool result = true;
|
||||
|
||||
for (u32 i = 0; i < m_count; i++)
|
||||
{
|
||||
std::as_const(*std::launder(m_threads + i))();
|
||||
|
||||
if (std::as_const(*std::launder(m_threads + i)) != thread_state::finished)
|
||||
result = false;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
// Join and access specific thread
|
||||
auto operator[](u32 index) const
|
||||
{
|
||||
return std::as_const(*std::launder(m_threads + index))();
|
||||
}
|
||||
|
||||
// Join and access specific thread
|
||||
auto operator[](u32 index)
|
||||
{
|
||||
return (*std::launder(m_threads + index))();
|
||||
}
|
||||
|
||||
// Dumb iterator
|
||||
auto begin()
|
||||
{
|
||||
return std::launder(m_threads);
|
||||
}
|
||||
|
||||
// Dumb iterator
|
||||
auto end()
|
||||
{
|
||||
return m_threads + m_count;
|
||||
}
|
||||
|
||||
u32 size() const
|
||||
{
|
||||
return m_count;
|
||||
}
|
||||
|
||||
~named_thread_group()
|
||||
{
|
||||
// Destroy all threads (it should join them)
|
||||
for (u32 i = 0; i < m_count; i++)
|
||||
{
|
||||
std::launder(m_threads + i)->~Thread();
|
||||
}
|
||||
|
||||
::operator delete(static_cast<void*>(m_threads), std::align_val_t{alignof(Thread)});
|
||||
}
|
||||
};
|
||||
|
||||
+9
-9
@@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
|
||||
#include <chrono>
|
||||
|
||||
@@ -8,8 +8,8 @@ class Timer
|
||||
{
|
||||
private:
|
||||
bool m_stopped;
|
||||
std::chrono::steady_clock::time_point m_start;
|
||||
std::chrono::steady_clock::time_point m_end;
|
||||
steady_clock::time_point m_start;
|
||||
steady_clock::time_point m_end;
|
||||
|
||||
public:
|
||||
Timer() : m_stopped(false)
|
||||
@@ -19,13 +19,13 @@ public:
|
||||
void Start()
|
||||
{
|
||||
m_stopped = false;
|
||||
m_start = std::chrono::steady_clock::now();
|
||||
m_start = steady_clock::now();
|
||||
}
|
||||
|
||||
void Stop()
|
||||
{
|
||||
m_stopped = true;
|
||||
m_end = std::chrono::steady_clock::now();
|
||||
m_end = steady_clock::now();
|
||||
}
|
||||
|
||||
double GetElapsedTimeInSec() const
|
||||
@@ -40,21 +40,21 @@ public:
|
||||
|
||||
u64 GetElapsedTimeInMicroSec() const
|
||||
{
|
||||
std::chrono::steady_clock::time_point now = m_stopped ? m_end : std::chrono::steady_clock::now();
|
||||
steady_clock::time_point now = m_stopped ? m_end : steady_clock::now();
|
||||
|
||||
return std::chrono::duration_cast<std::chrono::microseconds>(now - m_start).count();
|
||||
}
|
||||
|
||||
u64 GetElapsedTimeInNanoSec() const
|
||||
{
|
||||
std::chrono::steady_clock::time_point now = m_stopped ? m_end : std::chrono::steady_clock::now();
|
||||
steady_clock::time_point now = m_stopped ? m_end : steady_clock::now();
|
||||
|
||||
return std::chrono::duration_cast<std::chrono::nanoseconds>(now - m_start).count();
|
||||
}
|
||||
|
||||
u64 GetMsSince(std::chrono::steady_clock::time_point timestamp)
|
||||
u64 GetMsSince(steady_clock::time_point timestamp)
|
||||
{
|
||||
std::chrono::steady_clock::time_point now = m_stopped ? m_end : std::chrono::steady_clock::now();
|
||||
steady_clock::time_point now = m_stopped ? m_end : steady_clock::now();
|
||||
|
||||
return std::chrono::duration_cast<std::chrono::milliseconds>(now - timestamp).count();
|
||||
}
|
||||
|
||||
@@ -1,286 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "VirtualMemory.h"
|
||||
#ifdef _WIN32
|
||||
#include <Windows.h>
|
||||
#else
|
||||
#include <sys/mman.h>
|
||||
#include <sys/stat.h>
|
||||
#include <fcntl.h>
|
||||
#include <errno.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef __linux__
|
||||
#include <sys/syscall.h>
|
||||
|
||||
#ifdef __NR_memfd_create
|
||||
#elif __x86_64__
|
||||
#define __NR_memfd_create 319
|
||||
#elif __aarch64__
|
||||
#define __NR_memfd_create 279
|
||||
#endif
|
||||
|
||||
static int memfd_create_(const char *name, uint flags)
|
||||
{
|
||||
return syscall(__NR_memfd_create, name, flags);
|
||||
}
|
||||
#endif
|
||||
|
||||
namespace utils
|
||||
{
|
||||
// Convert memory protection (internal)
|
||||
static auto operator +(protection prot)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
DWORD _prot = PAGE_NOACCESS;
|
||||
switch (prot)
|
||||
{
|
||||
case protection::rw: _prot = PAGE_READWRITE; break;
|
||||
case protection::ro: _prot = PAGE_READONLY; break;
|
||||
case protection::no: break;
|
||||
case protection::wx: _prot = PAGE_EXECUTE_READWRITE; break;
|
||||
case protection::rx: _prot = PAGE_EXECUTE_READ; break;
|
||||
}
|
||||
#else
|
||||
int _prot = PROT_NONE;
|
||||
switch (prot)
|
||||
{
|
||||
case protection::rw: _prot = PROT_READ | PROT_WRITE; break;
|
||||
case protection::ro: _prot = PROT_READ; break;
|
||||
case protection::no: break;
|
||||
case protection::wx: _prot = PROT_READ | PROT_WRITE | PROT_EXEC; break;
|
||||
case protection::rx: _prot = PROT_READ | PROT_EXEC; break;
|
||||
}
|
||||
#endif
|
||||
|
||||
return _prot;
|
||||
}
|
||||
|
||||
void* memory_reserve(std::size_t size, void* use_addr)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
return ::VirtualAlloc(use_addr, size, MEM_RESERVE, PAGE_NOACCESS);
|
||||
#else
|
||||
auto ptr = ::mmap(use_addr, size, PROT_NONE, MAP_ANON | MAP_PRIVATE, -1, 0);
|
||||
|
||||
if (ptr == reinterpret_cast<void*>(-1))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (use_addr && ptr != use_addr)
|
||||
{
|
||||
::munmap(ptr, size);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return ptr;
|
||||
#endif
|
||||
}
|
||||
|
||||
void memory_commit(void* pointer, std::size_t size, protection prot)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
verify(HERE), ::VirtualAlloc(pointer, size, MEM_COMMIT, +prot);
|
||||
#else
|
||||
const u64 ptr64 = reinterpret_cast<u64>(pointer);
|
||||
verify(HERE), ::mprotect(reinterpret_cast<void*>(ptr64 & -4096), size + (ptr64 & 4095), +prot) != -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
void memory_decommit(void* pointer, std::size_t size)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
verify(HERE), ::VirtualFree(pointer, size, MEM_DECOMMIT);
|
||||
#else
|
||||
verify(HERE), ::mmap(pointer, size, PROT_NONE, MAP_FIXED | MAP_ANON | MAP_PRIVATE, -1, 0) != reinterpret_cast<void*>(-1);
|
||||
#endif
|
||||
}
|
||||
|
||||
void memory_reset(void* pointer, std::size_t size, protection prot)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
memory_decommit(pointer, size);
|
||||
memory_commit(pointer, size, prot);
|
||||
#else
|
||||
verify(HERE), ::mmap(pointer, size, +prot, MAP_FIXED | MAP_ANON | MAP_PRIVATE, -1, 0) != reinterpret_cast<void*>(-1);
|
||||
#endif
|
||||
}
|
||||
|
||||
void memory_release(void* pointer, std::size_t size)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
verify(HERE), ::VirtualFree(pointer, 0, MEM_RELEASE);
|
||||
#else
|
||||
verify(HERE), ::munmap(pointer, size) != -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
void memory_protect(void* pointer, std::size_t size, protection prot)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
for (u64 addr = reinterpret_cast<u64>(pointer), end = addr + size; addr < end;)
|
||||
{
|
||||
const u64 boundary = (addr + 0x10000) & -0x10000;
|
||||
const u64 block_size = std::min(boundary, end) - addr;
|
||||
|
||||
DWORD old;
|
||||
if (!::VirtualProtect(reinterpret_cast<LPVOID>(addr), block_size, +prot, &old))
|
||||
{
|
||||
fmt::throw_exception("VirtualProtect failed (%p, 0x%x, addr=0x%x, error=%#x)", pointer, size, addr, GetLastError());
|
||||
}
|
||||
|
||||
// Next region
|
||||
addr += block_size;
|
||||
}
|
||||
#else
|
||||
const u64 ptr64 = reinterpret_cast<u64>(pointer);
|
||||
verify(HERE), ::mprotect(reinterpret_cast<void*>(ptr64 & -4096), size + (ptr64 & 4095), +prot) != -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
shm::shm(u32 size)
|
||||
: m_size(::align(size, 0x10000))
|
||||
{
|
||||
#ifdef _WIN32
|
||||
m_handle = ::CreateFileMappingW(INVALID_HANDLE_VALUE, NULL, PAGE_EXECUTE_READWRITE, 0, m_size, NULL);
|
||||
verify(HERE), m_handle != INVALID_HANDLE_VALUE;
|
||||
#elif __linux__
|
||||
m_file = ::memfd_create_("", 0);
|
||||
verify(HERE), m_file >= 0;
|
||||
verify(HERE), ::ftruncate(m_file, m_size) >= 0;
|
||||
#else
|
||||
while ((m_file = ::shm_open("/rpcs3-mem1", O_RDWR | O_CREAT | O_EXCL, S_IWUSR | S_IRUSR)) == -1)
|
||||
{
|
||||
if (m_file == -1 && errno == EMFILE)
|
||||
{
|
||||
fmt::throw_exception("Too many open files. Raise the limit and try again.");
|
||||
}
|
||||
|
||||
verify(HERE), errno == EEXIST;
|
||||
}
|
||||
|
||||
verify(HERE), ::shm_unlink("/rpcs3-mem1") >= 0;
|
||||
verify(HERE), ::ftruncate(m_file, m_size) >= 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
shm::~shm()
|
||||
{
|
||||
#ifdef _WIN32
|
||||
::CloseHandle(m_handle);
|
||||
#else
|
||||
::close(m_file);
|
||||
#endif
|
||||
}
|
||||
|
||||
u8* shm::map(void* ptr, protection prot) const
|
||||
{
|
||||
#ifdef _WIN32
|
||||
DWORD access = FILE_MAP_WRITE;
|
||||
switch (prot)
|
||||
{
|
||||
case protection::rw:
|
||||
case protection::ro:
|
||||
case protection::no:
|
||||
break;
|
||||
case protection::wx:
|
||||
case protection::rx:
|
||||
access |= FILE_MAP_EXECUTE;
|
||||
break;
|
||||
}
|
||||
|
||||
if (auto ret = static_cast<u8*>(::MapViewOfFileEx(m_handle, access, 0, 0, m_size, ptr)))
|
||||
{
|
||||
if (prot != protection::rw && prot != protection::wx)
|
||||
{
|
||||
DWORD old;
|
||||
if (!::VirtualProtect(ret, m_size, +prot, &old))
|
||||
{
|
||||
::UnmapViewOfFile(ret);
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
#else
|
||||
const u64 ptr64 = reinterpret_cast<u64>(ptr);
|
||||
return static_cast<u8*>(::mmap(reinterpret_cast<void*>(ptr64 & -0x10000), m_size, +prot, MAP_SHARED | (ptr ? MAP_FIXED : 0), m_file, 0));
|
||||
#endif
|
||||
}
|
||||
|
||||
u8* shm::map_critical(void* ptr, protection prot)
|
||||
{
|
||||
const auto target = reinterpret_cast<u8*>(reinterpret_cast<u64>(ptr) & -0x10000);
|
||||
|
||||
#ifdef _WIN32
|
||||
::MEMORY_BASIC_INFORMATION mem;
|
||||
if (!::VirtualQuery(target, &mem, sizeof(mem)) || mem.State != MEM_RESERVE || !::VirtualFree(mem.AllocationBase, 0, MEM_RELEASE))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
const auto base = (u8*)mem.AllocationBase;
|
||||
const auto size = mem.RegionSize + (target - base);
|
||||
|
||||
if (base < target && !::VirtualAlloc(base, target - base, MEM_RESERVE, PAGE_NOACCESS))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (target + m_size < base + size && !::VirtualAlloc(target + m_size, base + size - target - m_size, MEM_RESERVE, PAGE_NOACCESS))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
#endif
|
||||
|
||||
return this->map(target, prot);
|
||||
}
|
||||
|
||||
void shm::unmap(void* ptr) const
|
||||
{
|
||||
#ifdef _WIN32
|
||||
::UnmapViewOfFile(ptr);
|
||||
#else
|
||||
::munmap(ptr, m_size);
|
||||
#endif
|
||||
}
|
||||
|
||||
void shm::unmap_critical(void* ptr)
|
||||
{
|
||||
const auto target = reinterpret_cast<u8*>(reinterpret_cast<u64>(ptr) & -0x10000);
|
||||
|
||||
this->unmap(target);
|
||||
|
||||
#ifdef _WIN32
|
||||
::MEMORY_BASIC_INFORMATION mem, mem2;
|
||||
if (!::VirtualQuery(target - 1, &mem, sizeof(mem)) || !::VirtualQuery(target + m_size, &mem2, sizeof(mem2)))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (mem.State == MEM_RESERVE && !::VirtualFree(mem.AllocationBase, 0, MEM_RELEASE))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (mem2.State == MEM_RESERVE && !::VirtualFree(mem2.AllocationBase, 0, MEM_RELEASE))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const auto size1 = mem.State == MEM_RESERVE ? target - (u8*)mem.AllocationBase : 0;
|
||||
const auto size2 = mem2.State == MEM_RESERVE ? mem2.RegionSize : 0;
|
||||
|
||||
if (!::VirtualAlloc(mem.State == MEM_RESERVE ? mem.AllocationBase : target, m_size + size1 + size2, MEM_RESERVE, PAGE_NOACCESS))
|
||||
{
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
+24
-21
@@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "util/types.hpp"
|
||||
#include "StrFmt.h"
|
||||
#include <vector>
|
||||
|
||||
@@ -60,21 +60,26 @@ namespace utils
|
||||
return (start1 >= start2 && end1 <= end2);
|
||||
}
|
||||
|
||||
address_range(u32 _start, u32 _end) : start(_start), end(_end) {}
|
||||
constexpr address_range(u32 _start, u32 _end) : start(_start), end(_end) {}
|
||||
|
||||
public:
|
||||
// Constructors
|
||||
address_range() = default;
|
||||
address_range(const address_range &other) : start(other.start), end(other.end) {}
|
||||
constexpr address_range() = default;
|
||||
constexpr address_range(const address_range &other) : start(other.start), end(other.end) {}
|
||||
|
||||
static inline address_range start_length(u32 _start, u32 _length)
|
||||
static constexpr address_range start_length(u32 _start, u32 _length)
|
||||
{
|
||||
return address_range(_start, _start + (_length - 1));
|
||||
if (!_length)
|
||||
{
|
||||
return {};
|
||||
}
|
||||
|
||||
return {_start, _start + (_length - 1)};
|
||||
}
|
||||
|
||||
static inline address_range start_end(u32 _start, u32 _end)
|
||||
static constexpr address_range start_end(u32 _start, u32 _end)
|
||||
{
|
||||
return address_range(_start, _end);
|
||||
return {_start, _end};
|
||||
}
|
||||
|
||||
// Length
|
||||
@@ -87,7 +92,7 @@ namespace utils
|
||||
void set_length(const u32 new_length)
|
||||
{
|
||||
end = start + new_length - 1;
|
||||
ASSERT(valid());
|
||||
ensure(valid());
|
||||
}
|
||||
|
||||
u32 next_address() const
|
||||
@@ -176,9 +181,7 @@ namespace utils
|
||||
|
||||
void set_min_max(const address_range &other)
|
||||
{
|
||||
const address_range _range = get_min_max(other);
|
||||
start = _range.start;
|
||||
end = _range.end;
|
||||
*this = get_min_max(other);
|
||||
}
|
||||
|
||||
bool is_page_range() const
|
||||
@@ -279,7 +282,7 @@ namespace utils
|
||||
|
||||
public:
|
||||
// Wrapped functions
|
||||
inline void reserve(size_t nr) { data.reserve(nr); }
|
||||
inline void reserve(usz nr) { data.reserve(nr); }
|
||||
inline void clear() { data.clear(); }
|
||||
inline size_type size() const { return data.size(); }
|
||||
inline bool empty() const { return data.empty(); }
|
||||
@@ -453,9 +456,9 @@ namespace utils
|
||||
// Will fail if ranges within the vector overlap our touch each-other
|
||||
bool check_consistency() const
|
||||
{
|
||||
size_t _size = data.size();
|
||||
usz _size = data.size();
|
||||
|
||||
for (size_t i = 0; i < _size; ++i)
|
||||
for (usz i = 0; i < _size; ++i)
|
||||
{
|
||||
const auto &r1 = data[i];
|
||||
if (!r1.valid())
|
||||
@@ -463,7 +466,7 @@ namespace utils
|
||||
continue;
|
||||
}
|
||||
|
||||
for (size_t j = i + 1; j < _size; ++j)
|
||||
for (usz j = i + 1; j < _size; ++j)
|
||||
{
|
||||
const auto &r2 = data[j];
|
||||
if (!r2.valid())
|
||||
@@ -579,15 +582,15 @@ namespace utils
|
||||
|
||||
namespace std
|
||||
{
|
||||
static_assert(sizeof(size_t) >= 2 * sizeof(u32), "size_t must be at least twice the size of u32");
|
||||
static_assert(sizeof(usz) >= 2 * sizeof(u32), "usz must be at least twice the size of u32");
|
||||
|
||||
template <>
|
||||
struct hash<utils::address_range>
|
||||
{
|
||||
std::size_t operator()(const utils::address_range& k) const
|
||||
usz operator()(const utils::address_range& k) const
|
||||
{
|
||||
// we can guarantee a unique hash since our type is 64 bits and size_t as well
|
||||
return (size_t{ k.start } << 32) | size_t{ k.end };
|
||||
// we can guarantee a unique hash since our type is 64 bits and usz as well
|
||||
return (usz{ k.start } << 32) | usz{ k.end };
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user