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

nemu: init at 2.6.0 #82004

Closed
wants to merge 3 commits into from
Closed

Conversation

matthiasbeyer
Copy link
Contributor

Can someone help me with the install step here?

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

++ (lib.optional withDbus "-DNM_WITH_DBUS=ON")
;

installPhase = ''
Copy link
Contributor

Choose a reason for hiding this comment

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

Upstream doesn't know how to write CMakeLists.txt. The following warning messages in configurePhase indicate this:

CMake Warning:
  Manually-specified variables were not used by the project:

    BUILD_TESTING
    CMAKE_CXX_COMPILER
    CMAKE_EXPORT_NO_PACKAGE_REGISTRY
    CMAKE_INSTALL_BINDIR
    CMAKE_INSTALL_DOCDIR
    CMAKE_INSTALL_INCLUDEDIR
    CMAKE_INSTALL_INFODIR
    CMAKE_INSTALL_LIBDIR
    CMAKE_INSTALL_LIBEXECDIR
    CMAKE_INSTALL_LOCALEDIR
    CMAKE_INSTALL_MANDIR
    CMAKE_INSTALL_OLDINCLUDEDIR
    CMAKE_INSTALL_SBINDIR

And it's notable when reading this:

https://github.com/nemuTUI/nemu/blob/1633a9ecb2b9b036a01a5dbeddb21787680064ec/CMakeLists.txt#L24-L36

I say - report this upstream and once fixed, use a fetchpatch remove the installPhase override.

Copy link
Contributor

Choose a reason for hiding this comment

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

In particular, most of these are caused not using GNUInstallDirs cmake module.

Copy link

Choose a reason for hiding this comment

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

We updated our CMakeLists.txt
nemuTUI/nemu@a3f179a

Can you guys check if it's ok in current state, if so, we can make a new release for your package

Copy link
Contributor

Choose a reason for hiding this comment

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

Evaluation has failed: https://gist.github.com/f2bfb5498488aa5d2895bcbcace14e8d because of libudev argument not suppliled.

Copy link
Member

Choose a reason for hiding this comment

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

@matthiasbeyer please fix the inputs.

@caadar
Copy link
Contributor

caadar commented Mar 10, 2020

Ah! Some time ago tried packaging nEMU but not finished it...
You may look at my nemu-nix if interested.

@stale
Copy link

stale bot commented Sep 7, 2020

Hello, I'm a bot and I thank you in the name of the community for your contributions.

Nixpkgs is a busy repository, and unfortunately sometimes PRs get left behind for too long. Nevertheless, we'd like to help committers reach the PRs that are still important. This PR has had no activity for 180 days, and so I marked it as stale, but you can rest assured it will never be closed by a non-human.

If this is still important to you and you'd like to remove the stale label, we ask that you leave a comment. Your comment can be as simple as "still important to me". But there's a bit more you can do:

If you received an approval by an unprivileged maintainer and you are just waiting for a merge, you can @ mention someone with merge permissions and ask them to help. You might be able to find someone relevant by using Git blame on the relevant files, or via GitHub's web interface. You can see if someone's a member of the nixpkgs-committers team, by hovering with the mouse over their username on the web interface, or by searching them directly on the list.

If your PR wasn't reviewed at all, it might help to find someone who's perhaps a user of the package or module you are changing, or alternatively, ask once more for a review by the maintainer of the package/module this is about. If you don't know any, you can use Git blame on the relevant files, or GitHub's web interface to find someone who touched the relevant files in the past.

If your PR has had reviews and nevertheless got stale, make sure you've responded to all of the reviewer's requests / questions. Usually when PR authors show responsibility and dedication, reviewers (privileged or not) show dedication as well. If you've pushed a change, it's possible the reviewer wasn't notified about your push via email, so you can always officially request them for a review, or just @ mention them and say you've addressed their comments.

Lastly, you can always ask for help at our Discourse Forum, or more specifically, at this thread or at #nixos' IRC channel.

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Sep 7, 2020
@SuperSandro2000
Copy link
Member

@ofborg eval

@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Dec 29, 2020
@doronbehar
Copy link
Contributor

@GrahamcOfBorg eval

pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
Comment on lines +82 to +77
substituteInPlace src/nm_cfg_file.c --replace \
' nm_str_format(&qemu_bin, "%s/bin/qemu-system-%s",
NM_STRING(NM_USR_PREFIX), token);' \
' nm_str_format(&qemu_bin, "/run/wrappers/bin/qemu-system-%s", token);'
Copy link
Member

Choose a reason for hiding this comment

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

I would prefer a patch for this to prevent bit rot.

Comment on lines +90 to +85
substituteInPlace src/nm_machine.c --replace \
' nm_str_format(&buf, "%s/bin/qemu-system-%s",
NM_STRING(NM_USR_PREFIX), arch);' \
' nm_str_format(&buf, "/run/wrappers/bin/qemu-system-%s", arch);'
Copy link
Member

Choose a reason for hiding this comment

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

I would prefer a patch for this to prevent bit rot.

platforms = with stdenv.lib.platforms; linux;
};
}

Copy link
Member

Choose a reason for hiding this comment

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

One final new line to much.

pkgs/applications/misc/nemu/default.nix Outdated Show resolved Hide resolved
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
@matthiasbeyer matthiasbeyer changed the title nemu: Init at 2.3.0 nemu: init at 2.6.0 Apr 1, 2021
Just leave me alone with this bikeshedding for gods sake.

Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
, pkg-config
, gettext
, libpthreadstubs
, libudev
Copy link
Contributor

Choose a reason for hiding this comment

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

libudev is an alias to udev, switch to using udev so ofborg eval won't fail:

https://gist.github.com/GrahamcOfBorg/0f0eac15e861b506912834b1000a8133


preConfigure = ''
patchShebangs .
substituteInPlace CMakeLists.txt --replace 'USR_PREFIX "/usr"' "USR_PREFIX \"$(out)\""
Copy link
Contributor

Choose a reason for hiding this comment

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

I see upstream has improved a bit their usage of CMake, but this is still present, it'd be nice to try to contribute upstream a more non-FHS friendly change for their CMakeLists.txt.

@stale
Copy link

stale bot commented Oct 1, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Oct 1, 2021
@doronbehar
Copy link
Contributor

@matthiasbeyer are you still interested in this? Upstream has released version 3.0.0 and it seems that now they support non-FHS file systems with some cmake flags so your expression can look much cleaner.

@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Oct 2, 2021
@matthiasbeyer matthiasbeyer deleted the add-nemu branch October 2, 2021 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants