Simplifying jpeg library header, and adding jpeg build target under tensorflow/core/platform.
PiperOrigin-RevId: 272099272
This commit is contained in:
parent
52143c2b49
commit
6f9c242cd0
@ -2571,7 +2571,7 @@ cc_library(
|
||||
deps = [
|
||||
":lib",
|
||||
":lib_internal",
|
||||
"//tensorflow/core/platform/default/build_config:jpeg",
|
||||
"//tensorflow/core/platform:jpeg",
|
||||
],
|
||||
)
|
||||
|
||||
@ -2657,8 +2657,8 @@ cc_library(
|
||||
linkopts = ["-ldl"],
|
||||
deps = [
|
||||
":core_stringpiece",
|
||||
"//tensorflow/core/platform:jpeg",
|
||||
"//tensorflow/core/platform:stringpiece",
|
||||
"//tensorflow/core/platform/default/build_config:jpeg",
|
||||
"//tensorflow/core/platform/default/build_config:logging",
|
||||
"@com_google_absl//absl/base:core_headers",
|
||||
"@com_google_absl//absl/strings",
|
||||
|
@ -242,6 +242,14 @@ cc_library(
|
||||
],
|
||||
)
|
||||
|
||||
cc_library(
|
||||
name = "jpeg",
|
||||
hdrs = ["jpeg.h"],
|
||||
deps = [
|
||||
"@libjpeg_turbo//:jpeg",
|
||||
],
|
||||
)
|
||||
|
||||
cc_library(
|
||||
name = "load_library",
|
||||
textual_hdrs = ["load_library.h"],
|
||||
|
@ -221,7 +221,7 @@ cc_library(
|
||||
name = "jpeg",
|
||||
copts = tf_copts(),
|
||||
deps = [
|
||||
"@jpeg",
|
||||
"@libjpeg_turbo//:jpeg",
|
||||
],
|
||||
)
|
||||
|
||||
|
@ -16,22 +16,14 @@ limitations under the License.
|
||||
#ifndef TENSORFLOW_CORE_PLATFORM_JPEG_H_
|
||||
#define TENSORFLOW_CORE_PLATFORM_JPEG_H_
|
||||
|
||||
#include "tensorflow/core/platform/platform.h"
|
||||
|
||||
#if defined(PLATFORM_GOOGLE) && !defined(IS_MOBILE_PLATFORM)
|
||||
#include "tensorflow/core/platform/google/build_config/jpeg.h"
|
||||
#elif defined(PLATFORM_POSIX) || defined(PLATFORM_WINDOWS) || \
|
||||
defined(PLATFORM_POSIX_ANDROID) || defined(IS_MOBILE_PLATFORM)
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
extern "C" {
|
||||
#include "jerror.h"
|
||||
#include "jpeglib.h"
|
||||
#include "jerror.h" // TF:libjpeg_turbo
|
||||
#include "jpeglib.h" // TF:libjpeg_turbo
|
||||
}
|
||||
#else
|
||||
#error Define the appropriate PLATFORM_<foo> macro for this platform
|
||||
#endif
|
||||
|
||||
#endif // TENSORFLOW_CORE_PLATFORM_JPEG_H_
|
||||
|
@ -153,7 +153,7 @@ genrule(
|
||||
"@highwayhash//:LICENSE",
|
||||
"@hwloc//:COPYING",
|
||||
"@icu//:icu4c/LICENSE",
|
||||
"@jpeg//:LICENSE.md",
|
||||
"@libjpeg_turbo//:LICENSE.md",
|
||||
"@lmdb//:LICENSE",
|
||||
"@local_config_sycl//sycl:LICENSE.text",
|
||||
"@local_config_tensorrt//:LICENSE",
|
||||
@ -225,7 +225,7 @@ genrule(
|
||||
"@highwayhash//:LICENSE",
|
||||
"@hwloc//:COPYING",
|
||||
"@icu//:icu4j/main/shared/licenses/LICENSE",
|
||||
"@jpeg//:LICENSE.md",
|
||||
"@libjpeg_turbo//:LICENSE.md",
|
||||
"@lmdb//:LICENSE",
|
||||
"@local_config_sycl//sycl:LICENSE.text",
|
||||
"@local_config_tensorrt//:LICENSE",
|
||||
|
@ -145,9 +145,9 @@ filegroup(
|
||||
"@highwayhash//:LICENSE",
|
||||
"@hwloc//:COPYING",
|
||||
"@icu//:icu4c/LICENSE",
|
||||
"@jpeg//:LICENSE.md",
|
||||
"@keras_applications_archive//:LICENSE",
|
||||
"@kissfft//:COPYING",
|
||||
"@libjpeg_turbo//:LICENSE.md",
|
||||
"@lmdb//:LICENSE",
|
||||
"@local_config_mlir//:LICENSE.TXT",
|
||||
"@local_config_sycl//sycl:LICENSE.text",
|
||||
|
2
third_party/jpeg/workspace.bzl
vendored
2
third_party/jpeg/workspace.bzl
vendored
@ -4,7 +4,7 @@ load("//third_party:repo.bzl", "third_party_http_archive")
|
||||
|
||||
def repo():
|
||||
third_party_http_archive(
|
||||
name = "jpeg",
|
||||
name = "libjpeg_turbo",
|
||||
urls = [
|
||||
"https://storage.googleapis.com/mirror.tensorflow.org/github.com/libjpeg-turbo/libjpeg-turbo/archive/2.0.0.tar.gz",
|
||||
"https://github.com/libjpeg-turbo/libjpeg-turbo/archive/2.0.0.tar.gz",
|
||||
|
2
third_party/nasm/BUILD.bazel
vendored
2
third_party/nasm/BUILD.bazel
vendored
@ -157,7 +157,7 @@ cc_binary(
|
||||
"output",
|
||||
"x86",
|
||||
],
|
||||
visibility = ["@jpeg//:__pkg__"],
|
||||
visibility = ["@libjpeg_turbo//:__pkg__"],
|
||||
)
|
||||
|
||||
config_setting(
|
||||
|
2
third_party/nasm/BUILD.system
vendored
2
third_party/nasm/BUILD.system
vendored
@ -8,5 +8,5 @@ filegroup(
|
||||
sh_binary(
|
||||
name = "nasm",
|
||||
srcs = ["nasm"],
|
||||
visibility = ["@jpeg//:__pkg__"],
|
||||
visibility = ["@libjpeg_turbo//:__pkg__"],
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user