Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sgdboop: init at 1.2.8 #341468

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 63 additions & 0 deletions pkgs/by-name/ca/canvasdraw/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
lib,
stdenv,
fetchurl,

lsb-release,
which,
pkg-config,
gtk3,
fontconfig,
ftgl,
libGLU,
}:

stdenv.mkDerivation rec {
pname = "canvasdraw";
version = "5.14";

src = fetchurl {
url = "mirror://sourceforge/canvasdraw/${version}/Docs%20and%20Sources/cd-${version}_Sources.tar.gz";
hash = "sha256-xE7cBBExyaakKTPIeaZE1r2CjWCyikuFWpzeYV/Fr08=";
};

nativeBuildInputs = [
lsb-release
which
pkg-config
];

buildInputs = [
gtk3
fontconfig
ftgl
libGLU
];

sourceRoot = "cd/src";

makeFlags = [
"USE_PKGCONFIG=Yes"
"USE_GTK3=Yes"
"cd"
"cdgl"
"cdcontextplus"
Comment on lines +42 to +44
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about other targets:

do_all:        cd cdpdf cdgl cdim cdcontextplus cdlua5 cdluapdf5 cdluagl5 cdluacontextplus5 cdluaim5

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about other targets:

do_all:        cd cdpdf cdgl cdim cdcontextplus cdlua5 cdluapdf5 cdluagl5 cdluacontextplus5 cdluaim5

I figure that they weren't added originally because they weren't needed but I am not sure. Should I add those other targets?

];

installPhase = ''
runHook preInstall
install -m755 -d "$out/lib"
install -m644 ../lib/*/lib*.so "$out/lib"
install -m755 -d "$out/include"
install -m644 ../include/* "$out/include"
runHook postInstall
'';

meta = {
description = "C platform-independent graphics library, aka canvasdraw";
homepage = "http://www.tecgraf.puc-rio.br/cd/";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ saturn745 ];
platforms = lib.platforms.linux;
};
}
59 changes: 59 additions & 0 deletions pkgs/by-name/im/imtoolkit/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
{
lib,
stdenv,
fetchurl,

lsb-release,
which,
pkg-config,
gtk3,
fontconfig,
ftgl,
libGLU,
fftw,
fftwFloat,
lua,
}:

stdenv.mkDerivation rec {
pname = "imtoolkit";
version = "3.15";

src = fetchurl {
url = "mirror://sourceforge/imtoolkit/${version}/Docs%20and%20Sources/im-${version}_Sources.tar.gz";
hash = "sha256-NsxCV/j1+BEouFS7O+KcXL3QkUdlKPMVr2ZtCTC5tX4=";
};

nativeBuildInputs = [
lsb-release
which
pkg-config
];

buildInputs = [
gtk3
fontconfig
ftgl
libGLU
fftw
fftwFloat
lua
];

sourceRoot = "im/src";

installPhase = ''
install -m755 -d "$out/lib"
install -m644 ../lib/*/lib*.so "$out/lib"
install -m755 -d "$out/include"
install -m644 ../include/* "$out/include"
'';

meta = {
description = "Toolkit for Digital Imaging";
homepage = "http://www.tecgraf.puc-rio.br/im/";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ saturn745 ];
platforms = lib.platforms.linux;
};
}
77 changes: 77 additions & 0 deletions pkgs/by-name/iu/iup/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
{
lib,
stdenv,
fetchurl,

lsb-release,
which,
pkg-config,
gtk3,
canvasdraw,
libGLU,
ftgl,
imtoolkit,
}:

stdenv.mkDerivation rec {
pname = "iup";
version = "3.31";

src = fetchurl {
url = "mirror://sourceforge/iup/${version}/Docs%20and%20Sources/${pname}-${version}_Sources.tar.gz";
hash = "sha256-rYL2KweC5G/31KsWdl3yHLF+Z6xrjnLFDMhVH/VKFHQ=";
};

nativeBuildInputs = [
lsb-release
which
pkg-config
];

buildInputs = [
gtk3
canvasdraw
libGLU
ftgl
imtoolkit
];

makeFlags = [
"USE_PKGCONFIG=Yes"
"USE_GTK3=Yes"
"USE_STATIC="
"LINK_CAIRO=Yes"

"iup"
"iupgtk"
"iupcd"
"iupcontrols"
"iupgl"
"iup_plot"
"iup_mglplot"
"iupglcontrols"
"iupim"
"iupole"
"iup_scintilla"
"iupim"
"iuptuio"
"iupimglib"
"ledc"
"iupview"
];

installPhase = ''
install -m755 -d "$out/lib"
install -m644 lib/*/lib*.so "$out/lib"
install -m755 -d "$out/include"
install -m644 include/* "$out/include"
'';

meta = {
description = "C cross platform GUI toolkit";
homepage = "https://www.tecgraf.puc-rio.br/iup/";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ saturn745 ];
platforms = lib.platforms.linux;
};
}
52 changes: 52 additions & 0 deletions pkgs/by-name/sg/sgdboop/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
lib,
stdenv,
fetchFromGitHub,
curl,
iup,
}:

stdenv.mkDerivation rec {
pname = "sgdboop";
version = "1.2.8";

src = fetchFromGitHub {
owner = "SteamGridDB";
repo = "SGDBoop";
rev = "v${version}";
hash = "sha256-bdSzTwObMEBe1pHTDwXeJ3GXmOwwFp4my7qTmifX218=";
};

makeFlags = [
# Makefile copies a bundled libiup.so, so put it somewhere it won't be found
"USER_LIB_PATH=ignored"

# The Flakepak install just copies things to /app - otherwise wants to do things with XDG
"FLATPAK_ID=fake"
];

postPatch = ''
substituteInPlace "linux-release/com.steamgriddb.SGDBoop.desktop" \
--replace "Exec=" "Exec=$out/bin/"
substituteInPlace Makefile \
--replace "/app/" "$out/"
'';

postInstall = ''
rm -r "$out/share/metainfo"
'';

buildInputs = [
curl
iup
];

meta = {
description = "A program used for applying custom artwork to Steam, using SteamGridDB";
homepage = "https://github.com/SteamGridDB/SGDBoop/";
license = lib.licenses.zlib;
maintainers = with lib.maintainers; [ saturn745 ];
mainProgram = "SGDBoop";
platforms = lib.platforms.linux;
};
}