# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. config("libpng_public") { include_dirs = [ "." ] } source_set("libpng") { public_configs = [ ":libpng_public" ] cflags_c = [] defines = [] sources = [ "png.c", "pngerror.c", "pngget.c", "pngmem.c", "pngpread.c", "pngread.c", "pngrio.c", "pngrtran.c", "pngrutil.c", "pngset.c", "pngtrans.c", "pngwio.c", "pngwrite.c", "pngwtran.c", "pngwutil.c", ] if (current_cpu == "arm" || current_cpu == "arm64") { sources += [ "arm/arm_init.c", "arm/filter_neon.S", "arm/filter_neon_intrinsics.c", "arm/palette_neon_intrinsics.c", ] defines += [ "PNG_ARM_NEON_OPT=2" ] cflags_c += [ "-Wno-sign-compare" ] } if (is_win) { cflags_c += [ "-Wno-tautological-constant-out-of-range-compare" ] } deps = [ "//third_party/zlib", ] }