diff options
author | jc_gargma <jc_gargma@iserlohn-fortress.net> | 2023-03-13 10:30:52 -0700 |
---|---|---|
committer | jc_gargma <jc_gargma@iserlohn-fortress.net> | 2023-03-13 10:30:52 -0700 |
commit | a09894839ccba98dd8cd2a15cfe09cb75de18125 (patch) | |
tree | 39300c2fabf6d202f199a9441a3e8466c8770b16 /PKGBUILD | |
parent | Update to 0.F.3 (diff) | |
download | cataclysm-dda-master.tar.xz |
Port patches back to DDA.
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 328 |
1 files changed, 224 insertions, 104 deletions
@@ -11,8 +11,8 @@ pkgbase=cataclysm-dda pkgname=(cataclysm-dda cataclysm-dda-tiles) pkgname=cataclysm-dda -pkgver=0.F.3 -_pkgver=0.F-3 +pkgver=0.G +_pkgver=0.G pkgrel=1 pkgdesc="A post-apocalyptic roguelike." #url="http://cataclysmrl.blogspot.com/" @@ -20,14 +20,21 @@ pkgdesc="A post-apocalyptic roguelike." #url="http://en.cataclysmdda.com/" url="https://cataclysmdda.org/" arch=('x86_64' 'aarch64') -license=("CCPL:by-sa") +license=("CCPL") +options=('lto') depends=('ncurses' 'hicolor-icon-theme' 'gettext') makedepends=('sdl2_image' 'sdl2_ttf' 'sdl2_mixer' 'freetype2' 'astyle') -source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/archive/$_pkgver.tar.gz" +#source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/archive/refs/tags/cdda-experimental-$_pkgver.tar.gz" +source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/archive/refs/tags/$_pkgver.tar.gz" +#source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/archive/$_pkgver.tar.gz" "cataclysm-dda.desktop" "cataclysm-dda-tiles.desktop" - "ammo-01_bugs.patch" + "ammo-01_inconsistent-ammo-names.patch" + "ammo-02_fix-20x66mm-loudness.patch" + "ammo-03_fix-reloaded-50bmg.patch" + "ammo-10_ammo-order-fix.patch" + "ammo-20_ammo-typos.patch" "armor-01_ankle-ammo-pouch-is-not-a-backpack.patch" "armor-02_fix-survivor-fingerless-gloves-warmth.patch" @@ -35,37 +42,46 @@ source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/ "bionics-01_npc-can-use-more-bionics.patch" "foods-01_fix-food-materials.patch" + "foods-03_fix-mutant-bad-taste.patch" "itemgroups-01_hk46-is-milspec.patch" - "itemgroups-02_fix-shelter-batteries.patch" + "itemgroups-03_fix-shelter-batteries.patch" "meds-01_antibiotics-unhealthy.patch" - "mutations-01_fix-evac3-background-visible.patch" + "mission-01_typos.patch" - "npc-01_dialogue-fixes.patch" + "mutations-02_fix-evac3-background-visible.patch" - "recipes-01_dragon-can-be-dismantled.patch" + "npc-08_nurse-takes-more-meds.patch" + "npc-09_broker-takes-more-foods.patch" + "npc-11_npcs-reload-gas-mask.patch" + "npc-20_dialogue-fixes.patch" - "terrain-01_tacoma-clinic-add-missing-floor.patch" - "terrain-02_make-firestation-shelter-wells-npc-drinkable.patch" + "recipes-01_4570-dragon-can-be-dismantled.patch" - "tools-01_foldable-bottle-is-container.patch" - "tools-02_normalize-drone-volume.patch" + "terrain-04_lumbermill-gasoline-not-spilled.patch" + "terrain-08_more-military-base-overmap.patch" + "terrain-11_clean-up-map-extras.patch" + + "tools-04_normalize-drone-volume.patch" "vehicles-01_portable-generator-engine.patch" + "vehicles-02_fix-fbi-car-name.patch" + "vehicles-03_black-box-can-be-installed.patch" "etc-01_fix-rubbersplosion.patch" - "etc-02_add-missing-price-postapoc.patch" - - "jc_ammo-loudness-ap-times-2.patch" - "jc_allow-bio-firestarter-on-smoker.patch" - "jc_stop-non-faction-npc-sleep-depirvation.patch" - "jc_stop-non-faction-npc-malnourishment.patch" - "jc_stop-sleeping-on-tables.patch" - "jc_allow-hacker-laptop.patch" - "jc_more-military-base-overmap.patch" - "jc_npc-eat-from-further-camp.patch" + + "src-01_radio-can-use-ups.patch" + "src-02_ammo-loudness-ap-times-2.patch" + "src-03_allow-bio-firestarter-on-smoker.patch" + "src-04_stop-non-faction-npc-sleep-depirvation.patch" + "src-05_stop-non-faction-npc-malnourishment.patch" + "src-06_stop-sleeping-on-tables.patch" + "src-07_allow-hacker-laptop.patch" + "src-09_npc-eat-from-further-camp.patch" + "src-11_remove-legacy-recruiting-penalty.patch" + "src-12_fix-food-supply-calculations.patch" "vampirism.patch" @@ -74,47 +90,79 @@ source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/ "cataclysm-dda-soundpack_jcsoundpack.tar.xz::https://library.iserlohn-fortress.net/cataclysm-dda-soundpack_jcsoundpack.git/snapshot/cataclysm-dda-soundpack_jcsoundpack-master.tar.xz" "cataclysm-dda-musicpack_coag-musicpack.tar.xz::https://library.iserlohn-fortress.net/cataclysm-dda-musicpack_coag-musicpack.git/snapshot/cataclysm-dda-musicpack_coag-musicpack-master.tar.xz" ) -b2sums=('2e715ff131ce654b0ad6f18cb465b80ab55a09e5d48434a7d209454c9a2a952970f572bb81539bf071efe1292310f5b922c75a6c86ba360cca13dbeb91e13996' +b2sums=('58b3e313d1aaae2d6a3b185904c35dda8fab2d37f99624be4661975772e9f08e94a97d8221f87fb0f27c7a4e1d1ab712811ec5067e63c92139ef36940d12efe6' '8cff87d80bf30b86f995f77a97cc1ddb7b809148d100f3c0d74e706fe59eac52de55710fb7aed1abd59836c05f2474c7d68455736aac4f229d1cdf806d7240a1' '8ffff827ed464af678497da5129eb69d3d1a4c6994bbcc00ef7f7b240cd04e7961c3c0ac52d6940252241406c04e647fac19c9327847afced33988eb15973ba8' - 'f71229fbaf2260602909187ba3894423a04c8625dc41813f2898faf4dcbeb6053007ea082201b1be68a59f6cbfd67e9e6a00d293e77c2f6bc1e225e3dc09ef9c' - '7ca2d6bbccb4ecb6495d9b7cc114194364c454f40163ac9420c5dceb2027429c9737bb837748987bf8e8b3143bef25552fc9bd7ae5d25a31f8df94ecb093bdc2' - 'a00106a04f63aeed03a81fb2a3ca6f321fa5c21d0d342753a56c9cccc9000dda9d6e2204368f00aa37c75ce35967b9ea2537b3e7a48ce6a486343c8c2d7f239f' - '900ec02ec9ec29a0b56341bbc9e947821e4c2c1f3e8914b2e59f317a2860d5b989afe5d1cd8585c60eb13b546167294a9253ad87a64775ad1d7152854bf6707a' - 'dd9026522976071a8cece8b935ab494e6a0e129b9242b043be3fbaa1478f75bedfbfab662d6286012fd5849e7b6bc097dea5de085d556bbfe1420d41ebddf81f' - '4d91e3555c0979bb59f8841588aefcb041e04b035931ec95bea519cb2c6df49e72029fa38104b7c80c157114d62203ce57b877dc338f3d2b8a6a5fb5dcef4784' - '31294c958b9c3d73cf460682f4a1260392b4e87fc04417e0d4ba02be73c3bd43f84537b30bcab09b7879f58c51cc2191d34ccef2f5fcec4d3dad7b1c522146e6' - '8c946f6f8302b7d184663d79805be93f22578ce11c18f7dbe8fabdddf85cd1cc0617af180fec1cbf3419e310fe57b510b9b961ba2b16c93ef8a66e45258d326e' - '33cbee2d251a4abf2ec507b31245205877d47152bd39000ea3058089b1fa45bbcb3624a7bbc58f394b1dd9710290f99c1708e3ece8221c71d760d67ff6965449' - '794ac1cfe88250e1717f3093ce999b1bd2cfaaaa3800d7ad0a13b720efbcc2795ed8c82d558b6b5909a8359178c70f21fe41b1c9ffe726a7a89537140801ef90' - 'd6421c0f12e7c1a08eee1918c349e7d88e21d5ab980a65ad5798ef3b61319bd4570ecaf8d007d9905f471b623c3633a31c471f34fe5955a8f71229dc0bc52dda' - 'b8a64accada87ee5be989c5307805610c9b5c0327bc107aab237ac3225dd9e4c51b6c79a2a7de15fe187d3c32d7cbe1c462f9b0e9fb5d5a55a74236c7061e96e' - '531f35be92feecdcc78faf4f76a538a075a144848b122616594eef7a0954aa6e2876f0007635a92f4be635060d0b58d943cd99dcec2889031363f7dd8d3bc58d' - '71ddf9190b79669f7e63973ce5b4b3fe0de5d78f52bd76fbe63608a5f330ea757458af2172d5588b59ba48f99c6f43ec051a066ff6bc07c13dd2c5e05d8161f7' - '8d6fd37497c2ce3c6e65933dded7cd27e165e74ce92cef01b4f1522cd550c8a4f227434d3e566f94e493c385226cf6ff52374d05686b203fd28fdca3babb471c' + '5dff40a22314227d603c278a8bf5ceb81e7e4b98fd8fa52edb17a006ee3dca84a1647d8d5ee5ba281c828a5b38b8b6ea2d22996c1c9b0b3ff816dd7f98bb1f14' + '28ccb5aae3dd693ffc127c7dc0a038295591cdf5c6fde1b298f7ed0ab0010693bb29c0f01650927e8d993a3af3144ab261de60dd04dc0bc002cbd2ecea6761d2' + 'a6c7f8d9741e1e327aeb3fb03ca8a59cb7a311e7a687bf73048a5a1b50c490f6cde99433196628d1bdbd29c078242deb22694e1d9becec1c1da4fa0660464ba7' + 'cf8c0c45f9a222b9cfb1694d3d39ebd516b70327cc4567a899a64e43570b35961bf16183dfc891834ac37328dbde7810b5466f130a5b26032b487d6b2ddbc472' + '2f5ca21814cc985c7c267d6747598704718b58680f4b94faa40c470070ba47abbf0ea69033763a0008b5234769c8b8358eed93f2c7c210ed7078b6669c2bd0c0' + 'b1383199d606fc3ed2cd40c1ec2e32aebc5edb69902ce0477b975bc57d3f6e43dde808ea5af0e326a19e5d61b50f2c1b59848d6505f7d42bb0189977feb6aa05' + '0f835c251fd439eb6b620250035ae9b4ca6dc4f6df4db1fa59f9995ef0a1cbdf254c734c3db3a91a66ccdb0459fe36a080de6a809b978a23a499e0e48c39aec1' + 'c23b043ecd1fb750ddd88856e7b27856a33a7eea0c6ccb5b376d4961f07ca09d5eac2bbaf71d74932dec3eca9af6ed36ae4230765391bd186268b0cd4d4bb3f8' + '2bce148423c87367312f2364c0101620b5da86c69acebd2c877f34788fe727f4ba43ad197f467aed750e17fec84e8445c226fdbbe3b7dea2135f2f4d3e0d6b64' + 'cca9a5d27768bf79a615aa9c019b081a0355e79e5417f6046bc331a7fc6079d2d0341dc8fd5d743a403c9baba554e47e497d56da36e55ecedecbb20b6fce05c9' + 'a68d2005f084cdeea2cfe11de6da1d3be07ab27da3dee567d1701bbb970f33d20b5e68ef66121c5821beffc96848ba5cbd02e316772f9327fceb7c496aa31ad4' + '880cb1a343e2bdaa53c85fe82f8340d5e1c6d32313a99e50063781215ee848e00b16a2041ca5e4c5f765f275525886e9cd20262ed41ca44406697823169cc273' + 'f75b8058c6b081eb6e9b889795929f076b0a17736644926eb69df8ac7460c40b3148569f53c5fa2bb390d8a43b7f2a5115c6fffaae82cffa94ff317e257f3a48' + '3b7276fe0e708830a09288bfb4076f0ff758ac3ed33711ccfdc93dda2f516630e1aeb5f6e67f417d71fad10eece05528ab4596d3912f657839c45e423df08313' + '8a0e245ea0e92649987590e321cc227c0911836f47ac538783e8f0a28a32da8595c916f54d249ac1364283a70e0abc9d7a52331e392f3f5f736ffc0d2fcee789' + 'cf2074b5a143d0fcc0ade09c3bdebf0f15b67a8189f5ac0cf2085fdbf3279cbe50298915b756e08fed77f6dd949ae37df9e8fd0ef4399490c33ad8628c1e9b06' + 'fbfeff325c231e3a7f556bac9cd1e5d773a1da6e2494a312eec4c3fd76707330b46cd6653aaded770ab46809f45aeec54cdf10344fbc1e0258bf348dca3c7082' + '4acf57f108ce331cb364408a63a414c39881b916c2d1c50e1e52ebe8e0b3df63596e9478caa2a7c3a06c59a07cbd80130e669662cc955aec2d32372fe0636771' + '79202bbc83ff080b8fe6dfa3beb162d0bf33a642aedd8339948b19e0426d41ee96d12229b1830e09fd6566ea7c941824f7a654130b731fd33b75c0eec5441151' + '9957d799eb495afe2505052171ca4835c3cf2dbd47197c983397a0b31caa1cf9ddb325ce365db62a7db5735f40e3951cc611ad3830788b8d3e94480ba586b171' + '85aeb5920ee5879848be4057324153a077fe907bed527ed8f9b80a3c5ee1ef64786f63ee2999f5ba74e80a43e99ded3280ce27759c1f7b73259a6e2b5e584aa8' + 'e3302d903d053f25aa666d572f74a8bbd3b65dde40eedcbf46e537ceb2294ac22b3772087fce04c4a780c2f18e855179c6ddc8af12d72a89b82957ce09deb52f' + '12d93f74de739ade2725983c9f6396111e2bb17f491c0de54f5e006e9b8dd5f5618afd63a1ea6fe2313cc5984157c0e5da62a60b429aa4f2d84751ecdba341f0' + '877f36479ff9b8a0284360f1425d3574251c8a48482a824579500bc7da833adecc44c7ecd7d61d708722cf3ae70ba48c2af607c3cbba881720455901521c4889' 'b5567d516b344ceb382bb0253e2b87c90ddc5379afb76a7d384aec0829a6d8a3de2a1f55740871cd286a8cfa23ca635ee9e3f81faa9839dc10fb209955b63c78' - '22779d1418f24d382431078a3fe35790edbbcfa94ed4c9bf2b2698fe00dbe87466c3dc460b3f02710440db63cf1aa255ab6cf589b06d1e0cf49f512657d588b1' - '75b1410a950f3d964ed8b610af86f1a60f22ce4a4ebf242370a76e1c66f913c287f1b02dfa77c6d5901c77b060b6f432df06ed322b26fa71d180775f64afc57b' - '623a0b62417b626817e33f376c14df69211313388ab65451f5eec0c512ee61bfe54871e57f3a6d873392110b538ea7ad18d5e8ac100a71f7fc036a6818d602c2' - 'fd1fabe15fa3127cfa2b5e60928ee9b48a98bd6e1e5f8f66a3f6625e7d7e076e7eae3048f1bb5a8b4c554679b4a28de30b97eedcb979050d9115c1f2685aae7d' - 'f346172ac4fdac9ffd7000901f6b145ff45df8abf6c8d495204c08af1e9a34809259819925ebbd0a1e54336701a1d0409671acae6c7c538dfd77ab4d4a506be1' - '8bb83ab44365599cd58efef13ad0ddf7e6fbc62bf09523c029323efe2bfe2e80ed42dfbd790ade66d26e35e59de623133edb51b0a6dd81637928c205a08c1fc8' - 'd5287ddb4c38fbca9e6440e5243c718437660c9cf20a836baf1569575f6d953de8995641e6ec20a2a8859b9eefb5b975c416c4fe6f92f0916a5e21c3328d4fce' - '4e40bc796ebd7941f76d9f11cfa62d7fa6d83c386f325bbec7f2cac99619c059cbf4611fb40ca0d78c8aa2cd3dd15a14de1f144d6f853e96939924caa87dac75' - '831acc3935f1554a8385c804138a3d83423c5843824e7fbe01334c5d07accd826d9e14805584e6b91d9c6cdc4dbed99ffe32763440da07479f4f5480fbdb941b' - 'f13c5d89fdaf60621297e86537fc84992bec9d60446dfe41731abde53997223094b91cbf8173636241bc17ebd1f28cf3a33ece604ae67ea0b3c9b6a128c182f6' - 'a52e780086bfbc44e02de637ec03e99f4aacfc7471f9bc6f8650ad5b36694e4d17a2dcbbf8838e6ed2cd7ef85f43e82035771ad7f283c66dd55e2e4c4358ab84' - 'ea1ab36365d19be71bd6052e98082a8feb6bbdbe487e8e5795143ceb495059d157b034834bd532a80ccc5a16daa3c355dd56316a27936d441b7c9cc85e40f450' + 'a8d9075f3b3c46ec7b6d4d96c6e346c7bf79daa832026faba97846aad89456e18c51eadbfe00d3e6e36fcf2a1ff153de644d7553035fc5046fe6f4ac6de2c9e6' + 'b9d519e75c8fdd1522b7ce82055f1c8f5c05e2aaf45d77747e8e3924289322e68dc0ff11145ac9674015593c296eef06b36c5e86b6dc9fb21f2c130282c2b70b' + '15f30d2dd4dc437aae2d9237d7ebc299a3b2d6752b111ef26462e165c3665a4aa825616b80e9927b9715ffb31aec25c2831a8015131d0e830e2cf6c9570526df' + '06c5652eb2c70b8aba6d788415089b740c3510cd9c570838f656202ba2dc65d4f3289f6695413665de930e84fe287ef035ed8e83a0610a5a316e76a17442683a' + '92cde696eec00e6758b58e73e8bc60ad1a73bb2a18d4fdfd24a19b5be715305a047943a02d94a9703c101ca0c769dbeb816f1f28809345bae0fec42fbc27bb34' + '9fb6d2945184347e5b4f56f022d9b1b40559c1210edd91cb984d2c69e711dd297eab2a06d1e7d4008052fad658a9574ebd933083e7f8f3b3600b271593cbde15' + 'ce82294e480ad42f0001c799fd8131b60024b6097653f3c57564c75e54596616e376f0d7f1cf4e54d8c302a61ef164b4323f795bfa19b2c13ab9e927d37f1600' + 'f4d2d03d255a8b73fab16cb04e4f460eb74dd961610b14cc3ea99df4aa52bd024eb230432907e3845f585f4906ba8b1caa9d850666528cee22bada96481a3a21' + '1e1c61c519805fe6c8c1d0fb3bf8c28f26823ffea20e4d92610117e81e50401d9eb02e05fb7135325580235bcc42be82921972467b416df5feb20a4742057b53' + '8213031fc1e154648008109ae654db938689f01bca27b9a2009854dda7bc4d99e3bd4581f6cbd06e31a632cd8431be01d5e96fd69534670996fde9a1a39691f6' + '66f65806ec968d4a9f571d0decb8f1c4f4b386aa3837b5c29713734c003676758e1e9ec8492adf2359847ac9e4ebf791c16dfee426272e90e42775379c5904fa' + 'ac2c5e03150bb0860b62d31c68304ad3ca5143a208bb58cd5bcc6beb924a6230cb3617a64bf902a4a69c5d25ce00de8398d5227d36efed4397652849467cfa4a' + 'f84197cbd2ed69f0107b136c118ab4608a2d3c70b112689f4dbc01399e8db3867c7673103e30dc9b24393f44438725a8ec82c7770fc7913aa39b61405ba3670b' + '4e188cebde0ffd81624f2b9a2c9111aa41a82e3d80a7b80f143af70f0182cce6e0b58350807db2948414f1d655d42367263af67bd5ae707d3ada4010c924ccd1' + 'ec274f6809765a638ce17b7c89c442ea9c4232c8ab1e0f72be8d682da76ab6a10cf02c67af5438e7e7a1901af9d6c64f3c598b49052cdeb20932b26bc5e9ba82' 'a56efdaae0344726debf5b74846edce8df7aa2357fbc7a05a3d369d1f457b02934a0d0ce2330072e03f1ac901e06e333c9393f795c761f8440307e7649ed5596' - '9d0e17552338c9d92ff696f1834a5d99c29d5dfbab6903b620410f62527a0ba60720c9ceec8e203b737f784ade8a53dbaca428ac7cc439f3f4f765aac7f1170f' + '14ef4cc6b05f8d9b0d6196c4b6f35cc8083bdf4820c19c320551158b47b570ee6b385f3d6b9888f614fb9d5325265feae810a2c5fff4a0deb42b01612bad6517' 'b9309da09b165fb57e83f84e3584d2479bd3336ed86e181e5df2d27daa92bd55d03d7f3fc226f03696af5f0f32d8e0e7ecd26ae7e50eed0200d0b0feaad07efb') prepare() { + #cd "Cataclysm-DDA-cdda-experimental-${_pkgver}" cd "Cataclysm-DDA-$_pkgver" - sed -i 's/-Werror//' Makefile - sed -i 's/ncursesw5-config/ncursesw6-config/' Makefile - sed -i 's/shell git/shell false/' Makefile - sed -i 's/-Os/-O3/' Makefile + sed \ + -e 's/-Werror//' \ + -e 's/ncursesw5-config/ncursesw6-config/' \ + -e 's/shell git/shell false/' \ + -i Makefile + + # Disable default optimizations + sed \ + -e 's/-Os/-O3/' \ + -e 's/-O0/-O3/' \ + -e 's/-Og/-O3/' \ + -e 's/CXXFLAGS += -ffast-math/#CXXFLAGS += -ffast-math/' \ + -i Makefile + + # Remove non-existent flags generating warnings + sed \ + -e 's/-Wzero-as-null-pointer-constant \\/-Wzero-as-null-pointer-constant/' \ + -e 's/-Wno-range-loop-analysis/#-Wno-range-loop-analysis/' \ + -e 's/-Wno-unknown-warning-option/#-Wno-unknown-warning-option/' \ + -i Makefile + + # They forgot to adjust the version in 0.G! + sed -i "s/0.F/0.G/" Makefile # # # Hotfixes @@ -124,11 +172,24 @@ prepare() { # # # Various fixes for bugs I came across # # Ammo fixes echo "Applying ammo fixes" - # Fix mulitple inconsistent ammuntion names and handloaded status. - # Also Change reloaded_50bmg to be based on 50bmg: The id and description make it pretty clear that reloaded_50bmg is not supposed to be based on Match rounds. - # Also set a fixed loudness of 20x66mm shotgun shells like that of other shotguns: Other shotguns have fixed loudness to work around how the short range factors causes them to be far quieter than one would otherwise expect. - # Also fix ammo ordering so as to not prevent those items being modded: Having copy-from items occuring earlier in a json than the item being copied from prevents items based on it being modified. - patch -Np1 -i "$srcdir"/ammo-01_bugs.patch + # Fix mulitple inconsistent ammunition names and handloaded status. + patch -Np1 -i "$srcdir"/ammo-01_inconsistent-ammo-names.patch + + # Set a fixed loudness for 20x66mm shotgun shells like that of other shotguns: + # Other shotguns have fixed loudness to work around how the short range factors causes them to be far quieter than one would otherwise expect. + patch -Np1 -i "$srcdir"/ammo-02_fix-20x66mm-loudness.patch + + # Change reloaded_50bmg to be based on 50bmg: + # The id and description make it pretty clear that reloaded_50bmg is not supposed to be based on Match rounds. + patch -Np1 -i "$srcdir"/ammo-03_fix-reloaded-50bmg.patch + + # Fix ammo ordering so as to not prevent those items being modded. + # Having copy-from items occuring earlier in a json than the item being copied from prevents items based on it being modified. + patch -Np1 -i "$srcdir"/ammo-10_ammo-order-fix.patch + + # Fix some rather serious typos in ammo descriptions: + # Probably someone did a global replace and never audited the results. :/ + patch -Np1 -i "$srcdir"/ammo-20_ammo-typos.patch # # armor fixes @@ -149,12 +210,24 @@ prepare() { patch -Np1 -i "$srcdir"/bionics-01_npc-can-use-more-bionics.patch + # # faction fixes + #echo "Applying faction fixes" + + + # # faction camp fixes + #echo "Applying faction camp fixes" + + # # food fixes echo "Applying food fixes" # Fix several foods not being marked as the correct material: # This prevents odd outcomes such as carnivores drinking almond/soy milk and eating peanut butter. patch -Np1 -i "$srcdir"/foods-01_fix-food-materials.patch + # Fix several mutant components lacking the BAD_TASTE flag: + # If raw mutant meat is flagged as disgusting, raw mutant fat must be just awful. + patch -Np1 -i "$srcdir"/foods-03_fix-mutant-bad-taste.patch + # # itemgroups fixes echo "Applying itemgroup fixes" @@ -164,60 +237,75 @@ prepare() { # Fix items in unlooted, unused lockers and cabinets missing batteries: # They need to be marked as the battery contained inside the item. - patch -Np1 -i "$srcdir"/itemgroups-02_fix-shelter-batteries.patch + patch -Np1 -i "$srcdir"/itemgroups-03_fix-shelter-batteries.patch - # # monster fixes + # # medicine fixes echo "Applying medicine fixes" # Add -4 health to antibiotics: # weak are -2, strong are -10, this feels like a nice middle ground. patch -Np1 -i "$srcdir"/meds-01_antibiotics-unhealthy.patch - # # monster fixes - #echo "Applying monster fixes" + # # missions fixes + echo "Applying mission fixes" + # Fix Typos: + # Foraging encounter has inconsistent monster references. Change all to cougar. + patch -Np1 -i "$srcdir"/mission-01_typos.patch # # mutation fixes echo "Applying mutation fixes" # Fix Evacuee 3 background 3 being player visible: # It was missing "player_display": false - patch -Np1 -i "$srcdir"/mutations-01_fix-evac3-background-visible.patch + patch -Np1 -i "$srcdir"/mutations-02_fix-evac3-background-visible.patch # # npc fixes echo "Applying NPC fixes" + # Update the Tacoma Nurse to buy almost every non-dangerous, non-electrical, and non-expensive medicine. + # Also remove acceptance for various tools that are not correctly taken, such as first aid kits. + patch -Np1 -i "$srcdir"/npc-08_nurse-takes-more-meds.patch + + # Update the FMC broker to buy most preserved foods. + # Also update the dialogue to specify that he buys more types. + patch -Np1 -i "$srcdir"/npc-09_broker-takes-more-foods.patch + + # Fix npcs failing to reload activated gas masks: + # Most masks lacked a "charges_per_use: 1" field, required for npcs to know they can reload it. + # They still won't activate a fresh mask on their own though. :/ + patch -Np1 -i "$srcdir"/npc-11_npcs-reload-gas-mask.patch + # Assorted typos in NPC dialogue. - patch -Np1 -i "$srcdir"/npc-01_dialogue-fixes.patch + patch -Np1 -i "$srcdir"/npc-20_dialogue-fixes.patch # # recipe fixes echo "Applying recipe fixes" - # Fix reloaded dragon shot not allowing dismantling when every other non-caseless round does. - patch -Np1 -i "$srcdir"/recipes-01_dragon-can-be-dismantled.patch + # Fix reloaded reloaded dragon shot not allowing dismantling when every other non-caseless round does. + patch -Np1 -i "$srcdir"/recipes-01_4570-dragon-can-be-dismantled.patch # # terrain and overmap fixes echo "Applying terrain and overmap fixes" - # Fix missing floor in the tacoma clinic: - # The hospital is still a mess. :/ - patch -Np1 -i "$srcdir"/terrain-01_tacoma-clinic-add-missing-floor.patch + # Fix lumbermill gasoline being spilled instead of being inside the gas pump: + # The gas pump was placed on top of a tile that didn't allow items inside, causing the gasoline to be shunted to the next valid one. + patch -Np1 -i "$srcdir"/terrain-04_lumbermill-gasoline-not-spilled.patch + + # Expand the overmap tiles for the miltiary base to be less MMMM + #patch -Np1 -i "$srcdir"/terrain-08_more-military-base-overmap.patch - # Fix npcs unable to drink from firestation and shelter basecamps wells: - # They were missing the water_well blueprint_provides. - patch -Np1 -i "$srcdir"/terrain-02_make-firestation-shelter-wells-npc-drinkable.patch + # Fix up several typos, missing symbols, odd naming, and many extras lacking map notes support in map extras: + # More choice is better than less. You can disable undesired map notes in the map notes settings menu. + patch -Np1 -i "$srcdir"/terrain-11_clean-up-map-extras.patch # # tool fixes echo "Applying tool fixes" - # Mark the foldable plastic bottle and steel water bottle as containers: - # Being counted as tools didn't seem to fit their role. - patch -Np1 -i "$srcdir"/tools-01_foldable-bottle-is-container.patch - # Normalize the manhack volumes to that of the base grenade/explosive: # I don't see how a c-4 manhack could be 1/4 the volume of a stick of c-4. # Grenade hacks were also thrice as big as the base grenade. - patch -Np1 -i "$srcdir"/tools-02_normalize-drone-volume.patch + patch -Np1 -i "$srcdir"/tools-04_normalize-drone-volume.patch # # vehicle fixes @@ -226,6 +314,13 @@ prepare() { # This way it can actually function as is. patch -Np1 -i "$srcdir"/vehicles-01_portable-generator-engine.patch + # Rename the FBI Car: + # The stock name was clearly a typo of some sort. + patch -Np1 -i "$srcdir"/vehicles-02_fix-fbi-car-name.patch + + # Fix the black box to actually be installable: + # No tool provided screwing 3 and wrenching 3. + patch -Np1 -i "$srcdir"/vehicles-03_black-box-can-be-installed.patch # # Uncategorized for now @@ -233,70 +328,83 @@ prepare() { # Fix rubber items dismantling into 10x item volume of rubber. patch -Np1 -i "$srcdir"/etc-01_fix-rubbersplosion.patch - # Add price_postapoc to a number of items that did not have one set. - patch -Np1 -i "$srcdir"/etc-02_add-missing-price-postapoc.patch - # # # Various other fixes for bugs I came across that modify src echo "Applying source code fixes" + # Fix radio, e-ink reader music, tactical tonfa not working with UPS. + #patch -Np1 -i "$srcdir"/src-01_radio-can-use-ups.patch + # Fix ammo loudness mulitplying by six instead of two. - patch -Np1 -i "$srcdir"/jc_ammo-loudness-ap-times-2.patch + patch -Np1 -i "$srcdir"/src-02_ammo-loudness-ap-times-2.patch # Fix smoker racks not accepting bionic firestarter. - patch -Np1 -i "$srcdir"/jc_allow-bio-firestarter-on-smoker.patch + #patch -Np1 -i "$srcdir"/src-03_allow-bio-firestarter-on-smoker.patch # Fix Non-Player facton NPCs from becoming sleep deprived. - patch -Np1 -i "$srcdir"/jc_stop-non-faction-npc-sleep-depirvation.patch + patch -Np1 -i "$srcdir"/src-04_stop-non-faction-npc-sleep-depirvation.patch # Fix Non-Player facton NPCs from becoming malnourished. - patch -Np1 -i "$srcdir"/jc_stop-non-faction-npc-malnourishment.patch + patch -Np1 -i "$srcdir"/src-05_stop-non-faction-npc-malnourishment.patch # Fix NPCs preferring tables to cots or woodstoves to the floor. - patch -Np1 -i "$srcdir"/jc_stop-sleeping-on-tables.patch + patch -Np1 -i "$srcdir"/src-06_stop-sleeping-on-tables.patch # Allow the hacker_laptop to utilize the extra functions. - patch -Np1 -i "$srcdir"/jc_allow-hacker-laptop.patch - - # Port the revised military base layout from BN to DDA - # Expand the overmap tiles for the miltiary base to be less MMMM - patch -Np1 -i "$srcdir"/jc_more-military-base-overmap.patch + patch -Np1 -i "$srcdir"/src-07_allow-hacker-laptop.patch # Allow npcs to pull food from the camp larder at the full range of tiles camp actions can be assigned from: # Should allow bases larger than 3x3 to have less food micromanagment for NPCs. - patch -Np1 -i "$srcdir"/jc_npc-eat-from-further-camp.patch + patch -Np1 -i "$srcdir"/src-09_npc-eat-from-further-camp.patch + + # cur_level is set to -1 on all modern basecamps. Remove the recruiting penalty this legacy variable inadvertently induces. + patch -Np1 -i "$srcdir"/src-11_remove-legacy-recruiting-penalty.patch + + # Fix faction food supply being calculated at 288 calories per person instead of 2500. + patch -Np1 -i "$srcdir"/src-12_fix-food-supply-calculations.patch # # # Additional changes echo "Applying vampirism patch" # Add vampire mutation lines and modify a number of functions to facilitate these traits. patch -Np1 -i "$srcdir"/vampirism.patch + } build() { + #cd "Cataclysm-DDA-cdda-experimental-${_pkgver}" cd "Cataclysm-DDA-$_pkgver" #export CFLAGS="$CFLAGS -fPIE" - export CXXFLAGS="$CXXFLAGS -flto=auto -flto-odr-type-merging -fPIE" + export CXXFLAGS="$CXXFLAGS -fPIE" export LDFLAGS="$LDFLAGS,-pie" + # Prevent segfaults when examine tile->search returns no results. + #export CXXFLAGS="$(echo $CXXFLAGS | sed -i 's/-Wp,-D_GLIBCXX_ASSERTIONS//' - )" # No longer works + export CXXFLAGS="$(echo $CXXFLAGS | sed 's/-Wp,-D_GLIBCXX_ASSERTIONS//')" + #echo $CXXFLAGS + # tests "ifdef TILES" so "TILES=0" will enable tiles! # DYNAMIC_LINKING appears to be a windows flag? - make PREFIX=/usr RELEASE=1 USE_XDG_DIR=1 BACKTRACE=0 RUNTESTS=0 LOCALIZE=1 LANGUAGES=all - make PREFIX=/usr RELEASE=1 USE_XDG_DIR=1 BACKTRACE=0 RUNTESTS=0 LOCALIZE=1 LANGUAGES=all TILES=1 SOUND=1 + make PREFIX=/usr RELEASE=1 USE_XDG_DIR=1 BACKTRACE=0 LOCALIZE=1 RUNTESTS=0 VERBOSE=1 PCH=0 LANGUAGES=all + make PREFIX=/usr RELEASE=1 USE_XDG_DIR=1 BACKTRACE=0 LOCALIZE=1 RUNTESTS=0 VERBOSE=1 PCH=0 LANGUAGES=all TILES=1 SOUND=1 ./lang/compile_mo.sh } package_cataclysm-dda() { + #cd "Cataclysm-DDA-cdda-experimental-${_pkgver}" cd "Cataclysm-DDA-$_pkgver" - make DESTDIR="$pkgdir" PREFIX="/usr" RELEASE=1 USE_HOME_DIR=1 LOCALIZE=1 LANGUAGES=all install + make DESTDIR="$pkgdir" PREFIX="/usr" RELEASE=1 USE_HOME_DIR=1 LOCALIZE=1 RUNTESTS=0 VERBOSE=1 PCH=0 LANGUAGES=all install # Docs install -d "$pkgdir/usr/share/doc/cataclysm-dda" cp --reflink -r doc/* "$pkgdir/usr/share/doc/cataclysm-dda" # undo symlink rm "$pkgdir/usr/share/doc/cataclysm-dda/JSON_LOADING_ORDER.md" - cp --reflink 'data/json/LOADING_ORDER.md' "$pkgdir/usr/share/doc/cataclysm-dda/JSON_LOADING_ORDER.md" + cp --reflink 'data/json/LOADING_ORDER.md' "$pkgdir/usr/share/doc/cataclysm-dda/JSON_LOADING_ORDER.md"+ # Manpage + + rm "$pkgdir/usr/share/doc/cataclysm-dda/"*.6 + install -Dm644 -t "$pkgdir/usr/share/man/man6" "doc/cataclysm.6" # License install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE" @@ -318,13 +426,26 @@ package_cataclysm-dda() { package_cataclysm-dda-tiles() { pkgdesc="A graphical post-apocalyptic roguelike." depends=('cataclysm-dda' 'sdl2_image' 'sdl2_ttf' 'freetype2' 'sdl2_mixer') + #cd "Cataclysm-DDA-cdda-experimental-${_pkgver}" cd "Cataclysm-DDA-$_pkgver" - make DESTDIR="$pkgdir" PREFIX="/usr" RELEASE=1 LOCALIZE=1 LANGUAGES=all TILES=1 SOUND=1 install + make DESTDIR="$pkgdir" PREFIX="/usr" RELEASE=1 LOCALIZE=1 RUNTESTS=0 VERBOSE=1 PCH=0 LANGUAGES=all TILES=1 SOUND=1 install # Icon - install -D 'build-data/osx/AppIcon.iconset/icon_128x128.png' "$pkgdir/usr/share/icons/hicolor/128x128/apps/$pkgname.png" - install -D 'build-data/osx/AppIcon.iconset/icon_128x128.png' "$pkgdir/usr/share/pixmaps/$pkgname.png" + # Icons + cd build-data/osx/AppIcon.iconset + for i in *.png + do + local _isize="$(echo "$i" | sed -Ee 's/icon_([[:digit:]]+)x\1\.png/\1x\1/')" + install -Dm644 "$i" "$pkgdir/usr/share/icons/hicolor/$_isize/apps/cataclysm-dda.png" + done + cd ../../.. + + # Manpage + install -Dm644 -t "$pkgdir/usr/share/man/man6" "doc/cataclysm-tiles.6" + + #install -D 'build-data/osx/AppIcon.iconset/icon_128x128.png' "$pkgdir/usr/share/icons/hicolor/128x128/apps/$pkgname.png" + #install -D 'build-data/osx/AppIcon.iconset/icon_128x128.png' "$pkgdir/usr/share/pixmaps/$pkgname.png" install -Dm644 "${srcdir}/$pkgname.desktop" "${pkgdir}/usr/share/applications/$pkgname.desktop" install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE" @@ -338,8 +459,6 @@ package_cataclysm-dda-tiles() { cp --reflink -r "$srcdir/cataclysm-dda-mod_battle-maid-redone-tileset-master/battle-maid-redone-tileset-pt1" "$pkgdir/usr/share/cataclysm-dda/mods" cp --reflink -r "$srcdir/cataclysm-dda-mod_battle-maid-redone-tileset-master/battle-maid-redone-tileset-pt2" "$pkgdir/usr/share/cataclysm-dda/mods" - #mv "$srcdir/cataclysm-dda-mod_vampire-stuff-redone-tileset-master" "$srcdir/vampire-stuff-redone-tileset" - #cp --reflink -r "$srcdir/vampire-stuff-redone-tileset" "$pkgdir/usr/share/cataclysm-dda/mods" # Sound mv "$srcdir/cataclysm-dda-soundpack_jcsoundpack-master" "$srcdir/jcsoundpack" @@ -350,6 +469,7 @@ package_cataclysm-dda-tiles() { install -Dm644 "$srcdir/coag-musicpack/musicset.json" "$pkgdir/usr/share/cataclysm-dda/sound/jcsoundpack/musicset.json" cp --reflink -r "$srcdir/coag-musicpack/music" "$pkgdir/usr/share/cataclysm-dda/sound/jcsoundpack" + # hack: remove overlapping files cd "$pkgdir/../cataclysm-dda" find . -type f -exec rm -f "$pkgdir"/{} \; |