Re: Problem on building NSS with Windows

2016-08-20 Thread John Jiang
Hi Julien,
Thanks for your info!

2016-08-21 6:49 GMT+08:00 Julien Pierre <julien.pie...@oracle.com>:

> This is an issue with the shell's inability to run "pwd.exe".
> It may be either a built-in shell, or a separately configured shell.
> What is the value of the SHELL environment variable, if any ?
>

$ echo $SHELL
/bin/sh


>
> See
> https://www.gnu.org/software/make/manual/make.html#Choosing-the-Shell
> for more details.
>
> "shell pwd" is what's used in the NSS build within coreconf to find the
> absolute path for source files - ie. this is the change that was made 10
> years ago.
>
> quickder.c is the first source file to be compiled in NSS, which I
> originally authored.
>
> Julien
>
> - Original Message -
> From: john.sha.ji...@gmail.com
> To: dev-tech-crypto@lists.mozilla.org
> Sent: Saturday, August 20, 2016 6:58:02 AM GMT -08:00 US/Canada Pacific
> Subject: Re: Problem on building NSS with Windows
>
> 2016-08-20 20:25 GMT+08:00 Manuel Dejonghe <man...@dejonghe.de>:
>
> > On Sat, Aug 20, 2016 at 4:00 AM, John Jiang <john.sha.ji...@gmail.com>
> > wrote:
> > > I checked the full logs. Many "execvp: pwd: Permission denied" in the
> > logs,
> > > like the below,
> > > ...
> > > make[1]: Leaving directory
> > > `/d/security/nss/nss-latest/nspr/WIN954.0_x86_64_64_DBG.OBJ'
> > > cd coreconf; make export
> > > make[1]: execvp: pwd: Permission denied
> > > make[1]: Entering directory `/d/security/nss/nss-latest/nss/coreconf'
> > > cd nsinstall; make export
> > > make[2]: execvp: pwd: Permission denied
> > > make[2]: Entering directory
> > > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > > make[2]: Nothing to be done for `export'.
> > > make[2]: Leaving directory
> > > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > > cd nsinstall; make libs
> > > ...
> > >
> > > Does it impact the building?
> >
> > Most certainly it does.
> > "pwd" is a command with which the build system could find out where
> > (in which directory) it is sitting. As long as that fails, I would not
> > be amazed that files are being searched/built in the wrong directory.
> >
> I'm really confused by this issue.
> If run "pwd" by manual in that command prompt, I didn't get any error or
> warning.
> It did work well.
>
>
> > ~manuel
> > --
> > dev-tech-crypto mailing list
> > dev-tech-crypto@lists.mozilla.org
> > https://lists.mozilla.org/listinfo/dev-tech-crypto
> >
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-20 Thread Julien Pierre
This is an issue with the shell's inability to run "pwd.exe". 
It may be either a built-in shell, or a separately configured shell.
What is the value of the SHELL environment variable, if any ?

See
https://www.gnu.org/software/make/manual/make.html#Choosing-the-Shell
for more details.

"shell pwd" is what's used in the NSS build within coreconf to find the 
absolute path for source files - ie. this is the change that was made 10 years 
ago.

quickder.c is the first source file to be compiled in NSS, which I originally 
authored.

Julien

- Original Message -
From: john.sha.ji...@gmail.com
To: dev-tech-crypto@lists.mozilla.org
Sent: Saturday, August 20, 2016 6:58:02 AM GMT -08:00 US/Canada Pacific
Subject: Re: Problem on building NSS with Windows

2016-08-20 20:25 GMT+08:00 Manuel Dejonghe <man...@dejonghe.de>:

> On Sat, Aug 20, 2016 at 4:00 AM, John Jiang <john.sha.ji...@gmail.com>
> wrote:
> > I checked the full logs. Many "execvp: pwd: Permission denied" in the
> logs,
> > like the below,
> > ...
> > make[1]: Leaving directory
> > `/d/security/nss/nss-latest/nspr/WIN954.0_x86_64_64_DBG.OBJ'
> > cd coreconf; make export
> > make[1]: execvp: pwd: Permission denied
> > make[1]: Entering directory `/d/security/nss/nss-latest/nss/coreconf'
> > cd nsinstall; make export
> > make[2]: execvp: pwd: Permission denied
> > make[2]: Entering directory
> > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > make[2]: Nothing to be done for `export'.
> > make[2]: Leaving directory
> > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > cd nsinstall; make libs
> > ...
> >
> > Does it impact the building?
>
> Most certainly it does.
> "pwd" is a command with which the build system could find out where
> (in which directory) it is sitting. As long as that fails, I would not
> be amazed that files are being searched/built in the wrong directory.
>
I'm really confused by this issue.
If run "pwd" by manual in that command prompt, I didn't get any error or
warning.
It did work well.


