Opened 2 years ago

Closed 2 years ago

#65065 closed defect (fixed)

curl: circular dependency introduced due to dependency on brotli

Reported by: Torsten-B Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.7.2
Keywords: Cc: xiaoqiangwang (Xiaoqiang Wang), cooljeanius (Eric Gallager), Dave-Allured (Dave Allured)
Port: curl

Description (last modified by ryandesign (Ryan Carsten Schmidt))

Building cmake or curl currently fails due to a circular dependency:

[torstenb@phoenix:~] sudo port -s install cmake
--->  Computing dependencies for cmake
The following dependencies will be installed:
 brotli
 cmake
 curl
Continue? [Y/n]: y
Error: The following dependencies were not installed because all of them have unmet dependencies (likely due to a dependency cycle): curl brotli cmake
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
Error: Processing of port cmake failed
[torstenb@phoenix:~] sudo port -s install curl
--->  Computing dependencies for curl
The following dependencies will be installed:
 brotli
 cmake
 curl
Continue? [Y/n]: y
Error: The following dependencies were not installed because all of them have unmet dependencies (likely due to a dependency cycle): brotli cmake curl
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
Error: Processing of port curl failed

The circular dependency is caused by cmake requiring port:curl, port:curl requiring port:brotli and port:brotli in turn requiring port:cmake.

This change was introduced in a recent commit that adds brotli support to curl. [e1ed418961c5919aacfeb582bb0baa2d74243a8f/macports-ports]

Change History (15)

comment:1 Changed 2 years ago by Torsten-B

Cc: Torsten-B added

comment:2 Changed 2 years ago by Torsten-B

Cc: Torsten-B removed

comment:3 Changed 2 years ago by Torsten-B

Cc: Torsten-B added

comment:4 Changed 2 years ago by Torsten-B

Summary: curl: circular dependency introduced due to dependency on brodlecurl: circular dependency introduced due to dependency on brotli

comment:5 Changed 2 years ago by reneeotten (Renee Otten)

Cc: Torsten-B removed
Owner: set to ryandesign
Status: newassigned

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

Description: modified (diff)
Keywords: curl brotli cmake removed
Status: assignedaccepted

Ugggggggh.

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

Possible solutions:

  • cmake stops using curl (#65068)
  • brotli stops using cmake (#65069)
  • curl stops using brotli by default, moving it to a variant

comment:8 Changed 2 years ago by Torsten-B

Alternative 3 (curl moving brotli support to a variant) doesn't actually fix the circular dependency, it just moves it to a variant and building that variant wouldn't work unless alternative 1 and/or 2 get implemented as well. Or am I missing something?

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

You could build curl without the variant, the dependencies would be installed, and then you could build curl again with the variant. Same strategy is used in a few other ports where such circular dependencies have no other solution (like #55393).

comment:10 Changed 2 years ago by kencu (Ken)

brotli has committed to supporting old cmake versions, so cmake-bootstrap will suffice, and it has no deps

https://github.com/google/brotli/blob/f4153a09f87cbb9c826d8fc12c74642bb2d879ea/CMakeLists.txt#L5

Last edited 2 years ago by kencu (Ken) (previous) (diff)

comment:11 Changed 2 years ago by reneeotten (Renee Otten)

Cc: xiaoqiangwang added

comment:12 Changed 2 years ago by reneeotten (Renee Otten)

has duplicate

comment:13 Changed 2 years ago by cooljeanius (Eric Gallager)

Cc: cooljeanius added

comment:14 Changed 2 years ago by Dave-Allured (Dave Allured)

Cc: Dave-Allured added

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

Resolution: fixed
Status: acceptedclosed

In d2aca51d29a3b894d39754dd090202e8deb85171/macports-ports (master):

brotli: Use cmake-bootstrap

Avoids a circular dependency, since cmake uses curl which now uses
brotli.

Closes: #65065
Closes: #65069

While we're here, remove unnecessary directory creations from
post-destroot.

Note: See TracTickets for help on using tickets.