1# 2D Fast Fourier Transform package 2# from http://momonga.t.u-tokyo.ac.jp/~ooura/fft2d.html 3 4package( 5 default_visibility = ["//visibility:public"], 6) 7 8# Unrestricted use; can only distribute original package. 9licenses(["notice"]) 10 11exports_files(["readme2d.txt"]) 12 13FFT2D_SRCS = [ 14 "fftsg.c", 15 "fftsg2d.c", 16] 17 18config_setting( 19 name = "windows", 20 values = {"cpu": "x64_windows"}, 21) 22 23# This is the main 2D FFT library. The 2D FFTs in this library call 24# 1D FFTs. In addition, fast DCTs are provided for the special case 25# of 8x8 and 16x16. This code in this library is referred to as 26# "Version II" on http://momonga.t.u-tokyo.ac.jp/~ooura/fft2d.html. 27cc_library( 28 name = "fft2d", 29 srcs = FFT2D_SRCS, 30 linkopts = select({ 31 ":windows": [], 32 "//conditions:default": ["-lm"], 33 }), 34) 35 36objc_library( 37 name = "fft2d_ios", 38 srcs = FFT2D_SRCS, 39) 40 41# Export the source code so that it could be compiled for Andoid native apps. 42filegroup( 43 name = "fft2d_srcs", 44 srcs = FFT2D_SRCS, 45) 46