Since the libs provided by spidermonkey prior to 1.7 and earlier differs from that of 1.9 and later, and because it's just plain easier to deal with pkg-config to gather library info, please install a spidermonkey.pc file for each of the various spidermonkey ebuilds. I will be attaching patches that provide this functionality Reproducible: Always
Created attachment 268495 [details] files/generate-spidermonkey-pc.sh This file generates a spidermonkey.pc file according to various environment variables set during emerge. it is meant to be source'd in the spidermonkey ebuilds. (note, this works, but may not be elegant enough for actual use in portage)
Created attachment 268497 [details, diff] patch to spidermonkey-1.7.0-r2.ebuild patch to add spidermonkey.pc generator support to the 1.7.0-r2 ebuild
Created attachment 268499 [details, diff] patch for spidermonkey-1.9.2.15.ebuild patch to add spidermonkey.pc generator support to the 1.9.2.15 ebuild
Exactly what packages will make use of it currently? I rather wait until we cut the 2.2 release of spidermonkey which will install pkg-config files.
Well, I will with media-gfx/freewrl ... I expect other packages that support both 1.7 and 1.9 would move to it as well if it were available? (Perhaps not so much if 1.7 and 1.9 had the same library name, but since they don't..) I expect anything depending on the 'threadsafe' property of spidermonkey (ie, whether or not -DJS_THREADSAFE should be specified) would also benefit from a .pc file...? If v2.2 will have .pc files, does that mean you are willing to add the .pc files for these older versions at that time? I'm personally not in any rush.
Could this fix the problems in bug 366729?
Potentially yes -- at least, it would make it a lot easier to fix, as at worst it would mean adding a quick patch to the package's ./configure script. More specifically, what this would do is allow the package to use either spidermonekey-1.7 or spidermonkey-1.9 (whichever it installed) without having to do any additional ebuild trickery.
Ebuild naming is chaning stable users will get a downgrade, and testing will get the latest change with pkgconfig entry.
I edited bumped the version number for spidermonkey-1.9.2.x down to 1.8.2.x today, and fixed dependencies in various packages. We can probably get the mozjs185 ball rolling sometime soon. Editing subject to show the actual solution.
Ok this bug kind of got usurped, so i'm closing it as it seems that there isn't a willingness (nor a point, i guess) to back-patch older spidermonkeys with pkg-config support. And, as stated in the title itself, spidermonkey-1.8.5 has been added to the tree (although masked), so it's resolved.