curro / mesa

8 stars 0 forks source link

compilation errors #1

Open tthtlc opened 9 years ago

tthtlc commented 9 years ago

i did a git clone, and then autogen.sh, and then configure was automatically executed:

 -DFEATURE_GL=1 strtod.c -o strtod.o
gcc -c -I. -I../mesa -I../mapi -I../../include  -g -O2 -Wall -std=c99 -Werror=implicit-function-declaration -Werror=missing-prototypes -fno-strict-aliasing -fno-builtin-memcmp -g -O2  -fPIC  -DUSE_X86_64_ASM -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 -fvisibility=hidden -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 ralloc.c -o ralloc.o
g++ -c -I. -I../mesa -I../mapi -I../../include  -g -O2 -Wall -fno-strict-aliasing -fno-builtin-memcmp  -fPIC  -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 -fvisibility=hidden -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 glsl_lexer.cpp -o glsl_lexer.o
g++ -c -I. -I../mesa -I../mapi -I../../include  -g -O2 -Wall -fno-strict-aliasing -fno-builtin-memcmp  -fPIC  -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 -fvisibility=hidden -D_GNU_SOURCE -DPTHREADS -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LLVM=0x0304  -DFEATURE_GL=1 glsl_parser.cpp -o glsl_parser.o
glsl_parser.cpp: In function ‘int _mesa_glsl_parse(_mesa_glsl_parse_state*)’:
glsl_parser.cpp:2483:41: error: ‘scanner’ was not declared in this scope
       yychar = yylex (&yylval, &yylloc, scanner);
                                         ^
make[2]: *** [glsl_parser.o] Error 1
make[2]: Leaving directory `/home/tthtlc/Downloads/curro_github_mesa/src/glsl'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/tthtlc/Downloads/curro_github_mesa/src'
make: *** [default] Error 1
evelikov commented 9 years ago

@tthtlc if you're interesting in reviving the work, I assume that rebasing in on top of current upstream is a nice way to go. I'm pretty sure that we've crushed a few dozen build bugs in the latter, including the one mentioned.

tthtlc commented 9 years ago

thanks for the advice. btw, since i compiled this this thing, i have been reinstalling my entire OS on two different machine, as it really thrashed my desktop GUI environment. not sure why....

but can i ask u do u used virtual machine for this kind of work? i am not sure as i thought it has to be nvidia/radeon specific?

evelikov commented 9 years ago

Well the code is 2+ years old, and depending on your system and method used (amongst other) the crash is not surprising.

When you say "this kind of work" do you mean compilation or driver development ? Both can be done remotely/in a VM. Yet for actual testing I would recommend installing the new mesa into a custom prefix and using LD_PRELOAD/LD_LIBRARY_PATH along with having direct access to the machine.

tthtlc commented 9 years ago

thanks for the reply, now i am trying to rebase, which i have not done before.

i am reading this: http://git-scm.com/book/en/v2/Git-Branching-Rebasing

let me know your way of rebasing? alternatively, i am just thinking: "git log -p" will give me the historical changes u have made, but and then i will attempt to apply each of these commit to that of the latest upstream mesa gittree. which is better?

tthtlc commented 9 years ago

sorry, looking at your changes, i think i will start with the single commit e2d7dfa1176c695d618751afc8b6d429494a3a62 which is already very large.

and now i am manually going through the patch line by line ....and I found that the latest mesa already has some of them.....not really sure how to do these automatically....but manually I can do it.

tthtlc commented 9 years ago

sorry again, have done zero changes yet, but diffing between your include/CL/cl.h and the latest cl.h, and focusing all those changes ADDED BY YOU but yet is NOT ADDED in the latest upstream, ...i have found a number of lines for that ("a" directory is yours)

diff -Nurp include/CL/cl.h ../a/include/CL/cl.h|grep "^+"
+++ ../a/include/CL/cl.h    2014-12-25 20:02:13.000000000 +0800
+ * Copyright (c) 2008-2010 The Khronos Group Inc.
+/* $Revision: 11985 $ on $Date: 2010-07-15 11:16:06 -0700 (Thu, 15 Jul 2010) $ */
+
+typedef intptr_t           cl_context_properties;
+/* 0x1032 reserved for CL_DEVICE_DOUBLE_FP_CONFIG */
+/* cl_context_info + cl_context_properties */
+  
+                cl_uint                       /* num_devices */,
+                const cl_device_id *          /* devices */,
+                void *                        /* user_data */,
+                cl_int *                      /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
+                        cl_device_type                /* device_type */,
+                        void *                        /* user_data */,
+                        cl_int *                      /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
+#ifdef CL_USE_DEPRECATED_OPENCL_1_0_APIS
+#warning CL_USE_DEPRECATED_OPENCL_1_0_APIS is defined. These APIs are unsupported and untested in OpenCL 1.1!
+/* 

and many other lines....how do I start from here?

evelikov commented 9 years ago

@tthtlc a few random bits:

In general git {show $sha,log -p,diff upstream..this-repo} are your friends, with the specific approach varying on the person.