2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchurl, openssl }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "mysocketw-031026";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.digitalfanatics.org/cal/socketw/files/SocketW031026.tar.gz";
|
|
|
|
sha256 = "0crinikhdl7xihzmc3k3k41pgxy16d5ci8m9sza1lbibns7pdwj4";
|
|
|
|
};
|
|
|
|
|
|
|
|
patches = [ ./gcc.patch ];
|
|
|
|
|
|
|
|
buildInputs = [ openssl ];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
postPatch = lib.optionalString stdenv.isDarwin ''
|
2020-04-24 23:36:52 +00:00
|
|
|
substituteInPlace src/Makefile \
|
|
|
|
--replace -Wl,-soname, -Wl,-install_name,$out/lib/
|
|
|
|
'';
|
|
|
|
|
2021-02-19 19:06:45 +00:00
|
|
|
makeFlags = [ "PREFIX=$(out)" "CXX=${stdenv.cc.targetPrefix}c++" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Cross platform (Linux/FreeBSD/Unix/Win32) streaming socket C++";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = lib.licenses.lgpl21Plus;
|
|
|
|
platforms = lib.platforms.all;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|