#1477 Python can't find config.guess on builds not using MOZ_OBJDIR

Closed
opened 1 year ago by dbsoft · 13 comments
dbsoft commented 1 year ago (Migrated from github.com)

During ./mach configure a python errno 2 No such file or directory is raised when building using the newly separated Pale Moon/Basilisk and UXP.

Result: OSError: [Errno 2] No such file or directory File “/Users/..../work/github/dbsoft/Basilisk/platform/python/mozbuild/mozbuild/base.py”, line 364, in resolve_config_guess
Expected result: No error.
Steps to reproduce: Checkout Pale-Moon or Basilisk, git submodule init && get submodule update && ./mach configure
Affected versions: Pale Moon 29 and current Basilisk
Affected environments: All macOS versions

Adding ‘platform’ to line 354 fixes the problem, can anyone test if this change breaks other platforms?

p = os.path.join(self.topsrcdir, ‘platform’, ‘build’, ‘autoconf’, ‘config.guess’)

During ./mach configure a python errno 2 No such file or directory is raised when building using the newly separated Pale Moon/Basilisk and UXP. Result: OSError: [Errno 2] No such file or directory File "/Users/..../work/github/dbsoft/Basilisk/platform/python/mozbuild/mozbuild/base.py", line 364, in resolve_config_guess Expected result: No error. Steps to reproduce: Checkout Pale-Moon or Basilisk, git submodule init && get submodule update && ./mach configure Affected versions: Pale Moon 29 and current Basilisk Affected environments: All macOS versions Adding 'platform' to line 354 fixes the problem, can anyone test if this change breaks other platforms? p = os.path.join(self.topsrcdir, 'platform', 'build', 'autoconf', 'config.guess')
mattatobin commented 1 year ago (Migrated from github.com)

This needs to be backwards compatible for building xulrunner and js as well as legacy comm.

Please check for file existence of p at
build/autoconf/config.guess
-else-
mozilla/build/autoconf/config.guess
-else-
platform/build/autoconf/config.guess
in that order.

BTW you should try and explain what needs to be done before making commits or PRs so that everything can stay clean and focused.

This needs to be backwards compatible for building `xulrunner` and `js` as well as legacy `comm`. Please check for file existence of `p` at `build/autoconf/config.guess` -else- `mozilla/build/autoconf/config.guess` -else- `platform/build/autoconf/config.guess` in that order. BTW you should try and explain what needs to be done before making commits or PRs so that everything can stay clean and focused.
mattatobin commented 1 year ago (Migrated from github.com)

You need to slow the hell down and stop trying to shove patches at us.

Don’t create “drafts” but explain the issue, point at the problem and don’t submit anything until you are instructed to.

Your PR that was submitted is worthless because it isn’t backwards compatible and doesn’t take other concerns into account because you aren’t aware of these things yet.

You need to slow the hell down and stop trying to shove patches at us. Don't create "drafts" but explain the issue, point at the problem and don't submit anything until you are instructed to. Your PR that was submitted is worthless because it isn't backwards compatible and doesn't take other concerns into account because you aren't aware of these things yet.
dbsoft commented 1 year ago (Migrated from github.com)

I figured that is what the drafts were for, so people could grab the draft and see if it works or needs changes... but sure. Will do.

I figured that is what the drafts were for, so people could grab the draft and see if it works or needs changes... but sure. Will do.
mattatobin commented 1 year ago (Migrated from github.com)

You really should stop assuming things and trying to rush. This isn’t an emergency or a crisis dude.

You really should stop assuming things and trying to rush. This isn't an emergency or a crisis dude.
mattatobin commented 1 year ago (Migrated from github.com)
See a similar situation @ http://xref.palemoon.org/moonchild-central/source/platform/python/mozbuild/mozbuild/controller/clobber.py#54 for reference.
dbsoft commented 1 year ago (Migrated from github.com)

Thanks I’ll look into making the change you requested to check the multiple locations. I don’t think I am rushing or acting like it is an emergency I am trying to use the tools that you use for the project as you instructed. I am sorry I used the draft PR incorrectly but I see no direction explaining anywhere when they are supposed to be used.

Thanks I'll look into making the change you requested to check the multiple locations. I don't think I am rushing or acting like it is an emergency I am trying to use the tools that you use for the project as you instructed. I am sorry I used the draft PR incorrectly but I see no direction explaining anywhere when they are supposed to be used.
dbsoft commented 1 year ago (Migrated from github.com)

Here is the diff to apply since my commit is unmergeable as is.

base.py.diff.zip

Here is the diff to apply since my commit is unmergeable as is. [base.py.diff.zip](https://github.com/MoonchildProductions/UXP/files/4321244/base.py.diff.zip)
wolfbeast commented 1 year ago (Migrated from github.com)

How about using the normal clone -> edit -> submit pull request method? You already did the first two steps, having a dbsoft/UXP repo.

How about using the normal clone -> edit -> submit pull request method? You already did the first two steps, having a `dbsoft/UXP` repo.
mattatobin commented 1 year ago (Migrated from github.com)

Because he is new to git and even newer to this method of doing things and is struggling so I suggested just sending a patch file for now until he gets more comfortable with it.

Not everyone can run an easy to use gui git client or has been using it for years and I have no issue with landing patch files on someone’s behalf especially when they trying to adapt to it all at once.

Besides I need to test them anyway and specifically requested it.

Because he is new to git and even newer to this method of doing things and is struggling so I suggested just sending a patch file for now until he gets more comfortable with it. Not everyone can run an easy to use gui git client or has been using it for years and I have no issue with landing patch files on someone's behalf especially when they trying to adapt to it all at once. Besides I need to test them anyway and specifically requested it.
wolfbeast commented 1 year ago (Migrated from github.com)

If you suggest something like that’s fine but communicate that fact too, please? How am I to guess this was as-directed?

If you suggest something like that's fine but communicate that fact too, please? How am I to guess this was as-directed?
wolfbeast commented 1 year ago (Migrated from github.com)
 +        # Try looking for mozilla, for comm-central
 +        if not os.path.isfile(p):
 +            p = os.path.join(self.topsrcdir, 'mozilla', 'build', 'autoconf', 'config.guess')
 +
 +        if not os.path.isfile(p):
 +            p = os.path.join(self.topsrcdir, 'platform', 'build', 'autoconf', 'config.guess')

Do we need the “mozilla” one? How would that ever be used?
Also... how would simply assuming UXP is going to be installed in directory X from within itself be a good solution? isn’t self.topsrcdir already pointing to the srcdir of the platform?

```diff + # Try looking for mozilla, for comm-central + if not os.path.isfile(p): + p = os.path.join(self.topsrcdir, 'mozilla', 'build', 'autoconf', 'config.guess') + + if not os.path.isfile(p): + p = os.path.join(self.topsrcdir, 'platform', 'build', 'autoconf', 'config.guess') ``` Do we need the "mozilla" one? How would that ever be used? Also... how would simply assuming UXP is going to be installed in directory X from within itself be a good solution? isn't `self.topsrcdir` already pointing to the srcdir of the platform?
mattatobin commented 1 year ago (Migrated from github.com)

Hyperbola has not renamed the platform directory yet.

I am specifically maintaining backwards compatibility anyway. The same was done elsewhere.

It still remains unclear why this seems to be a problem but only sometimes on mac but not anywhere else but for consistency it should be done exactly like it was in clobber.py which was the reference I gave him to follow.

Hyperbola has not renamed the platform directory yet. I am specifically maintaining backwards compatibility anyway. The same was done elsewhere. It still remains unclear why this seems to be a problem but only sometimes on mac but not anywhere else but for consistency it should be done exactly like it was in clobber.py which was the reference I gave him to follow.
mattatobin commented 1 year ago (Migrated from github.com)

self.topsrcdir is not the root of the platform tree when building not js or xulrunner.

`self.topsrcdir` is not the root of the platform tree when building not `js` or `xulrunner`.
This repo is archived. You cannot comment on issues.
No Milestone
No Assignees
1 Participants
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.