Bug 263448 - Build fix: add gtest dependency to gmock project
Summary: Build fix: add gtest dependency to gmock project
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: David Kilzer (:ddkilzer)
URL:
Keywords: InRadar
Depends on: 263225
Blocks:
  Show dependency treegraph
 
Reported: 2023-10-20 09:47 PDT by David Kilzer (:ddkilzer)
Modified: 2023-10-20 13:04 PDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Kilzer (:ddkilzer) 2023-10-20 09:47:30 PDT
Build fix: add gtest dependency to gmock project.

The gmock project depends on headers from the gtest project, but Xcode is not aware of this dependency, so gmock can sometimes build before gtest, resulting in a build failure:

```
In file included from OpenSource/Source/ThirdParty/gmock/src/gmock-all.cc:39:
In file included from include/gmock/gmock.h:59:
In file included from include/gmock/gmock-actions.h:145:
In file included from include/gmock/internal/gmock-internal-utils.h:46:
include/gmock/internal/gmock-port.h:56:10: fatal error: 'gtest/internal/gtest-port.h' file not found
#include <gtest/internal/gtest-port.h>
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/gmock/internal/gmock-port.h:56:10: note: did not find header 'internal/gtest-port.h' in framework 'gtest' (loaded from 'OpenSource/WebKitBuild/Release')
1 error generated.
```
Comment 1 Radar WebKit Bug Importer 2023-10-20 09:47:45 PDT
<rdar://problem/117266314>
Comment 2 David Kilzer (:ddkilzer) 2023-10-20 10:21:59 PDT
Pull request: https://github.com/WebKit/WebKit/pull/19347
Comment 3 EWS 2023-10-20 13:04:08 PDT
Committed 269581@main (14adb9294c87): <https://commits.webkit.org/269581@main>

Reviewed commits have been landed. Closing PR #19347 and removing active labels.