summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Kescher2022-10-20 00:11:02 +0200
committerJeremy Kescher2022-10-20 00:11:02 +0200
commitd1e3f2c128adc4b44e17435594613282f57fb5aa (patch)
tree4d9a284239020e007ad135f28d74ba1dfaf07ac1
parent3ffd8e736b1fbbbbaa84ab58dee95294fb715c97 (diff)
downloadaur-d1e3f2c128adc4b44e17435594613282f57fb5aa.tar.gz
Fix git submodules change, add upstream patches
-rw-r--r--.SRCINFO12
-rw-r--r--PKGBUILD30
-rw-r--r--dialog-crash-fix.diff26
-rw-r--r--mlc-discord-rich-presence.diff116
4 files changed, 165 insertions, 19 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 1469151efbc5..7a17122fa1fc 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = cemu
pkgdesc = Software to emulate Wii U games and applications on PC (with cutting edge Linux patches)
pkgver = 2.0.182
- pkgrel = 2
+ pkgrel = 3
url = https://cemu.info
install = cemu.install
arch = x86_64
@@ -30,9 +30,11 @@ pkgbase = cemu
source = git+https://github.com/Exzap/ZArchive#commit=d2c717730092c7bf8cbb033b12fd4001b7c4d932
source = git+https://github.com/arsenm/sanitizers-cmake#commit=aab6948fa863bc1cbe5d0850bc46b9ef02ed4c1a
source = git+https://github.com/google/googletest#commit=800f5422ac9d9e0ad59cd860a2ef3a679588acb4
+ source = crc.diff
+ source = dialog-crash-fix.diff
+ source = mlc-discord-rich-presence.diff
source = overlay.diff
source = mic.diff
- source = crc.diff
source = gui.diff
sha256sums = SKIP
sha256sums = SKIP
@@ -40,9 +42,11 @@ pkgbase = cemu
sha256sums = SKIP
sha256sums = SKIP
sha256sums = SKIP
+ sha256sums = 095b2d2882073c29405927bb3f00153c402de962affeb68878b6a752fb37ed5a
+ sha256sums = 03bc995a63af7be8c83673272c6c6bcb08bbb8ed48c8a06af7adfdaa475be61a
+ sha256sums = fa034a95b38e0e292deedda1d8d93663163a56460579c497ee8d76902ee8de95
sha256sums = f25d13fe76cc6a0b475f0131211a951288160ddae92cd7a815f5aea61d7cfc0f
sha256sums = 46992c822e75dc60e1b07162a6a3f502aed6cea4605f29c9038c442f7cb1869f
- sha256sums = 095b2d2882073c29405927bb3f00153c402de962affeb68878b6a752fb37ed5a
- sha256sums = 6ec9545cdd05f59a5d7e956c5c0e083f734dd9e6cc681c5dc500fd43dbeab44f
+ sha256sums = 1081822dec41144e0a7ac934b284f131fcb4b87ffdcef144da0a13e8f8dda169
pkgname = cemu
diff --git a/PKGBUILD b/PKGBUILD
index 524ad456960f..f73c99dcf9bd 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=cemu
pkgver=2.0.182
-pkgrel=2
+pkgrel=3
pkgdesc='Software to emulate Wii U games and applications on PC (with cutting edge Linux patches)'
arch=(x86_64)
url=https://cemu.info
@@ -34,17 +34,18 @@ source=(
# submodules
git+https://github.com/mozilla/cubeb#commit=dc511c6b3597b6384d28949285b9289e009830ea
git+https://github.com/ocornut/imgui#commit=8a44c31c95c8e0217f6e1fc814cbbbcca4981f14
- # git+https://github.com/microsoft/vcpkg#commit=1b0252ca70ca2244a711535462c7f981eb439e83
- # git+https://github.com/KhronosGroup/Vulkan-Headers#commit=715673702f5b18ffb8e5832e67cf731468d32ac6
git+https://github.com/Exzap/ZArchive#commit=d2c717730092c7bf8cbb033b12fd4001b7c4d932
# cubeb submodules
git+https://github.com/arsenm/sanitizers-cmake#commit=aab6948fa863bc1cbe5d0850bc46b9ef02ed4c1a
git+https://github.com/google/googletest#commit=800f5422ac9d9e0ad59cd860a2ef3a679588acb4
- # patches
- overlay.diff # 6aa7a0c7b2003f625bfecd64f6143a10605234b2
- mic.diff # 5231a71527cb57ea79b1b2ab9e4d7247d9141dd1
+ # upstream merged patches
crc.diff # f0938e1a23f6cdd03bfd1e21d84f2c0f65aeb45f
- gui.diff # b3814225e4a63fad543b2a9ebf11ed6f5e21f389
+ dialog-crash-fix.diff # e88d20cbfbada6b1d144c4944f080f70299c1506
+ mlc-discord-rich-presence.diff # 271a4e4719463ece58db74b9c390f83bf6e956cf
+ # upstream proposed patches
+ overlay.diff # 6aa7a0c7b2003f625bfecd64f6143a10605234b2 (https://github.com/cemu-project/Cemu/pull/142)
+ mic.diff # 5231a71527cb57ea79b1b2ab9e4d7247d9141dd1 (https://github.com/cemu-project/Cemu/pull/251)
+ gui.diff # b3814225e4a63fad543b2a9ebf11ed6f5e21f389 (https://github.com/cemu-project/Cemu/pull/345)
)
sha256sums=('SKIP'
'SKIP'
@@ -52,9 +53,11 @@ sha256sums=('SKIP'
'SKIP'
'SKIP'
'SKIP'
+ '095b2d2882073c29405927bb3f00153c402de962affeb68878b6a752fb37ed5a'
+ '03bc995a63af7be8c83673272c6c6bcb08bbb8ed48c8a06af7adfdaa475be61a'
+ 'fa034a95b38e0e292deedda1d8d93663163a56460579c497ee8d76902ee8de95'
'f25d13fe76cc6a0b475f0131211a951288160ddae92cd7a815f5aea61d7cfc0f'
'46992c822e75dc60e1b07162a6a3f502aed6cea4605f29c9038c442f7cb1869f'
- '095b2d2882073c29405927bb3f00153c402de962affeb68878b6a752fb37ed5a'
'1081822dec41144e0a7ac934b284f131fcb4b87ffdcef144da0a13e8f8dda169')
pkgver() {
@@ -72,12 +75,12 @@ prepare() {
# cemu submodules
for submodule in dependencies/{cubeb,imgui,ZArchive}; do
git config submodule.$submodule.url "file://$srcdir/${submodule##*/}"
- git submodule update --init $submodule
+ git submodule--helper update --init $submodule
done
pushd dependencies/cubeb > /dev/null
for submodule in {cmake/sanitizers-cmake,googletest}; do
git config submodule.$submodule.url "file://$srcdir/${submodule##*/}"
- git submodule update --init $submodule
+ git submodule--helper update --init $submodule
done
popd > /dev/null
@@ -99,20 +102,17 @@ prepare() {
# gamelist column width improvement
sed -i '/InsertColumn/s/kListIconWidth/&+8/;/SetColumnWidth/s/last_col_width/&-1/' src/gui/components/wxGameList.cpp
- # experimental: linux overlay (https://github.com/cemu-project/Cemu/pull/142)
rm -rf src/util/SystemInfo
git apply "$srcdir/overlay.diff"
sed -i '/add_library/aSystemInfo/SystemInfo.cpp SystemInfo/SystemInfoLinux.cpp' src/util/CMakeLists.txt
- # experimental: microphone (https://github.com/cemu-project/Cemu/pull/251)
rm -f src/audio/{Cubeb,IAudio}InputAPI.{cpp,h}
git apply "$srcdir/mic.diff"
- # Fix CRC errors (graphics packs) (https://github.com/cemu-project/Cemu/pull/375)
git apply "$srcdir/crc.diff"
-
- # experimental: input ui (https://github.com/cemu-project/Cemu/pull/345)
git apply "$srcdir/gui.diff"
+ git apply "$srcdir/dialog-crash-fix.diff"
+ git apply "$srcdir/mlc-discord-rich-presence.diff"
}
build() {
diff --git a/dialog-crash-fix.diff b/dialog-crash-fix.diff
new file mode 100644
index 000000000000..5d8cea6a4d98
--- /dev/null
+++ b/dialog-crash-fix.diff
@@ -0,0 +1,26 @@
+--- a/src/gui/MainWindow.cpp
++++ b/src/gui/MainWindow.cpp
+@@ -763,7 +763,6 @@ void MainWindow::OpenSettings()
+ frame.ShowModal();
+ const bool paths_modified = frame.ShouldReloadGamelist();
+ const bool mlc_modified = frame.MLCModified();
+- frame.Destroy();
+
+ if (paths_modified)
+ m_game_list->ReloadGameEntries(false);
+@@ -1722,7 +1721,6 @@ void MainWindow::OnTimer(wxTimerEvent& event)
+ {
+ CemuUpdateWindow update_window(this);
+ update_window.ShowModal();
+- update_window.Destroy();
+ }
+ }
+
+@@ -1999,7 +1997,6 @@ void MainWindow::OnHelpUpdate(wxCommandEvent& event)
+ {
+ CemuUpdateWindow test(this);
+ test.ShowModal();
+- test.Destroy();
+ }
+
+ void MainWindow::OnHelpGettingStarted(wxCommandEvent& event)
diff --git a/mlc-discord-rich-presence.diff b/mlc-discord-rich-presence.diff
new file mode 100644
index 000000000000..f9951ab886e1
--- /dev/null
+++ b/mlc-discord-rich-presence.diff
@@ -0,0 +1,116 @@
+--- a/src/Cafe/CafeSystem.cpp
++++ b/src/Cafe/CafeSystem.cpp
+@@ -704,9 +704,8 @@ namespace CafeSystem
+ std::string GetForegroundTitleName()
+ {
+ if (sLaunchModeIsStandalone)
+- return "Missing meta data";
+- // todo - use language based on Cemu console language
+- return sGameInfo_ForegroundTitle.GetBase().GetMetaInfo()->GetShortName(CafeConsoleLanguage::EN);
++ return "Unknown Game";
++ return sGameInfo_ForegroundTitle.GetBase().GetMetaInfo()->GetShortName(GetConfig().console_language);
+ }
+
+ std::string GetForegroundTitleArgStr()
+--- a/src/gui/MainWindow.cpp
++++ b/src/gui/MainWindow.cpp
+@@ -543,8 +543,7 @@ bool MainWindow::FileLoad(std::wstring fileName, wxLaunchGameEvent::INITIATED_BY
+ m_game_list = nullptr;
+ }
+
+- const auto game_name = GetGameName(fileName);
+- m_launched_game_name = boost::nowide::narrow(game_name);
++ m_launched_game_name = CafeSystem::GetForegroundTitleName();
+ #ifdef ENABLE_DISCORD_RPC
+ if (m_discord)
+ m_discord->UpdatePresence(DiscordPresence::Playing, m_launched_game_name);
+@@ -1496,79 +1495,6 @@ void MainWindow::DestroyCanvas()
+ }
+ }
+
+-
+-std::wstring MainWindow::GetGameName(std::wstring_view file_name)
+-{
+- fs::path path{ std::wstring{file_name} };
+- const auto extension = path.extension();
+- if (extension == ".wud" || extension == ".wux")
+- {
+- std::unique_ptr<FSTVolume> volume(FSTVolume::OpenFromDiscImage(path));
+- if (!volume)
+- return path.filename().generic_wstring();
+-
+- bool foundFile = false;
+- std::vector<uint8> metaContent = volume->ExtractFile("meta/meta.xml", &foundFile);
+- if (!foundFile)
+- return path.filename().generic_wstring();
+-
+- namespace xml = tinyxml2;
+- xml::XMLDocument doc;
+- doc.Parse((const char*)metaContent.data(), metaContent.size());
+-
+- // parse meta.xml
+- xml::XMLElement* root = doc.FirstChildElement("menu");
+- if (root)
+- {
+- xml::XMLElement* element = root->FirstChildElement("longname_en");
+- if (element)
+- {
+-
+- auto game_name = boost::nowide::widen(element->GetText());
+- const auto it = game_name.find(L'\n');
+- if (it != std::wstring::npos)
+- game_name.replace(it, 1, L" - ");
+-
+- return game_name;
+- }
+- }
+- return path.filename().generic_wstring();
+- }
+- else if (extension == ".rpx")
+- {
+- if (path.has_parent_path() && path.parent_path().has_parent_path())
+- {
+- auto meta_xml = path.parent_path().parent_path() / "meta/meta.xml";
+- auto metaXmlData = FileStream::LoadIntoMemory(meta_xml);
+- if (metaXmlData)
+- {
+- namespace xml = tinyxml2;
+- xml::XMLDocument doc;
+- if (doc.Parse((const char*)metaXmlData->data(), metaXmlData->size()) == xml::XML_SUCCESS)
+- {
+- xml::XMLElement* root = doc.FirstChildElement("menu");
+- if (root)
+- {
+- xml::XMLElement* element = root->FirstChildElement("longname_en");
+- if (element)
+- {
+-
+- auto game_name = boost::nowide::widen(element->GetText());
+- const auto it = game_name.find(L'\n');
+- if (it != std::wstring::npos)
+- game_name.replace(it, 1, L" - ");
+-
+- return game_name;
+- }
+- }
+- }
+- }
+- }
+- }
+-
+- return path.filename().generic_wstring();
+-}
+-
+ void MainWindow::OnSizeEvent(wxSizeEvent& event)
+ {
+ if (!IsMaximized() && !gui_isFullScreen())
+--- a/src/gui/MainWindow.h
++++ b/src/gui/MainWindow.h
+@@ -130,7 +130,6 @@ class MainWindow : public wxFrame
+ void CreateCanvas();
+ void DestroyCanvas();
+
+- std::wstring GetGameName(std::wstring_view file_name);
+ static void ShowCursor(bool state);
+
+ uintptr_t GetRenderCanvasHWND();