git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Compile Error v2.13.2 on Solaris SPARC

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 27, 2017, 17:38 UTC
Message-ID
<xmqq1sq52uwj.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20170627162808.p7sj3jpwum7n3hq2@oracle.com>
"Liam R. Howlett" <Liam.Howlett@Oracle.com> writes:
Show 18 quoted lines
> How about:
>
> ---- 8< ----
> diff --git a/sha1dc/sha1.c b/sha1dc/sha1.c
> index facea1bb5..ed8c63f2d 100644
> --- a/sha1dc/sha1.c
> +++ b/sha1dc/sha1.c
> @@ -38,9 +38,18 @@
>  
>  #if (defined(_BYTE_ORDER) || defined(__BYTE_ORDER) || defined(__BYTE_ORDER__))
>  
> +#define EMPTY_VAL(x) x ## 1
> +#define EMPTY(x) EMPTY_VAL(x)
> +
> +#if (defined(_BIG_ENDIAN) && (EMPTY(_BIG_ENDIAN) == 1))
> +#undef _BIG_ENDIAN
> +#define _BIG_ENDIAN 4321
> +#endif

I'd say it is a bad idea to define a symbol that you _know_ a platform header file defines. Any header you may include from the platform after these lines still expects the symbol to be defined in a way it defines without getting molested and will misbehave.

Previous: Liam R. HowlettNext: Liam R. Howlett
Message 47 of 50 in “Compile Error v2.13.2 on Solaris SPARC”
  1. Michael KebeJun 26, 2017
  2. 0/3 update sha1dc from PR #36Ævar Arnfjörð Bjarmason, Jun 27, 2017
  3. 1/3 sha1dc: update from my PR #36Ævar Arnfjörð Bjarmason, Jun 27, 2017
  4. Junio C HamanoJun 27, 2017
  5. Junio C HamanoJun 27, 2017
  6. Ævar Arnfjörð BjarmasonJun 27, 2017
  7. Junio C HamanoJun 27, 2017
  8. Liam R. HowlettJun 27, 2017
  9. Ævar Arnfjörð BjarmasonJun 27, 2017
  10. Junio C HamanoJun 27, 2017
  11. Junio C HamanoJun 27, 2017
  12. Ævar Arnfjörð BjarmasonJun 27, 2017
  13. Junio C HamanoJun 27, 2017
  14. Liam R. HowlettJun 27, 2017
  15. Junio C HamanoJun 27, 2017
  16. Ævar Arnfjörð BjarmasonJun 27, 2017
  17. Junio C HamanoJun 27, 2017
  18. Ævar Arnfjörð BjarmasonJun 27, 2017
  19. Junio C HamanoJun 27, 2017
  20. Junio C HamanoJun 27, 2017
  21. Ævar Arnfjörð BjarmasonJun 27, 2017
  22. 2/3 sha1dc: optionally use sha1collisiondetection as a submoduleÆvar Arnfjörð Bjarmason, Jun 27, 2017
  23. Stefan BellerJun 27, 2017
  24. Ævar Arnfjörð BjarmasonJun 27, 2017
  25. 3/3 sha1collisiondetection: automatically enable when submodule is populatedÆvar Arnfjörð Bjarmason, Jun 27, 2017
  26. Stefan BellerJun 27, 2017
  27. 0/3 Update sha1dc from upstreamÆvar Arnfjörð Bjarmason, Jul 1, 2017
  28. 2/3 sha1dc: optionally use sha1collisiondetection as a submoduleÆvar Arnfjörð Bjarmason, Jul 1, 2017
  29. Junio C HamanoJul 3, 2017
  30. Ævar Arnfjörð BjarmasonJul 3, 2017
  31. Junio C HamanoJul 4, 2017
  32. Ævar Arnfjörð BjarmasonJul 4, 2017
  33. Stefan BellerJul 5, 2017
  34. Junio C HamanoJul 5, 2017
  35. Stefan BellerJul 5, 2017
  36. Ævar Arnfjörð BjarmasonJul 5, 2017
  37. 1/3 sha1dc: update from upstreamÆvar Arnfjörð Bjarmason, Jul 1, 2017
  38. 3/3 sha1collisiondetection: automatically enable when submodule is populatedÆvar Arnfjörð Bjarmason, Jul 1, 2017
  39. Michael KebeJun 26, 2017
  40. Ævar Arnfjörð BjarmasonJun 26, 2017
  41. Michael KebeJun 26, 2017
  42. Ævar Arnfjörð BjarmasonJun 26, 2017
  43. Liam R. HowlettJun 26, 2017
  44. Michael KebeJun 27, 2017
  45. Michael KebeJun 27, 2017
  46. Liam R. HowlettJun 27, 2017
  47. Junio C HamanoJun 27, 2017
  48. Liam R. HowlettJun 27, 2017
  49. Ævar Arnfjörð BjarmasonJun 27, 2017
  50. Ævar Arnfjörð BjarmasonJun 27, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.