Skip to contentSkip to conversation

gtest and gmock not added to SDK

DISCUSSION Tom Hochstein 3 participants 5 messages May 22, 2020

lore
Share & tools
lore
#0 lore raw

The gtest and gmock packages provided by googletest are not added to the SDK by default. I assume it is because the googletest main package is empty?

I added an RDEPENDS_${PN} from the dependent package to fix it. Is there a better solution?

Tom

#1 lore raw
Quoted 3 lines · Tom Hochstein

The gtest and gmock packages provided by googletest are not added to the SDK by default. I assume it is because the googletest main package is empty?

I added an RDEPENDS_${PN} from the dependent package to fix it. Is there a better solution?

You can change the packages to have their -dev to rdepends on gtest/gmock-dev for example.

Signature · 3 lines
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854          Mobile: +1 (347) 903-9750
#2 lore raw
Quoted 3 lines · Otavio Salvador
Quoted 1 line · Tom Hochstein

The gtest and gmock packages provided by googletest are not added to the SDK by default. I assume it is because the googletest main package is empty?

Are you including googletest in the image used to create the SDK or gmock and gtest?

It looks like gmock and gtest are only mentioned in the googletest recipe as PROVIDES, so they are aliases for build time dependencies only. For run time dependencies you should use googletest.

Quoted 10 lines
Quoted 1 line

I added an RDEPENDS_${PN} from the dependent package to fix it. Is there a better solution?

You can change the packages to have their -dev to rdepends on gtest/gmock-dev for example.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.br http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854 Mobile: +1 (347) 903-9750

#3 lore raw
Quoted 13 lines · Andre McCurdy
Quoted 8 lines · Otavio Salvador
Quoted 3 lines · Tom Hochstein

The gtest and gmock packages provided by googletest are not added to the SDK by default. I assume it is because the googletest main package is empty?

Quoted 6 lines

Are you including googletest in the image used to create the SDK or gmock and gtest?

It looks like gmock and gtest are only mentioned in the googletest recipe as PROVIDES, so they are aliases for build time dependencies only. For run time dependencies you should use googletest.

Right, I should have mentioned that. I have a DEPENDS on gtest for a package in my image. To fix the SDK, I added an RDEPENDS on googletest from the same package.

Quoted 16 lines
Quoted 14 lines
Quoted 6 lines

I added an RDEPENDS_${PN} from the dependent package to fix it. Is there a better solution?

You can change the packages to have their -dev to rdepends on gtest/gmock-dev for example.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.br http://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854 Mobile: +1 (347) 903-9750

#4 lore raw
Quoted 5 lines · Tom Hochstein

On Fri, May 22, 2020 at 03:33 PM, Andre McCurdy wrote:
On Fri, May 22, 2020 at 5:48 PM Tom Hochstein <[email protected]> wrote:

The gtest and gmock packages provided by googletest are not added to the SDK by default. I assume it is because the googletest main package is empty?

Quoted 8 lines

Are you including googletest in the image used to create the SDK or gmock and gtest?

It looks like gmock and gtest are only mentioned in the googletest recipe as PROVIDES, so they are aliases for build time dependencies only. For run time dependencies you should use googletest.

Right, I should have mentioned that. I have a DEPENDS on gtest for a package in my image. To fix the SDK, I added an RDEPENDS on googletest from the same package.

What you have done is probably the best solution. You could alternatively add googletest to the image.