1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-17 08:01:36 +00:00

Update to 0.1.3 and unbreak

Pass maintainership to submitter

PR:		ports/150733
Submitted by:	Davide Italiano <davide.italiano at gmail.com>
This commit is contained in:
Max Brazhnikov 2010-10-02 11:19:30 +00:00
parent f893267d12
commit 2a3f9daa49
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=262318
7 changed files with 165 additions and 12 deletions

View File

@ -6,12 +6,11 @@
#
PORTNAME= lxtask
PORTVERSION= 0.1
PORTREVISION= 4
PORTVERSION= 0.1.3
CATEGORIES= sysutils gnome
MASTER_SITES= SF/lxde/LXTask%20%28task%20manager%29/LXTask%20${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
MAINTAINER= davide.italiano@gmail.com
COMMENT= A lightweight desktop-independent task manager
USE_GNOME= gtk20 intlhack
@ -31,4 +30,7 @@ CONFIGURE_ARGS+=--disable-nls
PLIST_SUB+= NLS="@comment "
.endif
post-install:
@${ECHO_CMD} ${PKGMESSAGE}
.include <bsd.port.mk>

View File

@ -1,3 +1,3 @@
MD5 (lxtask-0.1.tar.gz) = e69b31ea8169bcf1d9b0c40c06a6e782
SHA256 (lxtask-0.1.tar.gz) = fff1303410c023a99cc8b292d27449d91268c72b862699ba930c9ed0f23e4767
SIZE (lxtask-0.1.tar.gz) = 235606
MD5 (lxtask-0.1.3.tar.gz) = eccfb69ee1a209248b22a5f0a34a4734
SHA256 (lxtask-0.1.3.tar.gz) = 6d15c7711689aaf81b90815241021e8b9950f76c316c61677bca3f8d2b929844
SIZE (lxtask-0.1.3.tar.gz) = 223543

View File

@ -0,0 +1,18 @@
--- ./src/main.c.orig 2010-04-12 13:54:32.000000000 +0400
+++ ./src/main.c 2010-09-25 23:50:53.951634770 +0400
@@ -51,7 +51,6 @@
guint refresh_interval;
guint rID;
-int PAGE_SIZE;
int main (int argc, char *argv[])
{
@@ -65,7 +64,6 @@
gtk_set_locale ();
gtk_init (&argc, &argv);
- PAGE_SIZE=sysconf(_SC_PAGESIZE)>>10;
own_uid = getuid();
config_file = g_build_filename(g_get_user_config_dir(), "lxtask.conf", NULL);

View File

@ -0,0 +1,9 @@
--- ./src/types.h.orig 2010-04-12 13:54:32.000000000 +0400
+++ ./src/types.h 2010-09-25 23:50:53.953634766 +0400
@@ -78,6 +78,4 @@
const gchar *custom_signal_0;
const gchar *custom_signal_1;
-extern int PAGE_SIZE;
-
#endif

View File

@ -0,0 +1,87 @@
--- ./src/xfce-taskmanager-linux.c.orig 2010-04-12 13:54:32.000000000 +0400
+++ ./src/xfce-taskmanager-linux.c 2010-09-25 23:50:53.956637695 +0400
@@ -28,6 +28,7 @@
#include <glib/gi18n.h>
#include "xfce-taskmanager-linux.h"
+#define PAGE_SIZE ( sysconf(_SC_PAGESIZE) )
#if 1
void get_task_details(gint pid,struct task *task)
@@ -39,7 +40,7 @@
task->checked=FALSE;
task->size=0;
- sprintf(line,"/proc/%d/statm",pid);
+ sprintf(line,"/compat/linux/proc/%d/statm",pid);
fd=open(line,O_RDONLY);
if(fd==-1) return;
read(fd,line,256);
@@ -49,7 +50,7 @@
task->size*=PAGE_SIZE;
task->rss*=PAGE_SIZE;
- sprintf(line,"/proc/%d/stat",pid);
+ sprintf(line,"/compat/linux/proc/%d/stat",pid);
fd=open(line,O_RDONLY);
if(fd!=-1)
{
@@ -118,8 +119,8 @@
gchar filename[255];
gchar cmdline_filename[255];
- sprintf(filename, "/proc/%i/stat", pid);
- sprintf(cmdline_filename, "/proc/%i/cmdline", pid);
+ sprintf(filename, "/compat/linux/proc/%i/stat", pid);
+ sprintf(cmdline_filename, "/compat/linux/proc/%i/cmdline", pid);
stat(filename, &status);
@@ -235,9 +236,9 @@
GArray *task_list;
int count=0;
- if((dir = opendir("/proc/")) == NULL)
+ if((dir = opendir("/compat/linux/proc/")) == NULL)
{
- fprintf(stderr, "Error: couldn't load the /proc directory\n");
+ fprintf(stderr, "Error: couldn't load the /compat/linux/proc directory\n");
return NULL;
}
@@ -277,7 +278,7 @@
task_list = g_array_new(FALSE, FALSE, sizeof (struct task));
- n=scandir("/proc",&namelist,proc_filter,0);
+ n=scandir("/compat/linux/proc",&namelist,proc_filter,0);
if(n<0) return task_list;
g_array_set_size(task_list,n);
@@ -299,7 +300,7 @@
gboolean get_cpu_usage_from_proc(system_status *sys_stat)
{
- const gchar *file_name = "/proc/stat";
+ const gchar *file_name = "/compat/linux/proc/stat";
FILE *file;
if ( sys_stat->valid_proc_reading == TRUE ) {
@@ -340,7 +341,7 @@
int reach;
static int cpu_count;
- file = fopen ("/proc/meminfo", "r");
+ file = fopen ("/compat/linux/proc/meminfo", "r");
if(!file) return FALSE;
reach=0;
while (fgets (buffer, 100, file) != NULL)
@@ -357,7 +358,7 @@
if(!cpu_count)
{
- file = fopen ("/proc/cpuinfo", "r");
+ file = fopen ("/compat/linux/proc/cpuinfo", "r");
if(!file) return FALSE;
while (fgets (buffer, 100, file) != NULL)
{

View File

@ -0,0 +1,4 @@
******************************************************
This ports works only if linprocfs is mounted. Ensure
that linprocfs is mounted before running.
*****************************************************

View File

@ -1,25 +1,58 @@
bin/lxtask
share/applications/lxtask.desktop
%%NLS%%share/locale/af/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ar/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/bg/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/bn_IN/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ca/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/cs/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/da/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/de/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/el/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/en_GB/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/es/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/es_VE/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/et/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/eu/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/fa/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/fi/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/fr/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/frp/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/gl/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/he/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/hr/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/hu/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/id/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/it/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ja/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/lv/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/nb_NO/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ko/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/lt/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ml/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ms/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/nb/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/nl/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/nn/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/pl/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ps/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/pt/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/pt_BR/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/pt_PT/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ru/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/sk/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/sl/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/sr/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/sv/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/tr/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/uk/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ur/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/ur_PK/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/vi/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/lxtask.mo
%%NLS%%share/locale/zh_TW/LC_MESSAGES/lxtask.mo
share/applications/lxtask.desktop
@dirrmtry share/applications
%%NLS%%@dirrmtry share/locale/ur_PK/LC_MESSAGES
%%NLS%%@dirrmtry share/locale/ur_PK
%%NLS%%@dirrmtry share/locale/nb_NO/LC_MESSAGES
%%NLS%%@dirrmtry share/locale/nb_NO
%%NLS%%@dirrmtry share/locale/frp/LC_MESSAGES
%%NLS%%@dirrmtry share/locale/frp
%%NLS%%@dirrmtry share/locale/es_VE/LC_MESSAGES
%%NLS%%@dirrmtry share/locale/es_VE
@dirrmtry share/applications