Re: [Mesa-dev] [PATCH v2 06/12] meson: Build i965 and dri stack

2017-10-06 Thread Dylan Baker
Quoting Daniel Stone (2017-10-06 03:25:15)
> Hi,
> 
> On 5 October 2017 at 18:12, Dylan Baker  wrote:
> > This gets pretty much the entire classic tree building, as well as
> > i965, including the various glapis. There are some workarounds for bugs
> > that are fixed in meson 0.43.0, which is due out on October 8th.
> 
> I'm not really sure what prompt you typed the wrong thing into, but
> somehow this patch is declared to have a charset of 'true', rather
> than UTF-8.
> 
> Cheers,
> Daniel

Wow, I'm not sure what I did either. Strange.

Dylan


signature.asc
Description: signature
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH v2 06/12] meson: Build i965 and dri stack

2017-10-06 Thread Daniel Stone
Hi,

On 5 October 2017 at 18:12, Dylan Baker  wrote:
> This gets pretty much the entire classic tree building, as well as
> i965, including the various glapis. There are some workarounds for bugs
> that are fixed in meson 0.43.0, which is due out on October 8th.

I'm not really sure what prompt you typed the wrong thing into, but
somehow this patch is declared to have a charset of 'true', rather
than UTF-8.

Cheers,
Daniel
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH v2 06/12] meson: Build i965 and dri stack

2017-10-05 Thread Dylan Baker
Quoting Eric Anholt (2017-10-05 12:57:41)
> Dylan Baker  writes:
> 
> > This gets pretty much the entire classic tree building, as well as
> > i965, including the various glapis. There are some workarounds for bugs
> > that are fixed in meson 0.43.0, which is due out on October 8th.
> >
> > I have tested this with piglit using glx.
> >
> > v2: - fix typo "vaule" -> "value"
> > - use gtest dep instead of linking to libgtest (rebase error)
> > - use gtest dep instead of linking against libgtest (rebase error)
> > - copy the megadriver, then create hard links from that, then delete
> >   the megadriver. This matches the behavior of the autotools build.
> >   (Eric A)
> > - Use host_machine instead of target_machine (Eric A)
> > - Put a comment in the right place (Eric A)
> > - Don't have two variables for the same information (Eric A)
> > - Put pre_args at top of file in this patch (Eric A)
> > - Fix glx generators in this patch instead of next (Eric A)
> > - Remove -DMESON hack (Eric A)
> > - add sha1_h to mesa in this patch (Eric A)
> > - Put generators in loops when possible to reduce code in
> >   mapi/glapi/gen (Eric A)
> >
> > Signed-off-by: Dylan Baker 
> 
> > +pkg.generate(
> > +  libraries : libglesv1_cm,
> > +  # TODO: private libraries?
> > +  name : 'glesv1_cm',
> > +  version : meson.project_version(),
> > +  description : 'Mesa OpenGL ES 1.1 CM library',
> > +  filebase : 'glesv1_cm'
> > +)
> 
> I'd like to make sure we get these right, since our piglit/cts runs
> won't tell us if we screw it up.  Looks like we want libraries_private:
> m_dep, dl_dep, dep_thread.  Same for glesv2.

Okay. Currently that means passing strings to those arguments, and I couldn't
find any clever way to tease the dependency/library objects to to produce
strings, so I hadn't done that yet.. I have a meson branch that allows passing
dependency objects as well, but meson is in feature freeze for 0.43 (on the
8th), nirbheek suggested that we could actually just get that information from
the arguments to libraries as well. So I'll work on getting one of those two
features upstream so we can forget about setting *_private.

Dylan

> 
> With that fixed, I'd give it:
> 
> Reviewed-by: Eric Anholt 


signature.asc
Description: signature
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH v2 06/12] meson: Build i965 and dri stack

2017-10-05 Thread Eric Anholt
Dylan Baker  writes:

> This gets pretty much the entire classic tree building, as well as
> i965, including the various glapis. There are some workarounds for bugs
> that are fixed in meson 0.43.0, which is due out on October 8th.
>
> I have tested this with piglit using glx.
>
> v2: - fix typo "vaule" -> "value"
> - use gtest dep instead of linking to libgtest (rebase error)
> - use gtest dep instead of linking against libgtest (rebase error)
> - copy the megadriver, then create hard links from that, then delete
>   the megadriver. This matches the behavior of the autotools build.
>   (Eric A)
> - Use host_machine instead of target_machine (Eric A)
> - Put a comment in the right place (Eric A)
> - Don't have two variables for the same information (Eric A)
> - Put pre_args at top of file in this patch (Eric A)
> - Fix glx generators in this patch instead of next (Eric A)
> - Remove -DMESON hack (Eric A)
> - add sha1_h to mesa in this patch (Eric A)
> - Put generators in loops when possible to reduce code in
>   mapi/glapi/gen (Eric A)
>
> Signed-off-by: Dylan Baker 

> +pkg.generate(
> +  libraries : libglesv1_cm,
> +  # TODO: private libraries?
> +  name : 'glesv1_cm',
> +  version : meson.project_version(),
> +  description : 'Mesa OpenGL ES 1.1 CM library',
> +  filebase : 'glesv1_cm'
> +)

I'd like to make sure we get these right, since our piglit/cts runs
won't tell us if we screw it up.  Looks like we want libraries_private:
m_dep, dl_dep, dep_thread.  Same for glesv2.

With that fixed, I'd give it:

Reviewed-by: Eric Anholt 


