gcc_erorr.patch 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. --- a/tools/winebuild/main.c 2019-05-10 21:04:22.946749869 +0300
  2. +++ b/tools/winebuild/main.c 2019-05-10 21:11:45.232992256 +0300
  3. @@ -47,10 +47,13 @@
  4. int force_pointer_size = 0;
  5. int unwind_tables = 0;
  6. +#undef FORCE_POINTER_SIZE
  7. #ifdef __i386__
  8. enum target_cpu target_cpu = CPU_x86;
  9. +#define FORCE_POINTER_SIZE
  10. #elif defined(__x86_64__)
  11. enum target_cpu target_cpu = CPU_x86_64;
  12. +#define FORCE_POINTER_SIZE
  13. #elif defined(__powerpc__)
  14. enum target_cpu target_cpu = CPU_POWERPC;
  15. #elif defined(__arm__)
  16. @@ -619,6 +622,10 @@
  17. signal( SIGTERM, exit_on_signal );
  18. signal( SIGINT, exit_on_signal );
  19. +#ifdef FORCE_POINTER_SIZE
  20. + force_pointer_size = sizeof(size_t);
  21. +#endif
  22. +
  23. argv = parse_options( argc, argv, spec );
  24. atexit( cleanup ); /* make sure we remove the output file on exit */
  25. --- a/tools/winegcc/winegcc.c 2019-05-10 21:04:22.951749823 +0300
  26. +++ b/tools/winegcc/winegcc.c 2019-05-10 21:12:46.477428568 +0300
  27. @@ -224,10 +224,13 @@
  28. strarray* files;
  29. };
  30. +#undef FORCE_POINTER_SIZE
  31. #ifdef __i386__
  32. static const enum target_cpu build_cpu = CPU_x86;
  33. +#define FORCE_POINTER_SIZE
  34. #elif defined(__x86_64__)
  35. static const enum target_cpu build_cpu = CPU_x86_64;
  36. +#define FORCE_POINTER_SIZE
  37. #elif defined(__powerpc__)
  38. static const enum target_cpu build_cpu = CPU_POWERPC;
  39. #elif defined(__arm__)
  40. @@ -1351,6 +1354,10 @@
  41. opts.winebuild_args = strarray_alloc();
  42. opts.pic = 1;
  43. +#ifdef FORCE_POINTER_SIZE
  44. + opts.force_pointer_size = sizeof(size_t);
  45. +#endif
  46. +
  47. /* determine the processor type */
  48. if (strendswith(argv[0], "winecpp")) opts.processor = proc_cpp;
  49. else if (strendswith(argv[0], "++")) opts.processor = proc_cxx;