Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pkgcfg and warn #3

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
24 changes: 9 additions & 15 deletions myenv.sh
Expand Up @@ -23,38 +23,32 @@
# Copyright 2013 Nexenta Systems, Inc. All rights reserved.
#

# Configuration variables for the runtime environment of the nightly
# build script and other tools for construction and packaging of releases.
# This script is sourced by 'nightly' and 'bldenv' to set up the environment.
# See illumos-gate/usr/src/tools/env for details.
export NIGHTLY_OPTIONS='-DCFlnpr'
# Configuration variables for the runtime environment of the
# "buildenv" script, and construction and packaging of releases.
# Note: gfx-drm does NOT contain cw tools etc, so turn OFF 't'
# See also: BUILD_TOOLS, ONBLD_TOOLS below.
export NIGHTLY_OPTIONS="-nrN +t"

# CODEMGR_WS - where is your workspace
export CODEMGR_WS=`git rev-parse --show-toplevel`

# This is a variable for the rest of the script - GATE doesn't matter to
# nightly itself.
GATE=`basename ${CODEMGR_WS}`

# Maximum number of dmake jobs. Small WS -- keep it simple.
export DMAKE_MAX_JOBS=4

# You should not need to change the next three lines
export ATLOG="$CODEMGR_WS/log"
export LOGFILE="$ATLOG/nightly.log"
export MACH="$(uname -p)"

# where is the proto area etc.
export MACH="$(uname -p)"
export ROOT="$CODEMGR_WS/proto/root_${MACH}"
export SRC="$CODEMGR_WS/usr/src"
export MULTI_PROTO="no"

#
# Build environment variables, including version info for mcs, etc.
# We want the git changeset hash.
# We want the git changeset hash. GATE, GIT_REV are just a locals.
GATE=`basename ${CODEMGR_WS}`
GIT_REV=`git rev-parse --short=10 HEAD`
export VERSION="${GATE}:${GIT_REV}"
export ONNV_BUILDNUM=152
export PKGVERS_BRANCH=2016.1

# export RELEASE='5.11'
# export RELEASE_DATE='October 2007'
Expand Down
2 changes: 1 addition & 1 deletion usr/src/Makefile.master
Expand Up @@ -368,7 +368,7 @@ XSTRCONST= -xstrconst

#
# turn warnings into errors (C)
CERRWARN = -errtags=yes # -errwarn=%all
CERRWARN = -errtags=yes -errwarn=%all
CERRWARN += -erroff=E_EMPTY_TRANSLATION_UNIT
CERRWARN += -erroff=E_STATEMENT_NOT_REACHED

Expand Down
4 changes: 4 additions & 0 deletions usr/src/cmd/drm-tests/Makefile.drm
Expand Up @@ -23,3 +23,7 @@ ROOTCMDDIR=$(ROOT)/opt/drm-tests

LIBUTIL32=$(SRC)/cmd/drm-tests/util/i386/libutil.a
LIBUTIL64=$(SRC)/cmd/drm-tests/util/amd64/libutil.a

# We don't really care about warnings in the tests.
CERRWARN += -_gcc=-Wno-parentheses
CERRWARN += -_gcc=-Wno-uninitialized
4 changes: 2 additions & 2 deletions usr/src/common/libdrm/Check-patches
Expand Up @@ -89,8 +89,8 @@ diff_ref intel -name '*.c' > $chk/intel-drm.patch
echo patches/omap.patch
diff_ref omap -name '*.c' > $chk/omap.patch

echo patches/rpath-pc.in.patch
diff_ref . -name '*.pc.in' > $chk/rpath-pc.in.patch
echo patches/pkgconfig-in.patch
diff_ref . -name '*.pc.in' > $chk/pkgconfig-in.patch

