mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-01 05:45:45 +00:00
`xloadface' is a network load monitor for X11. This program use the rwhod
database for display `user' and `CPU load'. It displays a face for each machine gotten from rwho. Quite cute. The README and manpage are in Japanese. Closes-PR: ports/2115 Submitted by: furusawa@com.cs.osakafu-u.ac.jp
This commit is contained in:
parent
a5553bdbb5
commit
a236bfc478
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=4784
33
sysutils/xloadface/Makefile
Normal file
33
sysutils/xloadface/Makefile
Normal file
@ -0,0 +1,33 @@
|
||||
# New ports collection makefile for: xloadface
|
||||
# Version required: 1.6.1
|
||||
# Date created: 28 November 1996
|
||||
# Whom: FURUSAWA,Kazuhisa <furusawa@com.cs.osakafu-u.ac.jp>
|
||||
#
|
||||
# $Id: Makefile,v 1.1.1.1 1996/12/03 13:21:31 obrien Exp $
|
||||
#
|
||||
|
||||
DISTNAME= xloadface-1.6.1
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= ftp://ftp.waseda.ac.jp/pub/X11others/
|
||||
|
||||
MAINTAINER= furusawa@com.cs.osakafu-u.ac.jp
|
||||
|
||||
BUILD_DEPENDS= nkf:${PORTSDIR}/japanese/nkf
|
||||
|
||||
PATCH_STRIP= -p1
|
||||
USE_IMAKE= yes
|
||||
XLOADFACEDIR= $(X11BASE)/lib/X11/xloadface
|
||||
|
||||
pre-install:
|
||||
@nkf -e ${WRKSRC}/xloadface.1 > ${WRKSRC}/xloadface.man
|
||||
${MKDIR} $(XLOADFACEDIR)
|
||||
${INSTALL_DATA} ${WRKSRC}/README $(XLOADFACEDIR)
|
||||
${INSTALL_DATA} ${WRKSRC}/host_org.sample $(XLOADFACEDIR)
|
||||
${MKDIR} $(XLOADFACEDIR)/bigfaces
|
||||
${MKDIR} $(XLOADFACEDIR)/bitmap
|
||||
${MKDIR} $(XLOADFACEDIR)/catfaces
|
||||
${INSTALL_DATA} ${WRKSRC}/bigfaces/* $(XLOADFACEDIR)/bigfaces
|
||||
${INSTALL_DATA} ${WRKSRC}/bitmap/* $(XLOADFACEDIR)/bitmap
|
||||
${INSTALL_DATA} ${WRKSRC}/catfaces/* $(XLOADFACEDIR)/catfaces
|
||||
|
||||
.include <bsd.port.mk>
|
1
sysutils/xloadface/distinfo
Normal file
1
sysutils/xloadface/distinfo
Normal file
@ -0,0 +1 @@
|
||||
MD5 (xloadface-1.6.1.tar.gz) = 713905ddc339e09f485967b12dd3c23b
|
324
sysutils/xloadface/files/patch-01
Normal file
324
sysutils/xloadface/files/patch-01
Normal file
@ -0,0 +1,324 @@
|
||||
diff -cr xloadface-1.6.1.org/ArrangeBox.c xloadface-1.6.1/ArrangeBox.c
|
||||
*** xloadface-1.6.1.org/ArrangeBox.c Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/ArrangeBox.c Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 69,75 ****
|
||||
},
|
||||
{
|
||||
/* box_class fields */
|
||||
! /* empty */ NULL,
|
||||
},
|
||||
{
|
||||
/* ArrangeBox class fields */
|
||||
--- 69,75 ----
|
||||
},
|
||||
{
|
||||
/* box_class fields */
|
||||
! /* empty */ 0,
|
||||
},
|
||||
{
|
||||
/* ArrangeBox class fields */
|
||||
***************
|
||||
*** 194,201 ****
|
||||
w->core.parent->core.border_width);
|
||||
XtResizeWindow(w->core.parent);
|
||||
}
|
||||
! XtResizeWidget(w,width,height,w->core.border_width);
|
||||
! XtResizeWindow(w);
|
||||
}
|
||||
}
|
||||
|
||||
--- 194,201 ----
|
||||
w->core.parent->core.border_width);
|
||||
XtResizeWindow(w->core.parent);
|
||||
}
|
||||
! XtResizeWidget((Widget)w,width,height,w->core.border_width);
|
||||
! XtResizeWindow((Widget)w);
|
||||
}
|
||||
}
|
||||
|
||||
***************
|
||||
*** 203,217 ****
|
||||
* Insert child method
|
||||
*/
|
||||
static void
|
||||
! InsertChild(w,arg,num_args)
|
||||
Widget w;
|
||||
- ArgList arg;
|
||||
- Cardinal *num_args;
|
||||
{
|
||||
ArrangeBoxWidget ab;
|
||||
|
||||
ab = (ArrangeBoxWidget)w->core.parent;
|
||||
! (*((CompositeClassRec*)XtSuperclass(ab))->composite_class.insert_child)(w,arg,num_args);
|
||||
RearrangeSize(ab);
|
||||
}
|
||||
|
||||
--- 203,215 ----
|
||||
* Insert child method
|
||||
*/
|
||||
static void
|
||||
! InsertChild(w)
|
||||
Widget w;
|
||||
{
|
||||
ArrangeBoxWidget ab;
|
||||
|
||||
ab = (ArrangeBoxWidget)w->core.parent;
|
||||
! (*((CompositeClassRec*)XtSuperclass(ab))->composite_class.insert_child)(w);
|
||||
RearrangeSize(ab);
|
||||
}
|
||||
|
||||
diff -cr xloadface-1.6.1.org/Imakefile xloadface-1.6.1/Imakefile
|
||||
*** xloadface-1.6.1.org/Imakefile Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/Imakefile Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 11,14 ****
|
||||
SYS_LIBRARIES = -lm
|
||||
|
||||
ComplexProgramTarget(xloadface)
|
||||
- InstallManPage(xloadface.1,$(MANDIR)/xalive.n)
|
||||
--- 11,13 ----
|
||||
diff -cr xloadface-1.6.1.org/LabeledPicture.c xloadface-1.6.1/LabeledPicture.c
|
||||
*** xloadface-1.6.1.org/LabeledPicture.c Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/LabeledPicture.c Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 153,159 ****
|
||||
Window rootwin;
|
||||
|
||||
lp->label_width = XTextWidth(lp->font,lp->label,strlen(lp->label));
|
||||
! if (lp->pixmap != NULL && lp->pixmap != AiNullPixmap) {
|
||||
XGetGeometry(XtDisplay(w),lp->pixmap,
|
||||
&rootwin,
|
||||
&x,
|
||||
--- 153,159 ----
|
||||
Window rootwin;
|
||||
|
||||
lp->label_width = XTextWidth(lp->font,lp->label,strlen(lp->label));
|
||||
! if (lp->pixmap != 0 && lp->pixmap != AiNullPixmap) {
|
||||
XGetGeometry(XtDisplay(w),lp->pixmap,
|
||||
&rootwin,
|
||||
&x,
|
||||
***************
|
||||
*** 355,361 ****
|
||||
{
|
||||
UnSelectIt(w);
|
||||
if (w->labeled_picture.sensitive) {
|
||||
! XtCallCallbacks(w, AiNcallback, (caddr_t)event);
|
||||
}
|
||||
}
|
||||
|
||||
--- 355,361 ----
|
||||
{
|
||||
UnSelectIt(w);
|
||||
if (w->labeled_picture.sensitive) {
|
||||
! XtCallCallbacks((Widget)w, AiNcallback, (caddr_t)event);
|
||||
}
|
||||
}
|
||||
|
||||
***************
|
||||
*** 391,397 ****
|
||||
AdjustSize(w,True);
|
||||
|
||||
if (width != w->core.width || height != w->core.height) {
|
||||
! XtResizeWidget(w,
|
||||
w->core.width,
|
||||
w->core.height,
|
||||
w->core.border_width);
|
||||
--- 391,397 ----
|
||||
AdjustSize(w,True);
|
||||
|
||||
if (width != w->core.width || height != w->core.height) {
|
||||
! XtResizeWidget((Widget)w,
|
||||
w->core.width,
|
||||
w->core.height,
|
||||
w->core.border_width);
|
||||
diff -cr xloadface-1.6.1.org/LoadFace.c xloadface-1.6.1/LoadFace.c
|
||||
*** xloadface-1.6.1.org/LoadFace.c Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/LoadFace.c Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 2,7 ****
|
||||
--- 2,8 ----
|
||||
#include <X11/StringDefs.h>
|
||||
#include "LoadFaceP.h"
|
||||
#include <stdio.h>
|
||||
+ #include <stdlib.h>
|
||||
#include <sys/types.h>
|
||||
#include <netinet/in.h>
|
||||
#include <math.h>
|
||||
***************
|
||||
*** 166,172 ****
|
||||
{
|
||||
LoadFaceWidget w = (LoadFaceWidget)new;
|
||||
|
||||
! CALL_SUPER(w,expose,(new));
|
||||
}
|
||||
|
||||
#define HERE(w,tag) (w)->core_class.tag
|
||||
--- 167,173 ----
|
||||
{
|
||||
LoadFaceWidget w = (LoadFaceWidget)new;
|
||||
|
||||
! CALL_SUPER(w,expose,(new,NULL,NULL));
|
||||
}
|
||||
|
||||
#define HERE(w,tag) (w)->core_class.tag
|
||||
***************
|
||||
*** 208,221 ****
|
||||
picture = class->faces_data[0].pixmap;
|
||||
}
|
||||
AiChangePixmap(w,picture,False,True);
|
||||
! CALL_SUPER(new,initialize,(request,new));
|
||||
if (w->load_face.interval > 0) {
|
||||
if (w->load_face.shuffle)
|
||||
firstInterval = random()%(w->load_face.interval*2000);
|
||||
else
|
||||
firstInterval = w->load_face.interval*1000;
|
||||
w->load_face.interval_id =
|
||||
! XtAppAddTimeOut(XtWidgetToApplicationContext(w),
|
||||
firstInterval,
|
||||
updateLoad,
|
||||
(caddr_t)w);
|
||||
--- 209,222 ----
|
||||
picture = class->faces_data[0].pixmap;
|
||||
}
|
||||
AiChangePixmap(w,picture,False,True);
|
||||
! CALL_SUPER(new,initialize,(request,new,NULL,NULL));
|
||||
if (w->load_face.interval > 0) {
|
||||
if (w->load_face.shuffle)
|
||||
firstInterval = random()%(w->load_face.interval*2000);
|
||||
else
|
||||
firstInterval = w->load_face.interval*1000;
|
||||
w->load_face.interval_id =
|
||||
! XtAppAddTimeOut(XtWidgetToApplicationContext((Widget)w),
|
||||
firstInterval,
|
||||
updateLoad,
|
||||
(caddr_t)w);
|
||||
***************
|
||||
*** 262,268 ****
|
||||
wd.wd_sendtime = wd.wd_recvtime = 0;
|
||||
AiChangeLoad(w,&wd);
|
||||
w->load_face.interval_id =
|
||||
! XtAppAddTimeOut(XtWidgetToApplicationContext(w),
|
||||
w->load_face.interval*1000,
|
||||
updateLoad,
|
||||
(caddr_t)w);
|
||||
--- 263,269 ----
|
||||
wd.wd_sendtime = wd.wd_recvtime = 0;
|
||||
AiChangeLoad(w,&wd);
|
||||
w->load_face.interval_id =
|
||||
! XtAppAddTimeOut(XtWidgetToApplicationContext((Widget)w),
|
||||
w->load_face.interval*1000,
|
||||
updateLoad,
|
||||
(caddr_t)w);
|
||||
***************
|
||||
*** 290,297 ****
|
||||
newFace = FACE(w,newload);
|
||||
AiChangePixmap(w,newFace->pixmap,False,False);
|
||||
|
||||
! if (XtIsRealized(w) && oldload != newload)
|
||||
! CALL_SELF(w, expose, (w));
|
||||
}
|
||||
|
||||
static void
|
||||
--- 291,298 ----
|
||||
newFace = FACE(w,newload);
|
||||
AiChangePixmap(w,newFace->pixmap,False,False);
|
||||
|
||||
! if (XtIsRealized((Widget)w) && oldload != newload)
|
||||
! CALL_SELF(w, expose, (w,NULL,NULL));
|
||||
}
|
||||
|
||||
static void
|
||||
diff -cr xloadface-1.6.1.org/MachineInfo.c xloadface-1.6.1/MachineInfo.c
|
||||
*** xloadface-1.6.1.org/MachineInfo.c Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/MachineInfo.c Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 295,299 ****
|
||||
LINE_SKIP(w->machine_info.title_font)+
|
||||
LINE_SKIP(w->machine_info.load_info_font)*3+
|
||||
LINE_SKIP(w->machine_info.user_info_font)*nusers(wd);
|
||||
! XtResizeWidget(w, w->core.width, h, w->core.border_width);
|
||||
}
|
||||
--- 295,299 ----
|
||||
LINE_SKIP(w->machine_info.title_font)+
|
||||
LINE_SKIP(w->machine_info.load_info_font)*3+
|
||||
LINE_SKIP(w->machine_info.user_info_font)*nusers(wd);
|
||||
! XtResizeWidget((Widget)w, w->core.width, h, w->core.border_width);
|
||||
}
|
||||
diff -cr xloadface-1.6.1.org/alive.h xloadface-1.6.1/alive.h
|
||||
*** xloadface-1.6.1.org/alive.h Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/alive.h Thu Nov 28 11:27:09 1996
|
||||
***************
|
||||
*** 31,37 ****
|
||||
#define SSIZE sizeof(u_short)
|
||||
#define LSIZE sizeof(u_long)
|
||||
|
||||
! #define SPOOLDIR "/usr/spool/rwho"
|
||||
#define ORGAN_FILE "/etc/host_org"
|
||||
|
||||
typedef char bool;
|
||||
--- 31,37 ----
|
||||
#define SSIZE sizeof(u_short)
|
||||
#define LSIZE sizeof(u_long)
|
||||
|
||||
! #define SPOOLDIR "/var/rwho"
|
||||
#define ORGAN_FILE "/etc/host_org"
|
||||
|
||||
typedef char bool;
|
||||
diff -cr xloadface-1.6.1.org/widgets.c xloadface-1.6.1/widgets.c
|
||||
*** xloadface-1.6.1.org/widgets.c Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/widgets.c Thu Nov 28 11:26:32 1996
|
||||
***************
|
||||
*** 224,230 ****
|
||||
|
||||
/***** Popup Info *****/
|
||||
PopupInfo = XtCreatePopupShell("PopupInfo",transientShellWidgetClass,
|
||||
! Toplevel,NULL,NULL);
|
||||
PopupPane = mkWidget("InfoPane",arrangeBoxWidgetClass,PopupInfo,
|
||||
AiNvertNum, 1,
|
||||
AiNresizeParent, True,
|
||||
--- 224,230 ----
|
||||
|
||||
/***** Popup Info *****/
|
||||
PopupInfo = XtCreatePopupShell("PopupInfo",transientShellWidgetClass,
|
||||
! Toplevel,NULL,0);
|
||||
PopupPane = mkWidget("InfoPane",arrangeBoxWidgetClass,PopupInfo,
|
||||
AiNvertNum, 1,
|
||||
AiNresizeParent, True,
|
||||
***************
|
||||
*** 236,242 ****
|
||||
|
||||
/***** Popup Help *****/
|
||||
helpScreen = XtCreatePopupShell("Help",transientShellWidgetClass,
|
||||
! Toplevel,NULL,NULL);
|
||||
|
||||
addFaces();
|
||||
adjustWindowSize();
|
||||
--- 236,242 ----
|
||||
|
||||
/***** Popup Help *****/
|
||||
helpScreen = XtCreatePopupShell("Help",transientShellWidgetClass,
|
||||
! Toplevel,NULL,0);
|
||||
|
||||
addFaces();
|
||||
adjustWindowSize();
|
||||
diff -cr xloadface-1.6.1.org/xloadface.1 xloadface-1.6.1/xloadface.1
|
||||
*** xloadface-1.6.1.org/xloadface.1 Tue Oct 29 23:39:53 1996
|
||||
--- xloadface-1.6.1/xloadface.1 Thu Nov 28 11:26:51 1996
|
||||
***************
|
||||
*** 104,110 ****
|
||||
$@%0%k!<%WL>$r>JN,$7$?>l9g$K$O$3$N%0%k!<%W$,I=<($5$l$k!%(J
|
||||
.SH FILES
|
||||
.TP
|
||||
! .IR /usr/spool/rwho/whod.* $@3F%[%9%H$N>pJs(J
|
||||
.TP
|
||||
.IR /etc/host_org $@%0%k!<%W5-=R%U%!%$%k(J
|
||||
.SH RELATED INFORMATION
|
||||
--- 104,110 ----
|
||||
$@%0%k!<%WL>$r>JN,$7$?>l9g$K$O$3$N%0%k!<%W$,I=<($5$l$k!%(J
|
||||
.SH FILES
|
||||
.TP
|
||||
! .IR /var/rwho/whod.* $@3F%[%9%H$N>pJs(J
|
||||
.TP
|
||||
.IR /etc/host_org $@%0%k!<%W5-=R%U%!%$%k(J
|
||||
.SH RELATED INFORMATION
|
1
sysutils/xloadface/pkg-comment
Normal file
1
sysutils/xloadface/pkg-comment
Normal file
@ -0,0 +1 @@
|
||||
network load monitor for X11
|
8
sysutils/xloadface/pkg-descr
Normal file
8
sysutils/xloadface/pkg-descr
Normal file
@ -0,0 +1,8 @@
|
||||
`xloadface' is a network load monitor for X11. This program use the rwhod
|
||||
database for display `user' and `CPU load'.
|
||||
|
||||
See README and man page for details. The man page and README are only in
|
||||
Japanese for now, but it is easy to use none the less..
|
||||
|
||||
Orignal xloadface written by aito@rcais.tohoku.ac.jp.
|
||||
This port is done by furusawa@com.cs.osakafu-u.ac.jp.
|
26
sysutils/xloadface/pkg-plist
Normal file
26
sysutils/xloadface/pkg-plist
Normal file
@ -0,0 +1,26 @@
|
||||
bin/xloadface
|
||||
man/man1/xloadface.1.gz
|
||||
lib/X11/xloadface/README
|
||||
lib/X11/xloadface/host_org.sample
|
||||
lib/X11/xloadface/bigfaces/busy.icon
|
||||
lib/X11/xloadface/bigfaces/crazy.icon
|
||||
lib/X11/xloadface/bigfaces/down.icon
|
||||
lib/X11/xloadface/bigfaces/fever.icon
|
||||
lib/X11/xloadface/bigfaces/heavy.icon
|
||||
lib/X11/xloadface/bigfaces/idle.icon
|
||||
lib/X11/xloadface/bigfaces/run.icon
|
||||
lib/X11/xloadface/bitmap/busy.icon
|
||||
lib/X11/xloadface/bitmap/crazy.icon
|
||||
lib/X11/xloadface/bitmap/down.icon
|
||||
lib/X11/xloadface/bitmap/fever.icon
|
||||
lib/X11/xloadface/bitmap/heavy.icon
|
||||
lib/X11/xloadface/bitmap/icon.icon
|
||||
lib/X11/xloadface/bitmap/idle.icon
|
||||
lib/X11/xloadface/bitmap/run.icon
|
||||
lib/X11/xloadface/catfaces/busy.icon
|
||||
lib/X11/xloadface/catfaces/crazy.icon
|
||||
lib/X11/xloadface/catfaces/down.icon
|
||||
lib/X11/xloadface/catfaces/fever.icon
|
||||
lib/X11/xloadface/catfaces/heavy.icon
|
||||
lib/X11/xloadface/catfaces/idle.icon
|
||||
lib/X11/xloadface/catfaces/run.icon
|
Loading…
Reference in New Issue
Block a user