Opened 3 years ago

Closed 3 years ago

#51137 closed defect (worksforme)

Cannot build gobject-introspection when python+ucs4 is installed

Reported by: Tatsh (Andrew Udvare) Owned by: juanrgar@…
Priority: Normal Milestone:
Component: ports Version: 2.3.4
Keywords: Cc: dbevans (David B. Evans)
Port: gobject-introspection

Description

When I run port upgrade outdated I get the below output:

--->  Computing dependencies for atk..
--->  Dependencies to be installed: gobject-introspection
--->  Configuring gobject-introspection
Error: org.macports.configure for port gobject-introspection returned: You have python installed with the +ucs4 variant. Please build gobject-introspection with +python_ucs4
Warning: targets not executed for gobject-introspection: org.macports.activate org.macports.configure org.macports.build org.macports.destroot org.macports.install
Error: Failed to install gobject-introspection
Please see the log file for port gobject-introspection for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gnome_gobject-introspection/gobject-introspection/main.log
Error: The following dependencies were not installed: gobject-introspection
Error: Unable to upgrade port: 1

I manually installed gobject-introspection with +python_ucs4 and it still does not see it.

Is there any way ports can auto-detect the variant flags they need and apply them? This is a bit surprising to me (coming from Portage where USE flags can be very strict when it comes to dependencies (REQURED_USE)).

Change History (6)

comment:1 Changed 3 years ago by mf2k (Frank Schima)

Cc: devans@… added; juanrgar@… removed
Keywords: ucs4 removed
Owner: changed from macports-tickets@… to juanrgar@…

comment:2 Changed 3 years ago by ryandesign (Ryan Schmidt)

You should attach the main.log file so that we can see exactly what went wrong.

The use of the python ports' +ucs4 variant is not recommended, because it causes build failures of some other ports.

MacPorts doesn't have the ability for a port to declare a dependency on a variant of another port. See #126. As much as possible, variants should not be used for capabilities that other ports might need to depend on.

comment:3 Changed 3 years ago by dbevans (David B. Evans)

See also discussion in #51032.

comment:4 in reply to:  description Changed 3 years ago by dbevans (David B. Evans)

Replying to audvare@…:

When I run port upgrade outdated I get the below output:

--->  Computing dependencies for atk..
--->  Dependencies to be installed: gobject-introspection
--->  Configuring gobject-introspection
Error: org.macports.configure for port gobject-introspection returned: You have python installed with the +ucs4 variant. Please build gobject-introspection with +python_ucs4
Warning: targets not executed for gobject-introspection: org.macports.activate org.macports.configure org.macports.build org.macports.destroot org.macports.install
Error: Failed to install gobject-introspection
Please see the log file for port gobject-introspection for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gnome_gobject-introspection/gobject-introspection/main.log
Error: The following dependencies were not installed: gobject-introspection
Error: Unable to upgrade port: 1

The relevant message here is

You have python installed with the +ucs4 variant. Please build gobject-introspection with +python_ucs4

I manually installed gobject-introspection with +python_ucs4 and it still does not see it.

I'm not sure what you mean here by 'still does not see it' but the following commands work for me:

$ sudo port install python27 +ucs4
$ sudo port install gobject-introspection +python_ucs4
$ port installed python27 gobject-introspection
  gobject-introspection @1.48.0_0
  gobject-introspection @1.48.0_0+python_ucs4 (active)
  python27 @2.7.11_2
  python27 @2.7.11_2+ucs4 (active)

Keep in mind, however, that as stated above, using python27 +ucs is known to cause problems with some ports so if you don't really need to use it, best is to not do so.

Last edited 3 years ago by dbevans (David B. Evans) (previous) (diff)

comment:5 Changed 3 years ago by Tatsh (Andrew Udvare)

It's when I run port upgrade outdated that this does not work and I get the output I gave, even after running port install gobject-introspection +python_ucs4.

For now I will undo ucs4, but a non-wide version of Python is pretty weird nowadays. Packages like Unidecode become almost useless once you want characters outside the BMP. Is there any consideration to make ucs4 the default or not even allow it to be disabled?

comment:6 in reply to:  5 Changed 3 years ago by dbevans (David B. Evans)

Resolution: worksforme
Status: newclosed

Replying to audvare@…:

It's when I run port upgrade outdated that this does not work and I get the output I gave, even after running port install gobject-introspection +python_ucs4.

Will check this. Upgrade should use the same variants as previously installed.

For now I will undo ucs4, but a non-wide version of Python is pretty weird nowadays. Packages like Unidecode become almost useless once you want characters outside the BMP. Is there any consideration to make ucs4 the default or not even allow it to be disabled?

I'm not one of the python maintainers but it has been some time since I heard about these issues and it may be that it's time the current stance should be re-evalutated and modified if warranted.

Note: See TracTickets for help on using tickets.