void-packages/srcpkgs/mozc/patches/latomic.patch

135 lines
3.3 KiB
Diff

--- a/mozc/src/gui/gui.gyp
+++ b/mozc/src/gui/gui.gyp
@@ -794,6 +794,13 @@
'tool/mozc_tool_main_noqt.cc',
],
}],
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
# For Mac, ConfigDialog is the host app for necessary frameworks.
['OS=="win"', {
'product_name': '<(tool_product_name_win)',
--- a/mozc/src/gyp/defines.gypi
+++ b/mozc/src/gyp/defines.gypi
@@ -68,6 +68,9 @@
# use_libibus represents if ibus library is used or not.
# This option is only for Linux.
'use_libibus%': '0',
+
+ # use_libatomic represents if libatomic is required or not
+ 'use_libatomic%': '0',
},
'target_defaults': {
'defines': [
--- a/mozc/src/renderer/renderer.gyp
+++ b/mozc/src/renderer/renderer.gyp
@@ -600,6 +600,15 @@
'../base/base.gyp:crash_report_handler',
'mozc_renderer_lib',
],
+ 'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
+ ],
},
{
'target_name': 'gtk_renderer_test',
--- a/mozc/src/server/server.gyp
+++ b/mozc/src/server/server.gyp
@@ -55,6 +55,13 @@
'mozc_server_lib',
],
'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
['OS=="mac"', {
'product_name': '<(branding)Converter',
'sources': [
--- a/mozc/src/unix/emacs/emacs.gyp
+++ b/mozc/src/unix/emacs/emacs.gyp
@@ -47,6 +47,15 @@
'../../protocol/protocol.gyp:config_proto',
'mozc_emacs_helper_lib',
],
+ 'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
+ ],
},
{
'target_name': 'mozc_emacs_helper_lib',
--- a/mozc/src/unix/fcitx/fcitx.gyp
+++ b/mozc/src/unix/fcitx/fcitx.gyp
@@ -98,6 +98,15 @@
'defines': [
'LOCALEDIR="/usr/share/locale/"',
],
+ 'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
+ ],
},
],
}, {
--- a/mozc/src/unix/fcitx5/fcitx5.gyp
+++ b/mozc/src/unix/fcitx5/fcitx5.gyp
@@ -105,6 +105,15 @@
'defines': [
'FCITX_GETTEXT_DOMAIN="fcitx5-mozc"',
],
+ 'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
+ ],
},
],
}, {
--- a/mozc/src/unix/ibus/ibus.gyp
+++ b/mozc/src/unix/ibus/ibus.gyp
@@ -241,6 +241,15 @@
'ibus_mozc_lib',
'ibus_mozc_metadata',
],
+ 'conditions': [
+ ['use_libatomic==1', {
+ 'link_settings': {
+ 'libraries': [
+ '-latomic',
+ ],
+ },
+ }],
+ ],
},
{
'target_name': 'ibus_mozc_test',