undefined reference to `__builtin_stdarg_start'

Bug #381215 reported by Thorsten Glaser
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
dietlibc (Debian)
Fix Released
Unknown
dietlibc (Ubuntu)
Fix Released
Undecided
Unassigned
Nominated for Karmic by Thorsten Glaser
mksh (Ubuntu)
Fix Released
Undecided
Unassigned
Nominated for Karmic by Thorsten Glaser

Bug Description

Breakage with gcc 4.4:

tglase@tglase:~$ gcc test.c
tglase@tglase:~$ ./a.out
'./a.out' called with 1 args
tglase@tglase:~$ rm a.out
tglase@tglase:~$ diet gcc test.c
/usr/lib/diet/lib-i386/libc.a(vprintf.o): In function `vprintf':
vprintf.c:(.text+0x20): warning: warning: the printf functions add several kilobytes of bloat.
/tmp/cccpAo38.o: In function `printfoo':
test.c:(.text+0x14): undefined reference to `__builtin_stdarg_start'
collect2: ld returned 1 exit status
tglase@tglase:~$ cat test.c
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>

void printfoo(const char *, ...);

void
printfoo(const char *fmt, ...)
{
        va_list va;

        va_start(va, fmt);
        if (vprintf(fmt, va) < 0)
                abort();
        va_end(va);
}

int
main(int argc, char *argv[])
{
        printfoo("'%s' called with %d args\n", argv[0], argc);
}

Tags: patch

Related branches

Revision history for this message
Thorsten Glaser (mirabilos) wrote :

The attached debdiff fixes this problem and allows mksh to build again.

I suggest to forward it upstream to both Debian and Fefe though.

tags: added: patch
Revision history for this message
Thorsten Glaser (mirabilos) wrote :
Changed in mksh (Ubuntu):
status: New → Confirmed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package dietlibc - 0.31-1.2ubuntu2

---------------
dietlibc (0.31-1.2ubuntu2) karmic; urgency=low

  * Add 0901-fix-stdarg-gcc44.diff (LP: #381215)

 -- Thorsten Glaser <email address hidden> Thu, 28 May 2009 08:57:17 +0000

Changed in dietlibc (Ubuntu):
status: New → Fix Released
Revision history for this message
Thorsten Glaser (mirabilos) wrote :

Hi again,

I already sent a mail to the dietlibc mailing list regarding
this problem.

bye,
//mirabilos
--
Sometimes they [people] care too much: pretty printers [and syntax highligh-
ting, d.A.] mechanically produce pretty output that accentuates irrelevant
detail in the program, which is as sensible as putting all the prepositions
in English text in bold font. -- Rob Pike in "Notes on Programming in C"

Revision history for this message
Thorsten Glaser (mirabilos) wrote :

This bug was fixed in the package mksh - 38.1-1ubuntu1

Changed in mksh (Ubuntu):
status: Confirmed → Fix Released
Changed in dietlibc (Debian):
status: Unknown → New
Revision history for this message
Thorsten Glaser (mirabilos) wrote :

From discussion with Fefe:

----------------------------
revision 1.12
date: 2008-11-26 18:43:06 +0000; author: leitner; state: Exp; lines: +1 -1
add %Z to strptime, make stdarg work with gcc 4.4
----------------------------

I told him though that __builtin_stdarg_start is needed for
supporting gcc2 and older gcc3 versions. Anyway, this is fixed
upstream (and Fefe sounded surprised that Debian did not package
the CVS development versions of diet libc but releases).

bye,
//mirabilos
--
> emacs als auch vi zum Kotzen finde (joe rules) und pine für den einzig
> bedienbaren textmode-mailclient halte (und ich hab sie alle ausprobiert). ;)
Hallooooo, ich bin der Holger ("Hallo Holger!"), und ich bin ebenfalls
... pine-User, und das auch noch gewohnheitsmäßig ("Oooooooohhh"). [aus dasr]

Changed in dietlibc (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.