With this pipeline vkd3d automatically gets built on Linux (in an image based on Debian unstable), both in 32 and 64 bit mode. Both builds are tested with radv and llvmpipe. A number of caveats apply, though: * A number of tests currently fail in llvmpipe, so the llvmpipe jobs are marked as allowed to fail. Ideally we'll eventually fix our bugs and mark the llvmpipe ones in the tests, so that the CI tests completely pass and possible problems in the Vulkan driver are recorded at a better granularity (this is the reason why GitLab says that the pipeline is passed with warnings: the warnings are that there are jobs that failed, even if they were allowed to fail). * The runners provided by the GitLab instance don't have a GPU available, so I configured my own computer (equipped with an AMD Radeon RX 5700 RX) to provide a runner with access to the GPU. This setup is not currently satisfying: for me, because I use that computer for other things and I don't like having random code submitted to it (it is theoretically sandboxed, but sandboxes are not always bullet-proof, especially if they have access to a GPU); for the users, because my computer might be unavailable at any time. I'll work on a better solution. For the time being I intend the runner to only accept jobs from the master branch; once a better solution is implemented I'd like to run the pipeline for MRs too. * While the `Dockerfile` and related assets do not necessarily need to be available in this repository, given that the CI accesses the binary image from the Docker hub anyway, I think it's still valuable to have them, so others can improve them (and for sure improvement opportunities are nowhere near missing). However, other ways to make them available can be found, if for some reason it is not liked to have them in this repository (they are not pretty!). * One of the reason they are not pretty is that I have a custom hack to compile `widl` from the Wine sources without compiling (or installing from the distribution) the whole of Wine, in the interest of keeping the Docker image small (well, small-ish: Vulkan drivers, compilers and X libraries are not small anyway). * Again on the subject of the Docker image, I am currently putting the binary image in my own namespace on the Docker hub. Using the GitLab container registry in the namespace of the Wine project would probably be better, so that I am not a bottleneck in the future. * Even if we discount all the points above, this MR cannot be merged yet, because my runner is currently configured for my namespace only. I guess I need the intervention of a GitLab admin to fix that. However, I think there's already material enough for valuable feedback.
From: Giovanni Mascellani gmascellani@codeweavers.com
--- libs/vkd3d/device.c | 35 +++++++++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 4 deletions(-)
diff --git a/libs/vkd3d/device.c b/libs/vkd3d/device.c index b9a8943c..39047c92 100644 --- a/libs/vkd3d/device.c +++ b/libs/vkd3d/device.c @@ -1690,16 +1690,21 @@ static HRESULT vkd3d_init_device_caps(struct d3d12_device *device, static HRESULT vkd3d_select_physical_device(struct vkd3d_instance *instance, unsigned int device_index, VkPhysicalDevice *selected_device) { - VkPhysicalDevice dgpu_device = VK_NULL_HANDLE, igpu_device = VK_NULL_HANDLE; + VkPhysicalDevice dgpu_device = VK_NULL_HANDLE, igpu_device = VK_NULL_HANDLE, first_device = VK_NULL_HANDLE; const struct vkd3d_vk_instance_procs *vk_procs = &instance->vk_procs; VkInstance vk_instance = instance->vk_instance; VkPhysicalDeviceProperties device_properties; VkPhysicalDevice device = VK_NULL_HANDLE; VkPhysicalDevice *physical_devices; + unsigned int i, index = 0; + const char *filter; uint32_t count; - unsigned int i; VkResult vr;
+ filter = getenv("VKD3D_VULKAN_DEVICE_FILTER"); + if (!filter) + filter = ""; + count = 0; if ((vr = VK_CALL(vkEnumeratePhysicalDevices(vk_instance, &count, NULL))) < 0) { @@ -1727,25 +1732,47 @@ static HRESULT vkd3d_select_physical_device(struct vkd3d_instance *instance,
for (i = 0; i < count; ++i) { + bool filtered; + VK_CALL(vkGetPhysicalDeviceProperties(physical_devices[i], &device_properties)); + + filtered = !strstr(device_properties.deviceName, filter); + if (filtered) + TRACE("Ignored because of filter:\n"); + else + TRACE("Index %u:\n", index); vkd3d_trace_physical_device_properties(&device_properties);
- if (i == device_index) + if (filtered) + continue; + + if (index == device_index) device = physical_devices[i];
if (device_properties.deviceType == VK_PHYSICAL_DEVICE_TYPE_DISCRETE_GPU && !dgpu_device) dgpu_device = physical_devices[i]; else if (device_properties.deviceType == VK_PHYSICAL_DEVICE_TYPE_INTEGRATED_GPU && !igpu_device) igpu_device = physical_devices[i]; + + if (!first_device) + first_device = physical_devices[i]; + + ++index; }
if (!device) device = dgpu_device ? dgpu_device : igpu_device; if (!device) - device = physical_devices[0]; + device = first_device;
vkd3d_free(physical_devices);
+ if (!device) + { + ERR("No physical device accepted by filter.\n"); + return E_FAIL; + } + VK_CALL(vkGetPhysicalDeviceProperties(device, &device_properties)); TRACE("Using device: %s, %#x:%#x.\n", device_properties.deviceName, device_properties.vendorID, device_properties.deviceID);
From: Giovanni Mascellani gmascellani@codeweavers.com
--- .gitlab-ci.yml | 115 +++++++++++++++++++++++++++++++++++++++++ ci/Dockerfile | 25 +++++++++ ci/compile-widl.sh | 126 +++++++++++++++++++++++++++++++++++++++++++++ ci/config.h | 13 +++++ 4 files changed, 279 insertions(+) create mode 100644 .gitlab-ci.yml create mode 100644 ci/Dockerfile create mode 100644 ci/compile-widl.sh create mode 100644 ci/config.h
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 00000000..9e6bc895 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,115 @@ +image: giomasce/vkd3d + +stages: + - build + - test + +build64: + stage: build + script: + - ./autogen.sh + - mkdir build + - cd build + - ../configure --enable-demos + - make -j$(nproc) + - make -j$(nproc) crosstest + artifacts: + when: always + paths: + - . + +test64-amd: + stage: test + dependencies: + - build64 + needs: + - build64 + tags: + - gpu + script: + - mkdir info + - cat /proc/cpuinfo > info/cpuinfo.txt + - cat /proc/meminfo > info/meminfo.txt + - vulkaninfo > info/vulkaninfo.txt + - cd build + - VKD3D_VULKAN_DEVICE_FILTER=AMD VKD3D_VULKAN_DEVICE=0 make -j$(nproc) check + artifacts: + when: always + paths: + - info + - build + +test64-llvmpipe: + stage: test + dependencies: + - build64 + needs: + - build64 + allow_failure: true + script: + - mkdir info + - cat /proc/cpuinfo > info/cpuinfo.txt + - cat /proc/meminfo > info/meminfo.txt + - vulkaninfo > info/vulkaninfo.txt + - cd build + - VKD3D_VULKAN_DEVICE_FILTER=llvmpipe VKD3D_VULKAN_DEVICE=0 make -j$(nproc) check + artifacts: + when: always + paths: + - info + - build + +build32: + stage: build + script: + - ./autogen.sh + - mkdir build + - cd build + - ../configure --enable-demos CFLAGS=-m32 + - make -j$(nproc) + - make -j$(nproc) crosstest + artifacts: + when: always + paths: + - . + +test32-amd: + stage: test + dependencies: + - build32 + needs: + - build32 + tags: + - gpu + script: + - mkdir info + - cat /proc/cpuinfo > info/cpuinfo.txt + - cat /proc/meminfo > info/meminfo.txt + - vulkaninfo > info/vulkaninfo.txt + - cd build + - VKD3D_VULKAN_DEVICE_FILTER=AMD VKD3D_VULKAN_DEVICE=0 make -j$(nproc) check + artifacts: + when: always + paths: + - info + - build + +test32-llvmpipe: + stage: test + dependencies: + - build32 + needs: + - build32 + allow_failure: true + script: + - mkdir info + - cat /proc/cpuinfo > info/cpuinfo.txt + - cat /proc/meminfo > info/meminfo.txt + - vulkaninfo > info/vulkaninfo.txt + - cd build + - VKD3D_VULKAN_DEVICE_FILTER=llvmpipe VKD3D_VULKAN_DEVICE=0 make -j$(nproc) check + artifacts: + when: always + paths: + - info + - build diff --git a/ci/Dockerfile b/ci/Dockerfile new file mode 100644 index 00000000..73702105 --- /dev/null +++ b/ci/Dockerfile @@ -0,0 +1,25 @@ +FROM debian:unstable +ENV DEBIAN_FRONTEND=noninteractive + +RUN rm /etc/apt/sources.list.d/* +RUN dpkg --add-architecture i386 +RUN printf "deb [arch=amd64,i386] http://deb.debian.org/debian unstable main\ndeb-src [arch=amd64,i386] http://deb.debian.org/debian unstable main\n" > /etc/apt/sources.list +RUN apt-get update +RUN apt-get install -y eatmydata +RUN eatmydata apt-get dist-upgrade -y +RUN eatmydata apt-get install -y build-essential pkg-config locales mesa-vulkan-drivers vulkan-tools autoconf automake libtool flex bison libvulkan-dev spirv-headers gcc-mingw-w64 libncurses-dev libxcb1-dev gcc-multilib doxygen doxygen-latex graphviz libvulkan-dev:i386 mesa-vulkan-drivers:i386 libncurses-dev:i386 libxcb-util-dev libxcb-icccm4-dev libxcb-keysyms1-dev libxcb1-dev:i386 libxcb-util-dev:i386 libxcb-icccm4-dev:i386 libxcb-keysyms1-dev:i386 +RUN echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen && locale-gen +ENV LANG=en_US.UTF-8 + +# Installing widl from the repositories or compiling Wine with its +# build system would bring in a lot of useless (for us) dependencies, +# easily making the image 1 GB larger; so we just build widl with a +# custom list of gcc calls dumped from an actual Wine build +RUN eatmydata apt-get install -y git +RUN mkdir -p /root/build/include +RUN mkdir -p /root/build/tools/widl +COPY compile-widl.sh /root/build +COPY config.h /root/build/include +# Join everything in a single RUN so that the intermediate state with +# the Wine sources is not saved +RUN git clone --depth 1 https://gitlab.winehq.org/wine/wine.git /root/wine && cd /root/build && bash -v compile-widl.sh && cp /root/build/tools/widl/widl /usr/local/bin && rm -fr /root/wine /root/build diff --git a/ci/compile-widl.sh b/ci/compile-widl.sh new file mode 100644 index 00000000..c75fe4f4 --- /dev/null +++ b/ci/compile-widl.sh @@ -0,0 +1,126 @@ +bison -o tools/widl/parser.tab.c -d ../wine/tools/widl/parser.y +gcc -m64 -c -o tools/widl/attribute.o ../wine/tools/widl/attribute.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/client.o ../wine/tools/widl/client.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/expr.o ../wine/tools/widl/expr.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/hash.o ../wine/tools/widl/hash.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/header.o ../wine/tools/widl/header.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/proxy.o ../wine/tools/widl/proxy.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/register.o ../wine/tools/widl/register.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/server.o ../wine/tools/widl/server.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/typegen.o ../wine/tools/widl/typegen.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/typelib.o ../wine/tools/widl/typelib.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/typetree.o ../wine/tools/widl/typetree.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/utils.o ../wine/tools/widl/utils.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/widl.o ../wine/tools/widl/widl.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DINCLUDEDIR=""/usr/local/include"" \ + -DDLLDIR=""/usr/local/lib/wine"" -DBIN_TO_INCLUDEDIR="`tools/makedep -R /usr/local/bin /usr/local/include`" \ + -DBIN_TO_DLLDIR="`tools/makedep -R /usr/local/bin /usr/local/lib/wine`" -DWINE_UNIX_LIB -Wall -pipe \ + -fcf-protection=none -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement \ + -Wempty-body -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 \ + -Wstrict-prototypes -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith \ + -Wlogical-op -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/wpp.o ../wine/tools/wrc/wpp.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/write_msft.o ../wine/tools/widl/write_msft.c -Itools/widl -I../wine/tools/widl \ + -I../wine/tools/wrc -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe \ + -fcf-protection=none -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement \ + -Wempty-body -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 \ + -Wstrict-prototypes -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith \ + -Wlogical-op -gdwarf-4 -g -O2 +gcc -m64 -c -o tools/widl/parser.tab.o tools/widl/parser.tab.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +bison -o tools/widl/ppy.tab.c -d ../wine/tools/wrc/ppy.y +bison -o tools/widl/ppy.tab.c ../wine/tools/wrc/ppy.y +gcc -m64 -c -o tools/widl/ppy.tab.o tools/widl/ppy.tab.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc -Iinclude \ + -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +flex -otools/widl/parser.yy.c ../wine/tools/widl/parser.l +gcc -m64 -c -o tools/widl/parser.yy.o tools/widl/parser.yy.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc \ + -Iinclude -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +flex -otools/widl/ppl.yy.c ../wine/tools/wrc/ppl.l +gcc -m64 -c -o tools/widl/ppl.yy.o tools/widl/ppl.yy.c -Itools/widl -I../wine/tools/widl -I../wine/tools/wrc -Iinclude \ + -I../wine/include -D__WINESRC__ -DWINE_UNIX_LIB -Wall -pipe -fcf-protection=none \ + -fno-stack-protector -fno-strict-aliasing -Wdeclaration-after-statement -Wempty-body \ + -Wignored-qualifiers -Winit-self -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes \ + -Wtype-limits -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op \ + -gdwarf-4 -g -O2 +gcc -m64 -o tools/widl/widl tools/widl/attribute.o tools/widl/client.o tools/widl/expr.o tools/widl/hash.o \ + tools/widl/header.o tools/widl/proxy.o tools/widl/register.o tools/widl/server.o \ + tools/widl/typegen.o tools/widl/typelib.o tools/widl/typetree.o tools/widl/utils.o \ + tools/widl/widl.o tools/widl/wpp.o tools/widl/write_msft.o tools/widl/parser.tab.o \ + tools/widl/ppy.tab.o tools/widl/parser.yy.o tools/widl/ppl.yy.o diff --git a/ci/config.h b/ci/config.h new file mode 100644 index 00000000..f995c85e --- /dev/null +++ b/ci/config.h @@ -0,0 +1,13 @@ +#ifndef __WINE_CONFIG_H +#define __WINE_CONFIG_H + +/* vkd3d wants version at least 3.20 */ + +#define PACKAGE_BUGREPORT "fake build, do not report bugs" +#define PACKAGE_NAME "Fake Wine" +#define PACKAGE_STRING "Fake Wine 8.0" +#define PACKAGE_TARNAME "fakewine" +#define PACKAGE_URL "fake build, do not report bugs" +#define PACKAGE_VERSION "8.0" + +#endif /* __WINE_CONFIG_H */
A number of tests currently fail in llvmpipe, so the llvmpipe jobs are marked as allowed to fail. Ideally we'll eventually fix our bugs and mark the llvmpipe ones in the tests,
Yeah. Of course that doesn't necessarily need to wait for the rest of the CI bits. :)
Subject: [PATCH 1/2] vkd3d: Filter devices according to VKD3D_VULKAN_DEVICE_FILTER. --- libs/vkd3d/device.c | 35 +++++++++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 4 deletions(-)
Sure. Please add VKD3D_VULKAN_DEVICE_FILTER to the list of environment variables in the README though. It's perhaps also worth clarifying that VKD3D_VULKAN_DEVICE now applies to the filtered list.
+build32: + stage: build + script: + - ./autogen.sh + - mkdir build + - cd build + - ../configure --enable-demos CFLAGS=-m32 + - make -j$(nproc) + - make -j$(nproc) crosstest + artifacts: + when: always + paths: + - . +
CFLAGS=-m32 doesn't seem ideal, as that implies dropping "-g -O2". I'd suggest CC="gcc -m32", or perhaps something like CFLAGS="-m32 -g -O2".
+# Installing widl from the repositories or compiling Wine with its +# build system would bring in a lot of useless (for us) dependencies, +# easily making the image 1 GB larger; so we just build widl with a +# custom list of gcc calls dumped from an actual Wine build
I think "make tools/widl/widl" should generally do the right thing, without building all of Wine. I'd also be inclined to suggest building a specific widl version like 3.20, instead of building what happens to be in Wine git when creating the image. There may be a similar consideration around targetting unstable instead of a specific release.
Of course widl is also available in the wine64-tools package on Debian. It's a bit unfortunate that this package depends on libwine-dev -> libwine, which ends up pulling in most of Wine's dependencies anyway. Ideally that would be improved on the Debian side, but in theory we could at least do better for the packages hosted at dl.winehq.org...
CFLAGS=-m32 doesn't seem ideal, as that implies dropping "-g -O2". I'd suggest CC="gcc -m32", or perhaps something like CFLAGS="-m32 -g -O2".
Does -g matter for a CI build?
CFLAGS=-m32 doesn't seem ideal, as that implies dropping "-g -O2". I'd suggest CC="gcc -m32", or perhaps something like CFLAGS="-m32 -g -O2".
Does -g matter for a CI build?
Potentially, when attempting to debug test crashes, I'd say. More generally though, I don't think it matters less for the 32-bit build than it does for the 64-bit build; if we're convinced that we don't want debug information and are deliberately dropping those flags, we should probably drop them for the 64-bit build as well.
I think "make tools/widl/widl" should generally do the right thing, without building all of Wine.
Yeah, I thought that it would still require a ton of build dependencies for Wine, but it ended up not requiring anything else when using `--without-x --without-freetype`. So it's probably a better solution.
I'd also be inclined to suggest building a specific widl version like 3.20, instead of building what happens to be in Wine git when creating the image. There may be a similar consideration around targetting unstable instead of a specific release.
Ok, I don't have a strong opinion, so just went with Wine 3.21 (given that 3.20 proved to be too old). WRT the Debian version, I am somewhat less convinced, mostly because of the Mesa drivers. As I understand it, llvmpipe is evolving quite quickly, so tracking a more recent Mesa version might me more helpful for development. OTOH it's also valuable to check that things didn't break for released software. Maybe this is just a good reason to test on different Debian versions. One could say that in general more variations you test with, more useful the CI is; and that current pipelines are still quite fast, so we still have a few points to spend before the whole thing becomes unwieldy.
Let's say that I'll go with bookworm for the moment, and leave further experimentation for the future.
Of course widl is also available in the wine64-tools package on Debian. It's a bit unfortunate that this package depends on libwine-dev -> libwine, which ends up pulling in most of Wine's dependencies anyway. Ideally that would be improved on the Debian side, but in theory we could at least do better for the packages hosted at dl.winehq.org...
Initially I used the Debian package, but desisted for precisely that reason. Given that the current situation seems acceptable for us, I won't concern myself with packaging issues for the time being.
ACK to everything else.