[GNC-dev] Build on MacOS

Roger Moore ripngo at gmail.com
Thu Mar 5 00:29:36 EST 2020


mmm I'm running into a new problem now, which I really don't understand...

Teds-iMac:~ gnucash$ jhbuild build
Loading .env environment variables…
jhbuild build: failed to parse
/Users/gnucash/Source/jhbuild/modulesets/file:/Users/john/Development/GTK-OSX/gtk-osx-build/modulesets-stable/gtk-osx.modules:
[Errno 2] No such file or directory:
u'/Users/gnucash/Source/jhbuild/modulesets/file:/Users/john/Development/GTK-OSX/gtk-osx-build/modulesets-stable/gtk-osx.modules'

Where does this /Users/john path comes from?
I didn't change anything to my setup, came back 5 days later, and I'm
getting this error now... Does jhbuild run git in the background?

Any idea what I should do now?
Jean
On Wed, Mar 4, 2020 at 8:11 PM jean laroche <ripngo at gmail.com> wrote:

> Thanks John,
> Of course, I know it's never a good option to press [3] and skip, but
> this way you could see all errors that weren't caused by previous errors.
>
>  > Did you tell jhbuild to skip mysql?
> No, I don't even know how to do that! :)
>
> > You have a bad boost download so you'll have to delete the downloaded
> file and try again.
> OK.
> I'm going to try your recommendations and report.
> Thanks!
> Jean
>
> On 2/29/2020 12:42 PM, John Ralls wrote:
> > Skipping the itstool module caused the gtk-doc failure, and skipping
> that caused the gtk+ failure, and so on. When a build fails you have to fix
> it, so don't *ever* use [3] give up on module.
> >
> > The itstool failure itself is because python3 when built from scratch
> doesn't create a python or python-config symlink so itstool looks in the
> wrong place for the the python libxml2 module. I usually drop to the shell
> (option 4 on the jhbuild failure menu) cd to $PREFIX/bin, create the two
> symlinks, exit the shell and pick [1] from the menu to try again.
> >
> > For xmlsec use either [2] ignore and continue to build or [6] wipe
> directory and start over.
> >
> > Did you tell jhbuild to skip mysql?
> >
> > You have a bad boost download so you'll have to delete the downloaded
> file and try again.
> >
> > I pushed fixes for libgpg-error and libdbi-drivers tests/cgreen include
> problem. The latter involves a patch so you need to delete the source
> directory for it to apply.
> >
> > Regards,
> > John Ralls
> >
> >
> >> On Feb 29, 2020, at 9:00 AM, jean laroche <ripngo at gmail.com> wrote:
> >>
> >> I started from a fresh user, with no trace of brew. I'm getting many
> fails.
> >> I created a pastebin with the messages of a re-run of jhbuild build, so
> you can see the details:
> >> https://pastebin.com/293FMgVk
> >>
> >> Let me know what you think. I'll be away from the mac until next Wed,
> but I'll be within email contact.
> >>
> >> A million thanks for the help!
> >> Cheers,
> >> Jean
> >>
> >>
> >> On 2/28/2020 8:06 PM, John Ralls wrote:
> >>> Jean,
> >>>
> >>> Please remember to copy the list on all replies.
> >>>
> >>>> On Feb 28, 2020, at 8:26 PM, jean laroche <ripngo at gmail.com> wrote:
> >>>>
> >>>> Thanks for the pointers John! Very useful! As a newbie building this,
> I have no idea what's important and what not. Here are my notes.
> >>>>
> >>>> Note that a lot of this is hacking, trying to get to a point where I
> can build. The solutions are just band-aids, and they may not be good ones
> either!
> >>>>
> >>>>    • Build complained about perl XML parser. I started a shell at the
> point where it failed and followed this.  perl -MCPAN -e shell, followed by
> install XML::Parser. This fixed it.
> >>> xml-parser, along with several other critical infrastructure packages,
> is installed by `jhbuild bootstrap-gtk-osx`, which you need to run before
> starting the build proper. I wonder how you were able to proceed without
> that.
> >>>
> >>>>    • There was an error finding gpg-error.h, which is here:
> /usr/local/Cellar/libgpg-error/1.37/include/gpg-error.h so I did ln -s ->
> /Users/gnucash/gnucash-stable/include/gpg-error.h
> >>> Gtk-OSX is incompatible with Home-brew. Not only must you not try to
> install into /usr/local/Cellar, you must purge your environment of any
> paths (PATH, DYLD_LIBRARY_PATH, PKG_CONFIG_PATH, etc.) pointing into it.
> Same for MacPorts.
> >>>
> >>> Note that the Home-brew recipe for GnuCash simply downloads and
> installs the Mac release bundle from our distribution repository: Even they
> don't support building GnuCash from source. MacPorts does, but you have to
> decide to use either MacPorts or Gtk-OSX.
> >>>
> >>>>    • Had to do brew install postgresql
> >>> See above.
> >>>
> >>>>    • Got: “configure.ac: No such file or directory” Went into shell
> copied everything from /Users/gnucash/gnucash-stable/src/libgpg-error-1.27
> locally, and retried. It worked.
> >>> That's the wrong thing to do. Instead cd to the source dir and run
> either `autoreconf -fis` or `./autogen.sh`.
> >>>
> >>>>    • Xmlsec refused because of “dirty” dir. I removed the entire
> xmlsec directory. But then I get an error with cp -u which does not work on
> macos, which I fixed by removing -ru in line 749 of docs/Makefile.* and 619
> in docs/api/Makefile.*
> >>> How did you remove the directory? The correct way is to use selection
> 6, "delete directory and start over" from the jhbuild error menu. It should
> take care of getting the build restarted. OTOH I usually pick 2, "ignore
> the error and continue to configure" because it's frankly not that
> important to have the latest xmlsec code.
> >>>
> >>>>    • Ran into a problem with libdbi-drivers: Had to add
> -L/Users/gnucash/gnucash-stable/build/libdbi-drivers-0.9.0/drivers/mysql to
> the Makefile located there, and link /usr/local/Cellar/mysql at 5.6/5.6.46_2/lib/libmysqlclient.18.dylib
> there as well.
> >>> See above about Home-brew.
> >>>
> >>>>    • Ran into: “can’t find cgreen/parameters.h” for
> libdbi-drivers-0.9.0. I linked
> /Users/gnucash/gnucash-stable/src/libdbi-drivers-0.9.0/tests/cgreen/include/cgreen
> to the target dir. That fixed it.
> >>> I've been meaning to write a patch about that.
> >>>
> >>>>    • Intltool complained about version. I have the right version, so
> I removed check in the configure file.
> >>> It probably couldn't find the right version because of Home-brew.
> >>>>    • Then I was missing aclocal-1.15 … Ran  autoreconf -f -i as
> suggested.
> >>>>    • For libsoup same complaint about intltool version. Same action.
> >>>>    • Building shared-mime-info: manuallly ran configure
> --disable-dependency-tracking, then skipped to build, but hit Makefile
> 1161: *** missing separator. Edited. Also changed INTNL-UPDATE to
> intnl-update in Makefile.in.in in po. Also remove everything after
> “check” at line 149 same file.
> >>>> Then I get a hard crash:
> >>>> OSError: [Errno 2] No such file or directory:
> '/Users/gnucash/gnucash-stable/_jhbuild/root-shared-mime-info/Users/gnucash/gnucash-stable'
> >>>> File
> "/Users/gnucash/Source/jhbuild/jhbuild/frontends/buildscript.py", line 172,
> in build error, altphases = module.run_phase(self, phase)
> >>>> I added a pdb.set_trace() in the python script and created the dirs,
> then continued the command. That worked.
> >>>> It would be great if you could tell me if these errors ring a bell
> for you, and what better steps I should have taken to fix them... Not
> knowing anything about this build process I went for the most expedient
> solution I could find, chances are, not the best!
> >>>>
> >>>> Thanks! I appreciate the help!
> >>>>
> >>>> Jean
> >>>>
> >>>> BTW: swig-unittest-support-guile.c  is nowhere to be found in the
> tree, neither built nor src, so something's not right.
> >>> Unfortunately you've probably screwed up your Cellar on top of
> everything else so you might have to wipe it and reinstall Home-brew.
> >>>
> >>> The easiest way to get a clean environment for building GnuCash is to
> create a new user and switch to that user for building with Gtk-OSX.
> Unfortunately there's no way to stop bash from reading the environment it's
> launched from so I think that the only other option is to create a
> different .bash_profile and .bashrc with no Home-brew configuration and
> play name-swap, then open a new terminal session. IMO switching users would
> be easier.
> >>>
> >>> Regards,
> >>> John Ralls
> >>>
>
>


More information about the gnucash-devel mailing list