[v8-users] Re: gyp_v8 error when building

2016-07-27 Thread spaesani . console
Sorry bout the verbosity MIchael. The last post was mostly a joke.

To be clear the issue is the* current_hashes  [] *
It's empty.
It's set in get_toolchain_if_necesssary.py around line 480

  current_hashes = CalculateToolchainHashes(target_dir, True)

I'm not familiar with google builds and have no idea what it's looking for. 

I'm building on a GYP_MSVS_VERSION=*2015*



On Sunday, July 24, 2016 at 7:47:52 AM UTC-4, spaesani...@gmail.com wrote:
>
> Calling python gypfiles\gyp_v8 gives a CalledProcessError
>
> subprocess.check_call(get_toolchain_args) produces the error at  line 540 
> of check_call
>
> The call string in the error is a long string of double back slashed 
> paths, which I would assume are acceptable on windows, as well as what 
> looks like a chksum or signature.
>
> I don't have a copy function in te console window to show the whole error 
> but I'm wondering if it sounds familiar to anyone. Maybe the string is 
> misconcatenated somewhere earlier and can be addressed.
>
>
>
>
>  
>
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[v8-users] Re: gyp_v8 error when building

2016-07-27 Thread spaesani . console
I think I'm zeroing in on it

get_toolchain_if_necesssary.py
  toolchain_dir = '.'
  target_dir = os.path.normpath(os.path.join(toolchain_dir, 'vs_files'))

  target_dir == vs_files  // <--!

it's empty
?




On Sunday, July 24, 2016 at 7:47:52 AM UTC-4, spaesani...@gmail.com wrote:
>
> Calling python gypfiles\gyp_v8 gives a CalledProcessError
>
> subprocess.check_call(get_toolchain_args) produces the error at  line 540 
> of check_call
>
> The call string in the error is a long string of double back slashed 
> paths, which I would assume are acceptable on windows, as well as what 
> looks like a chksum or signature.
>
> I don't have a copy function in te console window to show the whole error 
> but I'm wondering if it sounds familiar to anyone. Maybe the string is 
> misconcatenated somewhere earlier and can be addressed.
>
>
>
>
>  
>
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[v8-users] Re: gyp_v8 error when building

2016-07-27 Thread 'Michael Achenbach' via v8-users

>
> To be clear the issue is the* current_hashes  [] *
> It's empty.
> It's set in get_toolchain_if_necesssary.py around line 480
>
>   current_hashes = CalculateToolchainHashes(target_dir, True)
>
> I'm not familiar with google builds and have no idea what it's looking 
> for. 
>

I can only repeat myself. It wouldn't enter this code if the environment 
variable I mentioned above was set correctly. If you do enter this code, 
it's not set. And it is expected to fail (it could fail in nicer ways for 
sure).

The script get_toolchain_if_necessary.py is called in your above stack 
trace in vs_toolchain.py line 336, in Update
 
This is roughly:
https://cs.chromium.org/chromium/src/v8/gypfiles/vs_toolchain.py?l=331

Update is called by SetEnvironmentAndGetRuntimeDllDirs line 44 which it 
should not have entered in the first place as described above.

I'm building on a GYP_MSVS_VERSION=*2015*
>

 Not officially supported yet, but should compile at least. The variable 
will probably be ignored as you're required to have msvs 2015 installed.

Cheers

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[v8-users] Re: gyp_v8 error when building

2016-07-27 Thread spaesani . console
Thanks for your help Michael. I thought the "if you're not a googler" and 
the env var was a joke to cut the build short. But I se it also 
at 
https://chromium.googlesource.com/chromium/src/+show/master/docs/windows_build_instructions.md

Thanks again for your help.

I might give v8 a shot on a linux box someday but maybe it's all for the 
best.

Cheers



On Sunday, July 24, 2016 at 7:47:52 AM UTC-4, spaesani...@gmail.com wrote:
>
> Calling python gypfiles\gyp_v8 gives a CalledProcessError
>
> subprocess.check_call(get_toolchain_args) produces the error at  line 540 
> of check_call
>
> The call string in the error is a long string of double back slashed 
> paths, which I would assume are acceptable on windows, as well as what 
> looks like a chksum or signature.
>
> I don't have a copy function in te console window to show the whole error 
> but I'm wondering if it sounds familiar to anyone. Maybe the string is 
> misconcatenated somewhere earlier and can be addressed.
>
>
>
>
>  
>
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [v8-users] Re: gyp_v8 error when building

2016-07-27 Thread Jochen Eisinger
btw, I want to point out that we have a code of conduct
https://chromium.googlesource.com/chromium/src/+/master/CODE_OF_CONDUCT.md

Offensive comments, jokes or otherwise, are explicitly called out as
something we don't tolerate.

Please take that into account for future communication.

thanks
-jochen

On Wed, Jul 27, 2016 at 12:12 PM  wrote:

