nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

commit e75423d795b7940c6f40c153dc716eaa86ea0a8d
parent d126c583e962f93017945eddeee292fbf705bbc7
Author: Nikolay Korotkiy <sikmir@disroot.org>
Date:   Tue, 29 Mar 2022 17:54:26 +0300

Fix sdlmap

Diffstat:
Apkgs/osm/sdlmap/Makefile.patch | 14++++++++++++++
Mpkgs/osm/sdlmap/default.nix | 6++++--
2 files changed, 18 insertions(+), 2 deletions(-)

diff --git a/pkgs/osm/sdlmap/Makefile.patch b/pkgs/osm/sdlmap/Makefile.patch @@ -0,0 +1,14 @@ +diff --git i/Makefile w/Makefile +index 569a347..a7f4032 100644 +--- i/Makefile ++++ w/Makefile +@@ -1,6 +1,6 @@ +-SDL_CONFIG=sdl2-config +-CXXFLAGS=`$(SDL_CONFIG) --cflags` -g +-LIBS=`$(SDL_CONFIG) --libs` -lcurl -lSDL2_image ++PKG_CONFIG=pkg-config ++CXXFLAGS=`$(PKG_CONFIG) --cflags SDL2` `$(PKG_CONFIG) --cflags SDL2_image` -g ++LIBS=`$(PKG_CONFIG) --libs SDL2` `$(PKG_CONFIG) --libs SDL2_image` -lcurl + TARGET=sdlmap + + sdlmap: sdlmap.o tile_downloader.o tile_collection.o map_view.o tile.o diff --git a/pkgs/osm/sdlmap/default.nix b/pkgs/osm/sdlmap/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, curl, SDL2, SDL2_image }: +{ lib, stdenv, fetchFromGitHub, pkg-config, curl, SDL2, SDL2_image }: stdenv.mkDerivation rec { pname = "sdlmap"; @@ -11,7 +11,9 @@ stdenv.mkDerivation rec { hash = "sha256-W09WzCKmuMjV1L2c1bvlBCmNvXxYgGNU/MLtu6TTsIg="; }; - patches = [ ./tile.patch ]; + patches = [ ./tile.patch ./Makefile.patch ]; + + nativeBuildInputs = [ pkg-config ]; buildInputs = [ curl SDL2 SDL2_image ];