signature.asc
Description: PGP signature
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH v2 06/12] meson: Build i965 and dri stack

2017-10-05 Thread Dylan Baker
This gets pretty much the entire classic tree building, as well as
i965, including the various glapis. There are some workarounds for bugs
that are fixed in meson 0.43.0, which is due out on October 8th.

I have tested this with piglit using glx.

v2: - fix typo "vaule" -> "value"
- use gtest dep instead of linking to libgtest (rebase error)
- use gtest dep instead of linking against libgtest (rebase error)
- copy the megadriver, then create hard links from that, then delete
  the megadriver. This matches the behavior of the autotools build.
  (Eric A)
- Use host_machine instead of target_machine (Eric A)
- Put a comment in the right place (Eric A)
- Don't have two variables for the same information (Eric A)
- Put pre_args at top of file in this patch (Eric A)
- Fix glx generators in this patch instead of next (Eric A)
- Remove -DMESON hack (Eric A)
- add sha1_h to mesa in this patch (Eric A)
- Put generators in loops when possible to reduce code in
  mapi/glapi/gen (Eric A)

Signed-off-by: Dylan Baker 
---
 src/meson.build => bin/install_megadrivers.py  |  63 ++-
 include/meson.build|  38 ++
 meson.build| 111 +++-
 meson_options.txt  |  12 +
 src/compiler/{ => glsl/glcpp}/meson.build  |  57 +-
 src/compiler/glsl/meson.build  | 229 +++-
 src/compiler/glsl/tests/meson.build|  76 +++
 src/compiler/meson.build   |  12 +-
 src/git_sha1.h.in  |   1 +
 src/{compiler/glsl => mapi/es1api}/meson.build |  39 +-
 src/{compiler/glsl => mapi/es2api}/meson.build |  38 +-
 src/mapi/glapi/gen/meson.build | 249 +
 src/mapi/glapi/meson.build |  82 +++
 {include => src/mapi}/meson.build  |  19 +-
 src/mapi/shared-glapi/meson.build  |  61 +++
 .../glsl => mesa/drivers/dri/common}/meson.build   |  24 +-
 src/mesa/drivers/dri/i965/meson.build  | 178 +++
 src/{ => mesa/drivers/dri}/meson.build |  63 ++-
 src/{compiler/glsl => mesa/main}/meson.build   |  29 +-
 src/mesa/meson.build   | 582 +
 src/{compiler/glsl => mesa/program}/meson.build|  18 +-
 src/meson.build|  26 +-
 src/util/meson.build   |   3 +-
 src/{compiler/glsl => util/xmlpool}/meson.build|  13 +-
 24 files changed, 1869 insertions(+), 154 deletions(-)
 copy src/meson.build => bin/install_megadrivers.py (54%)
 mode change 100644 => 100755
 copy src/compiler/{ => glsl/glcpp}/meson.build (58%)
 create mode 100644 src/compiler/glsl/tests/meson.build
 create mode 100644 src/git_sha1.h.in
 copy src/{compiler/glsl => mapi/es1api}/meson.build (53%)
 copy src/{compiler/glsl => mapi/es2api}/meson.build (54%)
 create mode 100644 src/mapi/glapi/meson.build
 copy {include => src/mapi}/meson.build (81%)
 create mode 100644 src/mapi/shared-glapi/meson.build
 copy src/{compiler/glsl => mesa/drivers/dri/common}/meson.build (69%)
 create mode 100644 src/mesa/drivers/dri/i965/meson.build
 copy src/{ => mesa/drivers/dri}/meson.build (53%)
 copy src/{compiler/glsl => mesa/main}/meson.build (55%)
 create mode 100644 src/mesa/meson.build
 copy src/{compiler/glsl => mesa/program}/meson.build (74%)
 copy src/{compiler/glsl => util/xmlpool}/meson.build (80%)

diff --git a/src/meson.build b/bin/install_megadrivers.py
old mode 100644
new mode 100755
similarity index 54%
copy from src/meson.build
copy to bin/install_megadrivers.py
index 76ff497e565..a5a46201ccb
--- a/src/meson.build
+++ b/bin/install_megadrivers.py
@@ -1,3 +1,5 @@
+#!/usr/bin/env python
+# encoding=utf-8
 # Copyright ?? 2017 Intel Corporation
 
 # Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -18,31 +20,36 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 # SOFTWARE.
 
-# TODO: libglsl_util
-
-# TODO: git_sha. There's a meson builtin for this
-
-inc_common = include_directories(
-  '../include', '.', 'mapi', 'mesa', 'gallium/include', 'gallium/auxiliary')
-inc_mesa = include_directories('mesa')
-inc_mapi = include_directories('mapi')
-
-subdir('gtest')
-subdir('util')
-#subdir('mapi/glapi/gen')
-# TODO: mapi
-# TODO: opengl
-# TODO: glx
-# TODO: osmesa
-subdir('compiler')
-subdir('egl/wayland/wayland-drm')
-subdir('vulkan')
-subdir('amd')
-subdir('intel')
-# TODO: vc4
-# TODO: opengl_common
-# TODO: dri_glx
-# TODO: gbm
-# TODO: egl
-# TODO: radv
-# TODO: gallium
+"""Script to install megadriver symlinks for meson."""
+
+from __future__ import print_function
+import argparse
+import os
+import shutil
+
+
+def main():
+parser = argparse.ArgumentParser()
+parser.add_argument('megadriver')
+parser.add_argument('libdir')
+