Bug 223475

Summary: [patch] net/asterisk13: Unbreak build on ARMv[67]
Product: Ports & Packages Reporter: Michal Meloun <mmel>
Component: Individual Port(s)Assignee: Guido Falsi <madpilot>
Status: Closed FIXED    
Severity: Affects Only Me CC: linimon
Priority: --- Keywords: patch
Version: LatestFlags: madpilot: maintainer-feedback+
Hardware: Any   
OS: Any   
Attachments:
Description Flags
arm_patch none

Description Michal Meloun freebsd_committer freebsd_triage 2017-11-06 14:39:50 UTC
Created attachment 187797 [details]
arm_patch

The SPANDSP problem has been fixed in pats, and now asterisk13 bild on real HW and/or poudriere  without problems.

Build log for armv7:
http://build.humusoft.cz/data/head12armv7-default/2017-11-04_08h04m53s/logs/asterisk13-13.18.0.log
Comment 1 Guido Falsi freebsd_committer freebsd_triage 2017-11-06 15:07:16 UTC
Thanks for the information and patch.

I was planning to better test asterisk on arm again and you beat me to it.

I'll test it myself and commit this soon, please allow me some time for testing.
Comment 2 Guido Falsi freebsd_committer freebsd_triage 2017-11-07 10:34:42 UTC
I'm hitting a roadblock testing this.

I'm using a poudriere armv6 jail with FreeBSD 11.1.

The build fails on a few dependent ports with "sincos" missing symbol errors.

I'm using armv6 jails very little lately, I did test more with them in the past, so I'm not sure what is wrong with it. If you have any pointers which could help me that would be useful to make things faster.
Comment 3 Mikael Urankar freebsd_committer freebsd_triage 2017-11-07 11:15:59 UTC
you can add:
CFLAGS+= -fno-builtin-sincos -fno-builtin-sin -fno-builtin-cos \
		-fno-builtin-sincosf -fno-builtin-sinf -fno-builtin-cosf \
		-fno-builtin-sincosl -fno-builtin-sinl -fno-builtin-cosl
CXXFLAGS+=-fno-builtin-sincos -fno-builtin-sin -fno-builtin-cos \
		-fno-builtin-sincosf -fno-builtin-sinf -fno-builtin-cosf \
		-fno-builtin-sincosl -fno-builtin-sinl -fno-builtin-cosl

to /etc/make.conf
Comment 4 Michal Meloun freebsd_committer freebsd_triage 2017-11-07 12:18:57 UTC
Ahh, I forget to this. sincoc(3) was added to libc recently, then MFC'ed to stable/11 (after 11.2 release). I'm not sure if this patch is applicable to anything other that head - sincos() is missing in too many packages :(.

For poudriere speedup, you can update your armv6 jail with -x. With this switch, poudriere builds and uses many native binaries(sh, clang,..).
Comment 5 Guido Falsi freebsd_committer freebsd_triage 2017-11-13 17:25:26 UTC
(In reply to Michal Meloun from comment #4)
> Ahh, I forget to this. sincoc(3) was added to libc recently, then MFC'ed to
> stable/11 (after 11.2 release). I'm not sure if this patch is applicable to
> anything other that head - sincos() is missing in too many packages :(.
> 

Sorry for the delay.

I'm holding this change for a little, while I figure out the best way to deploy it.

If users will not be able anyway to use asterisk due to this sincos() problem, there's no hurry anyway.

Some time ago I was actually able to use it on a raspberry Pi2, but maybe something has happened in a while, I just need time to setup a proper testing environment.

> For poudriere speedup, you can update your armv6 jail with -x. With this
> switch, poudriere builds and uses many native binaries(sh, clang,..).

Already done that. But I'm seeing failures on dependencies, I need to understand if they can be worked around, maybe disabling some options.
Comment 6 Eitan Adler freebsd_committer freebsd_triage 2018-05-23 10:27:02 UTC
batch change of PRs untouched in 2018 marked "in progress" back to open.
Comment 7 Mark Linimon freebsd_committer freebsd_triage 2018-06-11 05:35:10 UTC
Committed as part of r455173.