Bug 253447 - devel/libphonenumber: build error for can not find 'google/protobuf/inlined_string_field.h'
Summary: devel/libphonenumber: build error for can not find 'google/protobuf/inlined_s...
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-kde (Team)
Depends on:
Reported: 2021-02-12 06:14 UTC by marshall
Modified: 2021-02-16 21:44 UTC (History)
1 user (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description marshall 2021-02-12 06:14:37 UTC

    I tried to update software from source by ports, then find that kdepim-addons, kitinerary and libphonenumber can not build correctly.
    After read the Makefile inside their ports tree, I realized that kdepim-adeons depend on kitineray which depend on libphonenumber.
    When upgrade the libphonenumber, the first ERROR message is 

    "fatal error: 'google/protobuf/inlined_string_field.h' file not found"

    So I check the devel/protobuf plist file, and find that their is no such header file would install to the system.

    I also tried to find / -name 'inlined_string_field.h' in my whole computer, and nothing found.

    Now the devel/protobuf version is 3.14.0, which can not support to build /devel/libphonenumber.

    Please fixed that problem. Thanks.
Comment 1 marshall 2021-02-16 01:43:52 UTC
Hey Guys,
    Since there is no one response, I tried to fix it by my self, and finally done.
    It seems the older version of libphonenumber header files in /usr/local/include/phonenumber would need this 'google/protobuf/inlined_string_field.h'.
    When compiler it, the 'make' process automatically find the system include path instead of ports path of include file.
    So I delete the older version by 'make deinstall' to delete all /usr/local/include/phonenumber directory. Then re-make it.
    Now everything is fine!

    So, this bug is due to API change and the stupid c 'include <somepath/somefile.h>' mechanism.
    One should change the CMakeList.txt file to blacklist the /usr/local/include path. otherwise, this kind of ERROR would happen again and again!
Comment 2 Sunpoet Po-Chuan Hsieh freebsd_committer 2021-02-16 15:58:36 UTC
Fix summary and assign it to the maintainer.
Comment 3 Tobias C. Berner freebsd_committer 2021-02-16 21:44:34 UTC
(In reply to marshall from comment #1)
Moin moin 

It is advisable to build ports in poudriere or an other clean-room builder, so that exactly this issue won't happen.

Unfortunately it is generally not easy to make ports not pick up their own headers of the old version.

mfg Tobias