]> The Tcpdump Group git mirrors - libpcap/commitdiff
Do not define __EXTENSIONS__ if already defined. [skip ci]
authorDenis Ovsienko <[email protected]>
Tue, 10 Aug 2021 10:33:09 +0000 (11:33 +0100)
committerGuy Harris <[email protected]>
Sun, 20 Feb 2022 23:14:27 +0000 (15:14 -0800)
Same as in tcpdump.

./ftmacros.h:48:11: warning: '__EXTENSIONS__' macro redefined
  [-Wmacro-redefined]
<built-in>:347:9: note: previous definition is here

(cherry picked from commit 895ff3ad146837eef8a5321cacd3cf15a3a329e4)

ftmacros.h

index 3cd750568785d738bb241577c35d2385029f8557..7975463b3a6924738ef7e1ffa72370f11006ada6 100644 (file)
  * namespace to the maximum extent possible"?
  */
 #if defined(sun) || defined(__sun)
-  #define __EXTENSIONS__
+  /*
+   * On Solaris Clang defines __EXTENSIONS__ automatically.
+   */
+  #ifndef __EXTENSIONS__
+    #define __EXTENSIONS__
+  #endif
 
   /*
    * We also need to define _XPG4_2 in order to get