[DragonFlyBSD - Bug #1710] (Closed) gcc 4.1.2 on x86_64 undefined reference __udivti3 for __uint128_t division

Sascha Wildner via Redmine bugtracker-admin at leaf.dragonflybsd.org
Tue Aug 28 09:37:23 PDT 2012


Issue #1710 has been updated by Sascha Wildner.

Status changed from New to Closed
Assignee deleted (0)

Closing. gcc44 has since been made the default compiler.

gstreamer builds too, so does Xfce4.

----------------------------------------
Bug #1710: gcc 4.1.2 on x86_64 undefined reference __udivti3 for __uint128_t division
http://bugs.dragonflybsd.org/issues/1710

Author: David Shao
Status: Closed
Priority: Normal
Assignee: 
Category: 
Target version: 


pkgsrc gstreamer0.10 fails to build on
DragonFly  2.7-DEVELOPMENT DragonFly v2.7.0.4.g63c2a-DEVELOPMENT #11: Mon Mar 29
07:30:32 PDT 2010     root@:/usr/obj/usr/src/sys/X86_64_GENERIC  x86_64

due to default gcc 4.1.2 not being able to handle code similar to that from
/usr/pkgsrc/multimedia/gstreamer0.10/work/gstreamer-0.10.28/gst/gstutils.c:

#include <inttypes.h>
#include <stdio.h>

int main(void)
{
  __uint128_t num = 1000;
  __uint128_t denom = 10;
  __uint128_t res = num / denom;
  printf("Result = %ju\n", (uintmax_t)res); 
  return 0;
}

$ gcc div128.c
/tmp//ccHUakkJ.o: In function `main':
div128.c:(.text+0x39): undefined reference to `__udivti3'
$ CCVER=gcc44 gcc -Wall -Werror div128.c
$ ./a.out
Result = 100

Using CCVER=gcc44 before pkgsrc bmake allows gstreamer0.10 and thus xfce4 to
build and run on x86_64.


-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here: http://bugs.dragonflybsd.org/my/account





More information about the Bugs mailing list