Deepfreeze essential parts of the encodings module. ### Description

This is a split off from #3582.

Deepfreeze essential parts of encodings module (encodings.\__init__, encodings.utf_8, and encodings.aliases), which is required during the Python bootstrap.

package:
  name: sharedlib-test
  version: "1.0"
  tag:
    - pyodide.test

source:
  path: src

build:
  type: shared_library
  script: |
    emcc -c main.c -o main.o ${SIDE_MODULE_CFLAGS}
    emcc -c dep.c -o dep.o ${SIDE_MODULE_CFLAGS}
    emcc -c dep2.c -o dep2.o ${SIDE_MODULE_CFLAGS}

    emcc dep2.o ${SIDE_MODULE_LDFLAGS} -o ${DISTDIR}/sharedlib-test-dep2.so
    emcc dep.o ${SIDE_MODULE_LDFLAGS} ${DISTDIR}/sharedlib-test-dep2.so -o ${DISTDIR}/sharedlib-test-dep.so
    emcc main.o ${SIDE_MODULE_LDFLAGS} ${DISTDIR}/sharedlib-test-dep.so -o ${DISTDIR}/sharedlib-test.so

package:
  name: sharedlib-test
  version: "1.0"
  tag:
    - pyodide.test

source:
  path: src

build:
  type: shared_library
  script: |
    emcc -c main.c -o main.o ${SIDE_MODULE_CFLAGS}
    emcc -c dep.c -o dep.o ${SIDE_MODULE_CFLAGS}
    emcc -c dep2.c -o dep2.o ${SIDE_MODULE_CFLAGS}

    emcc dep2.o ${SIDE_MODULE_LDFLAGS} -o ${DISTDIR}/sharedlib-test-dep2.so
    emcc dep.o ${SIDE_MODULE_LDFLAGS} ${DISTDIR}/sharedlib-test-dep2.so -o ${DISTDIR}/sharedlib-test-dep.so
    emcc main.o ${SIDE_MODULE_LDFLAGS} ${DISTDIR}/sharedlib-test-dep.so -o ${DISTDIR}/sharedlib-test.so
