Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 650312 - net-libs/pjproject-2.7.1 : ../.../bcg729.c:539:9: error: too many arguments to function bcg729Encoder
Summary: net-libs/pjproject-2.7.1 : ../.../bcg729.c:539:9: error: too many arguments t...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Jaco Kroon
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-12 17:18 UTC by Toralf Förster
Modified: 2019-11-30 07:50 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,17.19 KB, text/plain)
2018-03-12 17:18 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,196.97 KB, text/plain)
2018-03-12 17:18 UTC, Toralf Förster
Details
environment (environment,101.05 KB, text/plain)
2018-03-12 17:18 UTC, Toralf Förster
Details
etc.portage.tbz2 (etc.portage.tbz2,11.53 KB, application/x-bzip)
2018-03-12 17:18 UTC, Toralf Förster
Details
logs.tbz2 (logs.tbz2,10.50 KB, application/x-bzip)
2018-03-12 17:18 UTC, Toralf Förster
Details
net-libs:pjproject-2.7.1:20180312-132051.log (net-libs:pjproject-2.7.1:20180312-132051.log,269.50 KB, text/plain)
2018-03-12 17:18 UTC, Toralf Förster
Details
temp.tbz2 (temp.tbz2,39.63 KB, application/x-bzip)
2018-03-12 17:18 UTC, Toralf Förster
Details
updated ebuild set (2.7.1-r1 and 2.7.2-r1). (net-libs_pjproject.tgz,4.30 KB, application/x-gtar)
2018-09-20 14:17 UTC, Jaco Kroon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2018-03-12 17:18:03 UTC
	../src/pjmedia-codec/bcg729.c 
../src/pjmedia-codec/bcg729.c: In function ‘bcg729_codec_encode’:
../src/pjmedia-codec/bcg729.c:539:9: error: too many arguments to function ‘bcg729Encoder’
         bcg729Encoder(bcg729_data->encoder, pcm_in,
         ^~~~~~~~~~~~~
In file included from ../src/pjmedia-codec/bcg729.c:32:0:

=== This is an issue at stable ===


  -------------------------------------------------------------------

  This is an stable amd64 chroot image at a tinderbox (==build bot)
  name: 17.0-desktop_stable_20180307-182850

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-6.4.0 *

Available Python interpreters, in order of preference:
  [1]   python3.5
  [2]   python2.7 (fallback)
  [3]   jython2.7 (fallback)
Available Ruby profiles:
  [1]   ruby22 (with Rubygems)
  [2]   ruby23 (with Rubygems) *
java-config:
The following VMs are available for generation-2:
*)	IcedTea JDK 3.7.0 [icedtea-bin-8]
Available Java Virtual Machines:
  [1]   icedtea-bin-8  system-vm

emerge -qpv net-libs/pjproject
[ebuild  N    ] net-libs/pjproject-2.7.1  USE="alsa ipv6 sdl ssl -amr -debug -doc -epoll -examples -ffmpeg -g711 -g722 -g7221 -gsm -ilbc -l16 -libyuv -openh264 -opus -oss -portaudio -resample -silk -speex -static-libs -v4l2 -webrtc"
Comment 1 Toralf Förster gentoo-dev 2018-03-12 17:18:06 UTC
Created attachment 523630 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2018-03-12 17:18:09 UTC
Created attachment 523632 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2018-03-12 17:18:12 UTC
Created attachment 523634 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2018-03-12 17:18:15 UTC
Created attachment 523636 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2018-03-12 17:18:18 UTC
Created attachment 523638 [details]
logs.tbz2
Comment 6 Toralf Förster gentoo-dev 2018-03-12 17:18:21 UTC
Created attachment 523640 [details]
net-libs:pjproject-2.7.1:20180312-132051.log
Comment 7 Toralf Förster gentoo-dev 2018-03-12 17:18:24 UTC
Created attachment 523642 [details]
temp.tbz2
Comment 8 Tony Vroon (RETIRED) gentoo-dev 2018-03-14 09:08:08 UTC
This appears to be an automagic dependency on media-libs/bcg729.
Comment 9 Tony Vroon (RETIRED) gentoo-dev 2018-03-14 09:12:47 UTC
Builds correctly for me with media-libs/bcg729-1.0.4 & net-libs/pjproject-2.7.2; the automagic dependency is unfortunate but I cannot reproduce the build breakage.
Comment 10 Jaco Kroon 2018-04-18 16:19:46 UTC
bcg729 relates (as far as I know) to the g729 codec, any way to disable that code?  I've filed a bug (https://bugs.gentoo.org/440100) for the inclusion of asterisk-g72x which also provides a g729 implementation via media-plugins/mediastreamer-bcg729 - but that conflicts with media-libs/bcg729 ... (and the difference in declarations is probably what causes the build failure Toralf is seeing.