> ~manuel
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-20 Thread John Jiang
2016-08-20 20:25 GMT+08:00 Manuel Dejonghe :

> On Sat, Aug 20, 2016 at 4:00 AM, John Jiang 
> wrote:
> > I checked the full logs. Many "execvp: pwd: Permission denied" in the
> logs,
> > like the below,
> > ...
> > make[1]: Leaving directory
> > `/d/security/nss/nss-latest/nspr/WIN954.0_x86_64_64_DBG.OBJ'
> > cd coreconf; make export
> > make[1]: execvp: pwd: Permission denied
> > make[1]: Entering directory `/d/security/nss/nss-latest/nss/coreconf'
> > cd nsinstall; make export
> > make[2]: execvp: pwd: Permission denied
> > make[2]: Entering directory
> > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > make[2]: Nothing to be done for `export'.
> > make[2]: Leaving directory
> > `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> > cd nsinstall; make libs
> > ...
> >
> > Does it impact the building?
>
> Most certainly it does.
> "pwd" is a command with which the build system could find out where
> (in which directory) it is sitting. As long as that fails, I would not
> be amazed that files are being searched/built in the wrong directory.
>
I'm really confused by this issue.
If run "pwd" by manual in that command prompt, I didn't get any error or
warning.
It did work well.


> ~manuel
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-20 Thread Manuel Dejonghe
On Sat, Aug 20, 2016 at 4:00 AM, John Jiang  wrote:
> I checked the full logs. Many "execvp: pwd: Permission denied" in the logs,
> like the below,
> ...
> make[1]: Leaving directory
> `/d/security/nss/nss-latest/nspr/WIN954.0_x86_64_64_DBG.OBJ'
> cd coreconf; make export
> make[1]: execvp: pwd: Permission denied
> make[1]: Entering directory `/d/security/nss/nss-latest/nss/coreconf'
> cd nsinstall; make export
> make[2]: execvp: pwd: Permission denied
> make[2]: Entering directory
> `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> make[2]: Nothing to be done for `export'.
> make[2]: Leaving directory
> `/d/security/nss/nss-latest/nss/coreconf/nsinstall'
> cd nsinstall; make libs
> ...
>
> Does it impact the building?

Most certainly it does.
"pwd" is a command with which the build system could find out where
(in which directory) it is sitting. As long as that fails, I would not
be amazed that files are being searched/built in the wrong directory.
~manuel
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread John Jiang
Hi,
Thanks for your reply.

I don't get any useful info from env output, like the below
$ env | grep msys
OSTYPE=msys
MACHTYPE=i686-pc-msys

2016-08-20 0:31 GMT+08:00 Wan-Teh Chang :

> On Fri, Aug 19, 2016 at 1:49 AM, John Jiang 
> wrote:
> > Hi,
> > Thanks for your reply.
> >
> > My steps are the follwings:
> > 1. Double-click start-shell-msvc2015-x64.bat in C:\mozilla-build. And it
> > displayed some information, like the below:
> > MozillaBuild Install Directory: C:\mozilla-build\
> > Visual C++ 2015 Directory: C:\Program Files (x86)\Microsoft Visual Studio
> > 14.0\VC\
> > Windows SDK Directory: C:\Program Files (x86)\Windows Kits\8.1\
> > Using the MSVC 2015 64-bit toolchain.
> > 2. cd /d/security/nss/nss-latest/nss/
> > The source directories of nss and nspr are under a same parent directory
> > nss-latest.
> > 3. export USE_64=1
> > 4. make nss_build_all
>
> Hi John,
>
> Your steps look correct to me. There must be something wrong in your
> environment variables.
>
> Our clue is the pathname 'C:/mozilla-build/msys/quickder.c'. The
> 'C:/mozilla-build/msys' part is the problem. Can you run the command
> 'env' to print your environment variables, and see which one contains
> 'C:/mozilla-build/msys'?
>
> Wan-Teh Chang
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread John Jiang
I checked the full logs. Many "execvp: pwd: Permission denied" in the logs,
like the below,
...
make[1]: Leaving directory
`/d/security/nss/nss-latest/nspr/WIN954.0_x86_64_64_DBG.OBJ'
cd coreconf; make export
make[1]: execvp: pwd: Permission denied
make[1]: Entering directory `/d/security/nss/nss-latest/nss/coreconf'
cd nsinstall; make export
make[2]: execvp: pwd: Permission denied
make[2]: Entering directory
`/d/security/nss/nss-latest/nss/coreconf/nsinstall'
make[2]: Nothing to be done for `export'.
make[2]: Leaving directory
`/d/security/nss/nss-latest/nss/coreconf/nsinstall'
cd nsinstall; make libs
...

Does it impact the building?
Thanks!

2016-08-20 9:48 GMT+08:00 Julien Pierre :

