]> git.ipfire.org Git - pakfire.git/commitdiff
macros: Add helpers to make GitHub URLs
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 15 Feb 2025 13:28:09 +0000 (13:28 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Sat, 15 Feb 2025 13:28:09 +0000 (13:28 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
macros/github.macro [new file with mode: 0644]

index 9da7e41ec095f805eeba942f13d1885ab2f58727..c2be8ef53d49a45a609e4c87c567db45a880fac3 100644 (file)
@@ -1072,6 +1072,7 @@ dist_macros_DATA = \
        macros/cflags.macro \
        macros/cmake.macro \
        macros/constants.macro \
+       macros/github.macro \
        macros/meson.macro \
        macros/ninja.macro \
        macros/package-default.macro \
diff --git a/macros/github.macro b/macros/github.macro
new file mode 100644 (file)
index 0000000..3f4b3f3
--- /dev/null
@@ -0,0 +1,31 @@
+###############################################################################
+#                                                                             #
+# Pakfire - The IPFire package management system                              #
+# Copyright (C) 2013 Pakfire development team                                 #
+#                                                                             #
+# This program is free software: you can redistribute it and/or modify        #
+# it under the terms of the GNU General Public License as published by        #
+# the Free Software Foundation, either version 3 of the License, or           #
+# (at your option) any later version.                                         #
+#                                                                             #
+# This program is distributed in the hope that it will be useful,             #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of              #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               #
+# GNU General Public License for more details.                                #
+#                                                                             #
+# You should have received a copy of the GNU General Public License           #
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.       #
+#                                                                             #
+###############################################################################
+
+# These macros help to deal with packages that are hosted on GitHub
+
+github_organization = %{name}
+github_project      = %{name}
+github_version      = %{version}
+
+# The project home URL
+github_home = https://github.com/%{github_organization}/%{github_project}/
+
+# URL to download sources
+github_url = %{github_home}/archive/%{github_version}/