Unmerging media-plugins/mediastreamer-bcg729, then merging pjproject works.  I suspect it's using a bundled media-libs/bcg729.

Two things here:

1.  The code (if it's going to use a bundled package) should use the bundled version and avoid includes from external sources for that.

2.  If 1 isn't possible then we need a hard NOT dependency in pjproject that you can't merge pjproject whilst mediastreamer-bcg720 is installed.

Merging pjproject first, and then merging mediastreamer-bcg729 works perfectly fine, so I'd suggest if possible we should do 1.
Comment 11 Jaco Kroon 2018-09-20 14:17:12 UTC
Created attachment 547371 [details]
updated ebuild set (2.7.1-r1 and 2.7.2-r1).

You can merge one or both.

Changes:  introduce g729 USE flag to determine whether or not to build in G.729 support via bcg729 library, and explicitly disable bcg729 dependency via ./configure if -g729.  Add depend on bcg729 libraries (which already correctly blocks against mediastreamer-g729).

This should enable those who need pjproject bcg729 support (not required for asterisk which only uses pjproject for SIP handling, not RTP - as far as I can determine) to use that, while those of us that use this for asterisk can safely disable it.  I'm using asterisk-g72x (submitted elsewhere) for g729 support currently, so need mediastreamer-bcg729.

This enables me to build without the compile failure, and I hope it fixes it for others too.

Previously the build was in deterministic in that whether or not bcg729 was utilized depended purely on whether the headers was available or not.

I note that there were already changes between 2.7.1 and 2.7.2:

libressl support
mask against mediastream-bcg729
It's marked ~.

I've compile tested both versions with and without g729 with mediastreamer-bcg729 merged, and with +g729 it correctly blocks, and builds with -g729.  I've compile tested 2.7.1 without mediastreamer-bcg729 merged and it correctly pulls in media-libs/bcg729 and builds successfully.  I've not done the latter test for 2.7.2.

I would like to see both ebuilds merged, but if you're only going to merge 2.7.2-r1 then it should also go stable.
Comment 12 Larry the Git Cow gentoo-dev 2019-11-30 07:50:04 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=90d194bc8a80a478c91f5196da9eac770a755ca2

commit 90d194bc8a80a478c91f5196da9eac770a755ca2
Author:     Jaco Kroon <jaco@uls.co.za>
AuthorDate: 2019-11-18 09:45:56 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2019-11-30 07:48:56 +0000

    net-libs/pjproject: Bump to 2.9.
    
    Drop libressl patches (upstream).
    Rebase configure for --enable-ssl.
    Pull in asterisk config_site.h file.
    Remove blocked on mediastreamer-bcg729 (bcg729 and mediastreamer-bcg729
    are the actual blockers and marked as such already).
    Use ${ED} instead of ${D} on install
    Correctly rm static libs if USE=-static-libs
    Set the PJMEDIA_HAS_VIDEO #define as per https://bugs.gentoo.org/652196
    Update package.use.mask for ppc to mask g729 for pjproject since
    net-libs/bcg729 isn't available (yet) on ppc.
    
    Closes: https://bugs.gentoo.org/609702
    Closes: https://bugs.gentoo.org/618352
    Closes: https://bugs.gentoo.org/652196
    Closes: https://bugs.gentoo.org/650312
    Closes: https://bugs.gentoo.org/653482
    Closes: https://bugs.gentoo.org/657014
    Closes: https://bugs.gentoo.org/686796
    Package-Manager: Portage-2.3.76, Repoman-2.3.16
    Signed-off-by: Jaco Kroon <jaco@uls.co.za>
    Closes: https://github.com/gentoo/gentoo/pull/13712
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 net-libs/pjproject/Manifest                        |   1 +
 .../pjproject/files/pjproject-2.9-config_site.h    |  74 +++++++++++++
 .../pjproject/files/pjproject-2.9-ssl-enable.patch | 100 +++++++++++++++++
 net-libs/pjproject/metadata.xml                    |   3 +-
 net-libs/pjproject/pjproject-2.9.ebuild            | 120 +++++++++++++++++++++
 .../linux/powerpc/ppc32/17.0/package.use.mask      |   3 +
 .../ppc64/17.0/32bit-userland/package.use.mask     |   3 +
 7 files changed, 303 insertions(+), 1 deletion(-)