winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
September 2020
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
1 participants
703 discussions
Start a n
N
ew thread
Hans Leidekker : advapi32: Reimplement SystemFunction036 using system interrupt information.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: e9090e1c903578b30118ce9559c1824361abc6da URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e9090e1c903578b30118ce95…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Mon Sep 7 14:10:13 2020 +0200 advapi32: Reimplement SystemFunction036 using system interrupt information. Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/advapi32/crypt.c | 62 +++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 48 insertions(+), 14 deletions(-) diff --git a/dlls/advapi32/crypt.c b/dlls/advapi32/crypt.c index 7199795b47..ab06c14393 100644 --- a/dlls/advapi32/crypt.c +++ b/dlls/advapi32/crypt.c @@ -2422,6 +2422,36 @@ BOOL WINAPI SystemFunction035(LPCSTR lpszDllFilePath) return TRUE; } +static CRITICAL_SECTION random_cs; +static CRITICAL_SECTION_DEBUG random_debug = +{ + 0, 0, &random_cs, + { &random_debug.ProcessLocksList, &random_debug.ProcessLocksList }, + 0, 0, { (DWORD_PTR)(__FILE__ ": random_cs") } +}; +static CRITICAL_SECTION random_cs = { &random_debug, -1, 0, 0, 0, 0 }; + +#define MAX_CPUS 128 +static char random_buf[sizeof(SYSTEM_INTERRUPT_INFORMATION) * MAX_CPUS]; +static ULONG random_len; +static ULONG random_pos; + +/* FIXME: assumes interrupt information provides sufficient randomness */ +static BOOL fill_random_buffer(void) +{ + ULONG len = sizeof(SYSTEM_INTERRUPT_INFORMATION) * min( NtCurrentTeb()->Peb->NumberOfProcessors, MAX_CPUS ); + NTSTATUS status; + + if ((status = NtQuerySystemInformation( SystemInterruptInformation, random_buf, len, NULL ))) + { + WARN( "failed to get random bytes %08x\n", status ); + return FALSE; + } + random_len = len; + random_pos = 0; + return TRUE; +} + /****************************************************************************** * SystemFunction036 (ADVAPI32.@) * @@ -2436,26 +2466,30 @@ BOOL WINAPI SystemFunction035(LPCSTR lpszDllFilePath) * Failure: FALSE */ -BOOLEAN WINAPI SystemFunction036(PVOID pbBuffer, ULONG dwLen) +BOOLEAN WINAPI SystemFunction036( void *buffer, ULONG len ) { - int dev_random; + char *ptr = buffer; - dev_random = open("/dev/urandom", O_RDONLY); - if (dev_random != -1) + EnterCriticalSection( &random_cs ); + while (len) { - if (read(dev_random, pbBuffer, dwLen) == (ssize_t)dwLen) + ULONG size; + if (random_pos >= random_len && !fill_random_buffer()) { - close(dev_random); - return TRUE; + SetLastError( NTE_FAIL ); + LeaveCriticalSection( &random_cs ); + return FALSE; } - close(dev_random); + size = min( len, random_len - random_pos ); + memcpy( ptr, random_buf + random_pos, size ); + random_pos += size; + ptr += size; + len -= size; } - else - FIXME("couldn't open /dev/urandom\n"); - SetLastError(NTE_FAIL); - return FALSE; -} - + LeaveCriticalSection( &random_cs ); + return TRUE; +} + /* These functions have nearly identical prototypes to CryptProtectMemory and CryptUnprotectMemory, in crypt32.dll.
1
0
0
0
Hans Leidekker : ntdll: Return buffer filled with random values from NtQuerySystemInformation(SystemInterruptInformation).
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: ec02224941eedf16b8b043964519f6363b5ce21f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ec02224941eedf16b8b04396…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Mon Sep 7 14:10:12 2020 +0200 ntdll: Return buffer filled with random values from NtQuerySystemInformation(SystemInterruptInformation). Based on a patch by Sebastian Lackner. Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- configure | 2 ++ configure.ac | 2 ++ dlls/ntdll/tests/info.c | 3 ++- dlls/ntdll/unix/system.c | 34 +++++++++++++++++++++++++++++----- include/config.h.in | 6 ++++++ 5 files changed, 41 insertions(+), 6 deletions(-) diff --git a/configure b/configure index 5da5e9e713..8d68b2e4cf 100755 --- a/configure +++ b/configure @@ -7486,6 +7486,7 @@ for ac_header in \ sys/protosw.h \ sys/ptrace.h \ sys/queue.h \ + sys/random.h \ sys/resource.h \ sys/scsiio.h \ sys/shm.h \ @@ -17877,6 +17878,7 @@ for ac_func in \ getauxval \ getifaddrs \ getopt_long_only \ + getrandom \ kqueue \ lstat \ mach_continuous_time \ diff --git a/configure.ac b/configure.ac index 08d0af0ec1..123dea0f5f 100644 --- a/configure.ac +++ b/configure.ac @@ -514,6 +514,7 @@ AC_CHECK_HEADERS(\ sys/protosw.h \ sys/ptrace.h \ sys/queue.h \ + sys/random.h \ sys/resource.h \ sys/scsiio.h \ sys/shm.h \ @@ -2181,6 +2182,7 @@ AC_CHECK_FUNCS(\ getauxval \ getifaddrs \ getopt_long_only \ + getrandom \ kqueue \ lstat \ mach_continuous_time \ diff --git a/dlls/ntdll/tests/info.c b/dlls/ntdll/tests/info.c index 057b855914..b09c57b97a 100644 --- a/dlls/ntdll/tests/info.c +++ b/dlls/ntdll/tests/info.c @@ -643,7 +643,8 @@ static void test_query_interrupt(void) sii = HeapAlloc(GetProcessHeap(), 0, NeededLength); status = pNtQuerySystemInformation(SystemInterruptInformation, sii, 0, &ReturnLength); - ok( status == STATUS_INFO_LENGTH_MISMATCH, "Expected STATUS_INFO_LENGTH_MISMATCH, got %08x\n", status); + ok(status == STATUS_INFO_LENGTH_MISMATCH, "Expected STATUS_INFO_LENGTH_MISMATCH, got %08x\n", status); + ok(ReturnLength == NeededLength, "got %u\n", ReturnLength); /* Try it for all processors */ status = pNtQuerySystemInformation(SystemInterruptInformation, sii, NeededLength, &ReturnLength); diff --git a/dlls/ntdll/unix/system.c b/dlls/ntdll/unix/system.c index c2412643af..ccbc68b972 100644 --- a/dlls/ntdll/unix/system.c +++ b/dlls/ntdll/unix/system.c @@ -29,6 +29,7 @@ #include <stdarg.h> #include <stdio.h> #include <stdlib.h> +#include <errno.h> #ifdef HAVE_SYS_TIME_H # include <sys/time.h> #endif @@ -42,6 +43,9 @@ #ifdef HAVE_MACHINE_CPU_H # include <machine/cpu.h> #endif +#ifdef HAVE_SYS_RANDOM_H +# include <sys/random.h> +#endif #ifdef HAVE_IOKIT_IOKITLIB_H # include <CoreFoundation/CoreFoundation.h> # include <IOKit/IOKitLib.h> @@ -2422,16 +2426,36 @@ NTSTATUS WINAPI NtQuerySystemInformation( SYSTEM_INFORMATION_CLASS class, case SystemInterruptInformation: { - SYSTEM_INTERRUPT_INFORMATION sii = {{ 0 }}; - - len = sizeof(sii); + len = NtCurrentTeb()->Peb->NumberOfProcessors * sizeof(SYSTEM_INTERRUPT_INFORMATION); if (size >= len) { if (!info) ret = STATUS_ACCESS_VIOLATION; - else memcpy( info, &sii, len); + else + { +#ifdef HAVE_GETRANDOM + int ret; + do + { + ret = getrandom( info, len, 0 ); + } + while (ret == -1 && errno == EINTR); +#else + int fd = open( "/dev/urandom", O_RDONLY ); + if (fd != -1) + { + int ret; + do + { + ret = read( fd, info, len ); + } + while (ret == -1 && errno == EINTR); + close( fd ); + } + else WARN( "can't open /dev/urandom\n" ); +#endif + } } else ret = STATUS_INFO_LENGTH_MISMATCH; - FIXME("info_class SYSTEM_INTERRUPT_INFORMATION\n"); break; } diff --git a/include/config.h.in b/include/config.h.in index 5a21875f66..4309920ffa 100644 --- a/include/config.h.in +++ b/include/config.h.in @@ -252,6 +252,9 @@ /* Define to 1 if you have the `getopt_long_only' function. */ #undef HAVE_GETOPT_LONG_ONLY +/* Define to 1 if you have the `getrandom' function. */ +#undef HAVE_GETRANDOM + /* Define to 1 if you have the `getservbyport' function. */ #undef HAVE_GETSERVBYPORT @@ -1061,6 +1064,9 @@ /* Define to 1 if you have the <sys/queue.h> header file. */ #undef HAVE_SYS_QUEUE_H +/* Define to 1 if you have the <sys/random.h> header file. */ +#undef HAVE_SYS_RANDOM_H + /* Define to 1 if you have the <sys/resource.h> header file. */ #undef HAVE_SYS_RESOURCE_H
1
0
0
0
Nikolay Sivov : evr/mixer: Add another set of attributes.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: 23a879ec0ed12454f26e597247c73739ad1f8bbd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=23a879ec0ed12454f26e5972…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed Sep 9 12:48:27 2020 +0300 evr/mixer: Add another set of attributes. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/evr/mixer.c | 355 +++++++++++++++++++++++++++++++++++++++++++++++++++ dlls/evr/tests/evr.c | 25 +++- 2 files changed, 377 insertions(+), 3 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=23a879ec0ed12454f26e…
1
0
0
0
Nikolay Sivov : maintainers: Get rid of removed paths.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: bce18ee78ad60b55a23642de45a76669211ea642 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=bce18ee78ad60b55a23642de…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed Sep 9 13:41:00 2020 +0300 maintainers: Get rid of removed paths. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- MAINTAINERS | 2 -- 1 file changed, 2 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 46b3d40ec3..b57eb5a536 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -198,8 +198,6 @@ M: Huw Davies <huw(a)codeweavers.com> F: dlls/combase/ F: dlls/ole32/compobj.c F: dlls/ole32/marshal.c -F: dlls/ole32/rpc.c -F: dlls/ole32/stubmanager.c F: dlls/ole32/usrmarshal.c OLE Storage
1
0
0
0
Paul Gofman : vcruntime140_1: Handle rethrowing from nested try blocks on x64.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: c25a611d95a449946273415f0fb3733edd485699 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c25a611d95a449946273415f…
Author: Paul Gofman <pgofman(a)codeweavers.com> Date: Tue Sep 8 23:36:41 2020 +0300 vcruntime140_1: Handle rethrowing from nested try blocks on x64. Signed-off-by: Paul Gofman <pgofman(a)codeweavers.com> Signed-off-by: Piotr Caban <piotr(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/vcruntime140_1/except_x86_64.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/dlls/vcruntime140_1/except_x86_64.c b/dlls/vcruntime140_1/except_x86_64.c index 0e27b02db1..f66ae43721 100644 --- a/dlls/vcruntime140_1/except_x86_64.c +++ b/dlls/vcruntime140_1/except_x86_64.c @@ -103,6 +103,7 @@ typedef struct BOOL rethrow; INT search_state; INT unwind_state; + EXCEPTION_RECORD *prev_rec; } cxx_catch_ctx; typedef struct @@ -473,7 +474,7 @@ static LONG CALLBACK cxx_rethrow_filter(PEXCEPTION_POINTERS eptrs, void *c) FlsSetValue(fls_index, (void*)(DWORD_PTR)ctx->search_state); if (rec->ExceptionCode != CXX_EXCEPTION) return EXCEPTION_CONTINUE_SEARCH; - if (rec->ExceptionInformation[1] == ((EXCEPTION_RECORD*)*__current_exception())->ExceptionInformation[1]) + if (rec->ExceptionInformation[1] == ctx->prev_rec->ExceptionInformation[1]) ctx->rethrow = TRUE; return EXCEPTION_CONTINUE_SEARCH; } @@ -503,6 +504,7 @@ static void* WINAPI call_catch_block4(EXCEPTION_RECORD *rec) __CxxRegisterExceptionObject(&ep, &ctx.frame_info); ctx.search_state = rec->ExceptionInformation[2]; ctx.unwind_state = rec->ExceptionInformation[3]; + ctx.prev_rec = prev_rec; (*__processing_throw())--; __TRY { @@ -685,6 +687,12 @@ static DWORD cxx_frame_handler4(EXCEPTION_RECORD *rec, ULONG64 frame, if (rec->ExceptionCode == CXX_EXCEPTION) { + if (!rec->ExceptionInformation[1] && !rec->ExceptionInformation[2]) + { + TRACE("rethrow detected.\n"); + *rec = *(EXCEPTION_RECORD*)*__current_exception(); + } + exc_type = (cxx_exception_type *)rec->ExceptionInformation[2]; if (TRACE_ON(seh))
1
0
0
0
Alexandre Julliard : makefiles: Build extra targets explicitly if they are not a dependency.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: 96e5ac876fd48c3692a2b89780e7bb40fe526798 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=96e5ac876fd48c3692a2b897…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 9 11:47:42 2020 +0200 makefiles: Build extra targets explicitly if they are not a dependency. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wineandroid.drv/Makefile.in | 2 -- tools/makedep.c | 7 ++++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dlls/wineandroid.drv/Makefile.in b/dlls/wineandroid.drv/Makefile.in index e35f85ac89..fcc988b211 100644 --- a/dlls/wineandroid.drv/Makefile.in +++ b/dlls/wineandroid.drv/Makefile.in @@ -18,8 +18,6 @@ SVG_SRCS = \ EXTRA_TARGETS = wine-debug.apk -all: wine-debug.apk - wine-debug.apk: build.gradle $(srcdir)/AndroidManifest.xml $(srcdir)/WineActivity.java $(srcdir)/wine.svg gradle -q assembleDebug mv build/outputs/apk/wine-debug.apk $@ diff --git a/tools/makedep.c b/tools/makedep.c index 96f7100a0e..4775a60334 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -3931,6 +3931,12 @@ static void output_sources( struct makefile *make ) add_install_rule( make, make->scripts.str[i], make->scripts.str[i], strmake( "S$(bindir)/%s", make->scripts.str[i] )); + for (i = 0; i < make->extra_targets.count; i++) + if (strarray_exists( &make->dependencies, obj_dir_path( make, make->extra_targets.str[i] ))) + strarray_add( &make->clean_files, make->extra_targets.str[i] ); + else + strarray_add( &make->all_targets, make->extra_targets.str[i] ); + if (!make->src_dir) strarray_add( &make->distclean_files, ".gitignore" ); strarray_add( &make->distclean_files, "Makefile" ); if (make->testdll) strarray_add( &make->distclean_files, "testlist.c" ); @@ -3969,7 +3975,6 @@ static void output_sources( struct makefile *make ) strarray_addall( &make->clean_files, make->pot_files ); strarray_addall( &make->clean_files, make->debug_files ); strarray_addall( &make->clean_files, make->all_targets ); - strarray_addall( &make->clean_files, make->extra_targets ); if (make->clean_files.count) {
1
0
0
0
Alexandre Julliard : makefiles: Add some missing object dir references.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: 5adb93c654aab78f26f40b83ebca39af0326ba6d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=5adb93c654aab78f26f40b83…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 9 11:47:29 2020 +0200 makefiles: Add some missing object dir references. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/makedep.c | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/tools/makedep.c b/tools/makedep.c index b4576d94f4..96f7100a0e 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -2559,13 +2559,13 @@ static void output_install_rules( struct makefile *make, enum install_rules rule } } - output( "install %s::", target ); + output( "%s %s::", obj_dir_path( make, "install" ), obj_dir_path( make, target )); output_filenames( targets ); output( "\n" ); output_install_commands( make, NULL, files ); - strarray_add_uniq( &make->phony_targets, "install" ); - strarray_add_uniq( &make->phony_targets, target ); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "install" )); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, target )); } @@ -2628,8 +2628,7 @@ static void output_uninstall_rules( struct makefile *make ) /******************************************************************* * output_importlib_symlinks */ -static struct strarray output_importlib_symlinks( const struct makefile *parent, - const struct makefile *make ) +static struct strarray output_importlib_symlinks( const struct makefile *make ) { struct strarray ret = empty_strarray; const char *lib, *dst, *ext[4]; @@ -2642,7 +2641,7 @@ static struct strarray output_importlib_symlinks( const struct makefile *parent, for (i = 0; i < count; i++) { lib = strmake( "lib%s.%s", make->importlib, ext[i] ); - dst = concat_paths( obj_dir_path( parent, "dlls" ), lib ); + dst = concat_paths( obj_dir_path( top_makefile, "dlls" ), lib ); output( "%s: %s\n", dst, base_dir_path( make, lib )); output_symlink_rule( concat_paths( make->base_dir + strlen("dlls/"), lib ), dst ); strarray_add( &ret, dst ); @@ -3357,7 +3356,7 @@ static void output_module( struct makefile *make ) strarray_add( &make->all_targets, unix_lib ); add_install_rule( make, make->module, unix_lib, strmake( "p$(dlldir)/%s", unix_lib )); - output( "%s:", unix_lib ); + output( "%s:", obj_dir_path( make, unix_lib )); if (spec_file) output_filename( spec_file ); output_filenames_obj_dir( make, make->unixobj_files ); output_filenames( unix_deps ); @@ -3576,18 +3575,18 @@ static void output_test_module( struct makefile *make ) testmodule, obj_dir_path( make, stripped ), ext, tools_path( make, "wrc" )); output_filenames_obj_dir( make, make->ok_files ); - output( ": %s%s ../%s%s\n", testmodule, ext, make->testdll, parent_ext ); - output( "check test:" ); + output( ": %s%s ../%s%s\n", obj_dir_path( make, testmodule ), ext, make->testdll, parent_ext ); + output( "%s %s:", obj_dir_path( make, "check" ), obj_dir_path( make, "test" )); if (!make->disabled && parent && !parent->disabled) output_filenames_obj_dir( make, make->ok_files ); output( "\n" ); - strarray_add( &make->phony_targets, "check" ); - strarray_add( &make->phony_targets, "test" ); - output( "testclean::\n" ); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "check" )); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "test" )); + output( "%s::\n", obj_dir_path( make, "testclean" )); output( "\trm -f" ); output_filenames_obj_dir( make, make->ok_files ); output( "\n" ); strarray_addall( &make->clean_files, make->ok_files ); - strarray_add( &make->phony_targets, "testclean" ); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "testclean" )); } @@ -3745,7 +3744,7 @@ static void output_subdirs( struct makefile *make ) } } if (needs_implib_symlink( submake )) - strarray_addall( &symlinks, output_importlib_symlinks( make, submake )); + strarray_addall( &symlinks, output_importlib_symlinks( submake )); } if (submake->disabled) continue; @@ -3884,7 +3883,7 @@ static void output_sources( struct makefile *make ) struct incl_file *source; unsigned int i, j; - strarray_add( &make->phony_targets, "all" ); + strarray_add_uniq( &make->phony_targets, "all" ); LIST_FOR_EACH_ENTRY( source, &make->sources, struct incl_file, entry ) { @@ -3947,9 +3946,10 @@ static void output_sources( struct makefile *make ) { if (make->all_targets.count) { - output( "all:" ); + output( "%s:", obj_dir_path( make, "all" )); output_filenames_obj_dir( make, make->all_targets ); output( "\n" ); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "all" )); } output_install_rules( make, INSTALL_LIB, "install-lib" ); output_install_rules( make, INSTALL_DEV, "install-dev" ); @@ -3977,8 +3977,7 @@ static void output_sources( struct makefile *make ) output( "\trm -f" ); output_filenames_obj_dir( make, make->clean_files ); output( "\n" ); - if (make->obj_dir) output( "__clean__: %s\n", obj_dir_path( make, "clean" )); - strarray_add( &make->phony_targets, obj_dir_path( make, "clean" )); + strarray_add_uniq( &make->phony_targets, obj_dir_path( make, "clean" )); } if (make->phony_targets.count)
1
0
0
0
Alexandre Julliard : makefiles: Store .pot files in a separate variable.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: 82acb284bda2fe655ce0ff51b18667f1c9311e30 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=82acb284bda2fe655ce0ff51…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 9 11:46:00 2020 +0200 makefiles: Store .pot files in a separate variable. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/makedep.c | 34 ++++++++++++---------------------- 1 file changed, 12 insertions(+), 22 deletions(-) diff --git a/tools/makedep.c b/tools/makedep.c index e17bf24c41..b4576d94f4 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -208,6 +208,7 @@ struct makefile /* values generated at output time */ struct strarray in_files; struct strarray ok_files; + struct strarray pot_files; struct strarray clean_files; struct strarray distclean_files; struct strarray uninstall_files; @@ -2657,32 +2658,18 @@ static void output_po_files( const struct makefile *make ) { const char *po_dir = src_dir_path( make, "po" ); struct strarray pot_files = empty_strarray; - struct incl_file *source; - unsigned int i; + unsigned int i, j; for (i = 0; i < make->subdirs.count; i++) { struct makefile *submake = make->submakes[i]; - LIST_FOR_EACH_ENTRY( source, &submake->sources, struct incl_file, entry ) + for (j = 0; j < submake->pot_files.count; j++) { - if (source->file->flags & FLAG_PARENTDIR) continue; - if (strendswith( source->name, ".rc" ) && (source->file->flags & FLAG_RC_PO)) - { - char *pot_file = replace_extension( source->name, ".rc", ".pot" ); - char *pot_path = base_dir_path( submake, pot_file ); - output( "%s: tools/wrc include dummy\n", pot_path ); - output( "\t@cd %s && $(MAKE) %s\n", base_dir_path( submake, "" ), pot_file ); - strarray_add( &pot_files, pot_path ); - } - else if (strendswith( source->name, ".mc" )) - { - char *pot_file = replace_extension( source->name, ".mc", ".pot" ); - char *pot_path = base_dir_path( submake, pot_file ); - output( "%s: tools/wmc include dummy\n", pot_path ); - output( "\t@cd %s && $(MAKE) %s\n", base_dir_path( submake, "" ), pot_file ); - strarray_add( &pot_files, pot_path ); - } + char *pot_path = base_dir_path( submake, submake->pot_files.str[j] ); + output( "%s: dummy\n", pot_path ); + output( "\t@cd %s && $(MAKE) %s\n", base_dir_path( submake, "" ), submake->pot_files.str[j] ); + strarray_add( &pot_files, pot_path ); } } if (linguas.count) @@ -2697,6 +2684,8 @@ static void output_po_files( const struct makefile *make ) output_filename( strmake( "%s/%s.po", po_dir, linguas.str[i] )); output( "\n" ); } + output_filenames( pot_files ); + output( ": tools/wrc tools/wmc include\n" ); output( "%s/wine.pot:", po_dir ); output_filenames( pot_files ); output( "\n" ); @@ -2766,7 +2755,7 @@ static void output_source_rc( struct makefile *make, struct incl_file *source, c strarray_add( &make->res_files, strmake( "%s.res", obj )); if (source->file->flags & FLAG_RC_PO && !(source->file->flags & FLAG_PARENTDIR)) { - strarray_add( &make->clean_files, strmake( "%s.pot", obj )); + strarray_add( &make->pot_files, strmake( "%s.pot", obj )); output( "%s.pot ", obj_dir_path( make, obj ) ); } output( "%s.res: %s", obj_dir_path( make, obj ), source->filename ); @@ -2800,7 +2789,7 @@ static void output_source_mc( struct makefile *make, struct incl_file *source, c char *obj_path = obj_dir_path( make, obj ); strarray_add( &make->res_files, strmake( "%s.res", obj )); - strarray_add( &make->clean_files, strmake( "%s.pot", obj )); + strarray_add( &make->pot_files, strmake( "%s.pot", obj )); output( "%s.pot %s.res: %s", obj_path, obj_path, source->filename ); output_filename( tools_path( make, "wmc" )); output_filenames( source->dependencies ); @@ -3977,6 +3966,7 @@ static void output_sources( struct makefile *make ) strarray_addall( &make->clean_files, make->crossobj_files ); strarray_addall( &make->clean_files, make->unixobj_files ); strarray_addall( &make->clean_files, make->res_files ); + strarray_addall( &make->clean_files, make->pot_files ); strarray_addall( &make->clean_files, make->debug_files ); strarray_addall( &make->clean_files, make->all_targets ); strarray_addall( &make->clean_files, make->extra_targets );
1
0
0
0
Alexandre Julliard : makefiles: Expand makedep path at compile time.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: a204ad557dd504391e13e1382278472cd86517f4 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a204ad557dd504391e13e138…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 9 11:36:45 2020 +0200 makefiles: Expand makedep path at compile time. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/gdi32/Makefile.in | 2 +- dlls/ntdll/Makefile.in | 8 ++++---- libs/wine/Makefile.in | 8 ++++---- loader/Makefile.in | 2 +- tools/widl/Makefile.in | 2 +- tools/winegcc/Makefile.in | 4 ++-- tools/wmc/Makefile.in | 2 +- tools/wrc/Makefile.in | 4 ++-- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/dlls/gdi32/Makefile.in b/dlls/gdi32/Makefile.in index 32b2e6959c..a94abad599 100644 --- a/dlls/gdi32/Makefile.in +++ b/dlls/gdi32/Makefile.in @@ -52,4 +52,4 @@ C_SRCS = \ RC_SRCS = gdi32.rc -freetype_EXTRADEFS = -DWINE_FONT_DIR=\"`$(MAKEDEP) -R ${datadir}/wine ${fontdir}`\" +freetype_EXTRADEFS = -DWINE_FONT_DIR=\"`${MAKEDEP} -R ${datadir}/wine ${fontdir}`\" diff --git a/dlls/ntdll/Makefile.in b/dlls/ntdll/Makefile.in index 52f63892af..a553536d4c 100644 --- a/dlls/ntdll/Makefile.in +++ b/dlls/ntdll/Makefile.in @@ -72,13 +72,13 @@ EXTRA_OBJS = unix/version.o server_EXTRADEFS = \ -DBINDIR=\"${bindir}\" \ - -DBIN_TO_DLLDIR=\"`$(MAKEDEP) -R ${bindir} ${dlldir}`\" \ - -DDLL_TO_BINDIR=\"`$(MAKEDEP) -R ${dlldir} ${bindir}`\" + -DBIN_TO_DLLDIR=\"`${MAKEDEP} -R ${bindir} ${dlldir}`\" \ + -DDLL_TO_BINDIR=\"`${MAKEDEP} -R ${dlldir} ${bindir}`\" unix_loader_EXTRADEFS = \ -DBINDIR=\"${bindir}\" \ - -DDLL_TO_BINDIR=\"`$(MAKEDEP) -R ${dlldir} ${bindir}`\" \ - -DBIN_TO_DATADIR=\"`$(MAKEDEP) -R ${bindir} ${datadir}/wine`\" + -DDLL_TO_BINDIR=\"`${MAKEDEP} -R ${dlldir} ${bindir}`\" \ + -DBIN_TO_DATADIR=\"`${MAKEDEP} -R ${bindir} ${datadir}/wine`\" unix/version.c: dummy version=`(GIT_DIR=$(top_srcdir)/.git git describe HEAD 2>/dev/null || echo "wine-$(PACKAGE_VERSION)") | sed -n -e '$$s/\(.*\)/const char wine_build[] = "\1";/p'` && (echo $$version | cmp -s - $@) || echo $$version >$@ || (rm -f $@ && exit 1) diff --git a/libs/wine/Makefile.in b/libs/wine/Makefile.in index 6bb27e34dc..65a0789502 100644 --- a/libs/wine/Makefile.in +++ b/libs/wine/Makefile.in @@ -87,10 +87,10 @@ C_SRCS = \ config_EXTRADEFS = \ -DBINDIR='"${bindir}"' \ -DDLLDIR='"${dlldir}"' \ - -DLIB_TO_BINDIR=\"`$(MAKEDEP) -R ${libdir} ${bindir}`\" \ - -DLIB_TO_DLLDIR=\"`$(MAKEDEP) -R ${libdir} ${dlldir}`\" \ - -DBIN_TO_DLLDIR=\"`$(MAKEDEP) -R ${bindir} ${dlldir}`\" \ - -DBIN_TO_DATADIR=\"`$(MAKEDEP) -R ${bindir} ${datadir}/wine`\" + -DLIB_TO_BINDIR=\"`${MAKEDEP} -R ${libdir} ${bindir}`\" \ + -DLIB_TO_DLLDIR=\"`${MAKEDEP} -R ${libdir} ${dlldir}`\" \ + -DBIN_TO_DLLDIR=\"`${MAKEDEP} -R ${bindir} ${dlldir}`\" \ + -DBIN_TO_DATADIR=\"`${MAKEDEP} -R ${bindir} ${datadir}/wine`\" SHAREDLIB = $(LIBWINE_SHAREDLIB) diff --git a/loader/Makefile.in b/loader/Makefile.in index 1cb9ab6bf7..e8c271f15d 100644 --- a/loader/Makefile.in +++ b/loader/Makefile.in @@ -18,7 +18,7 @@ INSTALL_LIB = $(WINELOADER_PROGRAMS) preloader_EXTRADEFS = -fno-builtin -main_EXTRADEFS = -DDLLDIR=\"${dlldir}\" -DBIN_TO_DLLDIR=\"`$(MAKEDEP) -R ${bindir} ${dlldir}`\" +main_EXTRADEFS = -DDLLDIR=\"${dlldir}\" -DBIN_TO_DLLDIR=\"`${MAKEDEP} -R ${bindir} ${dlldir}`\" wine_OBJS = main.o wine_DEPS = $(WINELOADER_DEPENDS) diff --git a/tools/widl/Makefile.in b/tools/widl/Makefile.in index 6c74e88d25..a231087f37 100644 --- a/tools/widl/Makefile.in +++ b/tools/widl/Makefile.in @@ -21,7 +21,7 @@ BISON_SRCS = parser.y widl_EXTRADEFS = \ -DINCLUDEDIR="\"${includedir}\"" \ - -DBIN_TO_INCLUDEDIR=\"`$(MAKEDEP) -R ${bindir} ${includedir}`\" + -DBIN_TO_INCLUDEDIR=\"`${MAKEDEP} -R ${bindir} ${includedir}`\" EXTRALIBS = -lwpp diff --git a/tools/winegcc/Makefile.in b/tools/winegcc/Makefile.in index 0d94eed5ff..8328d6f34a 100644 --- a/tools/winegcc/Makefile.in +++ b/tools/winegcc/Makefile.in @@ -11,8 +11,8 @@ C_SRCS = \ winegcc_EXTRADEFS = \ -DINCLUDEDIR="\"${includedir}\"" \ -DLIBDIR="\"${libdir}\"" \ - -DBIN_TO_INCLUDEDIR=\"`$(MAKEDEP) -R ${bindir} ${includedir}`\" \ - -DBIN_TO_LIBDIR=\"`$(MAKEDEP) -R ${bindir} ${libdir}`\" \ + -DBIN_TO_INCLUDEDIR=\"`${MAKEDEP} -R ${bindir} ${includedir}`\" \ + -DBIN_TO_LIBDIR=\"`${MAKEDEP} -R ${bindir} ${libdir}`\" \ -DCC="\"$(CC)\"" \ -DCPP="\"$(CPPBIN)\"" \ -DCXX="\"$(CXX)\"" \ diff --git a/tools/wmc/Makefile.in b/tools/wmc/Makefile.in index 660bc940f4..9d7c87e8fd 100644 --- a/tools/wmc/Makefile.in +++ b/tools/wmc/Makefile.in @@ -13,7 +13,7 @@ BISON_SRCS = mcy.y wmc_EXTRADEFS = \ -DNLSDIR="\"${nlsdir}\"" \ - -DBIN_TO_NLSDIR=\"`$(MAKEDEP) -R ${bindir} ${nlsdir}`\" + -DBIN_TO_NLSDIR=\"`${MAKEDEP} -R ${bindir} ${nlsdir}`\" EXTRALIBS = $(GETTEXTPO_LIBS) diff --git a/tools/wrc/Makefile.in b/tools/wrc/Makefile.in index b7462e3b99..fb6eba20c2 100644 --- a/tools/wrc/Makefile.in +++ b/tools/wrc/Makefile.in @@ -17,8 +17,8 @@ BISON_SRCS = parser.y wrc_EXTRADEFS = \ -DNLSDIR="\"${nlsdir}\"" \ -DINCLUDEDIR="\"${includedir}\"" \ - -DBIN_TO_NLSDIR=\"`$(MAKEDEP) -R ${bindir} ${nlsdir}`\" \ - -DBIN_TO_INCLUDEDIR=\"`$(MAKEDEP) -R ${bindir} ${includedir}`\" + -DBIN_TO_NLSDIR=\"`${MAKEDEP} -R ${bindir} ${nlsdir}`\" \ + -DBIN_TO_INCLUDEDIR=\"`${MAKEDEP} -R ${bindir} ${includedir}`\" EXTRALIBS = $(GETTEXTPO_LIBS) -lwpp
1
0
0
0
Alexandre Julliard : makefiles: Add dependencies for the import lib symlinks.
by Alexandre Julliard
09 Sep '20
09 Sep '20
Module: wine Branch: master Commit: b211bd7b6449e3a67bb0ecf5c113981eefa0dbb4 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=b211bd7b6449e3a67bb0ecf5…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 9 11:35:14 2020 +0200 makefiles: Add dependencies for the import lib symlinks. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/makedep.c | 49 +++++++++++++++++++++++++++++++++---------------- 1 file changed, 33 insertions(+), 16 deletions(-) diff --git a/tools/makedep.c b/tools/makedep.c index 56166af910..e17bf24c41 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -2151,6 +2151,24 @@ static int needs_delay_lib( const struct makefile *make ) } +/******************************************************************* + * needs_implib_symlink + */ +static int needs_implib_symlink( const struct makefile *make ) +{ + if (!make->module) return 0; + if (!make->importlib) return 0; + if (make->is_win16 && make->disabled) return 0; + if (strncmp( make->base_dir, "dlls/", 5 )) return 0; + if (!strcmp( make->module, make->importlib )) return 0; + if (!strchr( make->importlib, '.' ) && + !strncmp( make->module, make->importlib, strlen( make->importlib )) && + !strcmp( make->module + strlen( make->importlib ), ".dll" )) + return 0; + return 1; +} + + /******************************************************************* * add_default_libraries */ @@ -2227,8 +2245,12 @@ static struct strarray add_import_libs( const struct makefile *make, struct stra if (is_cross || !*dll_ext || submake->staticimplib) lib = base_dir_path( submake, strmake( "lib%s.a", name )); else + { strarray_add( deps, top_obj_dir_path( make, strmake( "%s/lib%s.def", submake->base_dir, name ))); + if (needs_implib_symlink( submake )) + strarray_add( deps, top_obj_dir_path( make, strmake( "dlls/lib%s.def", name ))); + } break; } @@ -2237,13 +2259,17 @@ static struct strarray add_import_libs( const struct makefile *make, struct stra if (lib) { - if (delay && !delay_load_flag && (is_cross || !*dll_ext)) - lib = replace_extension( lib, ".a", ".delay.a" ); - else if (is_cross) - lib = replace_extension( lib, ".a", ".cross.a" ); + const char *ext = NULL; + + if (delay && !delay_load_flag && (is_cross || !*dll_ext)) ext = ".delay.a"; + else if (is_cross) ext = ".cross.a"; + if (ext) lib = replace_extension( lib, ".a", ext ); lib = top_obj_dir_path( make, lib ); strarray_add( deps, lib ); strarray_add( &ret, lib ); + if (needs_implib_symlink( top_makefile->submakes[j] )) + strarray_add( deps, top_obj_dir_path( make, + strmake( "dlls/lib%s%s", name, ext ? ext : ".a" ))); } else strarray_add( &ret, strmake( "-l%s", name )); } @@ -2608,17 +2634,7 @@ static struct strarray output_importlib_symlinks( const struct makefile *parent, const char *lib, *dst, *ext[4]; int i, count = 0; - if (!make->module) return ret; - if (!make->importlib) return ret; - if (make->is_win16 && make->disabled) return ret; - if (strncmp( make->base_dir, "dlls/", 5 )) return ret; - if (!strcmp( make->module, make->importlib )) return ret; - if (!strchr( make->importlib, '.' ) && - !strncmp( make->module, make->importlib, strlen( make->importlib )) && - !strcmp( make->module + strlen( make->importlib ), ".dll" )) - return ret; - - ext[count++] = *dll_ext ? "def" : "a"; + ext[count++] = (*dll_ext && !make->implib_objs.count) ? "def" : "a"; if (needs_delay_lib( make )) ext[count++] = "delay.a"; if (needs_cross_lib( make )) ext[count++] = "cross.a"; @@ -3739,7 +3755,8 @@ static void output_subdirs( struct makefile *make ) output( "\n" ); } } - strarray_addall( &symlinks, output_importlib_symlinks( make, submake )); + if (needs_implib_symlink( submake )) + strarray_addall( &symlinks, output_importlib_symlinks( make, submake )); } if (submake->disabled) continue;
1
0
0
0
← Newer
1
...
47
48
49
50
51
52
53
...
71
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
Results per page:
10
25
50
100
200