Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macvim: 8.2.3455 -> 178 #260094

Merged
merged 2 commits into from
Jul 2, 2024
Merged

macvim: 8.2.3455 -> 178 #260094

merged 2 commits into from
Jul 2, 2024

Conversation

lilyball
Copy link
Member

@lilyball lilyball commented Oct 9, 2023

Description of changes

This updates MacVim to the latest release. I've been running these changes locally for a while now, on both macOS Ventura and macOS Sonoma. It also fixes the ability to override macvim (previously it would override the macvim-configurable.nix file instead). The version is now listed as 178 as MacVim has switched to reporting its own version as its release number.

MacVim release notes:
Release 173 (Vim 9.0.0065)
Release 174 (Vim 9.0.472)
(Release 175 was pulled)
Release 176 (Vim 9.0.1276)
r177 (Vim 9.0.1677)
r178 (Vim 9.0.1897)

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 23.11 Release Notes (or backporting 23.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux labels Oct 10, 2023
@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-ready-for-review/3032/2786

@lilyball
Copy link
Member Author

@millerjason I just requested review from you because you authored #239842 (which this obsoletes)

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-ready-for-review/3032/3329

@millerjason
Copy link
Contributor

@millerjason I just requested review from you because you authored #239842 (which this obsoletes)

Agreed and lgtm - thanks!

Comment on lines 21 to 22
# Python3 3.9 or above - the binary release builds against 3.11 so we will too
python3 = python311;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

python3 defaults to that, do we really need to hardcode it here? Same for ruby_3_2.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At the time this PR was written, python3 evaluated to python310 instead. And ruby still evaluates to ruby_3_1. I'm open to changing this to just python3 as MacVim documents compatibility with "Python3 3.9 or above", but the ruby support is documented as "Ruby 3.2" so we should match that.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've removed the python311 pin but left ruby_3_2.


src = fetchFromGitHub {
owner = "macvim-dev";
repo = "macvim";
rev = "snapshot-172";
sha256 = "sha256-LLLQ/V1vyKTuSXzHW3SOlOejZD5AV16NthEdMoTnfko=";
rev = "release-178";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be derived from version

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you proposing that this should use finalAttrs and programmatically change r### into release-###, so someone overriding the version to r179 will automatically update the rev too? Or do you just not like that the 178 is duplicated? I'm partial to the idea that changing the version changes the rev too, but that requires defining what happens if someone overrides the version to something that doesn't match r###.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you proposing that this should use finalAttrs and programmatically change r### into release-###, so someone overriding the version to r179 will automatically update the rev too?

First yes but then I remembered that we are stripping prefixes like r or v from versions, so we just need to substitute it here.

Suggested change
rev = "release-178";
rev = "release-${version}";

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@wegank wegank added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Mar 8, 2024
@hraban
Copy link
Member

hraban commented Mar 26, 2024

Can confirm this fixes the perl configuration issue on aarch64-darwin. It fails later in the build process but I assume that's unrelated to this PR?

macvim-r178> xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

@LeSuisse
Copy link
Contributor

LeSuisse commented Apr 2, 2024

Includes the fix for CVE-2023-41036.

@LeSuisse LeSuisse added the 1.severity: security Issues which raise a security issue, or PRs that fix one label Apr 2, 2024
@lilyball
Copy link
Member Author

Can confirm this fixes the perl configuration issue on aarch64-darwin. It fails later in the build process but I assume that's unrelated to this PR?

macvim-r178> xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

Yeah, that error is saying you need to have Xcode.app installed rather than using the CommandLineTools installation. The latter provides compiler support but does not provide everything that Xcode does, and MacVim is an Xcode project.

This error is the unfortunate consequence of the fact that MacVim is an impure derivation, relying on the user to have installed Xcode.app.

@wegank wegank added the 2.status: merge conflict This PR has merge conflicts with the target branch label May 22, 2024
Previously, attemping to override macvim would override the
`macvim-configurable.nix` definition instead of overriding the macvim
package.
@lilyball
Copy link
Member Author

lilyball commented Jun 4, 2024

Rebased to fix merge conflict. I also removed the hardcoding of python311 in the process.

@lilyball lilyball removed the 2.status: merge conflict This PR has merge conflicts with the target branch label Jun 4, 2024
@@ -29,13 +37,13 @@ in
stdenv.mkDerivation {
pname = "macvim";

version = "8.2.3455";
version = "r178";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
version = "r178";
version = "178";


src = fetchFromGitHub {
owner = "macvim-dev";
repo = "macvim";
rev = "snapshot-172";
sha256 = "sha256-LLLQ/V1vyKTuSXzHW3SOlOejZD5AV16NthEdMoTnfko=";
rev = "release-178";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you proposing that this should use finalAttrs and programmatically change r### into release-###, so someone overriding the version to r179 will automatically update the rev too?

First yes but then I remembered that we are stripping prefixes like r or v from versions, so we just need to substitute it here.

Suggested change
rev = "release-178";
rev = "release-${version}";

@wegank wegank removed the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Jun 26, 2024
MacVim now uses its own release number as its primary version, but this
is equivalent to 9.0.1897.
@lilyball lilyball changed the title macvim: 8.2.3455 -> r178 macvim: 8.2.3455 -> 178 Jun 27, 2024
@lilyball
Copy link
Member Author

I've applied the suggestion to set version = "178" and to use that version in the definition of rev.

Copy link
Member

@lilyinstarlight lilyinstarlight left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The diff looks good to me and is at least a clear improvement to status-quo for this package

Thank you!

(I technically stepped down from nixpkgs maintainership yesterday, but I'll send this as my last contribution to nixpkgs since it appears ready and I was already reviewing it yesterday before stepping down)

@lilyinstarlight lilyinstarlight merged commit 87ceeab into NixOS:master Jul 2, 2024
23 checks passed
@lilyball lilyball deleted the update-macvim branch July 2, 2024 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.severity: security Issues which raise a security issue, or PRs that fix one 6.topic: vim 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants