Ports: Add lolcat

This commit is contained in:
Ninad Sachania 2024-11-13 08:53:21 +00:00 committed by Nico Weber
parent bff196be31
commit 27b8bb7969
4 changed files with 61 additions and 0 deletions

View file

@ -193,6 +193,7 @@ This list is also available at [ports.serenityos.net](https://ports.serenityos.n
| [`links`](links/) | Links web browser | 2.29 | http://links.twibright.com/ |
| [`lite-xl`](lite-xl/) | Lite-XL | 2.1.3 | https://lite-xl.com/ |
| [`llvm`](llvm/) | LLVM | 19.1.0 | https://llvm.org/ |
| [`lolcat`](lolcat/) | lolcat | 1212a9c | https://github.com/jaseg/lolcat/ |
| [`lowdown`](lowdown/) | lowdown | 1.0.2 | https://kristaps.bsd.lv/lowdown/ |
| [`lrzip`](lrzip/) | lrzip | 0.651 | https://github.com/ckolivas/lrzip |
| [`lua`](lua/) | Lua | 5.4.6 | https://www.lua.org/ |

18
Ports/lolcat/package.sh Executable file
View file

@ -0,0 +1,18 @@
#!/usr/bin/env -S bash ../.port_include.sh
port='lolcat'
version='1212a9cc6c2a092359db460d9f62822b56dc02ef'
files=(
"https://github.com/jaseg/lolcat/archive/${version}.zip#f109665a7be2cafb7e0b14438d727826396a2e65e6349266561bd60f206e355d"
)
bin_path="/usr/local/bin"
build() {
run make
}
install() {
run_nocd mkdir -p "${SERENITY_INSTALL_ROOT}/${bin_path}/"
run cp lolcat "${SERENITY_INSTALL_ROOT}/${bin_path}/"
run cp censor "${SERENITY_INSTALL_ROOT}/${bin_path}/"
}

View file

@ -0,0 +1,37 @@
From 1855230d5734e829bd7569c8329ed2bb17b671d5 Mon Sep 17 00:00:00 2001
From: Ninad Sachania <ninad.sachania@gmail.com>
Date: Wed, 13 Nov 2024 08:46:33 +0000
Subject: [PATCH] Remove unnecessary headers
---
censor.c | 1 -
lolcat.c | 1 -
2 files changed, 2 deletions(-)
diff --git a/censor.c b/censor.c
index 39b25a4..6ca5d7a 100644
--- a/censor.c
+++ b/censor.c
@@ -14,7 +14,6 @@
*/
#include <ctype.h>
-#include <err.h>
#include <errno.h>
#include <locale.h>
#include <stdint.h>
diff --git a/lolcat.c b/lolcat.c
index 011f5dc..9097a83 100755
--- a/lolcat.c
+++ b/lolcat.c
@@ -16,7 +16,6 @@
#define _XOPEN_SOURCE
#include <ctype.h>
-#include <err.h>
#include <errno.h>
#include <locale.h>
#include <stdint.h>
--
2.43.0

View file

@ -0,0 +1,5 @@
# Patches for lolcat on SerenityOS
## `0001-Remove-unnecessary-headers.patch`
Remove unnecessary `#include <err.h>` headers