Skip to content

Widevine AARCH64 support #1128

@tmm1

Description

@tmm1

We have aarch64 version of libwidevinecdm.so available now, as detailed here: emilsvennesson/script.module.inputstreamhelper#530

However to use it is still a challenge. I will document the requirements in this issue.

  1. libnspr4.so dependency

    not sure if this is new, but the libnspr4 package must be installed because libwidevinecdm.so depends on libnspr4.so

  2. glibc patch for _dt_determine_tlsoffset

    this patch is required: https://github.com/LibreELEC/LibreELEC.tv/blob/master/packages/devel/glibc/patches/arm/glibc-tls-libwidevinecdm.so-since-4.10.2252.0-has-TLS-with.patch

    without it, there will be a SEGV when running dlopen(). note that RPIOS already includes this patch in their libc6==2.31-13+rpt2+rpi1+deb11u5 package

  3. glibc patch for GLIBC_ABI_DT_RELR support (if using glibc >= 2.36)

    patch found here: https://github.com/LibreELEC/LibreELEC.tv/blob/master/packages/devel/glibc/patches/arm/glibc-HACK-Don-t-check-GLIBC_ABI_DT_RELR-support-for-Chrom.patch

    not currently required on ubuntu (using glibc 2.35) or debian/rpios (using glibc 2.31)

  4. LSE atomic symbols present in .dynsym

    inside the .so file, there are references to two required symbols:

    $ readelf -Ws libwidevinecdm.so | grep -v GLIBC | grep -v WEAK | grep -v NOTYPE | grep UND
        25: 0000000000000000     0 FUNC    GLOBAL DEFAULT  UND __aarch64_ldadd4_acq_rel
       132: 0000000000000000     0 FUNC    GLOBAL DEFAULT  UND __aarch64_swp4_acq_rel
    

    it seems on chromeos they have modified glibc/gcc packages to provide these as dynamic symbols inside various libraries. on stock linux glibc systems, these are not present because they are only used as static/hidden methods provided by libgcc.a and embedded inside every library that uses them. we would expect that these definitions would be embedded inside the widevine.so, but instead they are undefined and expected to be provided by an external library

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions