[gjs/mozjs91] build: Remove workaround for Meson precompiled headers bug



commit 7556788a3b6d6f5bf78d034935f55644bf6f79dc
Author: Philip Chimento <philip chimento gmail com>
Date:   Sat Oct 9 15:42:07 2021 -0700

    build: Remove workaround for Meson precompiled headers bug
    
    This bug was triggered by the "-include js/RequiredDefines.h" compiler
    flag that SpiderMonkey specified in its pkg-config file. This header no
    longer exists, so we should not have this bug anymore.

 meson.build | 15 +++------------
 1 file changed, 3 insertions(+), 12 deletions(-)
---
diff --git a/meson.build b/meson.build
index 7784c329..936711b2 100644
--- a/meson.build
+++ b/meson.build
@@ -512,14 +512,6 @@ if host_machine.system() == 'windows'
     libgjs_cpp_args += ['-DWIN32', '-DXP_WIN', '-DWIN32_LEAN_AND_MEAN']
 endif
 
-pch_headers = ['gjs/gjs_pch.hh']
-if get_option('b_pch') and not meson.version().version_compare('>= 0.59.0')
-    if cxx.get_id() == 'gcc'
-        warning('Precompiled headers not supported with g++ and meson versions earlier than 0.59.0')
-        pch_headers = []
-    endif
-endif
-
 # This dependency should provide everything that is needed to compile gjs except
 # the sources themselves, is used to copmile both the static libraries and the
 # tests
@@ -536,7 +528,7 @@ internal_build_dep = declare_dependency(
 
 libgjs_jsapi = static_library(meson.project_name() + '-jsapi',
     libgjs_jsapi_sources, probes_header, probes_objfile,
-    cpp_pch: pch_headers,
+    cpp_pch: 'gjs/gjs_pch.hh',
     dependencies: internal_build_dep,
     install: false)
 
@@ -545,7 +537,7 @@ libgjs_jsapi = static_library(meson.project_name() + '-jsapi',
 # library so that we compile its sources just once.
 libgjs_internal = static_library('gjs-internal',
     libgjs_sources, probes_header, probes_objfile,
-    cpp_pch: pch_headers,
+    cpp_pch: 'gjs/gjs_pch.hh',
     dependencies: internal_build_dep,
     link_with: libgjs_jsapi)
 
@@ -758,6 +750,5 @@ message('\n'.join([
     'Use readline for input in interactive shell and debugger: @0@'.format(
         build_readline),
     'Build profiler (Linux only): @0@'.format(build_profiler),
-    'Build with precompiled headers: @0@'.format(get_option('b_pch') and
-        pch_headers.length() > 0),
+    'Build with precompiled headers: @0@'.format(get_option('b_pch')),
 ]))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]