dptf: failed to build with clang. |
||
Issue description
With llvm-next, I got
mdelete called on non-final 'DptfTime' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor]^[[0m
delete __p;
^[[0;1;32m ^
,
Sep 21 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/05c06d0cc25d833711ac283a1873ee8208465755 commit 05c06d0cc25d833711ac283a1873ee8208465755 Author: Yunlian Jiang <yunlian@google.com> Date: Thu Sep 21 02:44:28 2017 dptf: fix delete-non-virtual-dtor warning. This fixes a warning delete-non-virtual-dtor by adding the attribute 'virtual' to destructuors of the classes that contains virtual functions. BUG= chromium:767227 TEST=The warning is gone. Change-Id: Ib74772c5c23dcf5a6d428e8a76b187aa70aed9d8 Reviewed-on: https://chromium-review.googlesource.com/676327 Reviewed-by: Brian Bian <brian.bian@intel.com> Reviewed-by: Manoj Gupta <manojgupta@chromium.org> Commit-Queue: Yunlian Jiang <yunlian@chromium.org> Tested-by: Yunlian Jiang <yunlian@chromium.org> Trybot-Ready: Yunlian Jiang <yunlian@chromium.org> [rename] https://crrev.com/05c06d0cc25d833711ac283a1873ee8208465755/sys-power/dptf/dptf-8.4.10100-r3.ebuild [add] https://crrev.com/05c06d0cc25d833711ac283a1873ee8208465755/sys-power/dptf/files/dptf-fix-delete-non-virtual-dtor.patch
,
Oct 2 2017
,
Oct 18 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/429726a3531a3f05f64ef771edc4bc41faec842a commit 429726a3531a3f05f64ef771edc4bc41faec842a Author: Brian Bian <brian.bian@intel.com> Date: Wed Oct 18 21:29:03 2017 Update ebuild file for DPTF release 8.4.10400 This release merges a few patches to the previous release (8.4.10100), as shown in the bug section below. It has also improved its capabilities to work with the new UI tuning tools. BUG=b:67399465 BUG= chromium:767227 TEST=None Change-Id: Ieda9be6fc13c8022cc689f692879267c6c8330c9 Signed-off-by: Brian Bian <brian.bian@intel.com> Reviewed-on: https://chromium-review.googlesource.com/722355 Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Sumeet R Pawnikar <sumeet.r.pawnikar@intel.com> Reviewed-by: Duncan Laurie <dlaurie@google.com> [delete] https://crrev.com/7ea42f456352086997ce818fef8bf30233c9eca6/sys-power/dptf/files/dptf-fix-unterminated-pragma.patch [delete] https://crrev.com/7ea42f456352086997ce818fef8bf30233c9eca6/sys-power/dptf/files/dptf.conf [delete] https://crrev.com/7ea42f456352086997ce818fef8bf30233c9eca6/sys-power/dptf/files/dptf-fix-delete-non-virtual-dtor.patch [rename] https://crrev.com/429726a3531a3f05f64ef771edc4bc41faec842a/sys-power/dptf/dptf-8.4.10400-r1.ebuild [modify] https://crrev.com/429726a3531a3f05f64ef771edc4bc41faec842a/sys-power/dptf/Manifest |
||
►
Sign in to add a comment |
||
Comment 1 by yunlian@chromium.org
, Sep 20 2017A more detailed log is In file included from ../../../dptf-8.4.10100/DPTF/Sources/Policies/PolicyLib/PolicyBase.cpp:19: In file included from ../../../dptf-8.4.10100/DPTF/Sources/Policies/PolicyLib/PolicyBase.h:21: In file included from ../../../dptf-8.4.10100/DPTF/Sources/SharedLib/BasicTypesLib/Dptf.h:42: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.x/include/g++-v4/memory:82: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.x/include/g++-v4/bits/shared_ptr.h:52: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.x/include/g++-v4/bits/shared_ptr_base.h:573:8: error: delete called on non-final 'DptfTime' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor] delete __p; ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.x/include/g++-v4/bits/shared_ptr_base.h:871:24: note: in instantiation of function template specialization 'std::__shared_count<__gnu_cxx::_Lock_policy::_S_atomic>::__shared_count<DptfTime *>' requested here : _M_ptr(__p), _M_refcount(__p) ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.x/include/g++-v4/bits/shared_ptr_base.h:1023:4: note: in instantiation of function template specialization 'std::__shared_ptr<TimeInterface, __gnu_cxx::_Lock_policy::_S_atomic>::__shared_ptr<DptfTime>' requested here __shared_ptr(__p).swap(*this); ^ ../../../dptf-8.4.10100/DPTF/Sources/Policies/PolicyLib/PolicyBase.cpp:27:9: note: in instantiation of function template specialization 'std::__shared_ptr<TimeInterface, __gnu_cxx::_Lock_policy::_S_atomic>::reset<DptfTime>' requested here m_time.reset(new DptfTime()); ^