public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: ElXreno <elxreno@gmail.com>
To: git-commits@fedoraproject.org
Subject: [rpms/ddnet] exclude-empty-files: Initial import (#1787069).
Date: Thu, 03 Sep 2026 00:09:42 GMT	[thread overview]
Message-ID: <178839418297.1.14964480156733209081.rpms-ddnet-08ccf2499fdf@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/ddnet
Branch : exclude-empty-files
Commit : 08ccf2499fdfd2f87e34eb18da63af6e3fa12a23
Author : ElXreno <elxreno@gmail.com>
Date   : 2020-02-15T10:38:21+03:00
Stats  : +462/-0 in 6 file(s)
URL    : https://src.fedoraproject.org/rpms/ddnet/c/08ccf2499fdfd2f87e34eb18da63af6e3fa12a23?branch=exclude-empty-files

Log:
Initial import (#1787069).

---
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..ffaad99
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+/ddnet-12.9.1.tar.gz

diff --git a/0001-disabled-network-lookup-test.patch b/0001-disabled-network-lookup-test.patch
new file mode 100644
index 0000000..907a2b6
--- /dev/null
+++ b/0001-disabled-network-lookup-test.patch
@@ -0,0 +1,44 @@
+From 60296da7106bfe65f7c19e4e4dfbf2e13c504914 Mon Sep 17 00:00:00 2001
+From: ElXreno <elxreno@gmail.com>
+Date: Fri, 6 Dec 2019 23:23:50 +0300
+Subject: [PATCH] Disabled network lookup test
+
+---
+ src/test/jobs.cpp | 22 ----------------------
+ 1 file changed, 22 deletions(-)
+
+diff --git a/src/test/jobs.cpp b/src/test/jobs.cpp
+index dd74fdd9b..643449b51 100644
+--- a/src/test/jobs.cpp
++++ b/src/test/jobs.cpp
+@@ -51,28 +51,6 @@ TEST_F(Jobs, Wait)
+ 	sphore_destroy(&sphore);
+ }
+ 
+-TEST_F(Jobs, LookupHost)
+-{
+-	static const char *HOST = "example.com";
+-	static const int NETTYPE = NETTYPE_ALL;
+-	auto pJob = std::make_shared<CHostLookup>(HOST, NETTYPE);
+-
+-	EXPECT_STREQ(pJob->m_aHostname, HOST);
+-	EXPECT_EQ(pJob->m_Nettype, NETTYPE);
+-
+-	Add(pJob);
+-	while(pJob->Status() != IJob::STATE_DONE)
+-	{
+-		// yay, busy loop...
+-		thread_yield();
+-	}
+-
+-	EXPECT_STREQ(pJob->m_aHostname, HOST);
+-	EXPECT_EQ(pJob->m_Nettype, NETTYPE);
+-	ASSERT_EQ(pJob->m_Result, 0);
+-	EXPECT_EQ(pJob->m_Addr.type & NETTYPE, pJob->m_Addr.type);
+-}
+-
+ TEST_F(Jobs, Many)
+ {
+ 	std::atomic<int> ThreadsRunning(0);
+-- 
+2.24.0

diff --git a/0002-unbundled-md5.patch b/0002-unbundled-md5.patch
new file mode 100644
index 0000000..7145448
--- /dev/null
+++ b/0002-unbundled-md5.patch
@@ -0,0 +1,42 @@
+From cc0059062e9a5ce6b4a15a2383f17472e24533ac Mon Sep 17 00:00:00 2001
+From: ElXreno <elxreno@gmail.com>
+Date: Wed, 1 Jan 2020 20:00:52 +0300
+Subject: [PATCH 1/2] Unbundled md5
+
+---
+ CMakeLists.txt | 11 ++---------
+ 1 file changed, 2 insertions(+), 9 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 024b5de9a..b498af737 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -536,15 +536,8 @@ endif()
+ set_src(DEP_JSON_SRC GLOB src/engine/external/json-parser json.c json.h)
+ add_library(json EXCLUDE_FROM_ALL OBJECT ${DEP_JSON_SRC})
+ 
+-set_src(DEP_MD5_SRC GLOB src/engine/external/md5 md5.c md5.h)
+-add_library(md5 EXCLUDE_FROM_ALL OBJECT ${DEP_MD5_SRC})
+-
+-list(APPEND TARGETS_DEP json md5)
++list(APPEND TARGETS_DEP json)
+ set(DEP_JSON $<TARGET_OBJECTS:json>)
+-set(DEP_MD5)
+-if(NOT CRYPTO_FOUND)
+-  set(DEP_MD5 $<TARGET_OBJECTS:md5>)
+-endif()
+ 
+ ########################################################################
+ # COPY DATA AND DLLS
+@@ -776,7 +769,7 @@ set(GAME_GENERATED_SHARED
+   src/game/generated/protocol.h
+ )
+ 
+-set(DEPS ${DEP_JSON} ${DEP_MD5} ${ZLIB_DEP})
++set(DEPS ${DEP_JSON} ${ZLIB_DEP})
+ 
+ # Libraries
+ set(LIBS
+-- 
+2.24.1
+

diff --git a/0003-unbundled-json-parser.patch b/0003-unbundled-json-parser.patch
new file mode 100644
index 0000000..69dd7b6
--- /dev/null
+++ b/0003-unbundled-json-parser.patch
@@ -0,0 +1,133 @@
+From d9f81735bbc2e87a2bc2dfec4b423f2c2f491fab Mon Sep 17 00:00:00 2001
+From: ElXreno <elxreno@gmail.com>
+Date: Thu, 2 Jan 2020 12:06:05 +0300
+Subject: [PATCH 2/2] Unbundled json-parser
+
+---
+ CMakeLists.txt                      | 15 ++++-----------
+ src/engine/client/http.cpp          |  2 +-
+ src/engine/client/serverbrowser.cpp |  2 +-
+ src/engine/client/serverbrowser.h   |  2 +-
+ src/engine/client/updater.cpp       |  2 +-
+ src/engine/shared/json.h            |  2 +-
+ 6 files changed, 9 insertions(+), 16 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index b498af737..3ae69d448 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -312,6 +312,7 @@ if(DOWNLOAD_GTEST)
+ endif()
+ find_package(GLEW)
+ find_package(GTest)
++pkg_check_modules(JSONPARSER REQUIRED json-parser)
+ if(MYSQL)
+   find_package(MySQL)
+ else()
+@@ -382,6 +383,7 @@ if(DOWNLOAD_GTEST)
+ endif()
+ show_dependency_status("Glew" GLEW)
+ show_dependency_status("GTest" GTEST)
++show_dependency_status("json-parser" JSONPARSER)
+ if(TARGET_OS AND TARGET_OS STREQUAL "mac")
+   show_dependency_status("Hdiutil" HDIUTIL)
+ endif()
+@@ -529,16 +531,6 @@ if(NOT(GTEST_FOUND) AND DOWNLOAD_GTEST)
+   endif()
+ endif()
+ 
+-########################################################################
+-# DEPENDENCY COMPILATION
+-########################################################################
+-
+-set_src(DEP_JSON_SRC GLOB src/engine/external/json-parser json.c json.h)
+-add_library(json EXCLUDE_FROM_ALL OBJECT ${DEP_JSON_SRC})
+-
+-list(APPEND TARGETS_DEP json)
+-set(DEP_JSON $<TARGET_OBJECTS:json>)
+-
+ ########################################################################
+ # COPY DATA AND DLLS
+ ########################################################################
+@@ -769,11 +761,12 @@ set(GAME_GENERATED_SHARED
+   src/game/generated/protocol.h
+ )
+ 
+-set(DEPS ${DEP_JSON} ${ZLIB_DEP})
++set(DEPS ${ZLIB_DEP})
+ 
+ # Libraries
+ set(LIBS
+   ${CRYPTO_LIBRARIES}
++  ${JSONPARSER_LIBRARIES}
+   ${WEBSOCKETS_LIBRARIES}
+   ${ZLIB_LIBRARIES}
+   ${PLATFORM_LIBS}
+diff --git a/src/engine/client/http.cpp b/src/engine/client/http.cpp
+index a1ed50311..a73d4ed3c 100644
+--- a/src/engine/client/http.cpp
++++ b/src/engine/client/http.cpp
+@@ -2,7 +2,7 @@
+ 
+ #include <base/system.h>
+ #include <engine/engine.h>
+-#include <engine/external/json-parser/json.h>
++#include <json-parser/json.h>
+ #include <engine/shared/config.h>
+ #include <engine/storage.h>
+ #include <game/version.h>
+diff --git a/src/engine/client/serverbrowser.cpp b/src/engine/client/serverbrowser.cpp
+index 1bc41849b..a639e7591 100644
+--- a/src/engine/client/serverbrowser.cpp
++++ b/src/engine/client/serverbrowser.cpp
+@@ -20,7 +20,7 @@
+ 
+ #include <mastersrv/mastersrv.h>
+ 
+-#include <engine/external/json-parser/json.h>
++#include <json-parser/json.h>
+ 
+ #include "serverbrowser.h"
+ class SortWrap
+diff --git a/src/engine/client/serverbrowser.h b/src/engine/client/serverbrowser.h
+index 282d20208..bb27ff1f1 100644
+--- a/src/engine/client/serverbrowser.h
++++ b/src/engine/client/serverbrowser.h
+@@ -5,7 +5,7 @@
+ 
+ #include <engine/serverbrowser.h>
+ #include <engine/shared/memheap.h>
+-#include <engine/external/json-parser/json.h>
++#include <json-parser/json.h>
+ 
+ class CServerBrowser : public IServerBrowser
+ {
+diff --git a/src/engine/client/updater.cpp b/src/engine/client/updater.cpp
+index 180fd6ddb..add49c973 100644
+--- a/src/engine/client/updater.cpp
++++ b/src/engine/client/updater.cpp
+@@ -3,7 +3,7 @@
+ #include <engine/engine.h>
+ #include <engine/storage.h>
+ #include <engine/client.h>
+-#include <engine/external/json-parser/json.h>
++#include <json-parser/json.h>
+ #include <engine/shared/json.h>
+ #include <game/version.h>
+ 
+diff --git a/src/engine/shared/json.h b/src/engine/shared/json.h
+index 9b5af36c5..62d245615 100644
+--- a/src/engine/shared/json.h
++++ b/src/engine/shared/json.h
+@@ -1,7 +1,7 @@
+ #ifndef ENGINE_SHARED_JSON_H
+ #define ENGINE_SHARED_JSON_H
+ 
+-#include <engine/external/json-parser/json.h>
++#include <json-parser/json.h>
+ 
+ const struct _json_value *json_object_get (const json_value * object, const char * index);
+ const struct _json_value *json_array_get (const json_value * array, int index);
+-- 
+2.24.1
+

diff --git a/ddnet.spec b/ddnet.spec
new file mode 100644
index 0000000..1f2751f
--- /dev/null
+++ b/ddnet.spec
@@ -0,0 +1,241 @@
+# Enable LTO
+%bcond_without lto
+
+# Enable Ninja build
+%bcond_without ninja_build
+
+%if %{with lto}
+%global optflags        %{optflags} -flto
+%global build_ldflags   %{build_ldflags} -flto
+%endif
+
+Name:           ddnet
+Version:        12.9.1
+Release:        1%{?dist}
+Summary:        DDraceNetwork, a cooperative racing mod of Teeworlds
+
+#
+# zlib
+# --------------------------------------
+# src/engine/external/md5/
+#
+# CC-BY-SA
+# --------------------------------------
+# data/languages/
+# data/fonts/DejaVuSansCJKName.ttf
+# data/fonts/DejavuWenQuanYiMicroHei.ttf
+#
+# ASL 2.0
+# --------------------------------------
+# data/
+#
+# MIT
+# --------------------------------------
+# man/
+#
+# Public domain
+# --------------------------------------
+# src/base/hash_libtomcrypt.c
+#
+
+
+License:        zlib and CC-BY-SA and ASL 2.0 and MIT and Public Domain
+URL:            https://ddnet.tw/
+Source0:        https://github.com/ddnet/ddnet/archive/%{version}/%{name}-%{version}.tar.gz
+
+# Disable network lookup test because without internet access tests not pass
+Patch1:         0001-disabled-network-lookup-test.patch
+
+# Unbundle md5
+Patch2:         0002-unbundled-md5.patch
+
+# Unbundle json-parser
+Patch3:         0003-unbundled-json-parser.patch
+
+BuildRequires:  desktop-file-utils
+BuildRequires:  libappstream-glib
+
+%if %{with ninja_build}
+BuildRequires:  ninja-build
+%endif
+
+BuildRequires:  cmake
+BuildRequires:  gcc-c++
+BuildRequires:  git-core
+BuildRequires:  python3
+
+BuildRequires:  pkgconfig(freetype2)
+BuildRequires:  pkgconfig(glew)
+BuildRequires:  pkgconfig(gtest)
+BuildRequires:  pkgconfig(json-parser)
+BuildRequires:  pkgconfig(libcurl)
+BuildRequires:  pkgconfig(ogg)
+BuildRequires:  pkgconfig(openssl)
+BuildRequires:  pkgconfig(opus)
+BuildRequires:  pkgconfig(opusfile)
+BuildRequires:  pkgconfig(sdl2)
+BuildRequires:  pkgconfig(wavpack)
+BuildRequires:  pkgconfig(zlib)
+
+# pkgconfig not available
+BuildRequires:  pnglite-devel
+
+Requires:       %{name}-data = %{version}-%{release}
+
+# https://github.com/ddnet/ddnet/issues/2019
+Provides:       bundled(dejavu-sans-cjkname-fonts)
+Provides:       bundled(dejavu-wenquanyi-micro-hei-fonts)
+
+
+%description
+DDraceNetwork (DDNet) is an actively maintained version of DDRace,
+a Teeworlds modification with a unique cooperative gameplay.
+Help each other play through custom maps with up to 64 players,
+compete against the best in international tournaments, design your
+own maps, or run your own server.
+
+
+%package        data
+Summary:        Data files for %{name}
+
+Requires:       %{name} = %{version}-%{release}
+Requires:       hicolor-icon-theme
+
+BuildArch:      noarch
+
+%description    data
+Data files for %{name}.
+
+
+%package        server
+Summary:        Standalone server for %{name}
+
+Requires:       %{name}%{?_isa} = %{version}-%{release}
+
+%description    server
+Standalone server for %{name}.
+
+
+%prep
+%autosetup -S git
+touch CMakeLists.txt
+
+# Remove bundled stuff...
+rm -rf src/engine/external
+
+mkdir -p %{_target_platform}
+
+
+%build
+# TODO: Add mysql support
+# WebSockets disable because it freezes all GUI | https://github.com/ddnet/ddnet/issues/1900
+pushd %{_target_platform}
+%cmake \
+    %{?with_ninja_build: -GNinja} \
+    -DPREFER_BUNDLED_LIBS=OFF \
+    -DAUTOUPDATE=OFF \
+    ..
+popd
+
+%if %{with ninja_build}
+%ninja_build -C %{_target_platform}
+%else
+%make_build -C %{_target_platform}
+%endif
+
+
+%install
+%if %{with ninja_build}
+%ninja_install -C %{_target_platform}
+%else
+%make_install -C %{_target_platform}
+%endif
+
+# Install man pages...
+install -Dp -m 0644 man/DDNet.6 %{buildroot}%{_mandir}/man6/DDNet.6
+install -Dp -m 0644 man/DDNet-Server.6 %{buildroot}%{_mandir}/man6/DDNet-Server.6
+
+
+%check
+%if %{with ninja_build}
+%ninja_build run_tests -C %{_target_platform}
+%else
+%make_build run_tests -C %{_target_platform}
+%endif
+desktop-file-validate %{buildroot}%{_datadir}/applications/%{name}.desktop
+appstream-util validate-relax --nonet %{buildroot}%{_metainfodir}/*.appdata.xml
+
+
+%files
+%license license.txt
+%doc README.md
+%{_mandir}/man6/DDNet.6*
+
+%{_bindir}/DDNet
+%{_libdir}/%{name}/
+
+%{_datadir}/applications/%{name}.desktop
+%{_metainfodir}/*.appdata.xml
+
+%files data
+%{_datadir}/%{name}/
+%{_datadir}/icons/hicolor/*/apps/%{name}.png
+
+%files server
+%{_mandir}/man6/DDNet-Server.6*
+
+%{_bindir}/DDNet-Server
+
+
+%changelog
+* Fri Feb 14 2020 ElXreno <elxreno@gmail.com> - 12.9.1-1
+- Updated to version 12.9.1
+
+* Thu Feb 13 2020 ElXreno <elxreno@gmail.com> - 12.9-2
+- Fixed build error for Rawhide
+
+* Thu Feb 13 2020 ElXreno <elxreno@gmail.com> - 12.9-1
+- Updated to version 12.9
+
+* Wed Jan 01 2020 ElXreno <elxreno@gmail.com> - 12.8.1-6
+- Applied patch by @atim
+- Added license breakdown explanation
+- Unbundled md5 and json-parser
+- Removed hicolor-icon-theme from main package
+
+* Tue Dec 31 2019 ElXreno <elxreno@gmail.com> - 12.8.1-5
+- Added AppData manifest
+- Disabled websockets
+
+* Mon Dec 30 2019 ElXreno <elxreno@gmail.com> - 12.8.1-4
+- Fixed man pages and license
+
+* Mon Dec 30 2019 ElXreno <elxreno@gmail.com> - 12.8.1-3
+- Ninja build
+
+* Mon Dec 30 2019 ElXreno <elxreno@gmail.com> - 12.8.1-2
+- WebSockets support for server
+
+* Mon Dec 23 2019 ElXreno <elxreno@gmail.com> - 12.8.1-1
+- Updated to version 12.8.1
+
+* Wed Dec 18 2019 ElXreno <elxreno@gmail.com> - 12.8-1
+- Updated to version 12.8
+
+* Sun Dec 08 2019 ElXreno <elxreno@gmail.com> - 12.7.3-6
+- Extracted ddnet-maps into ddnet-maps.spec, enabled tests
+
+* Sat Dec 07 2019 Artem Polishchuk <ego.cordatus@gmail.com> - 12.7.3-5
+- Spec file fixes
+
+* Sat Dec 07 2019 ElXreno <elxreno@gmail.com> - 12.7.3-4
+- Updated maps to commit 950f9ec7a40814759c78241816903a236ab8de93
+
+* Fri Dec 06 2019 Artem Polishchuk <ego.cordatus@gmail.com> - 12.7.3-3
+- Tim was here :)
+
+* Fri Dec 06 2019 ElXreno <elxreno@gmail.com> - 12.7.3-2
+- More docs, tests, and additions
+
+* Sat Nov 30 2019 ElXreno <elxreno@gmail.com> - 12.7.3-1
+- Initial packaging

diff --git a/sources b/sources
new file mode 100644
index 0000000..74c490f
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+SHA512 (ddnet-12.9.1.tar.gz) = 82247d4738080ea2b0deff668327e25e48e1d2af745a576a1c76f17fce8f8a5c6fdac7af68203efb07a627998fcc53f27813193f0b23a851693646a382d83dee

                 reply	other threads:[~2026-09-03  0:09 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178839418297.1.14964480156733209081.rpms-ddnet-08ccf2499fdf@fedoraproject.org \
    --to=elxreno@gmail.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox