From owner-dev-commits-ports-all@freebsd.org Tue Jun 1 15:06:27 2021 Return-Path: Delivered-To: dev-commits-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3978A656012; Tue, 1 Jun 2021 15:06:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Fvb8g19Qlz3PpW; Tue, 1 Jun 2021 15:06:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 1026A2595D; Tue, 1 Jun 2021 15:06:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 151F6Q6x018274; Tue, 1 Jun 2021 15:06:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 151F6QGX018273; Tue, 1 Jun 2021 15:06:26 GMT (envelope-from git) Date: Tue, 1 Jun 2021 15:06:26 GMT Message-Id: <202106011506.151F6QGX018273@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: "Vanilla I. Shu" Subject: git: 8e1e5df81a6d - main - net/gamenetworkingsockets: add new ports. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: vanilla X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8e1e5df81a6deb4424f0e3f4f33bdc196dfd26ea Auto-Submitted: auto-generated X-BeenThere: dev-commits-ports-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the ports repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Jun 2021 15:06:27 -0000 The branch main has been updated by vanilla: URL: https://cgit.FreeBSD.org/ports/commit/?id=8e1e5df81a6deb4424f0e3f4f33bdc196dfd26ea commit 8e1e5df81a6deb4424f0e3f4f33bdc196dfd26ea Author: Vanilla I. Shu AuthorDate: 2021-06-01 15:03:55 +0000 Commit: Vanilla I. Shu CommitDate: 2021-06-01 15:03:55 +0000 net/gamenetworkingsockets: add new ports. GameNetworkingSockets is Valve's semi-recently open-sourced networking library. It supports a number of very useful features, including: - Reliable & unreliable messages over UDP. - Robust message fragmentation & reassembly. - P2P networking / NAT traversal. Encryption. PR: 256295 Reported by: Karsten Pedersen --- net/Makefile | 1 + net/gamenetworkingsockets/Makefile | 24 +++++++++++++++++++ net/gamenetworkingsockets/distinfo | 3 +++ .../files/patch-include_steam_steamclientpublic.h | 11 +++++++++ .../files/patch-src_CMakeLists.txt | 10 ++++++++ net/gamenetworkingsockets/pkg-descr | 27 ++++++++++++++++++++++ net/gamenetworkingsockets/pkg-plist | 19 +++++++++++++++ 7 files changed, 95 insertions(+) diff --git a/net/Makefile b/net/Makefile index d2962af2565d..9dba94a11213 100644 --- a/net/Makefile +++ b/net/Makefile @@ -171,6 +171,7 @@ SUBDIR += fspclient SUBDIR += fspd SUBDIR += fsplib + SUBDIR += gamenetworkingsockets SUBDIR += gdrive SUBDIR += gemserv SUBDIR += geoclue diff --git a/net/gamenetworkingsockets/Makefile b/net/gamenetworkingsockets/Makefile new file mode 100644 index 000000000000..f8ff540c510a --- /dev/null +++ b/net/gamenetworkingsockets/Makefile @@ -0,0 +1,24 @@ +# Created by: Karsten Pedersen + +PORTNAME= gamenetworkingsockets +PORTVERSION= 1.3.0 +DISTVERSIONPREFIX= v +CATEGORIES= net + +MAINTAINER= kpedersen@disroot.org +COMMENT= GameNetworkingSockets is a basic transport layer for games + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libprotobuf.so:devel/protobuf + +USES= cmake +USE_GITHUB= yes +GH_ACCOUNT= ValveSoftware +GH_PROJECT= GameNetworkingSockets + +CMAKE_ARGS= -DGAMENETWORKINGSOCKETS_BUILD_EXAMPLES=OFF \ + -DGAMENETWORKINGSOCKETS_BUILD_TESTS=OFF + +.include diff --git a/net/gamenetworkingsockets/distinfo b/net/gamenetworkingsockets/distinfo new file mode 100644 index 000000000000..6fdfd390e9fb --- /dev/null +++ b/net/gamenetworkingsockets/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1622554893 +SHA256 (ValveSoftware-GameNetworkingSockets-v1.3.0_GH0.tar.gz) = f473789ae8a8415dd1f5473793775e68a919d27eba18b9ba7d0a14f254afddf9 +SIZE (ValveSoftware-GameNetworkingSockets-v1.3.0_GH0.tar.gz) = 10921035 diff --git a/net/gamenetworkingsockets/files/patch-include_steam_steamclientpublic.h b/net/gamenetworkingsockets/files/patch-include_steam_steamclientpublic.h new file mode 100644 index 000000000000..2034a2143f25 --- /dev/null +++ b/net/gamenetworkingsockets/files/patch-include_steam_steamclientpublic.h @@ -0,0 +1,11 @@ +--- include/steam/steamclientpublic.h.orig 2021-05-31 13:43:13 UTC ++++ include/steam/steamclientpublic.h +@@ -1257,7 +1257,7 @@ typedef void *BREAKPAD_HANDLE; + #define VALVE_CALLBACK_PACK_LARGE + #else + +- #if defined(__linux__) || defined(__APPLE__) ++ #if defined(__linux__) || defined(__APPLE__) || defined(__FreeBSD__) + // The 32-bit version of gcc has the alignment requirement for uint64 and double set to + // 4 meaning that even with #pragma pack(8) these types will only be four-byte aligned. + // The 64-bit version of gcc has the alignment requirement for these types set to diff --git a/net/gamenetworkingsockets/files/patch-src_CMakeLists.txt b/net/gamenetworkingsockets/files/patch-src_CMakeLists.txt new file mode 100644 index 000000000000..eedb44326f3d --- /dev/null +++ b/net/gamenetworkingsockets/files/patch-src_CMakeLists.txt @@ -0,0 +1,10 @@ +--- src/CMakeLists.txt.orig 2021-05-29 00:43:16 UTC ++++ src/CMakeLists.txt +@@ -285,6 +285,7 @@ endmacro() + add_library(GameNetworkingSockets SHARED "") + add_library(GameNetworkingSockets::GameNetworkingSockets ALIAS GameNetworkingSockets) + add_library(GameNetworkingSockets::shared ALIAS GameNetworkingSockets) ++set_target_properties(GameNetworkingSockets PROPERTIES VERSION 1 SOVERSION 1.3.0) + gamenetworkingsockets_common(GameNetworkingSockets) + + add_library(GameNetworkingSockets_s STATIC "") diff --git a/net/gamenetworkingsockets/pkg-descr b/net/gamenetworkingsockets/pkg-descr new file mode 100644 index 000000000000..9c0487cd113e --- /dev/null +++ b/net/gamenetworkingsockets/pkg-descr @@ -0,0 +1,27 @@ +GameNetworkingSockets is a basic transport layer for games. The features are: + +- Connection-oriented API (like TCP) + +- ... but message-oriented (like UDP), not stream-oriented. + +- Supports both reliable and unreliable message types + +- Messages can be larger than underlying MTU. The protocol performs + fragmentation, reassembly, and retransmission for reliable messages. + +- A reliability layer significantly more sophisticated than a basic + TCP-style sliding window. It is based on the "ack vector" model + from DCCP (RFC 4340, section 11.4) and Google QUIC and discussed + in the context of games by Glenn Fiedler. The basic idea is for the + receiver to efficiently communicate to the sender the status of + every packet number (whether or not a packet was received with that + number). By remembering which segments were sent in each packet, + the sender can deduce which segments need to be retransmitted. + +- Encryption. AES-GCM-256 per packet, Curve25519 for key exchange + and cert signatures. The details for shared key derivation and + per-packet IV are based on the design used by Google's QUIC + protocol. Tools for simulating packet latency/loss, and detailed + stats measurement IPv6 support Peer-to-peer networking: + +WWW: https://github.com/ValveSoftware/GameNetworkingSockets diff --git a/net/gamenetworkingsockets/pkg-plist b/net/gamenetworkingsockets/pkg-plist new file mode 100644 index 000000000000..d108d3899b4b --- /dev/null +++ b/net/gamenetworkingsockets/pkg-plist @@ -0,0 +1,19 @@ +include/GameNetworkingSockets/steam/isteamnetworkingmessages.h +include/GameNetworkingSockets/steam/isteamnetworkingsockets.h +include/GameNetworkingSockets/steam/isteamnetworkingutils.h +include/GameNetworkingSockets/steam/steam_api_common.h +include/GameNetworkingSockets/steam/steamclientpublic.h +include/GameNetworkingSockets/steam/steamclientpublic.h.orig +include/GameNetworkingSockets/steam/steamnetworkingcustomsignaling.h +include/GameNetworkingSockets/steam/steamnetworkingsockets.h +include/GameNetworkingSockets/steam/steamnetworkingsockets_flat.h +include/GameNetworkingSockets/steam/steamnetworkingtypes.h +include/GameNetworkingSockets/steam/steamtypes.h +include/GameNetworkingSockets/steam/steamuniverse.h +lib/cmake/GameNetworkingSockets/GameNetworkingSockets-%%CMAKE_BUILD_TYPE%%.cmake +lib/cmake/GameNetworkingSockets/GameNetworkingSockets.cmake +lib/cmake/GameNetworkingSockets/GameNetworkingSocketsConfig.cmake +lib/libGameNetworkingSockets.so +lib/libGameNetworkingSockets.so.1 +lib/libGameNetworkingSockets.so.1.3.0 +lib/libGameNetworkingSockets_s.a