Files
linux-nv-oot/drivers/media/platform/tegra/camera/Makefile
Jon Hunter e3fc979712 camera: Fix build when CONFIG_MEDIA_SUPPORT is not enabled
Some camera drivers are dependent upon CONFIG_MEDIA_SUPPORT being
enabled in the kernel and if it is not enabled, building these drivers
fail. Fix this by only building the camera drivers dependent upon
CONFIG_MEDIA_SUPPORT when this option is actually enabled.

Bug 4449072

Change-Id: I3637b5763667fbc9965bbeaf126115010e711c7e
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3050559
(cherry picked from commit 9de3e799ae)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3053101
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-01-15 23:54:55 -08:00

37 lines
1.3 KiB
Makefile

# SPDX-License-Identifier: GPL-2.0-only
# Copyright (c) 2022-2024, NVIDIA CORPORATION. All rights reserved.
ifdef CONFIG_MEDIA_SUPPORT
ifeq ($(findstring ack_src,$(NV_BUILD_KERNEL_OPTIONS)),)
LINUXINCLUDE += -I$(srctree.nvidia-oot)/drivers/video/tegra/camera
LINUXINCLUDE += -I$(srctree.nvidia-oot)/drivers/media/platform/tegra
LINUXINCLUDE += -DCONFIG_TEGRA_HOST1X
LINUXINCLUDE += -Werror
tegra-camera-objs := regmap_util.o
tegra-camera-objs += camera_common.o
tegra-camera-objs += camera_gpio.o
tegra-camera-objs += sensor_common.o
tegra-camera-objs += camera_version_utils.o
tegra-camera-objs += nvcamera_log.o
tegra-camera-objs += tegracam_v4l2.o
tegra-camera-objs += tegracam_core.o
tegra-camera-objs += tegracam_ctrls.o
tegra-camera-objs += tegracam_utils.o
tegra-camera-objs += vi/vi5_fops.o
tegra-camera-objs += vi/mc_common.o
tegra-camera-objs += vi/graph.o
tegra-camera-objs += vi/channel.o
tegra-camera-objs += vi/core.o
tegra-camera-objs += csi/csi.o
tegra-camera-objs += nvcsi/csi5_fops.o
tegra-camera-objs += fusa-capture/capture-vi.o
tegra-camera-objs += fusa-capture/capture-common.o
tegra-camera-objs += fusa-capture/capture-vi-channel.o
tegra-camera-objs += fusa-capture/capture-isp-channel.o
tegra-camera-objs += fusa-capture/capture-isp.o
obj-m += tegra-camera.o
obj-m += tests/
endif
endif