> Thanks for your help Michael. I thought the "if you're not a googler" and
> the env var was a joke to cut the build short. But I se it also at
> https://chromium.googlesource.com/chromium/src/+show/master/docs/windows_build_instructions.md
>
> Thanks again for your help.
>
> I might give v8 a shot on a linux box someday but maybe it's all for the
> best.
>
> Cheers
>
>
>
> On Sunday, July 24, 2016 at 7:47:52 AM UTC-4, spaesani...@gmail.com wrote:
>
>> Calling python gypfiles\gyp_v8 gives a CalledProcessError
>>
>> subprocess.check_call(get_toolchain_args) produces the error at  line 540
>> of check_call
>>
>> The call string in the error is a long string of double back slashed
>> paths, which I would assume are acceptable on windows, as well as what
>> looks like a chksum or signature.
>>
>> I don't have a copy function in te console window to show the whole error
>> but I'm wondering if it sounds familiar to anyone. Maybe the string is
>> misconcatenated somewhere earlier and can be addressed.
>>
>>
>>
>>
>>
>>
>> --
> --
> v8-users mailing list
> v8-users@googlegroups.com
> http://groups.google.com/group/v8-users
> ---
> You received this message because you are subscribed to the Google Groups
> "v8-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to v8-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [v8-users] Exposing nested maps from C++ into JS world

2016-07-27 Thread Jochen Eisinger
Can you provide a complete example? I suspect that WrapHTTPBodyMap doesn't
do what you expect it does

On Tue, Jul 26, 2016 at 1:04 PM Abhishek Singh 
wrote:

> Would you mind guiding me a bit here? For now just trying to expose nested
> “body” map i.e. to allow something like “response.body.result =
> dbQueryResult"
>
> First is the Set interceptor for “response” (C++ object) and here I’m
> setting up “body” (C++ object for “body”) & setting return value to “body”
> object. Second one is Set interceptor for “body”
>
> void HTTPResponse::HTTPResponseSet(Local name, Local
> value_obj,
>const PropertyCallbackInfo&
> info) {
>   if (name->IsSymbol()) return;
>
>   V8Handle* w = UnwrapV8HandleInstance(info.Holder());
>   HTTPBody* body = new HTTPBody(w);
>
>   Local body_map = body->WrapHTTPBodyMap();
>   info.GetReturnValue().Set(body_map);
> }
>
>
> void HTTPBody::HTTPBodySet(Local name, Local value_obj,
>const PropertyCallbackInfo& info) {
>   if (name->IsSymbol()) return;
>
>   string key = ObjectToString(Local::Cast(name));
>   string value = ToString(info.GetIsolate(), value_obj);
>
>   map* body = UnwrapMap(info.Holder());
>   (*body)[key] = value;
>
>   cout << "body field " << value << endl;
> }
>
>
> Currently I’m not hitting Set interceptor of “body” object, I suppose I’m
> doing something wrong here.
>
> On 25-Jul-2016, at 10:00 PM, Jochen Eisinger  wrote:
>
> To create dynamic nested maps from C++, the outter object (response) would
> have to return another intercepted object (e.g. body) that then returns the
> actual values on access.
>
> On Fri, Jul 22, 2016 at 8:12 AM Abhishek Singh <
> singhabhishek@gmail.com> wrote:
>
>> Hi,
>>
>> I’m wondering if there is a way to expose map
>> > into JS world from C++? Exposing map looks
>> straightforward and I’m doing for some C++ objects using
>> NamedPropertyConfigurationHandler. I’ll just show sample JS code that I
>> would like to have and where C++ map > will
>> come into picture:
>>
>> function OnHTTPGet(request, response) {
>>
>> var city = “BLR”;
>> var limit = “10”;
>>
>> var queryResult = dbCal(“select * from users where city=${city}
>> limit ${limit}”);
>>
>> // This works for me presently
>> /* response.data = queryResult;
>> response.status_code = 200; */
>>
>> // What I would like to have
>> response.body.data = queryResult;
>> response.header.status_code = 200;
>> }
>>
>> “request” - native HTTP request JSON passed from C++ V8 binding as args
>> to JS function
>> “response” - C++ based HTTP object exposed with Setter callback set using
>> NamedPropertyConfigHandler and this what I write back to user who made the
>> “request"
>>
>> I basically want to set HTTP response body and header transparently,
>> which would require me to expose C++ HTTP object probably as a map> map >. Hope my question is clear, please let me know if
>> there a way to do this?
>>
>> Thanks,
>> Abhishek
>>
>> --
>> --
>> v8-users mailing list
>> v8-users@googlegroups.com
>> http://groups.google.com/group/v8-users
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "v8-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to v8-users+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> --
> v8-users mailing list
> v8-users@googlegroups.com
> http://groups.google.com/group/v8-users
> ---
> You received this message because you are subscribed to the Google Groups
> "v8-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to v8-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
> --
> --
> v8-users mailing list
> v8-users@googlegroups.com
> http://groups.google.com/group/v8-users
> ---
> You received this message because you are subscribed to the Google Groups
> "v8-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to v8-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [v8-users] Exposing nested maps from C++ into JS world

2016-07-27 Thread Abhishek Singh
Hi Jochen,

