Skip to content

Missing include for round() usage in tones.cc #108

Open
@jdapena

Description

@jdapena

Chromium build with GCC/libstdc++ library because of missing include in tones.cc. It should include math.h.

FAILED: obj/third_party/material_color_utilities/material_color_utilities/tones.o 
g++ -MMD -MF obj/third_party/material_color_utilities/material_color_utilities/tones.o.d -DUSE_UDEV -DUSE_AURA=1 -DUSE_GLIB=1 -DUSE_OZONE=1 -DOFFICIAL_BUILD -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D_FORTIFY_SOURCE=2 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -DNO_UNWIND_TABLES -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -I../.. -Igen -I../../third_party/material_color_utilities/src -I../../third_party/abseil-cpp -Wall -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations -Wno-comments -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -fno-ident -fno-strict-aliasing --param=ssp-buffer-size=4 -fstack-protector -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -pipe -pthread -m64 -msse3 -O2 -fdata-sections -ffunction-sections -fno-omit-frame-pointer -gdwarf-4 -g2 -gsplit-dwarf -fvisibility=hidden -Wno-narrowing -Wno-class-memaccess -std=gnu++2a -fno-exceptions -fno-rtti -fvisibility-inlines-hidden -c ../../third_party/material_color_utilities/src/cpp/palettes/tones.cc -o obj/third_party/material_color_utilities/material_color_utilities/tones.o
../../third_party/material_color_utilities/src/cpp/palettes/tones.cc: In member function ‘material_color_utilities::Hct material_color_utilities::TonalPalette::createKeyColor(double, double)’:
../../third_party/material_color_utilities/src/cpp/palettes/tones.cc:70:9: error: ‘round’ was not declared in this scope
   70 |     if (round(chroma) == round(smallest_delta_hct.get_chroma())) {
      |         ^~~~~

Metadata

Metadata

Assignees

No one assigned

    Labels

    quick(Label used internally)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions