Let's add pkg-config and install headers since this is needed for ozone to build with a gbm platform. BUG=chromium:394868,chromium:402597,chromium:413947,chromium:412508 TEST=emerge minigbm, then try pkg-config-board --libs --cflags. Rejoice that it works! Change-Id: I94a26b1986db76e2d0dad638feda80ec10f48a9f Reviewed-on: https://chromium-review.googlesource.com/218979 Reviewed-by: Stéphane Marchesin <marcheu@chromium.org> Tested-by: Stéphane Marchesin <marcheu@chromium.org>
29 lines
819 B
Makefile
29 lines
819 B
Makefile
# Copyright 2014 The Chromium OS Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
include common.mk
|
|
|
|
PC_DEPS = libdrm
|
|
PC_CFLAGS := $(shell $(PKG_CONFIG) --cflags $(PC_DEPS))
|
|
PC_LIBS := $(shell $(PKG_CONFIG) --libs $(PC_DEPS))
|
|
|
|
CPPFLAGS += -std=c99 -D_GNU_SOURCE=1
|
|
CFLAGS += -Wall -Wsign-compare -Wpointer-arith -Wcast-qual -Wcast-align
|
|
|
|
CPPFLAGS += $(PC_CFLAGS)
|
|
LDLIBS += $(PC_LIBS)
|
|
|
|
LIBDIR ?= /usr/lib/
|
|
|
|
CC_LIBRARY(libgbm.so): $(C_OBJECTS)
|
|
|
|
all: CC_LIBRARY(libgbm.so)
|
|
|
|
clean: CLEAN(libgbm.so)
|
|
|
|
install: all
|
|
mkdir -p $(DESTDIR)/$(LIBDIR)
|
|
install -D -m 755 $(OUT)/libgbm.so $(DESTDIR)/$(LIBDIR)
|
|
install -D -m 0644 $(SRC)/libgbm.pc $(DESTDIR)$(LIBDIR)/pkgconfig/libgbm.pc
|
|
install -D -m 0644 $(SRC)/gbm.h $(DESTDIR)/usr/include/gbm.h
|