limo: init at 1.0.8.2

+124
+82
pkgs/by-name/li/limo/package.nix
···
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchFromGitHub, 5 + 6 + cmake, 7 + pkg-config, 8 + 9 + jsoncpp, 10 + libarchive, 11 + libcpr, 12 + libloot, 13 + pugixml, 14 + 15 + libsForQt5, 16 + 17 + withUnrar ? true, 18 + unrar, # has an unfree license 19 + }: 20 + 21 + stdenv.mkDerivation (finalAttrs: { 22 + pname = "limo"; 23 + version = "1.0.8.2"; 24 + 25 + src = fetchFromGitHub { 26 + owner = "limo-app"; 27 + repo = "limo"; 28 + rev = "refs/tags/v${finalAttrs.version}"; 29 + hash = "sha256-6rv1IjWb/nrymd57CtrlAjX2KfMYlYNnfiodiRAJ1Ok="; 30 + }; 31 + 32 + patches = lib.optionals (!withUnrar) [ 33 + # remove `unrar` as fallback when libarchive fails 34 + ./remove-unrar.patch 35 + ]; 36 + 37 + strictDeps = true; 38 + 39 + nativeBuildInputs = [ 40 + cmake 41 + pkg-config 42 + libsForQt5.wrapQtAppsHook 43 + ]; 44 + 45 + buildInputs = 46 + [ 47 + jsoncpp 48 + libarchive 49 + libcpr 50 + libloot 51 + pugixml 52 + 53 + libsForQt5.qtbase 54 + libsForQt5.qtsvg 55 + libsForQt5.qtwayland 56 + ] 57 + ++ lib.optionals withUnrar [ 58 + unrar 59 + ]; 60 + 61 + cmakeFlags = 62 + [ 63 + (lib.cmakeFeature "LIMO_INSTALL_PREFIX" (placeholder "out")) 64 + (lib.cmakeBool "USE_SYSTEM_LIBUNRAR" true) 65 + ] 66 + ++ lib.optionals (!withUnrar) [ 67 + (lib.cmakeFeature "LIBUNRAR_PATH" "") 68 + (lib.cmakeFeature "LIBUNRAR_INCLUDE_DIR" "") 69 + ]; 70 + 71 + meta = { 72 + description = "General purpose mod manager with support for the NexusMods API and LOOT"; 73 + homepage = "https://github.com/limo-app/limo"; 74 + license = lib.licenses.gpl3Plus; 75 + mainProgram = "Limo"; 76 + maintainers = with lib.maintainers; [ 77 + tomasajt 78 + MattSturgeon 79 + ]; 80 + platforms = lib.platforms.linux; 81 + }; 82 + })
+42
pkgs/by-name/li/limo/remove-unrar.patch
···
··· 1 + diff --git a/src/core/installer.cpp b/src/core/installer.cpp 2 + index ea384a8..aab8be0 100644 3 + --- a/src/core/installer.cpp 4 + +++ b/src/core/installer.cpp 5 + @@ -7,7 +7,6 @@ 6 + #include <ranges> 7 + #include <regex> 8 + #define _UNIX 9 + -#include <dll.hpp> 10 + 11 + namespace sfs = std::filesystem; 12 + namespace pu = path_utils; 13 + @@ -35,6 +34,8 @@ void Installer::extract(const sfs::path& source_path, 14 + } 15 + catch(CompressionError& error) 16 + { 17 + + throw error; 18 + + /* 19 + std::string extension = source_path.extension().string(); 20 + std::transform(extension.begin(), 21 + extension.end(), 22 + @@ -48,6 +49,7 @@ void Installer::extract(const sfs::path& source_path, 23 + } 24 + else 25 + throw error; 26 + + */ 27 + } 28 + for(const auto& dir_entry : sfs::recursive_directory_iterator(dest_path)) 29 + { 30 + @@ -428,6 +430,7 @@ void Installer::extractWithProgress(const sfs::path& source_path, 31 + sfs::current_path(working_dir); 32 + } 33 + 34 + +/* 35 + void Installer::extractRarArchive(const sfs::path& source_path, const sfs::path& dest_path) 36 + { 37 + log(Log::LOG_DEBUG, "Using fallback rar extraction"); 38 + @@ -459,3 +462,4 @@ void Installer::extractRarArchive(const sfs::path& source_path, const sfs::path& 39 + throw CompressionError("Failed to extract RAR archive."); 40 + RARCloseArchive(hArcData); 41 + } 42 + +*/