2021-09-18 10:52:07 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, autoreconfHook
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "ip2location-c";
|
2023-07-15 17:15:38 +00:00
|
|
|
version = "8.6.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "chrislim2888";
|
|
|
|
repo = "IP2Location-C-Library";
|
|
|
|
rev = version;
|
2023-07-15 17:15:38 +00:00
|
|
|
sha256 = "sha256-3/cLoGV7go4S1ew73IJzJEMTlLnvM3adl+/Sb7mPrZY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
# Checks require a database, which require registration (although sample
|
|
|
|
# databases are available, downloading them for just 1 test seems excessive):
|
|
|
|
doCheck = false;
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Library to look up locations of host names and IP addresses";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "ip2location";
|
2020-04-24 23:36:52 +00:00
|
|
|
longDescription = ''
|
|
|
|
A C library to find the country, region, city,coordinates,
|
|
|
|
zip code, time zone, ISP, domain name, connection type, area code,
|
|
|
|
weather, MCC, MNC, mobile brand name, elevation and usage type of
|
|
|
|
any IP address or host name in the IP2Location databases.
|
|
|
|
'';
|
2021-09-18 10:52:07 +00:00
|
|
|
homepage = "https://www.ip2location.com/developers/c";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = with licenses; [ gpl3Plus lgpl3Plus ];
|
2024-07-31 10:19:44 +00:00
|
|
|
maintainers = [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|