Compare commits
38 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a0ce0d4ff5 | ||
|
|
ccd217463b | ||
|
|
8f27d67269 | ||
|
|
df2eae7e4e | ||
|
|
8bacc1c6f0 | ||
|
|
1e26f175fb | ||
|
|
0327816edb | ||
|
|
03886615a7 | ||
|
|
657a007118 | ||
|
|
ede8e3ab78 | ||
|
|
f5ce23d2ae | ||
|
|
bd0533188e | ||
|
|
1b0701f233 | ||
|
|
c6c2691faf | ||
|
|
3a67d1b4ee | ||
|
|
59ba3ba13b | ||
|
|
e27aaf9838 | ||
|
|
e0ffa3a6eb | ||
|
|
0877276ab7 | ||
|
|
d7023a6df2 | ||
|
|
fa93c9a986 | ||
|
|
008d389922 | ||
|
|
b8f5033395 | ||
|
|
c3a71855b7 | ||
|
|
83f591b36a | ||
|
|
a8bb517841 | ||
|
|
a3d78e7dda | ||
|
|
bf4d3ccaba | ||
|
|
495132b98c |
||
|
|
b7dc1aaeed | ||
|
|
6a23e9e9ae | ||
|
|
6e82d99ef8 | ||
|
|
610ddbb9fb | ||
|
|
c1c4bba2c1 | ||
|
|
f090eecfb3 | ||
|
|
39f36ed792 | ||
|
|
ee01e85ac9 | ||
|
|
5c96c2e615 |
7 changed files with 340 additions and 204 deletions
9
.gitignore
vendored
9
.gitignore
vendored
|
|
@ -1,2 +1,11 @@
|
|||
calendar-1.26-20110531cvs.tar.gz
|
||||
/calendar-1.28-20140613cvs.tar.gz
|
||||
/calendar-1.35-20180719cvs.tar.gz
|
||||
/calendar-1.35-20190227cvs.tar.gz
|
||||
/calendar-1.37-20190827cvs.tar.gz
|
||||
/calendar-1.37-20200430cvs.tar.gz
|
||||
/calendar-1.37-20211220cvs.tar.gz
|
||||
/calendar-1.37-20221115cvs.tar.gz
|
||||
/calendar-1.37-20240209cvs.tar.gz
|
||||
/calendar-1.37-20240528cvs.tar.gz
|
||||
/calendar-1.37-20250303cvs.tar.gz
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ CFLAGS = $(RPM_OPT_FLAGS) -D_GNU_SOURCE -DTM_YEAR_BASE=1900
|
|||
|
||||
SRCS = calendar.c io.c day.c pesach.c ostern.c paskha.c
|
||||
OBJS = $(SRCS:.c=.o)
|
||||
INTER = de_DE.ISO_8859-1 hr_HR.ISO_8859-2 ru_RU.KOI8-R fr_FR.ISO8859-1
|
||||
INTER = de_DE.UTF-8 hr_HR.UTF-8 ru_RU.UTF-8 fr_FR.UTF-8
|
||||
|
||||
all: calendar
|
||||
|
||||
|
|
|
|||
|
|
@ -1,186 +0,0 @@
|
|||
diff -up calendar-1.28-20140613cvs/calendar.c.linux calendar-1.28-20140613cvs/calendar.c
|
||||
--- calendar-1.28-20140613cvs/calendar.c.linux 2012-01-31 03:29:25.000000000 -0500
|
||||
+++ calendar-1.28-20140613cvs/calendar.c 2014-06-13 11:55:10.282747232 -0400
|
||||
@@ -35,14 +35,12 @@
|
||||
#include <err.h>
|
||||
#include <errno.h>
|
||||
#include <locale.h>
|
||||
-#include <login_cap.h>
|
||||
#include <pwd.h>
|
||||
#include <signal.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
-#include <tzfile.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "pathnames.h"
|
||||
@@ -171,10 +169,6 @@ main(int argc, char *argv[])
|
||||
case 0: /* child */
|
||||
(void)setpgid(getpid(), getpid());
|
||||
(void)setlocale(LC_ALL, "");
|
||||
- if (setusercontext(NULL, pw, pw->pw_uid,
|
||||
- LOGIN_SETALL ^ LOGIN_SETLOGIN))
|
||||
- err(1, "unable to set user context (uid %u)",
|
||||
- pw->pw_uid);
|
||||
if (acstat) {
|
||||
if (chdir(pw->pw_dir) ||
|
||||
stat(calendarFile, &sbuf) != 0 ||
|
||||
diff -up calendar-1.28-20140613cvs/calendar.h.linux calendar-1.28-20140613cvs/calendar.h
|
||||
--- calendar-1.28-20140613cvs/calendar.h.linux 2010-04-28 14:20:15.000000000 -0400
|
||||
+++ calendar-1.28-20140613cvs/calendar.h 2014-06-13 12:57:23.200747232 -0400
|
||||
@@ -29,6 +29,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
+#include <sys/types.h>
|
||||
|
||||
extern struct passwd *pw;
|
||||
extern int doall;
|
||||
@@ -110,7 +111,7 @@ extern int f_SetdayAfter; /* calendar in
|
||||
|
||||
/* calendars */
|
||||
extern enum calendars { GREGORIAN = 0, JULIAN, LUNAR } calendar;
|
||||
-extern u_long julian;
|
||||
+extern unsigned long julian;
|
||||
|
||||
#define NUMEV 3 /* Total number of such special events */
|
||||
extern struct specialev spev[NUMEV];
|
||||
@@ -120,3 +121,5 @@ extern struct specialev spev[NUMEV];
|
||||
* (e.g. by using named pipes)
|
||||
*/
|
||||
#define USERTIMEOUT 20
|
||||
+
|
||||
+#define SECSPERDAY 86400
|
||||
diff -up calendar-1.28-20140613cvs/day.c.linux calendar-1.28-20140613cvs/day.c
|
||||
--- calendar-1.28-20140613cvs/day.c.linux 2013-11-26 08:18:53.000000000 -0500
|
||||
+++ calendar-1.28-20140613cvs/day.c 2014-06-13 11:55:10.283747232 -0400
|
||||
@@ -39,7 +39,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
-#include <tzfile.h>
|
||||
|
||||
#include "pathnames.h"
|
||||
#include "calendar.h"
|
||||
@@ -157,7 +156,7 @@ settime(time_t *now)
|
||||
tp->tm_isdst = 0;
|
||||
tp->tm_hour = 12;
|
||||
*now = mktime(tp);
|
||||
- if (isleap(tp->tm_year + TM_YEAR_BASE))
|
||||
+ if (__isleap(tp->tm_year + TM_YEAR_BASE))
|
||||
cumdays = daytab[1];
|
||||
else
|
||||
cumdays = daytab[0];
|
||||
@@ -288,8 +287,10 @@ isnow(char *endp, int bodun)
|
||||
return (NULL);
|
||||
|
||||
/* adjust bodun rate */
|
||||
- if (bodun && !bodun_always)
|
||||
- bodun = !arc4random_uniform(3);
|
||||
+ if (bodun && !bodun_always) {
|
||||
+ srandom(3);
|
||||
+ bodun = random();
|
||||
+ }
|
||||
|
||||
/* Easter or Easter depending days */
|
||||
if (flags & F_SPECIAL)
|
||||
@@ -440,7 +441,7 @@ isnow(char *endp, int bodun)
|
||||
}
|
||||
v2 = day - tp->tm_yday;
|
||||
if ((v2 > v1) || (v2 < 0)) {
|
||||
- if ((v2 += isleap(tp->tm_year + TM_YEAR_BASE) ? 366 : 365)
|
||||
+ if ((v2 += __isleap(tp->tm_year + TM_YEAR_BASE) ? 366 : 365)
|
||||
<= v1)
|
||||
tmtmp.tm_year++;
|
||||
else if(!bodun || (day - tp->tm_yday) != -1)
|
||||
@@ -676,7 +677,7 @@ variable_weekday(int *day, int month, in
|
||||
int *cumdays;
|
||||
int day1;
|
||||
|
||||
- if (isleap(year))
|
||||
+ if (__isleap(year))
|
||||
cumdays = daytab[1];
|
||||
else
|
||||
cumdays = daytab[0];
|
||||
diff -up calendar-1.28-20140613cvs/io.c.linux calendar-1.28-20140613cvs/io.c
|
||||
--- calendar-1.28-20140613cvs/io.c.linux 2013-11-26 08:18:53.000000000 -0500
|
||||
+++ calendar-1.28-20140613cvs/io.c 2014-06-13 11:55:10.283747232 -0400
|
||||
@@ -45,7 +45,6 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
-#include <tzfile.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "pathnames.h"
|
||||
@@ -68,7 +67,7 @@ void
|
||||
cal(void)
|
||||
{
|
||||
int ch, l, i, bodun = 0, bodun_maybe = 0, var, printing;
|
||||
- struct event *events, *cur_evt, *ev1, *tmp;
|
||||
+ struct event *events = NULL, *cur_evt = NULL, *ev1 = NULL, *tmp = NULL;
|
||||
char buf[2048 + 1], *prefix = NULL, *p;
|
||||
struct match *m;
|
||||
FILE *fp;
|
||||
diff -up calendar-1.28-20140613cvs/ostern.c.linux calendar-1.28-20140613cvs/ostern.c
|
||||
--- calendar-1.28-20140613cvs/ostern.c.linux 2009-10-27 19:59:36.000000000 -0400
|
||||
+++ calendar-1.28-20140613cvs/ostern.c 2014-06-13 11:55:10.283747232 -0400
|
||||
@@ -30,7 +30,6 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <time.h>
|
||||
-#include <tzfile.h>
|
||||
|
||||
#include "calendar.h"
|
||||
|
||||
@@ -61,7 +60,7 @@ easter(int year) /* 0 ... abcd, NOT sinc
|
||||
e_p = e_p + 1;
|
||||
|
||||
e_q = 31 + 28 + e_p;
|
||||
- if (isleap(year))
|
||||
+ if (__isleap(year))
|
||||
e_q++;
|
||||
|
||||
if (e_n == 4)
|
||||
diff -up calendar-1.28-20140613cvs/paskha.c.linux calendar-1.28-20140613cvs/paskha.c
|
||||
--- calendar-1.28-20140613cvs/paskha.c.linux 2009-10-27 19:59:36.000000000 -0400
|
||||
+++ calendar-1.28-20140613cvs/paskha.c 2014-06-13 13:44:02.029747232 -0400
|
||||
@@ -27,7 +27,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
-#include <tzfile.h>
|
||||
+#include <time.h>
|
||||
|
||||
#include "calendar.h"
|
||||
|
||||
@@ -48,7 +48,7 @@ paskha(int R) /*year*/
|
||||
d = (19*a + x) % 30;
|
||||
e = (2*b + 4*c + 6*d + y) % 7;
|
||||
cumdays = 31 + 28;
|
||||
- if (isleap(R))
|
||||
+ if (__isleap(R))
|
||||
cumdays++;
|
||||
return ((cumdays + 22) + (d + e) + 13);
|
||||
}
|
||||
diff -up calendar-1.28-20140613cvs/pesach.c.linux calendar-1.28-20140613cvs/pesach.c
|
||||
--- calendar-1.28-20140613cvs/pesach.c.linux 2009-10-27 19:59:36.000000000 -0400
|
||||
+++ calendar-1.28-20140613cvs/pesach.c 2014-06-13 12:57:51.624747232 -0400
|
||||
@@ -18,7 +18,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
-#include <tzfile.h>
|
||||
+#include <time.h>
|
||||
|
||||
#include "calendar.h"
|
||||
|
||||
@@ -62,5 +62,5 @@ pesach(int R)
|
||||
if (R > 1582)
|
||||
cumdays += R / 100 - R /400 - 2;
|
||||
|
||||
- return (31 + 28 + cumdays + (isleap(R)? 1 : 0));
|
||||
+ return (31 + 28 + cumdays + (__isleap(R)? 1 : 0));
|
||||
}
|
||||
213
calendar-1.37-linux.patch
Normal file
213
calendar-1.37-linux.patch
Normal file
|
|
@ -0,0 +1,213 @@
|
|||
diff -up calendar-1.37-20221115cvs/calendar.c.orig calendar-1.37-20221115cvs/calendar.c
|
||||
--- calendar-1.37-20221115cvs/calendar.c.orig 2019-02-01 11:22:53.000000000 -0500
|
||||
+++ calendar-1.37-20221115cvs/calendar.c 2022-11-15 14:33:05.908157513 -0500
|
||||
@@ -35,7 +35,6 @@
|
||||
#include <err.h>
|
||||
#include <errno.h>
|
||||
#include <locale.h>
|
||||
-#include <login_cap.h>
|
||||
#include <pwd.h>
|
||||
#include <signal.h>
|
||||
#include <stdio.h>
|
||||
@@ -98,16 +97,20 @@ main(int argc, char *argv[])
|
||||
break;
|
||||
|
||||
case 'A': /* days after current date */
|
||||
- f_dayAfter = strtonum(optarg, 0, INT_MAX, &errstr);
|
||||
- if (errstr)
|
||||
- errx(1, "-A %s: %s", optarg, errstr);
|
||||
+ f_dayAfter = strtoll(optarg, NULL, 10);
|
||||
+ if (errno == ERANGE && (f_dayAfter == LLONG_MIN || f_dayBefore == LLONG_MAX))
|
||||
+ errx(1, "-A %s: %s", optarg, strerror(errno));
|
||||
+ else if (f_dayAfter < 0 || f_dayAfter > INT_MAX)
|
||||
+ errx(1, "-A %s: %s out of range", optarg, optarg);
|
||||
f_Setday = 1;
|
||||
break;
|
||||
|
||||
case 'B': /* days before current date */
|
||||
- f_dayBefore = strtonum(optarg, 0, INT_MAX, &errstr);
|
||||
- if (errstr)
|
||||
- errx(1, "-B %s: %s", optarg, errstr);
|
||||
+ f_dayBefore = strtoll(optarg, NULL, 10);
|
||||
+ if (errno == ERANGE && (f_dayBefore == LLONG_MIN || f_dayBefore == LLONG_MAX))
|
||||
+ errx(1, "-B %s: %s", optarg, strerror(errno));
|
||||
+ else if (f_dayBefore < 0 || f_dayBefore > INT_MAX)
|
||||
+ errx(1, "-B %s: %s out of range", optarg, optarg);
|
||||
if (f_dayBefore != 0)
|
||||
f_Setday = 1;
|
||||
break;
|
||||
@@ -125,15 +128,6 @@ main(int argc, char *argv[])
|
||||
if (argc)
|
||||
usage();
|
||||
|
||||
- if (doall) {
|
||||
- if (pledge("stdio rpath tmppath fattr getpw id proc exec", NULL)
|
||||
- == -1)
|
||||
- err(1, "pledge");
|
||||
- } else {
|
||||
- if (pledge("stdio rpath proc exec", NULL) == -1)
|
||||
- err(1, "pledge");
|
||||
- }
|
||||
-
|
||||
/* use current time */
|
||||
if (f_time <= 0)
|
||||
(void)time(&f_time);
|
||||
@@ -192,10 +186,6 @@ main(int argc, char *argv[])
|
||||
case 0: /* child */
|
||||
(void)setpgid(getpid(), getpid());
|
||||
(void)setlocale(LC_ALL, "");
|
||||
- if (setusercontext(NULL, pw, pw->pw_uid,
|
||||
- LOGIN_SETALL ^ LOGIN_SETLOGIN))
|
||||
- err(1, "unable to set user context (uid %u)",
|
||||
- pw->pw_uid);
|
||||
if (acstat) {
|
||||
if (chdir(pw->pw_dir) ||
|
||||
stat(calendarFile, &sbuf) != 0 ||
|
||||
diff -up calendar-1.37-20221115cvs/calendar.h.orig calendar-1.37-20221115cvs/calendar.h
|
||||
--- calendar-1.37-20221115cvs/calendar.h.orig 2019-02-01 11:22:53.000000000 -0500
|
||||
+++ calendar-1.37-20221115cvs/calendar.h 2022-11-15 14:33:44.201071607 -0500
|
||||
@@ -29,6 +29,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
+#include <sys/types.h>
|
||||
|
||||
extern struct passwd *pw;
|
||||
extern int doall;
|
||||
@@ -116,7 +117,7 @@ extern int f_Setday; /* calendar invoked
|
||||
|
||||
/* calendars */
|
||||
extern enum calendars { GREGORIAN = 0, JULIAN, LUNAR } calendar;
|
||||
-extern u_long julian;
|
||||
+extern unsigned long julian;
|
||||
|
||||
#define NUMEV 3 /* Total number of such special events */
|
||||
extern struct specialev spev[NUMEV];
|
||||
diff -up calendar-1.37-20221115cvs/day.c.orig calendar-1.37-20221115cvs/day.c
|
||||
--- calendar-1.37-20221115cvs/day.c.orig 2019-08-12 16:03:28.000000000 -0400
|
||||
+++ calendar-1.37-20221115cvs/day.c 2022-11-15 14:35:03.925892751 -0500
|
||||
@@ -160,7 +160,7 @@ settime(time_t *now)
|
||||
tp->tm_isdst = 0;
|
||||
tp->tm_hour = 12;
|
||||
*now = mktime(tp);
|
||||
- if (isleap(tp->tm_year + 1900))
|
||||
+ if (__isleap(tp->tm_year + 1900))
|
||||
cumdays = daytab[1];
|
||||
else
|
||||
cumdays = daytab[0];
|
||||
@@ -288,8 +288,10 @@ isnow(char *endp, int bodun)
|
||||
return (NULL);
|
||||
|
||||
/* adjust bodun rate */
|
||||
- if (bodun && !bodun_always)
|
||||
- bodun = !arc4random_uniform(3);
|
||||
+ if (bodun && !bodun_always) {
|
||||
+ srandom(3);
|
||||
+ bodun = random();
|
||||
+ }
|
||||
|
||||
/* Easter or Easter depending days */
|
||||
if (flags & F_SPECIAL)
|
||||
@@ -444,7 +446,7 @@ isnow(char *endp, int bodun)
|
||||
}
|
||||
v2 = day - tp->tm_yday;
|
||||
if ((v2 > v1) || (v2 < 0)) {
|
||||
- if ((v2 += isleap(tp->tm_year + 1900) ? 366 : 365)
|
||||
+ if ((v2 += __isleap(tp->tm_year + 1900) ? 366 : 365)
|
||||
<= v1)
|
||||
tmtmp.tm_year++;
|
||||
else if(!bodun || (day - tp->tm_yday) != -1)
|
||||
@@ -674,7 +676,7 @@ variable_weekday(int *day, int month, in
|
||||
int *cumdays;
|
||||
int day1;
|
||||
|
||||
- if (isleap(year))
|
||||
+ if (__isleap(year))
|
||||
cumdays = daytab[1];
|
||||
else
|
||||
cumdays = daytab[0];
|
||||
diff -up calendar-1.37-20221115cvs/io.c.orig calendar-1.37-20221115cvs/io.c
|
||||
--- calendar-1.37-20221115cvs/io.c.orig 2021-12-07 09:00:33.000000000 -0500
|
||||
+++ calendar-1.37-20221115cvs/io.c 2022-11-15 14:36:05.933753650 -0500
|
||||
@@ -67,7 +67,7 @@ void
|
||||
cal(void)
|
||||
{
|
||||
int ch, l, i, bodun = 0, bodun_maybe = 0, var, printing;
|
||||
- struct event *events, *cur_evt, *ev1, *tmp;
|
||||
+ struct event *events = NULL, *cur_evt = NULL, *ev1 = NULL, *tmp = NULL;
|
||||
char buf[2048 + 1], *prefix = NULL, *p;
|
||||
struct match *m;
|
||||
FILE *fp;
|
||||
@@ -282,8 +282,8 @@ getfield(char *p, char **endp, int *flag
|
||||
switch (*start) {
|
||||
case '-':
|
||||
case '+':
|
||||
- var = strtonum(start + 1, 0, 365, &errstr);
|
||||
- if (errstr)
|
||||
+ var = strtoll(start + 1, NULL, 10);
|
||||
+ if ((errno == ERANGE && (var == LLONG_MIN || var == LLONG_MAX)) || (var < 0 || var > 365))
|
||||
return (0); /* Someone is just being silly */
|
||||
if (*start == '-')
|
||||
var = -var;
|
||||
diff -up calendar-1.37-20221115cvs/ostern.c.orig calendar-1.37-20221115cvs/ostern.c
|
||||
--- calendar-1.37-20221115cvs/ostern.c.orig 2019-01-17 01:15:44.000000000 -0500
|
||||
+++ calendar-1.37-20221115cvs/ostern.c 2022-11-15 14:36:20.564720831 -0500
|
||||
@@ -58,7 +58,7 @@ easter(int year) /* 0 ... abcd, NOT sinc
|
||||
e_p = e_p + 1;
|
||||
|
||||
e_q = 31 + 28 + e_p;
|
||||
- if (isleap(year))
|
||||
+ if (__isleap(year))
|
||||
e_q++;
|
||||
|
||||
if (e_n == 4)
|
||||
diff -up calendar-1.37-20221115cvs/paskha.c.orig calendar-1.37-20221115cvs/paskha.c
|
||||
--- calendar-1.37-20221115cvs/paskha.c.orig 2015-03-14 20:41:28.000000000 -0400
|
||||
+++ calendar-1.37-20221115cvs/paskha.c 2022-11-15 14:36:48.138658978 -0500
|
||||
@@ -27,6 +27,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
+#include <time.h>
|
||||
|
||||
#include "calendar.h"
|
||||
|
||||
@@ -47,7 +48,7 @@ paskha(int R) /*year*/
|
||||
d = (19*a + x) % 30;
|
||||
e = (2*b + 4*c + 6*d + y) % 7;
|
||||
cumdays = 31 + 28;
|
||||
- if (isleap(R))
|
||||
+ if (__isleap(R))
|
||||
cumdays++;
|
||||
return ((cumdays + 22) + (d + e) + 13);
|
||||
}
|
||||
diff -up calendar-1.37-20221115cvs/pathnames.h.orig calendar-1.37-20221115cvs/pathnames.h
|
||||
--- calendar-1.37-20221115cvs/pathnames.h.orig 2021-12-07 09:00:33.000000000 -0500
|
||||
+++ calendar-1.37-20221115cvs/pathnames.h 2022-11-15 14:37:06.633617492 -0500
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
#include <paths.h>
|
||||
|
||||
-#define _PATH_CPP "/usr/libexec/cpp"
|
||||
+#define _PATH_CPP "/usr/bin/cpp"
|
||||
|
||||
/* XXX -- fix when cpp parses arguments rationally */
|
||||
#define _PATH_INCLUDE "-I/usr/share/calendar"
|
||||
diff -up calendar-1.37-20221115cvs/pesach.c.orig calendar-1.37-20221115cvs/pesach.c
|
||||
--- calendar-1.37-20221115cvs/pesach.c.orig 2015-03-14 20:41:28.000000000 -0400
|
||||
+++ calendar-1.37-20221115cvs/pesach.c 2022-11-15 14:37:31.728561201 -0500
|
||||
@@ -18,6 +18,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
+#include <time.h>
|
||||
|
||||
#include "calendar.h"
|
||||
|
||||
@@ -61,5 +62,5 @@ pesach(int R)
|
||||
if (R > 1582)
|
||||
cumdays += R / 100 - R /400 - 2;
|
||||
|
||||
- return (31 + 28 + cumdays + (isleap(R)? 1 : 0));
|
||||
+ return (31 + 28 + cumdays + (__isleap(R)? 1 : 0));
|
||||
}
|
||||
112
calendar.spec
112
calendar.spec
|
|
@ -1,11 +1,10 @@
|
|||
%define alphatag 20140613cvs
|
||||
%define alphatag 20250303cvs
|
||||
|
||||
Summary: Reminder utility
|
||||
Name: calendar
|
||||
Version: 1.28
|
||||
Release: 8.%{alphatag}%{?dist}
|
||||
License: BSD
|
||||
Group: Applications/Productivity
|
||||
Version: 1.37
|
||||
Release: 12.%{alphatag}%{?dist}
|
||||
License: BSD-3-Clause AND BSD-2-Clause AND ISC
|
||||
URL: http://www.openbsd.org/cgi-bin/cvsweb/src/usr.bin/calendar
|
||||
|
||||
# The source archive is generated with the export-calendar-source.sh
|
||||
|
|
@ -17,9 +16,10 @@ Source0: %{name}-%{version}-%{alphatag}.tar.gz
|
|||
Source1: Makefile.linux
|
||||
Source2: export-calendar-source.sh
|
||||
|
||||
Patch0: %{name}-1.28-linux.patch
|
||||
|
||||
Patch0: %{name}-1.37-linux.patch
|
||||
|
||||
BuildRequires: gcc
|
||||
BuildRequires: make
|
||||
Requires: cpp
|
||||
|
||||
%description
|
||||
|
|
@ -30,8 +30,7 @@ tomorrow's. The output of the command shows upcoming events for the
|
|||
week.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-%{version}-%{alphatag}
|
||||
%patch0 -p1
|
||||
%autosetup -n %{name}-%{version}-%{alphatag}
|
||||
cp %{SOURCE1} Makefile
|
||||
|
||||
for c in calendars/*.*/* ; do
|
||||
|
|
@ -43,19 +42,106 @@ for c in calendars/*.*/* ; do
|
|||
done
|
||||
|
||||
%build
|
||||
make %{?_smp_mflags}
|
||||
%make_build
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
make install DESTDIR=%{buildroot}
|
||||
%make_install
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%attr(755,root,root) %{_bindir}/calendar
|
||||
%{_mandir}/man1/calendar.1.gz
|
||||
%{_datadir}/calendar
|
||||
|
||||
%changelog
|
||||
* Wed Jul 23 2025 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-12.20250303cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
|
||||
|
||||
* Mon Mar 03 2025 David Cantrell <dcantrell@redhat.com> - 1.37-11.20250303cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 7.6
|
||||
|
||||
* Thu Jan 16 2025 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-10.20240528cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
|
||||
|
||||
* Wed Jul 17 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-9.20240528cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
|
||||
|
||||
* Tue May 28 2024 David Cantrell <dcantrell@redhat.com> - 1.37-8.20240528cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 7.5
|
||||
|
||||
* Thu Mar 28 2024 Evan Goode <egoode@redhat.com> - 1.37-7.20240209cvs
|
||||
- Bump release to stay newer than Fedora 37 package
|
||||
|
||||
* Fri Feb 09 2024 David Cantrell <dcantrell@redhat.com> - 1.37-6.20240209cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 7.4
|
||||
- Use non-deprecated syntax for the %%patch macro
|
||||
|
||||
* Tue Jan 23 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-5.20221115cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-4.20221115cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-3.20221115cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||
|
||||
* Wed Jan 18 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-2.20221115cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
* Tue Nov 15 2022 David Cantrell <dcantrell@redhat.com> - 1.37-20221115cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 7.2
|
||||
- Use SPDX license expression in the License tag
|
||||
|
||||
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-7.20211220cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||
|
||||
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-6.20211220cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||
|
||||
* Mon Dec 20 2021 David Cantrell <dcantrell@redhat.com> - 1.37-20211220cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 7.0
|
||||
|
||||
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-4.20200430cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-3.20200430cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-2.20200430cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Thu Apr 30 2020 David Cantrell <dcantrell@redhat.com> - 1.37-1.20200430cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 6.6
|
||||
- Include missing calendar data files (#1809218)
|
||||
|
||||
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.37-2.20190827cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Tue Aug 27 2019 David Cantrell <dcantrell@redhat.com> - 1.37-1.20190827cvs
|
||||
- Upgrade to calendar(1) from OpenBSD 6.5
|
||||
- Correct translation filenames in Makefile.linux
|
||||
|
||||
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.35-4.20190227cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Thu Mar 07 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.35-2.20190227cvs
|
||||
- Fix downgradepath
|
||||
|
||||
* Wed Feb 27 2019 David Cantrell <dcantrell@redhat.com> - 1.35-1.20190227cvs
|
||||
- Upgrade to calendar-1.35 from OpenBSD 6.4
|
||||
- Fix path to 'cpp' in pathnames.h (#1653311)
|
||||
|
||||
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.35-2.20180719cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Thu Jul 19 2018 David Cantrell <dcantrell@redhat.com> - 1.35-1.20180719cvs
|
||||
- Upgrade to calendar-1.35 from OpenBSD 6.3
|
||||
|
||||
* Thu Jul 19 2018 David Cantrell <dcantrell@redhat.com> - 1.28-10.20140613cvs
|
||||
- BR gcc per https://fedoraproject.org/wiki/Changes/Remove_GCC_from_BuildRoot
|
||||
|
||||
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.28-9.20140613cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.28-8.20140613cvs
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
|
|
|
|||
20
export-calendar-source.sh
Normal file → Executable file
20
export-calendar-source.sh
Normal file → Executable file
|
|
@ -1,19 +1,33 @@
|
|||
#!/bin/sh
|
||||
|
||||
#TAG=HEAD
|
||||
TAG=OPENBSD_5_5
|
||||
TAG=OPENBSD_7_6
|
||||
SERVER=anoncvs4.usa.openbsd.org
|
||||
|
||||
PATH=/usr/bin
|
||||
CWD=$(pwd)
|
||||
|
||||
if ! grep "${SERVER}" ~/.ssh/config ; then
|
||||
echo "*** Configuration block for ${SERVER} not found in ~/.ssh/config" >&2
|
||||
echo "*** Make sure this block exists in ~/.ssh/config:" >&2
|
||||
echo >&2
|
||||
echo "Host ${SERVER}" >&2
|
||||
echo " Port 2022" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
CVS_RSH=ssh ; export CVS_RSH
|
||||
|
||||
rm -rf calendar calendar-${VER}
|
||||
mkdir calendar
|
||||
cvs -d anoncvs@anoncvs.ca.openbsd.org:/cvs co \
|
||||
-d calendar -r ${TAG} src/usr.bin/calendar
|
||||
cvs -d :ext:anoncvs@${SERVER}:/cvs co -d calendar -r ${TAG} src/usr.bin/calendar
|
||||
|
||||
cd calendar
|
||||
VER="$(cvs status calendar.c | grep 'Working revision:' | awk '{ print $3; }')"
|
||||
SNAPSHOT="$(date +%Y%m%d)cvs"
|
||||
cd ..
|
||||
find calendar -type d -name CVS | xargs rm -rf
|
||||
|
||||
mv calendar calendar-${VER}-${SNAPSHOT}
|
||||
tar -cvf - calendar-${VER}-${SNAPSHOT} | gzip -9c > calendar-${VER}-${SNAPSHOT}.tar.gz
|
||||
rm -rf calendar-${VER}-${SNAPSHOT}
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
016045f29b283c4267e525de6d5cc1fd calendar-1.28-20140613cvs.tar.gz
|
||||
SHA512 (calendar-1.37-20250303cvs.tar.gz) = e5f15b6c4efc11ee6c7041535ba5e8f2d0cc3ed22a3944bf2f499fabcfae9ae45290b59a564641bf0355fa402674890694054790a9ee64304a8214752b6b4edf
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue