Bug#535660: heirloom-mailx: FTBFS on mips* due to reuse of weak symbol optopt

2009-07-11 Thread Luk Claes
Hilko Bengen wrote:
> Luk Claes  writes:
> 
>> Package: heirloom-mailx
>> Version: 12.4-1
>> Severity: serious
>> Tags: patch
>>
>> Dear maintainer,
>>
>> I've prepared an NMU for heirloom-mailx (versioned as 12.4-1.1), but
>> have not uploaded it yet. Please free to tell me if I should upload or
>> let you take care of it.
> 
> You may proceed. :-)

Ok, I'll upload soon.

> But I am not sure I understand the nature of this bug. Where can I read
> more about those "weak symbols" and why does the linker on mips and
> mipsel behave differently than on all other architectures?

The linker on mips* has become very strict. I'm not sure why that
happened, but luckily it's in most cases rather easy to work around.

Cheers

Luk



-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org



Bug#535660: heirloom-mailx: FTBFS on mips* due to reuse of weak symbol optopt

2009-07-06 Thread Hilko Bengen
Luk Claes  writes:

> Package: heirloom-mailx
> Version: 12.4-1
> Severity: serious
> Tags: patch
>
> Dear maintainer,
>
> I've prepared an NMU for heirloom-mailx (versioned as 12.4-1.1), but
> have not uploaded it yet. Please free to tell me if I should upload or
> let you take care of it.

You may proceed. :-)

But I am not sure I understand the nature of this bug. Where can I read
more about those "weak symbols" and why does the linker on mips and
mipsel behave differently than on all other architectures?

Cheers,
-Hilko



-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org



Bug#535660: heirloom-mailx: FTBFS on mips* due to reuse of weak symbol optopt

2009-07-04 Thread Luk Claes
Package: heirloom-mailx
Version: 12.4-1
Severity: serious
Tags: patch

Dear maintainer,

I've prepared an NMU for heirloom-mailx (versioned as 12.4-1.1), but have not
uploaded it yet. Please free to tell me if I should upload or let you take care 
of it.

Cheers

Luk
diff -u heirloom-mailx-12.4/debian/changelog heirloom-mailx-12.4/debian/changelog
--- heirloom-mailx-12.4/debian/changelog
+++ heirloom-mailx-12.4/debian/changelog
@@ -1,3 +1,10 @@
+heirloom-mailx (12.4-1.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Don't reuse weak symbol optopt to fix FTBFS on mips* 
+
+ -- Luk Claes   Sat, 04 Jul 2009 10:54:53 +0200
+
 heirloom-mailx (12.4-1) unstable; urgency=low
 
   * New upstream version
only in patch2:
unchanged:
--- heirloom-mailx-12.4.orig/getopt.c
+++ heirloom-mailx-12.4/getopt.c
@@ -43,7 +43,7 @@
 char	*optarg;
 int	optind = 1;
 int	opterr = 1;
-int	optopt;
+int	optoptc;
 
 static void
 error(const char *s, int c)
@@ -69,7 +69,7 @@
 		*bp++ = *s++;
 	while (*msg)
 		*bp++ = *msg++;
-	*bp++ = optopt;
+	*bp++ = optoptc;
 	*bp++ = '\n';
 	write(2, buf, bp - buf);
 	ac_free(buf);
@@ -101,13 +101,13 @@
 		}
 		curp = &argv[optind][1];
 	}
-	optopt = curp[0] & 0377;
+	optoptc = curp[0] & 0377;
 	while (optstring[0]) {
 		if (optstring[0] == ':') {
 			optstring++;
 			continue;
 		}
-		if ((optstring[0] & 0377) == optopt) {
+		if ((optstring[0] & 0377) == optoptc) {
 			if (optstring[1] == ':') {
 if (curp[1] != '\0') {
 	optarg = (char *)&curp[1];
@@ -127,7 +127,7 @@
 	optind++;
 optarg = 0;
 			}
-			return optopt;
+			return optoptc;
 		}
 		optstring++;
 	}