]> git.eshelyaron.com Git - emacs.git/commitdiff
Silence some macOS build warnings
authorMattias EngdegÄrd <mattiase@acm.org>
Sun, 12 May 2024 12:55:55 +0000 (14:55 +0200)
committerEshel Yaron <me@eshelyaron.com>
Sun, 12 May 2024 15:49:43 +0000 (17:49 +0200)
* src/image.c (native_image_type): Declare static.
* src/keyboard.c (lispy_function_keys): Declare static on NS.
* src/nsmenu.m (context_menu_value):
* src/nsterm.m (ns_frame_parm_handlers): Move extern declarations...
* src/nsterm.h: ...here.
* test/src/emacs-module-resources/mod-test.c: Add extern declaration.

(cherry picked from commit 9365feadccf1e28438e41c4ce8bf60ab8e4e1def)

src/image.c
src/keyboard.c
src/nsmenu.m
src/nsterm.h
src/nsterm.m
test/src/emacs-module-resources/mod-test.c

index e93fc3183af9a26c8e84897de9c5a6b863e8c292..3138ef25a639b60c400b4083c9b23b9fdf882af6 100644 (file)
@@ -12744,7 +12744,7 @@ static struct image_type const image_types[] =
 };
 
 #if HAVE_NATIVE_IMAGE_API
-struct image_type native_image_type =
+static struct image_type native_image_type =
   { SYMBOL_INDEX (Qnative_image), native_image_p, native_image_load,
     image_clear_image };
 #endif
index dff86bbca13c85d627e6b4e1e083cbae3f2e3921..d5892115e4b246a88f46c14d35b125d66f466dba 100644 (file)
@@ -5396,6 +5396,10 @@ static const char *const lispy_kana_keys[] =
 
 /* You'll notice that this table is arranged to be conveniently
    indexed by X Windows keysym values.  */
+#ifdef HAVE_NS
+/* FIXME: Why are we using X11 keysym values for NS?  */
+static
+#endif
 const char *const lispy_function_keys[] =
   {
     /* X Keysym value */
index 0d21f7d03d32f364833954c8a4f28951d783c4d1..46ee9e1c3fc29e279715caac8234890493390b35 100644 (file)
@@ -47,7 +47,6 @@ Carbon version by Yamamoto Mitsuharu. */
 #endif
 
 
-extern long context_menu_value;
 EmacsMenu *svcsMenu;
 /* Nonzero means a menu is currently active.  */
 static int popup_activated_flag;
index ae940ec5b4fed0935fcc7dba73dd91fc91dda792..3a713f8e8c949000c6e3b80d562156d7ba7c451b 100644 (file)
@@ -921,6 +921,8 @@ struct ns_display_info
 /* This is a chain of structures for all the NS displays currently in use.  */
 extern struct ns_display_info *x_display_list;
 
+extern long context_menu_value;
+
 struct ns_output
 {
 #ifdef __OBJC__
@@ -1269,6 +1271,8 @@ extern void ns_finish_events (void);
 
 extern double ns_frame_scale_factor (struct frame *);
 
+extern frame_parm_handler ns_frame_parm_handlers[];
+
 #ifdef NS_IMPL_GNUSTEP
 extern char gnustep_base_version[];  /* version tracking */
 #endif
index f26cdb17903add009ddea7569bdddaca730691b1..794630de1c118883a6d3badd2555383df99842a3 100644 (file)
@@ -5438,7 +5438,6 @@ ns_flush_display (struct frame *f)
    redisplay interface.  In addition, many of the ns_ methods have
    code that is shared with all terms, indicating need for further
    refactoring.  */
-extern frame_parm_handler ns_frame_parm_handlers[];
 static struct redisplay_interface ns_redisplay_interface =
 {
   ns_frame_parm_handlers,
index 3aafae1b896d538a5881e5f47c0e219e906c6318..3abe2a4122bc9c3e36c68220359c2b015b27f04f 100644 (file)
@@ -46,6 +46,7 @@ uintptr_t _beginthread (void (__cdecl *) (void *), unsigned, void *);
 #include <gmp.h>
 #include <emacs-module.h>
 
+extern int plugin_is_GPL_compatible;
 int plugin_is_GPL_compatible;
 
 #if INTPTR_MAX <= 0