[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Cinnamon 4.2, salsa and master branch



¡Hola Norbert!

El 2019-09-05 a las 12:13 +0900, Norbert Preining escribió:
Hi Max,

On Wed, 04 Sep 2019, Maximiliano Curia wrote:
I just tweaked the symbols file a bit, dropped the optional MISSING symbols,
and tweaked the one that uses a size_t so it uses a subst instead of having
to list all the arches. Also this is being reexported from mozjs so I tagged
it as optional.

Could you look into the experimental branch, too, please? I have updated
the symbols file from the build logs, and removed the MISSING, but if
there are other substitutions necessary/helpful, please go ahead.
Thanks.

I'm happy to pass on what I gathered. The cjs experimental symbols file as is, is valid, but, it can be improved. See, for example, these two:

+ (optional=templinst|arch=armel armhf hppa i386 m68k sh4)_ZNSt7__cxx1112basic_stringIDsSt11char_traitsIDsESaIDsEE6resizeEjDs@Base 4.2.0
+ (optional=templinst|arch=!armel !armhf !hppa !i386 !m68k !sh4)_ZNSt7__cxx1112basic_stringIDsSt11char_traitsIDsESaIDsEE6resizeEmDs@Base 4.0.0

these are quite suspicious, running c++filt:
$ c++filt <<<'_ZNSt7__cxx1112basic_stringIDsSt11char_traitsIDsESaIDsEE6resizeEjDs@Base'
std::__cxx11::basic_string<char16_t, std::char_traits<char16_t>, std::allocator<char16_t> >::resize(unsigned int, char16_t)@Base
$ c++filt <<<'_ZNSt7__cxx1112basic_stringIDsSt11char_traitsIDsESaIDsEE6resizeEmDs@Base'
std::__cxx11::basic_string<char16_t, std::char_traits<char16_t>, std::allocator<char16_t> >::resize(unsigned long, char16_t)@Base4

So they are basicaly the same method (resize for basic_string) but one receives an unsigned long (in 64bits arches) and the other and unsigned int (in 32bits arches). That's what the size_t does, so we can use a substitution here for that, and keep only one symbol:
(optional=templinst|subst)_ZNSt7__cxx1112basic_stringIDsSt11char_traitsIDsESaIDsEE6resizeE{size_t}Ds@Base 4.0.0

This has the benefit that building for a new arch shouldn't cause a new symbols diff that we need to apply.

The same logic can be applied to:
_ZZN2JS18SourceBufferHolderC4EPKDsjNS0_9OwnershipEE9NullChar_@Base
_ZZN2JS18SourceBufferHolderC4EPKDsmNS0_9OwnershipEE9NullChar_@Base

Also these two seem to be reexported from mozjs, so I consider them optional. As we already did in the master branch we can have:
+ (optional=mozjs|subst)_ZZN2JS18SourceBufferHolderC4EPKDs{size_t}NS0_9OwnershipEE9NullChar_@Base 4.0.0

There are a number of substitutions that pkgkde-symbolshelper can keep in place and it's useful to know them. The documentation of those is, sadly, only in the code:
/usr/share/perl5/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm

If you try to read it, you'll find that every substitution is a perl package, in the simple cases, the new method has a substvar like "{size_t}", and the expand method has the rule and the symbols the substvar is replaced with.

Please let me know if this information was useful or you need more explanation.

I have not done the changes, I would prefer if going forward you could do these changes yourselves. Thanks.

Happy hacking,
--
"Anytime you have a fifty-fifty chance of getting something right, there's a
90 percent probability you'll get it wrong."
-- The 50-50-90 rule
Saludos /\/\ /\ >< `/

Attachment: signature.asc
Description: PGP signature


Reply to: