Opened on 09/12/2018 at 09:10:12 PM

Last modified on 09/20/2018 at 02:41:25 AM

#6947 new defect

Can not build LibAdblockPlus

Reported by: jahmedir Assignee:
Priority: Unknown Milestone:
Module: Libadblockplus Keywords:
Cc: sergz, oleksandr Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: no Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

Description

Environment

I am using Windows 10 x64 OS
I downloaded the master branch of libadblockplus from the link below:
https://github.com/adblockplus/libadblockplus

How to reproduce

  1. I have built V8. The path for the headers files and binary files of my V8 built are as follows, respectively:

C:\V-eight\v8\include
C:\V-eight\v8\out.gn\x64.release\obj

  1. I have set my path in environment variables such that if I do "where python" at the command for example C:\>where python then I get the following response:

C:\V-eight\depot_tools\python.bat

  1. I have set the environment variable "GYP_DEFINES" as below:

GYP_DEFINES=C:\V-eight\v8

  1. I ran the createsolution.bat from the path as below:

C:\V-eight\libadblockplus>createsolution.bat

Observed behaviour

  1. I am getting the following error:


File "C:\V-eight\depot_tools\win_tools-2_7_6_bin\python\bin\lib\subprocess.py", line 957, in _execute_child

startupinfo)

WindowsError: [Error 2] The system cannot find the file specified

Expected behaviour

Please ,any one, can help me to build libadblockplus

Attachments (7)

cs-bat.jpg (146.4 KB) - added by jahmedir on 09/12/2018 at 09:15:46 PM.
cs-bat.2.jpg (146.4 KB) - added by jahmedir on 09/12/2018 at 09:20:38 PM.
crs.gif (159.9 KB) - added by jahmedir on 09/14/2018 at 04:43:54 AM.
image1.bmp (1.2 MB) - added by jahmedir on 09/15/2018 at 04:42:29 AM.
VS-git-cloning.gif (188.7 KB) - added by jahmedir on 09/17/2018 at 03:16:54 AM.
Git-Bash-clone.gif (44.7 KB) - added by jahmedir on 09/18/2018 at 12:35:01 AM.
createsolution.gif (51.4 KB) - added by jahmedir on 09/18/2018 at 12:35:19 AM.

Download all attachments as: .zip

Change History (30)

Changed on 09/12/2018 at 09:15:46 PM by jahmedir

Changed on 09/12/2018 at 09:20:38 PM by jahmedir

comment:1 Changed on 09/13/2018 at 11:03:12 AM by oleksandr

  • Cc sergz oleksandr added

comment:2 Changed on 09/13/2018 at 11:11:24 AM by sergz

GYP_DEFINES=C:\V-eight\v8

could you try
set "GYP_DEFINED=v8_dir=C:/V-eight/v8" (in your case v8_dir= is missing) and ensure that there is v8_monolith static library in C:\V-eight\v8\win-x64.Release, please adjust x64 and Release in accordance with your settings. This convention comes from v8.gypi, alternatively you can try to pass libv8_lib_dir, e.g.
set "GYP_DEFINED=v8_dir=C:/V-eight/v8 libv8_lib_dir=C:/V-eight/v8/out.gn/x64.release/obj"

comment:3 Changed on 09/13/2018 at 11:15:10 AM by sergz

I also took a look at the screenshots, it seems that your are using mercurial but it's not installed or is not reachable by any path from PATH environment variable. One can also use git, just clone libadblockplus using git and the dependencies will be fetched using git too.
https://github.com/adblockplus/libadblockplus or https://gitlab.com/eyeo/adblockplus/libadblockplus/

comment:4 Changed on 09/13/2018 at 11:16:03 AM by sergz

  • Component changed from Unknown to Libadblockplus

comment:5 Changed on 09/14/2018 at 03:51:59 AM by jahmedir

I have tried
set "GYP_DEFINES=v8_dir=C:\V-eight\v8 libv8_lib_dir=C:\V-eight\v8\out.gn\x64.release\obj"

