[GNC-dev] Fresh Windows build setup fails

John Ralls jralls at ceridwen.us
Fri Dec 25 22:38:54 EST 2020



> On Dec 24, 2020, at 7:51 AM, Robert Fewell <14ubobit at gmail.com> wrote:
> 
> John,
> 
> I think this is down to paths / filenames, I can fix all the missing dependencies by doing this...
> 
> 
>     c_include_search_paths = None
>     for dep_type, value, altdeps in sysdeps:
>         print("dep_type: ", dep_type)
>         print("value is: ", value)
>         dep_met = True
>         if dep_type.lower() == 'path':
>             if os.path.split(value)[0]:
>                 if not os.path.isfile(value) and not os.access(value, os.X_OK):
>                     dep_met = False
>             else:
>                 pathdirs = set(os.environ.get('PATH', '').split(os.pathsep))
>                 pathdirs.update(['/sbin', '/usr/sbin'])
>                 for path in pathdirs:
>                     filename = os.path.join(path, value)
>                     filename = filename.replace("/c/", "/")
>                     print("path filename is: ", filename)
>                     if os.path.isfile(filename) and os.access(filename, os.X_OK):
>                         break
>                     filename = filename + ".exe"
>                     print("path filename is: ", filename)
>                     if os.path.isfile(filename) and os.access(filename, os.X_OK):
>                         break
>                 else:
>                     dep_met = False
>         elif dep_type.lower() == 'c_include':
>             if c_include_search_paths is None:
>                 c_include_search_paths = get_c_include_search_paths(config)
>             found = False
>             for path in c_include_search_paths:
>                 filename = os.path.join(path, value)
>                 print("filename is: ", filename)
>                 filename = filename.replace("/c/", "/")
>                 print("filename is: ", filename)
>                 if os.path.isfile(filename):
>                     found = True
>                     break
>             if not found:
>                 dep_met = False
> 
> Not very portable but may give you an idea for correct fix.
> 
> Now I get ....
> Traceback (most recent call last):
>   File "C:/gcdev64/msys2/usr/bin/jhbuild", line 23, in <module>
>     jhbuild.main.main(sys.argv[1:])
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/main.py", line 120, in main
>     rc = jhbuild.commands.run(command, config, args, help=lambda: print_help(parser))
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/commands/__init__.py", line 188, in run
>     return cmd.execute(config, args, help)
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/commands/__init__.py", line 56, in execute
>     return self.run(config, options, args, help)
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/commands/base.py", line 262, in run
>     build = jhbuild.frontends.get_buildscript(config, module_list, module_set=module_set)
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/frontends/__init__.py", line 27, in get_buildscript
>     return BuildScript(config, module_list, module_set=module_set)
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/frontends/terminal.py", line 111, in __init__
>     buildscript.BuildScript.__init__(self, config, module_list, module_set=module_set)
>   File "c:\gcdev64\src\jhbuild.git/jhbuild/frontends/buildscript.py", line 78, in __init__
>     subprocess.call(chrt_args + ['true'], stdout=devnull, stderr=devnull) == 0):
> AttributeError: module 'jhbuild.utils.subprocess_win32' has no attribute 'call'

Bob,

Did you add that python fragment to jhbuildrc?

I tested two things yesterday: Installing a fresh build environment and running pacman -Syuu on my current one. In the latter I found that the replacement of pkg-config with pkgconf was a dependency of cmake 3.19 so I set an ignore on cmake in pacman.conf before allowing the upgrade to proceed. I also pulled the latest jhbuild. That one works fine.

I'm trying figure out what's making subprocess_win32 to break subprocess on the new install while it works OK on the old one. The python packages are the same and I've made sure that both jhbuild repos are at the current HEAD. I rolled back cmake to 3.18 and reinstalled pkg-config replacing pkgconf. 

Regards,
John Ralls




More information about the gnucash-devel mailing list