> That looks correct; must be a different issue then.
>
> Julien
>
>
>
> On 8/19/2016 18:44, John Jiang wrote:
>
>> Run "make -version" in the MSYS/BASH command prompt, which is launched by
>> MozillaBuild, and got the following info,
>> GNU Make 3.81.90
>> Copyright (C) 2006  Free Software Foundation, Inc.
>> This is free software; see the source for copying conditions.
>> There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
>> PARTICULAR PURPOSE.
>>
>> This program built for i686-pc-msys32
>>
>> 2016-08-20 9:24 GMT+08:00 Julien Pierre :
>>
>> Which version of GNU make do you have in your PATH ?
>>>
>>> The NSS build system tries to get the absolute location of all source
>>> files. It does so to facilitate debugging, so that debug binaries can
>>> automatically locate the files in a debugger. It uses gmake
>>> macros/function
>>> that don't work in very old gmake. This is a change I made 10+ years ago.
>>>
>>> If you have gmake < 3.81, I think that path computation will fail. Just
>>> check which gmake or make you have with gmake.exe -v .
>>>
>>> You might also have the Microsoft make.exe / nmake.exe in your path .
>>>
>>> Make sure the version of make in your path is GNU make and not another
>>> make.
>>>
>>> Julien
>>>
>>>
>>>
>>> On 8/19/2016 00:24, John Jiang wrote:
>>>
>>> Hi,
 I tried to build NSS on Windows 7 x86_64 machine, and followed the
 instructions at:
 https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Building

 VS 2015 community and Latest MozillaBuild have been installed, and
 USE_64
 was set to 1.
 When "make nss_build_all" finished, I got the below errors:
 c1: fatal error C1083: Cannot open source file:
 'C:/mozilla-build/msys/quickder.c': No such file or directory
 make[2]: *** [WIN954.0_x86_64_64_DBG.OBJ/quickder.obj] Error 2
 make[2]: Leaving directory `/d/security/nss/nss-latest/nss/lib/util'
 make[1]: *** [libs] Error 2
 make[1]: Leaving directory `/d/security/nss/nss-latest/nss/lib'
 make: *** [libs] Error 2

 How to resolve this problem?
 Thanks!

 --
>>> dev-tech-crypto mailing list
>>> dev-tech-crypto@lists.mozilla.org
>>> https://lists.mozilla.org/listinfo/dev-tech-crypto
>>>
>>>
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread Julien Pierre

That looks correct; must be a different issue then.

Julien


On 8/19/2016 18:44, John Jiang wrote:

Run "make -version" in the MSYS/BASH command prompt, which is launched by
MozillaBuild, and got the following info,
GNU Make 3.81.90
Copyright (C) 2006  Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.

This program built for i686-pc-msys32

2016-08-20 9:24 GMT+08:00 Julien Pierre :


Which version of GNU make do you have in your PATH ?

The NSS build system tries to get the absolute location of all source
files. It does so to facilitate debugging, so that debug binaries can
automatically locate the files in a debugger. It uses gmake macros/function
that don't work in very old gmake. This is a change I made 10+ years ago.

If you have gmake < 3.81, I think that path computation will fail. Just
check which gmake or make you have with gmake.exe -v .

You might also have the Microsoft make.exe / nmake.exe in your path .

Make sure the version of make in your path is GNU make and not another
make.

Julien



On 8/19/2016 00:24, John Jiang wrote:


Hi,
I tried to build NSS on Windows 7 x86_64 machine, and followed the
instructions at:
https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Building

VS 2015 community and Latest MozillaBuild have been installed, and USE_64
was set to 1.
When "make nss_build_all" finished, I got the below errors:
c1: fatal error C1083: Cannot open source file:
'C:/mozilla-build/msys/quickder.c': No such file or directory
make[2]: *** [WIN954.0_x86_64_64_DBG.OBJ/quickder.obj] Error 2
make[2]: Leaving directory `/d/security/nss/nss-latest/nss/lib/util'
make[1]: *** [libs] Error 2
make[1]: Leaving directory `/d/security/nss/nss-latest/nss/lib'
make: *** [libs] Error 2

How to resolve this problem?
Thanks!


--
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto



--
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread Julien Pierre

Which version of GNU make do you have in your PATH ?

The NSS build system tries to get the absolute location of all source 
files. It does so to facilitate debugging, so that debug binaries can 
automatically locate the files in a debugger. It uses gmake 
macros/function that don't work in very old gmake. This is a change I 
made 10+ years ago.


If you have gmake < 3.81, I think that path computation will fail. Just 
check which gmake or make you have with gmake.exe -v .


You might also have the Microsoft make.exe / nmake.exe in your path .

Make sure the version of make in your path is GNU make and not another make.

Julien


On 8/19/2016 00:24, John Jiang wrote:

Hi,
I tried to build NSS on Windows 7 x86_64 machine, and followed the
instructions at:
https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Building