echo patches/incl-drm-drm-h.patch
( head -27 patches/incl-drm-drm-h.patch ;
Expand Down
5 changes: 4 additions & 1 deletion usr/src/common/libdrm/Makefile.drm
Expand Up @@ -26,7 +26,7 @@ ROOTLIBDIR64 = $(ROOT)/usr/lib/xorg/$(MACH64)

CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE

# Defines that would normally come from autoconf. ook through
# Defines that would normally come from autoconf. Look through
# libdrm-$(LIBDRM_VERS)/config.h.in when updating libdrm to
# check for new ones we might need to define.
CPPFLAGS += -DHAVE_ALLOCA_H
Expand All @@ -39,3 +39,6 @@ CPPFLAGS += -DMAJOR_IN_MKDEV
CPPFLAGS += -I$(SRC)/uts/common \
-I$(SRC)/uts/common/drm \
-I$(LIBDRM_CMN_DIR)/include/drm

# The libdrm code has lots of parentheses warnings. Suppress.
CERRWARN += -_gcc=-Wno-parentheses
44 changes: 35 additions & 9 deletions usr/src/common/libdrm/patches/exynos.patch
@@ -1,6 +1,6 @@
diff ... libdrm-2.4.71/exynos/exynos_drm.c
--- libdrm-2.4.71-ref/exynos/exynos_drm.c Thu Apr 21 09:40:06 2016
+++ libdrm-2.4.71/exynos/exynos_drm.c Sat Nov 19 21:07:12 2016
diff ... libdrm-2.4.73/exynos/exynos_drm.c
--- libdrm-2.4.73-ref/exynos/exynos_drm.c Wed Aug 24 12:57:39 2016
+++ libdrm-2.4.73/exynos/exynos_drm.c Sat Dec 31 12:27:53 2016
@@ -35,7 +35,7 @@
#include <unistd.h>

Expand All @@ -10,9 +10,9 @@ diff ... libdrm-2.4.71/exynos/exynos_drm.c

#include <xf86drm.h>

diff ... libdrm-2.4.71/exynos/exynos_fimg2d.c
--- libdrm-2.4.71-ref/exynos/exynos_fimg2d.c Sun Jan 17 16:22:14 2016
+++ libdrm-2.4.71/exynos/exynos_fimg2d.c Sat Nov 19 21:07:12 2016
diff ... libdrm-2.4.73/exynos/exynos_fimg2d.c
--- libdrm-2.4.73-ref/exynos/exynos_fimg2d.c Wed Aug 24 12:57:39 2016
+++ libdrm-2.4.73/exynos/exynos_fimg2d.c Sat Dec 31 17:52:27 2016
@@ -21,7 +21,7 @@
#include <assert.h>

Expand All @@ -22,9 +22,35 @@ diff ... libdrm-2.4.71/exynos/exynos_fimg2d.c

#include <xf86drm.h>

diff ... libdrm-2.4.71/tests/exynos/exynos_fimg2d_test.c
--- libdrm-2.4.71-ref/tests/exynos/exynos_fimg2d_test.c Sun Jan 17 16:22:14 2016
+++ libdrm-2.4.71/tests/exynos/exynos_fimg2d_test.c Sat Nov 19 21:07:12 2016
@@ -698,9 +698,10 @@
if (negative)
negative = 1;

- if (src_w == dst_w && src_h == dst_h)
+ if (src_w == dst_w && src_h == dst_h) {
scale = 0;
- else {
+ scale_x = scale_y = 0; /* GCC warnings */
+ } else {
scale = 1;
scale_x = g2d_get_scaling(src_w, dst_w);
scale_y = g2d_get_scaling(src_h, dst_h);
@@ -920,9 +921,10 @@
unsigned int scale, gem_space;
unsigned int scale_x, scale_y;

- if (src_w == dst_w && src_h == dst_h)
+ if (src_w == dst_w && src_h == dst_h) {
scale = 0;
- else {
+ scale_x = scale_y = 0; /* GCC warnings */
+ } else {
scale = 1;
scale_x = g2d_get_scaling(src_w, dst_w);
scale_y = g2d_get_scaling(src_h, dst_h);
diff ... libdrm-2.4.73/tests/exynos/exynos_fimg2d_test.c
--- libdrm-2.4.73-ref/tests/exynos/exynos_fimg2d_test.c Wed Aug 24 12:57:39 2016
+++ libdrm-2.4.73/tests/exynos/exynos_fimg2d_test.c Sat Dec 31 12:27:53 2016
@@ -22,7 +22,7 @@
#include <unistd.h>

Expand Down
18 changes: 16 additions & 2 deletions usr/src/common/libdrm/patches/freedreno.patch
@@ -1,5 +1,6 @@
--- libdrm-2.4.70/freedreno/kgsl/kgsl_bo.c.orig 2016-09-14 01:56:02.447145494 +0200
+++ libdrm-2.4.70/freedreno/kgsl/kgsl_bo.c 2016-09-14 01:57:13.859602672 +0200
diff ... libdrm-2.4.73/freedreno/kgsl/kgsl_bo.c
--- libdrm-2.4.73-ref/freedreno/kgsl/kgsl_bo.c Wed Aug 24 12:57:41 2016
+++ libdrm-2.4.73/freedreno/kgsl/kgsl_bo.c Sat Dec 31 12:27:53 2016
@@ -32,7 +32,12 @@

#include "kgsl_priv.h"
Expand All @@ -13,3 +14,16 @@

static int set_memtype(struct fd_device *dev, uint32_t handle, uint32_t flags)
{
diff ... libdrm-2.4.73/freedreno/kgsl/kgsl_ringbuffer.c
--- libdrm-2.4.73-ref/freedreno/kgsl/kgsl_ringbuffer.c Mon Nov 14 12:55:20 2016
+++ libdrm-2.4.73/freedreno/kgsl/kgsl_ringbuffer.c Sat Dec 31 18:02:19 2016
@@ -146,7 +146,8 @@
ibdesc.gpuaddr = kgsl_ring->bo->gpuaddr;
ibdesc.hostptr = kgsl_ring->bo->hostptr;
ibdesc.sizedwords = 0x145;
- req.timestamp = (uint32_t)kgsl_ring->bo->hostptr;
+ /* This way to avoid GCC -Wpointer-to-int-cast */
+ req.timestamp = (unsigned int) (unsigned long) kgsl_ring->bo->hostptr;
}

do {
97 changes: 0 additions & 97 deletions usr/src/common/libdrm/patches/includedir-pc.in.patch

This file was deleted.

13 changes: 12 additions & 1 deletion usr/src/common/libdrm/patches/intel-drm.patch
@@ -1,6 +1,6 @@
diff ... libdrm-2.4.73/intel/intel_bufmgr_gem.c
--- libdrm-2.4.73-ref/intel/intel_bufmgr_gem.c Mon Nov 14 14:48:04 2016
+++ libdrm-2.4.73/intel/intel_bufmgr_gem.c Mon Nov 28 14:37:11 2016
+++ libdrm-2.4.73/intel/intel_bufmgr_gem.c Sat Dec 31 12:27:53 2016
@@ -3352,6 +3352,16 @@
static pthread_mutex_t bufmgr_list_mutex = PTHREAD_MUTEX_INITIALIZER;
static drmMMListHead bufmgr_list = { &bufmgr_list, &bufmgr_list };
Expand Down Expand Up @@ -28,3 +28,14 @@ diff ... libdrm-2.4.73/intel/intel_bufmgr_gem.c
atomic_inc(&bufmgr_gem->refcount);
return bufmgr_gem;
}
diff ... libdrm-2.4.73/intel/intel_decode.c
--- libdrm-2.4.73-ref/intel/intel_decode.c Wed Aug 24 12:57:39 2016
+++ libdrm-2.4.73/intel/intel_decode.c Sat Dec 31 17:49:32 2016
@@ -402,6 +402,7 @@
format = "1555";
break;
case 3:
+ default: /* Keep GCC happy. */
format = "8888";
break;
}