[bug #16762] Cannot compile mc-2006-06-05-20

2006-06-07 Thread yaroslav

Follow-up Comment #2, bug #16762 (project mc):

 Does this fix your issue?
No :(


___

Reply to this item at:

  http://savannah.gnu.org/bugs/?func=detailitemitem_id=16762

___
  Message sent via/by Savannah
  http://savannah.gnu.org/

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


[bug #16762] Cannot compile mc-2006-06-05-20

2006-06-07 Thread Pavel Tsekov

Follow-up Comment #3, bug #16762 (project mc):

The real problem here is that noone sets HAVE_STRUCT_STATFS_F_FSTYPENAME.
I.e. there is no test
at configure time which sets this. Before Leonard's changes
to configure there was a test which used to set HAVE_F_FSTYPENAME. 

#if defined(HAVE_STATVFS)
#  if defined(HAVE_STRUCT_STATVFS_F_FSTYPENAME)
#define HAVE_F_FSTYPENAME
#  endif
#else
#  if defined(HAVE_STRUCT_STATFS_F_FSTYPENAME)
#define HAVE_F_FSTYPENAME
#  endif
#endif

So what happens is that on FreeBSD we take the second branch and since
HAVE_F_FSTYPENAME is not set the fstype_to_string() routine is compiled in.
Apparently MOUNT_UFS is not available on FreeBSD
and the build fails.



___

Reply to this item at:

  http://savannah.gnu.org/bugs/?func=detailitemitem_id=16762

___
  Message sent via/by Savannah
  http://savannah.gnu.org/

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


[bug #16762] Cannot compile mc-2006-06-05-20

2006-06-07 Thread Pavel Tsekov

Follow-up Comment #4, bug #16762 (project mc):

In fact in the past the code used to check whether MOUNT_UFS was defined but
the check was removed later and the code assumed the 
availability of MOUNT_UFS for granted:

http://cvs.savannah.gnu.org/viewcvs/mc/mc/src/mountlist.c?sortby=dater2=1.5r1=1.4diff_format=u

In my opinion  this issue should be handled carefully.

___

Reply to this item at:

  http://savannah.gnu.org/bugs/?func=detailitemitem_id=16762

___
  Message sent via/by Savannah
  http://savannah.gnu.org/

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


Re: utf8 patch for mc, slang 2 version

2006-06-07 Thread Vladimir Nadvornik
On Saturday 12 November 2005 20:59, Leonard den Ottolander wrote:
 Hi Bart, list,

 On Tue, 2005-09-20 at 08:14 +1200, Bart Oldeman wrote:
  Basically you'd need to apply Fedora's patch, and then (sorry no proper
  patch here but it's not a big deal)

 Attached you'll find a proper patch. I've moved the hunk from global.h
 to myslang.h (and dropped the inclusion of slang.h as it is redundant).

 Jindrich, please merge this patch with the UTF8 patch. You might even
 consider to build the next mc for FC --with-screen=mcslang, as I see the
 FC development tree does not yet feature slang-2.

Hi all,

In non-UTF-8 mode slang2 behaves a bit different than the patched slang1.
As a result, mc does work with 8bit encodings, like 8859-2 or KOI8.
The attached patch fixes the SLsmg_write_nwchars() function to be fully
compatible with the slang1 version and uses it consistently instead of
SLsmg_write_char(). It should be applied on top of all the previous patches.


-- 
Vladimir Nadvornik
developer
-  
SuSE CR, s.r.o. e-mail: [EMAIL PROTECTED]
Drahobejlova 27 tel:+420 2 9654 2373 
190 00 Praha 9  fax:+420 2 9654 2374   
Ceska republika http://www.suse.cz
diff -ruN mc-4.6.1.orig/edit/editdraw.c mc-4.6.1/edit/editdraw.c
--- mc-4.6.1.orig/edit/editdraw.c	2006-06-07 11:57:19.0 +0200
+++ mc-4.6.1/edit/editdraw.c	2006-06-07 11:56:30.0 +0200
@@ -234,7 +234,7 @@
 	lowlevel_set_color (color);
 	}
 #ifdef UTF8
-	SLsmg_write_char(textchar);
+	SLsmg_write_nwchars(textchar, 1);
 #else
 	addch (textchar);
 #endif
diff -ruN mc-4.6.1.orig/src/help.c mc-4.6.1/src/help.c
--- mc-4.6.1.orig/src/help.c	2006-06-07 11:57:19.0 +0200
+++ mc-4.6.1/src/help.c	2006-06-07 11:56:30.0 +0200
@@ -461,7 +461,7 @@
 		len = mbrtowc(wc, p, MB_CUR_MAX, mbs);
 		if (len = 0) len = 1; /* skip broken multibyte chars */
 
-	SLsmg_write_char(wc);
+	SLsmg_write_nwchars(wc, 1);
 		p += len - 1;
 		} else
 #endif
diff -ruN mc-4.6.1.orig/src/util.c mc-4.6.1/src/util.c
--- mc-4.6.1.orig/src/util.c	2006-06-07 11:57:19.0 +0200
+++ mc-4.6.1/src/util.c	2006-06-07 11:56:30.0 +0200
@@ -58,8 +58,26 @@
 #if SLANG_VERSION = 2
 void SLsmg_write_nwchars(wchar_t *s, size_t n)
 {
-  while(n--)
-  SLsmg_write_char(*s++);
+if (SLsmg_is_utf8_mode()) { /* slang can handle it directly */
+	while(n--  *s)
+	SLsmg_write_char(*s++);
+}
+else { /* convert wchars back to 8bit encoding */
+mbstate_t mbs;
+	memset (mbs, 0, sizeof (mbs));
+	while (n--  *s) {
+	char buf[MB_LEN_MAX + 1]; /* should use 1 char, but to be sure */
+	if (*s  0x80) {
+		SLsmg_write_char(*s++); /* ASCII */
+	}
+	else {
+		if (wcrtomb(buf, *s++, mbs) == 1)
+		SLsmg_write_char((wchar_t)(buf[0]));
+		else
+		SLsmg_write_char('?'); /* should not happen */
+	}
+	} 
+}
 }
 #endif
 
diff -ruN mc-4.6.1.orig/src/view.c mc-4.6.1/src/view.c
--- mc-4.6.1.orig/src/view.c	2006-06-07 11:57:19.0 +0200
+++ mc-4.6.1/src/view.c	2006-06-07 11:56:30.0 +0200
@@ -852,7 +852,7 @@
 #ifndef UTF8
 #define view_add_character(view,c) addch (c)
 #else /* UTF8 */
-#define view_add_character(view,c) SLsmg_write_char(c)
+#define view_add_character(view,c) {wchar_t tmp=c; SLsmg_write_nwchars(tmp, 1);}
 #endif /* UTF8 */
 #define view_add_one_vline()   one_vline()
 #define view_add_string(view,s)addstr (s)
___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


[bug #16762] Cannot compile mc-2006-06-05-20

2006-06-07 Thread Pavel Tsekov

Update of bug #16762 (project mc):

 Assigned to:None = ptsekov

___

Follow-up Comment #5:

I'll fix this.

___

Reply to this item at:

  http://savannah.gnu.org/bugs/?func=detailitemitem_id=16762

___
  Message sent via/by Savannah
  http://savannah.gnu.org/

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


mc bug

2006-06-07 Thread Adel Gabr
Dear Sir,
I have installed Suse in my machine,when I try to use  Midnight Commander 
4.6.0 using the command 'mc' is not working.But if I use mc -x it is working. 
The output of `mc -V'is :-
master:/rhome mc -V
GNU Midnight Commander 4.6.0
Virtual File System: tarfs, extfs, cpiofs, ftpfs, fish
With builtin Editor
Using system-installed S-Lang library with terminfo database
With subshell support as default
With support for background operations
With mouse support on xterm and Linux console
With support for X11 events
With internationalization support
With multiple codepages support

Please advise and send me the good way to reinstall th mc again.
Best regards
Adel

--
Open WebMail Project (http://openwebmail.org)

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


Re: utf8 patch for mc, slang 2 version

2006-06-07 Thread Jindrich Novy
Hi,

On Wed, 2006-06-07 at 12:18 +0200, Vladimir Nadvornik wrote:
 On Saturday 12 November 2005 20:59, Leonard den Ottolander wrote:
  Hi Bart, list,
 
  On Tue, 2005-09-20 at 08:14 +1200, Bart Oldeman wrote:
   Basically you'd need to apply Fedora's patch, and then (sorry no proper
   patch here but it's not a big deal)
 
  Attached you'll find a proper patch. I've moved the hunk from global.h
  to myslang.h (and dropped the inclusion of slang.h as it is redundant).
 
  Jindrich, please merge this patch with the UTF8 patch. You might even
  consider to build the next mc for FC --with-screen=mcslang, as I see the
  FC development tree does not yet feature slang-2.
 

slang-2.0.5 is used since FC5 so only FC4 now uses the old slang-1.4.9.

 Hi all,
 
 In non-UTF-8 mode slang2 behaves a bit different than the patched slang1.
 As a result, mc does work with 8bit encodings, like 8859-2 or KOI8.
 The attached patch fixes the SLsmg_write_nwchars() function to be fully
 compatible with the slang1 version and uses it consistently instead of
 SLsmg_write_char(). It should be applied on top of all the previous patches.

Thanks for the patch. The last hunk didn't apply as there's no
view_add_character used in editdraw.c.

Jindrich

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


[bug #16762] Cannot compile mc-2006-06-05-20

2006-06-07 Thread Pavel Tsekov

Follow-up Comment #6, bug #16762 (project mc):

Hello yaroslav,

Fetch the latest CVS version of MC and apply the attached patch. Let us know
wheter it fixes your problem or not.
___

Additional Item Attachment:

File name: getmntinfo-fix.patch   Size:3 KB

http://savannah.gnu.org/bugs/download.php?file_id=10138

___

Reply to this item at:

  http://savannah.gnu.org/bugs/?func=detailitemitem_id=16762

___
  Message sent via/by Savannah
  http://savannah.gnu.org/

___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel


Re: FTP: Cannot change to write-only directory

2006-06-07 Thread Leonard den Ottolander
Hi,

On Tue, 2006-06-06 at 22:14 +0200, Leonard den Ottolander wrote:
 https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=194277

False alarm. The issue seems to be recently fixed.

Leonard.

-- 
mount -t life -o ro /dev/dna /genetic/research


___
Mc-devel mailing list
http://mail.gnome.org/mailman/listinfo/mc-devel