From f8aed76f34dc5d06014d663b7c0dc32b33abc68c Mon Sep 17 00:00:00 2001 From: Biswapriyo Nath Date: Sat, 6 Nov 2021 22:52:39 +0530 Subject: [PATCH] crt: Add bits GUID library Required for python-pywin32 project Signed-off-by: Biswapriyo Nath Signed-off-by: LIU Hao --- mingw-w64-crt/Makefile.am | 17 +++++++++++++++++ mingw-w64-crt/libsrc/bits.c | 17 +++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 mingw-w64-crt/libsrc/bits.c diff --git a/mingw-w64-crt/Makefile.am b/mingw-w64-crt/Makefile.am index 43bebf750..e6b644ec1 100644 --- a/mingw-w64-crt/Makefile.am +++ b/mingw-w64-crt/Makefile.am @@ -94,6 +94,7 @@ src_dfp_math = endif +src_libbits=libsrc/bits.c src_libshell32=libsrc/shell32.c src_libdinput=libsrc/dinput_kbd.c libsrc/dinput_joy.c libsrc/dinput_joy2.c libsrc/dinput_mouse.c libsrc/dinput_mouse2.c src_libdinput8=libsrc/dinput_private.h libsrc/dinput_joy.c libsrc/dinput_joy2.c libsrc/dinput_mouse.c libsrc/dinput_mouse2.c libsrc/dinput_kbd.c @@ -677,6 +678,10 @@ lib32/libmsvcrt-os.a: lib-common/msvcrt-os.mri lib32/libmsvcrt_def.a lib32/libms cd $(dir $@) && $(AR) -M < $(abspath $<) endif +lib32_LIBRARIES += lib32/libbits.a +lib32_libbits_a_SOURCES = $(src_libbits) +lib32_libbits_a_CPPFLAGS=$(CPPFLAGS32) $(sysincludes) + lib32_LIBRARIES += lib32/libshell32.a lib32_libshell32_a_SOURCES = $(src_libshell32) lib32_libshell32_a_AR = $(DTLIB32) && $(AR) $(ARFLAGS) @@ -1002,6 +1007,10 @@ lib64/libmsvcrt-os.a: lib-common/msvcrt-os.mri lib64/libmsvcrt_def.a lib64/libms cd $(dir $@) && $(AR) -M < $(abspath $<) endif +lib64_LIBRARIES += lib64/libbits.a +lib64_libbits_a_SOURCES = $(src_libbits) +lib64_libbits_a_CPPFLAGS=$(CPPFLAGS64) $(sysincludes) + lib64_LIBRARIES += lib64/libshell32.a lib64_libshell32_a_SOURCES = $(src_libshell32) lib64_libshell32_a_CPPFLAGS=$(CPPFLAGS64) $(sysincludes) @@ -1336,6 +1345,10 @@ libarm32/libmsvcrt-os.a: lib-common/msvcrt-os.mri libarm32/libmsvcrt_def.a libar cd $(dir $@) && $(AR) -M < $(abspath $<) endif +libarm32_LIBRARIES += libarm32/libbits.a +libarm32_libbits_a_SOURCES = $(src_libbits) +libarm32_libbits_a_CPPFLAGS=$(CPPFLAGSARM32) $(sysincludes) + libarm32_LIBRARIES += libarm32/libshell32.a libarm32_libshell32_a_SOURCES = $(src_libshell32) libarm32_libshell32_a_AR = $(DTDEFARM32) $(top_srcdir)/lib-common/shell32.def && $(AR) $(ARFLAGS) @@ -1614,6 +1627,10 @@ libarm64/libmsvcrt-os.a: lib-common/msvcrt-os.mri libarm64/libmsvcrt_def.a libar cd $(dir $@) && $(AR) -M < $(abspath $<) endif +libarm64_LIBRARIES += libarm64/libbits.a +libarm64_libbits_a_SOURCES = $(src_libbits) +libarm64_libbits_a_CPPFLAGS=$(CPPFLAGSARM64) $(sysincludes) + libarm64_LIBRARIES += libarm64/libshell32.a libarm64_libshell32_a_SOURCES = $(src_libshell32) libarm64_libshell32_a_AR = $(DTDEFARM64) $(top_srcdir)/lib-common/shell32.def && $(AR) $(ARFLAGS) diff --git a/mingw-w64-crt/libsrc/bits.c b/mingw-w64-crt/libsrc/bits.c new file mode 100644 index 000000000..2858d1596 --- /dev/null +++ b/mingw-w64-crt/libsrc/bits.c @@ -0,0 +1,17 @@ +/** + * This file has no copyright assigned and is placed in the Public Domain. + * This file is part of the mingw-w64 runtime package. + * No warranty is given; refer to the file DISCLAIMER.PD within this package. + */ + +/* crt/libsrc/bits.c */ +/* Generate GUIDs for Background Intelligent Transfer Service (BITS) interfaces */ + +#include +#include +#include +#include +#include +#include +#include +#include