2021-11-28 20:30:22 +00:00
|
|
|
diff --no-dereference -Naur -- nyancat.normalized/Makefile nyancat.srctix/Makefile
|
2022-01-29 11:02:14 +00:00
|
|
|
--- nyancat.normalized/Makefile 2018-08-18 15:40:20.000000000 +0200
|
|
|
|
+++ nyancat.srctix/Makefile 2020-02-22 23:53:15.702136508 +0100
|
2021-11-28 20:30:22 +00:00
|
|
|
@@ -1,39 +1,26 @@
|
|
|
|
-package = nyancat
|
|
|
|
-version = 1.5.2
|
|
|
|
-tarname = $(package)
|
|
|
|
-distdir = $(tarname)-$(version)
|
|
|
|
-
|
|
|
|
-all clean check nyancat:
|
|
|
|
- cd src && $(MAKE) $@
|
|
|
|
-
|
|
|
|
-dist: $(distdir).tar.gz
|
|
|
|
-
|
|
|
|
-$(distdir).tar.gz: $(distdir)
|
|
|
|
- tar chof - $(distdir) | gzip -9 -c > $@
|
|
|
|
- rm -rf $(distdir)
|
|
|
|
-
|
|
|
|
-$(distdir): FORCE
|
|
|
|
- mkdir -p $(distdir)/src
|
|
|
|
- cp Makefile $(distdir)
|
|
|
|
- cp src/Makefile $(distdir)/src
|
|
|
|
- cp src/nyancat.c $(distdir)/src
|
|
|
|
- cp src/animation.h $(distdir)/src
|
|
|
|
- cp src/telnet.h $(distdir)/src
|
|
|
|
-
|
|
|
|
-FORCE:
|
|
|
|
- -rm $(distdir).tar.gz >/dev/null 2>&1
|
|
|
|
- -rm -rf $(distdir) >/dev/null 2>&1
|
|
|
|
-
|
|
|
|
-distcheck: $(distdir).tar.gz
|
|
|
|
- gzip -cd $(distdir).tar.gz | tar xvf -
|
|
|
|
- cd $(distdir) && $(MAKE) all
|
|
|
|
- cd $(distdir) && $(MAKE) check
|
|
|
|
- cd $(distdir) && $(MAKE) clean
|
|
|
|
- rm -rf $(distdir)
|
|
|
|
- @echo "*** Package $(distdir).tar.gz is ready for distribution."
|
2022-01-29 11:02:14 +00:00
|
|
|
+include ../../build-aux/compiler.mak
|
|
|
|
+include ../../build-aux/version.mak
|
|
|
|
+include ../../build-aux/dirs.mak
|
2021-11-28 20:30:22 +00:00
|
|
|
+
|
|
|
|
+OPTLEVEL?=-g -O2
|
|
|
|
+CFLAGS?=$(OPTLEVEL)
|
|
|
|
+
|
|
|
|
+CFLAGS:=$(CXXFLAGS) -Wall -Wextra -std=c99 -pedantic -Wwrite-strings
|
|
|
|
+CPPFLAGS:=$(CPPFLAGS)
|
|
|
|
+
|
|
|
|
+all: src/nyancat
|
|
|
|
+
|
|
|
|
+.PHONY: all install clean
|
|
|
|
+
|
|
|
|
+src/nyancat: src/nyancat.o
|
|
|
|
+
|
|
|
|
+src/nyancat.o: src/animation.c src/telnet.h
|
|
|
|
|
|
|
|
install: all
|
|
|
|
- install src/nyancat /usr/bin/${package}
|
|
|
|
- gzip -9 -c < nyancat.1 > /usr/share/man/man1/nyancat.1.gz
|
|
|
|
+ mkdir -p $(DESTDIR)$(BINDIR)
|
|
|
|
+ install src/nyancat $(DESTDIR)$(BINDIR)
|
|
|
|
+ mkdir -p $(DESTDIR)$(MANDIR)/man1
|
|
|
|
+ install nyancat.1 $(DESTDIR)$(MANDIR)/man1
|
|
|
|
|
|
|
|
-.PHONY: FORCE all clean check dist distcheck install
|
|
|
|
+clean:
|
|
|
|
+ rm -f src/nyancat src/nyancat.o
|
|
|
|
diff --no-dereference -Naur -- nyancat.normalized/src/Makefile nyancat.srctix/src/Makefile
|
2022-01-29 11:02:14 +00:00
|
|
|
--- nyancat.normalized/src/Makefile 2018-08-18 15:40:20.000000000 +0200
|
|
|
|
+++ nyancat.srctix/src/Makefile 1970-01-01 01:00:00.000000000 +0100
|
2021-11-28 20:30:22 +00:00
|
|
|
@@ -1,20 +0,0 @@
|
|
|
|
-OBJECTS = nyancat.o
|
|
|
|
-
|
|
|
|
-CC ?=
|
|
|
|
-CFLAGS ?= -g -Wall -Wextra -std=c99 -pedantic -Wwrite-strings
|
|
|
|
-CPPFLAGS ?=
|
|
|
|
-LDFLAGS ?=
|
|
|
|
-
|
|
|
|
-all: nyancat
|
|
|
|
-
|
|
|
|
-nyancat: $(OBJECTS)
|
|
|
|
- $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(OBJECTS) -o $@
|
|
|
|
-
|
|
|
|
-clean:
|
|
|
|
- -rm -f $(OBJECTS) nyancat
|
|
|
|
-
|
|
|
|
-check: all
|
|
|
|
- # Unit tests go here. None currently.
|
|
|
|
- @echo "*** ALL TESTS PASSED ***"
|
|
|
|
-
|
|
|
|
-.PHONY: all clean check
|
|
|
|
diff --no-dereference -Naur -- nyancat.normalized/src/nyancat.c nyancat.srctix/src/nyancat.c
|
2022-01-29 11:02:14 +00:00
|
|
|
--- nyancat.normalized/src/nyancat.c 2018-08-18 15:40:20.000000000 +0200
|
|
|
|
+++ nyancat.srctix/src/nyancat.c 2020-02-23 16:27:36.461123269 +0100
|
2021-11-28 20:30:22 +00:00
|
|
|
@@ -54,6 +54,7 @@
|
|
|
|
#define _BSD_SOURCE
|
|
|
|
#define _DEFAULT_SOURCE
|
|
|
|
#define __BSD_VISIBLE 1
|
|
|
|
+#define _SORTIX_SOURCE 1
|
|
|
|
#include <ctype.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <stdint.h>
|
|
|
|
@@ -585,6 +586,8 @@
|
|
|
|
ttype = 1; /* 256-color, spaces */
|
|
|
|
} else if (strstr(term, "toaru")) {
|
|
|
|
ttype = 1; /* emulates xterm */
|
|
|
|
+ } else if (strstr(term, "sortix")) {
|
|
|
|
+ ttype = 1; /* emulates xterm */
|
|
|
|
} else if (strstr(term, "linux")) {
|
|
|
|
ttype = 3; /* Spaces and blink attribute */
|
|
|
|
} else if (strstr(term, "vtnt")) {
|
|
|
|
@@ -892,7 +895,7 @@
|
|
|
|
* The \033[0m prevents the Apple ][ from flipping everything, but
|
|
|
|
* makes the whole nyancat less bright on the vt220
|
|
|
|
*/
|
|
|
|
- printf("\033[1;37mYou have nyaned for %0.0f seconds!\033[J\033[0m", diff);
|
|
|
|
+ printf("\033[1;37mYou have nyaned for %lli seconds!\033[J\033[0m", (long long)diff);
|
|
|
|
}
|
|
|
|
/* Reset the last color so that the escape sequences rewrite */
|
|
|
|
last = 0;
|
|
|
|
diff --no-dereference -Naur -- nyancat.normalized/tixbuildinfo nyancat.srctix/tixbuildinfo
|
2022-01-29 11:02:14 +00:00
|
|
|
--- nyancat.normalized/tixbuildinfo 1970-01-01 01:00:00.000000000 +0100
|
|
|
|
+++ nyancat.srctix/tixbuildinfo 2017-02-12 00:52:20.285170797 +0100
|
2021-11-28 20:30:22 +00:00
|
|
|
@@ -0,0 +1,5 @@
|
|
|
|
+tix.version=1
|
|
|
|
+tix.class=srctix
|
|
|
|
+pkg.name=nyancat
|
|
|
|
+pkg.build-libraries=
|
|
|
|
+pkg.build-system=sortix-usual-makefile
|