did not work

comment:6 Changed on 09/14/2018 at 03:56:48 AM by jahmedir

I have tried
set "GYP_DEFINES=v8_dir=C:\V-eight\V8-build\v8 libv8_lib_dir=C:\V-eight\V8-build\v8\win-x64.Release"

did not work

in this case I created these folders C:\V-eight\V8-build\v8 and C:\V-eight\V8-build\v8\include and C:\V-eight\V8-build\v8\win-x64.Release

and I placed all headers files in the \include folder and I placed all .lib files in the win-x64.Release folder

In both cases , I had v8_monolith.lib

Changed on 09/14/2018 at 04:43:54 AM by jahmedir

comment:7 Changed on 09/14/2018 at 04:45:12 AM by jahmedir

please see crs.gif

Any idea please ~

comment:8 Changed on 09/14/2018 at 04:47:15 AM by jahmedir

can we get any idea from this link
https://github.com/coursera-dl/edx-dl/issues/163

comment:9 follow-up: Changed on 09/14/2018 at 08:35:03 AM by sergz

The first step should be #comment:3

comment:10 Changed on 09/14/2018 at 01:50:25 PM by jahmedir

I am not using mercurial.

Last edited on 09/15/2018 at 05:06:35 AM by jahmedir

comment:11 Changed on 09/14/2018 at 04:44:16 PM by jahmedir

@sergz
some one have had similar issue a while ago.
https://issues.adblockplus.org/ticket/5270

but I don't know if he fixed it and if he did then how did he fixed it.

Last edited on 09/15/2018 at 01:24:32 AM by jahmedir

Changed on 09/15/2018 at 04:42:29 AM by jahmedir

comment:12 Changed on 09/15/2018 at 04:43:26 AM by jahmedir

Last edited on 09/15/2018 at 08:00:53 PM by jahmedir

comment:13 Changed on 09/15/2018 at 06:30:06 PM by jahmedir

Do I need to do this :

set "GYP_DEFINES=v8_dir=C:/V-eight/v8 libv8_lib_dir=C:/V-eight/v8/out.gn/x64.release/obj libv8_libs=C:/V-eight/v8/out.gn/x64.release/obj libv8_include_dir=C:\V_8\v8\include"

comment:14 in reply to: ↑ 9 Changed on 09/15/2018 at 08:00:14 PM by jahmedir

Replying to sergz:

The first step should be #comment:3

I got the clone from the link below:
https://github.com/adblockplus/libadblockplus.git
and then I ran createsolution.bat but the problem persisted so I investigated and then I found a potential fix as below:
In ensure_dependencies.py , inside the function "get_repo_type" at line 45 , I modified 'hg' to 'git' as below:


def get_repo_type(repo):

for name, repotype in repo_types.iteritems():

if repotype.istype(repo):

return name

return 'git'


Then I ran the createsolution.bat again and this time it looked like working and got the repositories . Please see the attached "image1"
However, createsolution.bat did not create the build\x64\shell folder, neither the solution is built
Please suggest ... ~

Last edited on 09/15/2018 at 08:04:43 PM by jahmedir

comment:15 Changed on 09/15/2018 at 11:44:29 PM by jahmedir

set "GYP_DEFINES=v8_dir=C:/V-eight/v8 libv8_lib_dir=C:/V-eight/v8/out.gn/x64.release/obj libv8_libs=C:/V-eight/v8/out.gn/x64.release/obj libv8_include_dir=C:\V_8\v8\include libv8_show_warnings=true"

comment:16 Changed on 09/16/2018 at 01:27:24 AM by jahmedir

The libadblockplus solution is generated after using the above Set "GYP_DEFINES................."

now I am trying to build the libadblockplus solution and libadblockplus project inside the solution but getting an error as below:

1>c:\v_8\adblockplus-clone\src\consolejsobject.cpp(45): error C2660: 'v8::StackTrace::GetFrame': function does not take 1 arguments

