htop-home_etc.patch

romke romke at estrefa.pl
Wed Jun 8 05:06:01 CEST 2005


jak w temacie, proszę o dodanie

pozdr
-- 
romke Roman Barczyński  ~~~~  tel. +48 12 632 7365  ~~~~  www.romke.info
____________________________________________ JID/email: romke at estrefa.pl
-------------- next part --------------
--- htop.spec~	2005-05-16 22:27:35.000000000 +0200
+++ htop.spec	2005-06-08 04:55:06.000000000 +0200
@@ -3,11 +3,12 @@
 Summary(pl):	Interaktywna przeglądarka procesów
 Name:		htop
 Version:	0.5.2
-Release:	1
+Release:	2
 License:	GPL
 Group:		Applications/System
 Source0:	http://dl.sourceforge.net/htop/%{name}-%{version}.tar.gz
 # Source0-md5:	e1a3f03971a3868315c4c1f92aee9b7f
+Patch0:		%{name}-home_etc.patch
 URL:		http://htop.sourceforge.net/
 BuildRequires:	ncurses-devel
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -22,6 +23,7 @@
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %configure
-------------- next part --------------
--- htop-0.5.2/Settings.c~	2005-04-09 00:41:32.000000000 +0200
+++ htop-0.5.2/Settings.c	2005-06-08 04:42:24.000000000 +0200
@@ -29,7 +29,9 @@
    // TODO: how to get SYSCONFDIR correctly through Autoconf?
    // char* systemSettings = String_cat(SYSCONFDIR, "/htoprc");
    // Settings_read(this, systemSettings);
-   char* home = getenv("HOME");
+   char* home;
+   home = getenv("HOME_ETC");
+   if (!home) home = getenv("HOME");
    this->userSettings = String_cat(home, "/.htoprc");
    Settings_read(this, this->userSettings);
    // free(systemSettings);


More information about the pld-devel-pl mailing list