Full code of relevant file available - http://pastebin.com/fZJENvSi 


Snippet of relevant portions for WrapHTTPBodyMap:

Local HTTPBody::MakeHTTPBodyMapTemplate(
Isolate* isolate) {
  EscapableHandleScope handle_scope(isolate);

  Local result = ObjectTemplate::New(isolate);
  result->SetInternalFieldCount(1);
  result->SetHandler(NamedPropertyHandlerConfiguration(NULL,
   HTTPBodySet));

  return handle_scope.Escape(result);
}

Local HTTPBody::WrapHTTPBodyMap() {
  EscapableHandleScope handle_scope(GetIsolate());

  if (http_body_map_template_.IsEmpty()) {
Local raw_template = MakeHTTPBodyMapTemplate(GetIsolate());
http_body_map_template_.Reset(GetIsolate(), raw_template);
  }
  Local templ =
  Local::New(GetIsolate(), http_body_map_template_);

  Local result =
  templ->NewInstance(GetIsolate()->GetCurrentContext()).ToLocalChecked();

  Local map_ptr = External::New(GetIsolate(), &http_body);

  result->SetInternalField(0, map_ptr);

  return handle_scope.Escape(result);
}


> On 27-Jul-2016, at 7:47 PM, Jochen Eisinger  wrote:
> 
> Can you provide a complete example? I suspect that WrapHTTPBodyMap doesn't do 
> what you expect it does
> 
> On Tue, Jul 26, 2016 at 1:04 PM Abhishek Singh  > wrote:
> Would you mind guiding me a bit here? For now just trying to expose nested 
> “body” map i.e. to allow something like “response.body.result = dbQueryResult"
> 
> First is the Set interceptor for “response” (C++ object) and here I’m setting 
> up “body” (C++ object for “body”) & setting return value to “body” object. 
> Second one is Set interceptor for “body”
> 
> void HTTPResponse::HTTPResponseSet(Local name, Local value_obj,
>const PropertyCallbackInfo& info) {
>   if (name->IsSymbol()) return;
> 
>   V8Handle* w = UnwrapV8HandleInstance(info.Holder());
>   HTTPBody* body = new HTTPBody(w);
> 
>   Local body_map = body->WrapHTTPBodyMap();
>   info.GetReturnValue().Set(body_map);
> }
> 
> 
> void HTTPBody::HTTPBodySet(Local name, Local value_obj,
>const PropertyCallbackInfo& info) {
>   if (name->IsSymbol()) return;
> 
>   string key = ObjectToString(Local::Cast(name));
>   string value = ToString(info.GetIsolate(), value_obj);
> 
>   map* body = UnwrapMap(info.Holder());
>   (*body)[key] = value;
> 
>   cout << "body field " << value << endl;
> }
> 
> 
> Currently I’m not hitting Set interceptor of “body” object, I suppose I’m 
> doing something wrong here.
> 
> 
>> On 25-Jul-2016, at 10:00 PM, Jochen Eisinger > > wrote:
>> 
> 
>> To create dynamic nested maps from C++, the outter object (response) would 
>> have to return another intercepted object (e.g. body) that then returns the 
>> actual values on access.
>> 
>> On Fri, Jul 22, 2016 at 8:12 AM Abhishek Singh > > wrote:
>> Hi,
>> 
>> I’m wondering if there is a way to expose map > 
>> into JS world from C++? Exposing map looks straightforward 
>> and I’m doing for some C++ objects using NamedPropertyConfigurationHandler. 
>> I’ll just show sample JS code that I would like to have and where C++ 
>> map > will come into picture:
>> 
>> function OnHTTPGet(request, response) {
>> 
>> var city = “BLR”;
>> var limit = “10”;
>> 
>> var queryResult = dbCal(“select * from users where city=${city} 
>> limit ${limit}”);
>> 
>> // This works for me presently
>> /* response.data = queryResult;
>> response.status_code = 200; */
>> 
>> // What I would like to have
>> response.body.data = queryResult;
>> response.header.status_code = 200;
>> }
>> 
>> “request” - native HTTP request JSON passed from C++ V8 binding as args to 
>> JS function
>> “response” - C++ based HTTP object exposed with Setter callback set using 
>> NamedPropertyConfigHandler and this what I write back to user who made the 
>> “request"
>> 
>> I basically want to set HTTP response body and header transparently, which 
>> would require me to expose C++ HTTP object probably as a map> map >. Hope my question is clear, please let me know if 
>> there a way to do this?
>> 
>> Thanks,
>> Abhishek
>> 
>> --
>> --
>> v8-users mailing list
>> v8-users@googlegroups.com 
>> http://groups.google.com/group/v8-users 
>> 
>> ---
>> You received this message because you are subscribed to the Google Groups 
>> "v8-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to v8-users+unsubscr...@googlegroups.com 
>> .
>> For more options, visit https://groups.google.com/d/optout 
>> .
>> 
>> -- 
>> -- 
>> v8-users mailing list
>> v8-users@googlegroups.com