VS 2015 community and Latest MozillaBuild have been installed, and USE_64
was set to 1.
When "make nss_build_all" finished, I got the below errors:
c1: fatal error C1083: Cannot open source file:
'C:/mozilla-build/msys/quickder.c': No such file or directory
make[2]: *** [WIN954.0_x86_64_64_DBG.OBJ/quickder.obj] Error 2
make[2]: Leaving directory `/d/security/nss/nss-latest/nss/lib/util'
make[1]: *** [libs] Error 2
make[1]: Leaving directory `/d/security/nss/nss-latest/nss/lib'
make: *** [libs] Error 2

How to resolve this problem?
Thanks!


--
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread John Jiang
Hi,
Thanks for your reply.

My steps are the follwings:
1. Double-click start-shell-msvc2015-x64.bat in C:\mozilla-build. And it
displayed some information, like the below:
MozillaBuild Install Directory: C:\mozilla-build\
Visual C++ 2015 Directory: C:\Program Files (x86)\Microsoft Visual Studio
14.0\VC\
Windows SDK Directory: C:\Program Files (x86)\Windows Kits\8.1\
Using the MSVC 2015 64-bit toolchain.
2. cd /d/security/nss/nss-latest/nss/
The source directories of nss and nspr are under a same parent directory
nss-latest.
3. export USE_64=1
4. make nss_build_all


2016-08-19 16:21 GMT+08:00 Franziskus Kiefer :

> This sounds like there's something wrong with the setup. quickder.c is a
> file in NSS [1] (lib/util as your output shows as well).
>
> 'C:/mozilla-build/msys/quickder.c': No such file or directory
>
> So this line is a bit confusing. Why is your build searching in the
> mozilla-build directory for NSS files? What's your folder structure and
> where do you execute the make command? Describing the exact steps of what
> you're doing might help to figure this out.
>
> Cheers
>
> [1]
> http://searchfox.org/nss/rev/462a77115abebd0f3cd9cb56dbc350
> a25b9be706/lib/util/quickder.c
>
> On Fri, Aug 19, 2016 at 9:30 AM, John Jiang 
> wrote:
>
> > In addition, I have checked my installed MozillaBuild. It doesn't include
> > file quickder.c.
> > Is there any wrong on MoziilaBuild? Or some issue in my environment?
> >
> > 2016-08-19 15:24 GMT+08:00 John Jiang :
> >
> > > Hi,
> > > I tried to build NSS on Windows 7 x86_64 machine, and followed the
> > > instructions at:
> > > https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Building
> > >
> > > VS 2015 community and Latest MozillaBuild have been installed, and
> USE_64
> > > was set to 1.
> > > When "make nss_build_all" finished, I got the below errors:
> > > c1: fatal error C1083: Cannot open source file: 'C:/mozilla-build/msys/
> > quickder.c':
> > > No such file or directory
> > > make[2]: *** [WIN954.0_x86_64_64_DBG.OBJ/quickder.obj] Error 2
> > > make[2]: Leaving directory `/d/security/nss/nss-latest/nss/lib/util'
> > > make[1]: *** [libs] Error 2
> > > make[1]: Leaving directory `/d/security/nss/nss-latest/nss/lib'
> > > make: *** [libs] Error 2
> > >
> > > How to resolve this problem?
> > > Thanks!
> > >
> > --
> > dev-tech-crypto mailing list
> > dev-tech-crypto@lists.mozilla.org
> > https://lists.mozilla.org/listinfo/dev-tech-crypto
> >
> --
> dev-tech-crypto mailing list
> dev-tech-crypto@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-crypto
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto


Re: Problem on building NSS with Windows

2016-08-19 Thread John Jiang
In addition, I have checked my installed MozillaBuild. It doesn't include
file quickder.c.
Is there any wrong on MoziilaBuild? Or some issue in my environment?

2016-08-19 15:24 GMT+08:00 John Jiang :

> Hi,
> I tried to build NSS on Windows 7 x86_64 machine, and followed the
> instructions at:
> https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Building
>
> VS 2015 community and Latest MozillaBuild have been installed, and USE_64
> was set to 1.
> When "make nss_build_all" finished, I got the below errors:
> c1: fatal error C1083: Cannot open source file: 
> 'C:/mozilla-build/msys/quickder.c':
> No such file or directory
> make[2]: *** [WIN954.0_x86_64_64_DBG.OBJ/quickder.obj] Error 2
> make[2]: Leaving directory `/d/security/nss/nss-latest/nss/lib/util'
> make[1]: *** [libs] Error 2
> make[1]: Leaving directory `/d/security/nss/nss-latest/nss/lib'
> make: *** [libs] Error 2
>
> How to resolve this problem?
> Thanks!
>
-- 
dev-tech-crypto mailing list
dev-tech-crypto@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto