diff --git a/Platform/v1.0/sdk/mingw.yaml b/Platform/v1.0/ExtensionMinGW.yaml similarity index 71% rename from Platform/v1.0/sdk/mingw.yaml rename to Platform/v1.0/ExtensionMinGW.yaml index cbef9d9..91ac2bc 100644 --- a/Platform/v1.0/sdk/mingw.yaml +++ b/Platform/v1.0/ExtensionMinGW.yaml @@ -1,4 +1,13 @@ -name: mingw +build-extension: true +id: de.marko10_000.winebarrels.Platform.ExtensionsV1.MinGW +branch: "v1" + +sdk: de.marko10_000.winebarrels.Sdk +runtime: de.marko10_000.winebarrels.Platform +runtime-version: "v1.0" + +build-options: + prefix: /usr/wine_extensions/v1/MinGW modules: - name: mingw-binutils-32bit sources: @@ -18,16 +27,8 @@ modules: - --enable-static-pie - --enable-threads builddir: true - build-options: - make-install-args: - - DESTDIR=/usr/tmp_binutils - - install - post-install: - - rm -rf /usr/tmp_binutils/usr/share - - cp -raP --remove-destination /usr/tmp_binutils/usr / - - rm -rfv /usr/tmp_binutils - cleanup-platform: - - "*" + cleanup: + - /share - name: mingw-headers-32bit sources: - type: archive @@ -35,22 +36,19 @@ modules: sha256: 805e11101e26d7897fce7d49cbb140d7bac15f3e085a91e0001e80b2adaf48f0 buildsystem: simple build-commands: + - ls -la /usr/wine_extensions/v1/MinGW - mkdir builds - cd builds && ../mingw-w64-headers/configure --host=i686-w64-mingw32 --enable-sdk=all --enable-secure-api - --prefix=/usr/i686-w64-mingw32 - - cd builds && make DESTDIR=/usr/tmp_mingw install - - echo "" > /usr/tmp_mingw/usr/i686-w64-mingw32/include/pthread_signal.h - - echo "" > /usr/tmp_mingw/usr/i686-w64-mingw32/include/pthread_time.h - - echo "" > /usr/tmp_mingw/usr/i686-w64-mingw32/include/pthread_unistd.h - post-install: - - rm -rf /usr/tmp_mingw/usr/share - - cp -rP --remove-destination /usr/tmp_mingw/usr / - - rm -rfv /usr/tmp_mingw - cleanup-platform: - - "*" + --prefix=/usr/wine_extensions/v1/MinGW/i686-w64-mingw32 + - cd builds && make install + - echo "" > /usr/wine_extensions/v1/MinGW/i686-w64-mingw32/include/pthread_signal.h + - echo "" > /usr/wine_extensions/v1/MinGW/i686-w64-mingw32/include/pthread_time.h + - echo "" > /usr/wine_extensions/v1/MinGW/i686-w64-mingw32/include/pthread_unistd.h + cleanup: + - /share - name: mingw-gcc-pass1-32bit sources: - type: archive @@ -70,10 +68,9 @@ modules: dest: mpc - type: shell commands: - - ln -s /usr/bin/cpp /lib/cpp - sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64 config-opts: &gcc32 - - --libexecdir=/usr/lib + - --libexecdir=/usr/wine_extensions/v1/MinGW/lib - --target=i686-w64-mingw32 - --disable-dw2-exceptions - --disable-multilib @@ -94,12 +91,9 @@ modules: make-args: - all-gcc post-install: - - make DESTDIR=/usr/tmp_gcc install-gcc - - rm -rf /usr/tmp_gcc/usr/share - - cp -raP --remove-destination /usr/tmp_gcc/usr / - - rm -rfv /usr/tmp_gcc /lib/cpp - cleanup-platform: - - "*" + - make install-gcc + cleanup: + - /share - name: mingw-crt-32bit sources: - type: archive @@ -112,22 +106,17 @@ modules: - --enable-shared - --enable-static - --enable-wildcard - - --prefix=/usr/i686-w64-mingw32 + - --prefix=/usr/wine_extensions/v1/MinGW/i686-w64-mingw32 - CFLAGS=-fno-stack-protector - CPPFLAGS=-fno-stack-protector #- LDFLAGS=-fstack-protector-strong #- ARFLAGS=-fstack-protector-strong builddir: true build-options: - make-install-args: - - DESTDIR=/usr/tmp_mingw - - install - post-install: - - rm -rf /usr/tmp_mingw/usr/share - - cp -raP --remove-destination /usr/tmp_mingw/usr / - - rm -rfv /usr/tmp_mingw - cleanup-platform: - - "*" + env: + PATH: "/usr/wine_extensions/v1/MinGW/bin:/usr/bin" + cleanup: + - /share - name: mingw-gcc-32bit sources: - type: archive @@ -147,21 +136,13 @@ modules: dest: mpc - type: shell commands: - - rm -rf /usr/tmp_gcc - - ln -s /usr/bin/cpp /lib/cpp - sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64 config-opts: *gcc32 builddir: true - build-options: - make-install-args: - - DESTDIR=/usr/tmp_gcc - - install post-install: - - rm -rf /usr/tmp_gcc/usr/share - - cp -rf /usr/tmp_gcc/usr / - - rm -rfv /usr/tmp_gcc /lib/cpp - cleanup-platform: - - "*" + - rm -rfv /lib/cpp + cleanup: + - /share - name: mingw-binutils-64bit sources: - type: archive @@ -180,16 +161,8 @@ modules: - --enable-static-pie - --enable-threads builddir: true - build-options: - make-install-args: - - DESTDIR=/usr/tmp_binutils - - install - post-install: - - rm -rf /usr/tmp_binutils/usr/share - - cp -raP --remove-destination /usr/tmp_binutils/usr / - - rm -rfv /usr/tmp_binutils - cleanup-platform: - - "*" + cleanup: + - /share only-arches: - x86_64 - name: mingw-headers-64bit @@ -204,14 +177,10 @@ modules: --host=x86_64-w64-mingw32 --enable-sdk=all --enable-secure-api - --prefix=/usr/x86_64-w64-mingw32 - - cd builds && make DESTDIR=/usr/tmp_mingw install - post-install: - - rm -rf /usr/tmp_mingw/usr/share - - cp -raP --remove-destination /usr/tmp_mingw/usr / - - rm -rfv /usr/tmp_mingw - cleanup-platform: - - "*" + --prefix=/usr/wine_extensions/v1/MinGW/x86_64-w64-mingw32 + - cd builds && make install + cleanup: + - /share only-arches: - x86_64 - name: mingw-gcc-pass1-64bit @@ -233,10 +202,9 @@ modules: dest: mpc - type: shell commands: - - ln -s /usr/bin/cpp /lib/cpp - sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64 config-opts: &gcc64 - - --libexecdir=/usr/lib + - --libexecdir=/usr/wine_extensions/v1/MinGW/lib - --target=x86_64-w64-mingw32 - --disable-dw2-exceptions - --disable-multilib @@ -257,12 +225,9 @@ modules: make-args: - all-gcc post-install: - - make DESTDIR=/usr/tmp_gcc install-gcc - - rm -rf /usr/tmp_gcc/usr/share - - cp -raP --remove-destination /usr/tmp_gcc/usr / - - rm -rfv /usr/tmp_gcc /lib/cpp - cleanup-platform: - - "*" + - make install-gcc + cleanup: + - /share only-arches: - x86_64 - name: mingw-crt-64bit @@ -277,24 +242,17 @@ modules: - --enable-lib64 - --enable-shared - --enable-wildcard - - --prefix=/usr/x86_64-w64-mingw32 + - --prefix=/usr/wine_extensions/v1/MinGW/x86_64-w64-mingw32 - CFLAGS=-fno-stack-protector - CPPFLAGS=-fno-stack-protector #- LDFLAGS=-fstack-protector-strong #- ARFLAGS=-fstack-protector-strong builddir: true build-options: - make-install-args: - - DESTDIR=/usr/tmp_mingw - - install env: - PATH: "/usr/tmp_gcc64/usr/bin:/usr/bin" - post-install: - - rm -rf /usr/tmp_mingw/usr/share - - cp -rf /usr/tmp_mingw/usr / - - rm -rfv /usr/tmp_mingw - cleanup-platform: - - "*" + PATH: "/usr/wine_extensions/v1/MinGW/bin:/usr/bin" + cleanup: + - /share only-arches: - x86_64 - name: mingw-gcc-64bit @@ -316,19 +274,17 @@ modules: dest: mpc - type: shell commands: - - ln -s /usr/bin/cpp /lib/cpp - sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64 config-opts: *gcc64 builddir: true - build-options: - make-install-args: - - DESTDIR=/usr/tmp_gcc - - install - post-install: - - rm -rf /usr/tmp_gcc/usr/share - - cp -raP --remove-destination /usr/tmp_gcc/usr / - - rm -rfv /usr/tmp_gcc /lib/cpp - cleanup-platform: - - "*" + cleanup: + - /share only-arches: - x86_64 + - name: update_elf + sources: + - type: file + path: elf_compress.py + buildsystem: simple + build-commands: + - python3 elf_compress.py /usr/wine_extensions/v1/MinGW diff --git a/Platform/v1.0/Sdk-i386.yaml b/Platform/v1.0/Sdk-i386.yaml index 600b0d9..95437cd 100644 --- a/Platform/v1.0/Sdk-i386.yaml +++ b/Platform/v1.0/Sdk-i386.yaml @@ -20,9 +20,9 @@ inherit-extensions: - org.freedesktop.Platform.VAAPI.Intel add-extensions: - de.marko10_000.winebarrels.Platform.ExtensionsV1_0: - directory: wine_extensions/v1.0 - version: "v1.0" + de.marko10_000.winebarrels.Platform.ExtensionsV1: + directory: wine_extensions/v1 + version: "v1" subdirectories: true autodelete: true no-autodownload: true diff --git a/Platform/v1.0/Sdk-x86_64.yaml b/Platform/v1.0/Sdk-x86_64.yaml index 84adb65..6c6d9c9 100644 --- a/Platform/v1.0/Sdk-x86_64.yaml +++ b/Platform/v1.0/Sdk-x86_64.yaml @@ -21,8 +21,8 @@ inherit-extensions: - org.freedesktop.Platform.GL32 add-extensions: - de.marko10_000.winebarrels.Platform.ExtensionsV1_0: - directory: wine_extensions/v1.0 + de.marko10_000.winebarrels.Platform.ExtensionsV1: + directory: wine_extensions/v1 version: "v1.0" subdirectories: true autodelete: true diff --git a/Platform/v1.0/elf_compress.py b/Platform/v1.0/elf_compress.py new file mode 100644 index 0000000..8b9e92b --- /dev/null +++ b/Platform/v1.0/elf_compress.py @@ -0,0 +1,23 @@ +#! /usr/bin/evn python3 + +if __name__ == '__main__': + import os + import subprocess + import sys + + def parse_path(path): + if os.path.islink(path): + return + elif os.path.isfile(path): + if open(path, "rb").read(4) == b"\x7FELF": + print("Compress: " + path) + subprocess.call(["cp", "-a", path, "tmp.so"]) + subprocess.call(["strip", "--strip-debug", "tmp.so"]) + subprocess.call(["cp", "-a", "tmp.so", path]) + subprocess.call(["eu-elfcompress", "-vt", "gnu", path]) + elif os.path.isdir(path): + for i in map(lambda x: os.path.join(path, x), + sorted(os.listdir(path))): + parse_path(i) + for i in sys.argv[1:]: + parse_path(i) diff --git a/Platform/v1.0/platform/platform.yaml b/Platform/v1.0/platform/platform.yaml index 0fb181a..2861a8e 100644 --- a/Platform/v1.0/platform/platform.yaml +++ b/Platform/v1.0/platform/platform.yaml @@ -1,7 +1,7 @@ name: platform-meta buildsystem: simple build-commands: - - mkdir -p /usr/wine_extensions/v1.0 + - mkdir -p /usr/wine_extensions/v1 modules: - winetricks.yaml - libglu.yaml diff --git a/Platform/v1.0/sdk/sdk.yaml b/Platform/v1.0/sdk/sdk.yaml index a813ec8..e7aaf17 100644 --- a/Platform/v1.0/sdk/sdk.yaml +++ b/Platform/v1.0/sdk/sdk.yaml @@ -1,3 +1,2 @@ name: sdk-meta -modules: - - mingw.yaml +modules: []