comment:17 follow-ups: Changed on 09/16/2018 at 01:36:47 PM by oleksandr

You should not have to hack around hg get_repo_type. Are you cloning into an empty directory using git (and only git) and still see errors? Can you post the exact commands you type to clonse and initialize the repository?

comment:18 Changed on 09/16/2018 at 08:40:33 PM by jahmedir

I cloned through VS2017 IDE's github option that is in the Team Explored from the link below:
https://github.com/adblockplus/libadblockplus.git
and I cloned in the empty directory

Changed on 09/17/2018 at 03:16:54 AM by jahmedir

comment:19 in reply to: ↑ 17 Changed on 09/17/2018 at 03:20:21 AM by jahmedir

Please see the image "VS-git-cloning.gif" this is how I cloned the https://github.com/adblockplus/libadblockplus.git in my hard disk folder .
Then I ran createsolution.bat , see image1.bmp

If you think, this is not the proper way of cloning then please suggest how should I clone and initialize repository ~

Replying to oleksandr:

You should not have to hack around hg get_repo_type. Are you cloning into an empty directory using git (and only git) and still see errors? Can you post the exact commands you type to clonse and initialize the repository?

comment:20 follow-up: Changed on 09/17/2018 at 11:00:59 PM by jahmedir

@ oleksandr

I fetched latest version of V8 and having compatibility issue in invoking a function from libadblockplus ...
1>c:\v_8\adblockplus-clone\src\consolejsobject.cpp(45): error C2660: 'v8::StackTrace::GetFrame': function does not take 1 arguments

Can you please let me know, what version of V8 is used by libadblockplus ~

comment:21 in reply to: ↑ 17 Changed on 09/18/2018 at 12:32:56 AM by jahmedir

I got the clone of libadblockplus from the scratch , this time by using Git Bash and I used the command as follows:
$ git clone https://github.com/adblockplus/libadblockplus.git

See the image "Git-Bash-clone.gif"

This command gave me a folder libadblockplus and its contents and then I ran createsolution.bat (without any refactoring of "get_repo_type") . See the image createsolutin.gif

So, essentially ensure_dependencies.py is failing somewhere at the moment due to which the build\x64\ folder is not created neither the libadblockproject solution is generated.

Please suggest.

Replying to oleksandr:

You should not have to hack around hg get_repo_type. Are you cloning into an empty directory using git (and only git) and still see errors? Can you post the exact commands you type to clonse and initialize the repository?

Last edited on 09/18/2018 at 12:37:00 AM by jahmedir

Changed on 09/18/2018 at 12:35:01 AM by jahmedir

Changed on 09/18/2018 at 12:35:19 AM by jahmedir

comment:22 in reply to: ↑ 20 Changed on 09/18/2018 at 07:04:51 AM by jahmedir

I figured from https://hg.adblockplus.org/libadblockplus/file/default/README.md
that V8 version should be 6.7
So, the closest, I found is 6.7.1
Thanks though

Replying to jahmedir:

@ oleksandr

I fetched latest version of V8 and having compatibility issue in invoking a function from libadblockplus ...
1>c:\v_8\adblockplus-clone\src\consolejsobject.cpp(45): error C2660: 'v8::StackTrace::GetFrame': function does not take 1 arguments

Can you please let me know, what version of V8 is used by libadblockplus ~

comment:23 Changed on 09/20/2018 at 02:41:25 AM by jahmedir

Project abpshell in the libadblockplus.sln solution has a reference of obj.lib in the
Configuration Properties --> Linker --> Input --> additional dependencies

v8/out.gn/x64.release/obj.lib

But there is no obj.lib and if I remove this reference then I get 123 errors when building abpshell project

Add Comment

Modify Ticket

Change Properties
Action
as new .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from (none).
Next status will be 'reviewing'.
 
Note: See TracTickets for help on using tickets.