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

geteltorito: init at 0.6 #18614

Merged
merged 1 commit into from
Oct 4, 2016
Merged

geteltorito: init at 0.6 #18614

merged 1 commit into from
Oct 4, 2016

Conversation

Profpatsch
Copy link
Member

@Profpatsch Profpatsch commented Sep 15, 2016

  • Built on platform(s)
    • NixOS
  • Tested execution of all binary files (usually in ./result/bin/)

@Profpatsch
Copy link
Member Author

Update: Doesn’t depend on fetchdir anymore, uses a github mirror repo instead.

@RamKromberg
Copy link
Contributor

RamKromberg commented Sep 15, 2016

it's your own git... Just commit the .roff \ man page instead of depending on ronn :/

(EDIT) Here, just use this mdoc:

.Dd 2015-02-25
.Dt GETELTORITO 1
.Os Unix
.Sh NAME
.Nm geteltorito
.Nd an El Torito boot image extractor
.Sh SYNOPSIS
.Nm
.Op Fl hv
.Op Fl o Ar outputfilename
.Ar cd-image
.Nm
.Ar cd-image
>
.Ar outputfilename
.Sh DESCRIPTION
.Nm
will try to extract the initial (default) El Torito image from a bootable CD (or cd-image) given by
.Ar cd-image
and write the data extracted to STDOUT or to
.Ar outputfilename \.
All other information is written to STDERR (e.g. type and size of image).
.Pp
.Nm
will not extract any of other possibly existing bootimages that are allowed by the El Torito standard.
.Pp
.Bl -tag -width "outputfilename" -compact
.It cd-image
bootable CD or cd-image
.It outputfilename
optional output file name
.El
.Bl -tag -width -indent
.It Fl h
Build-in help.
.It Fl v
Print version of script and exit.
.It Fl o
Write extracted data to
.Pa outputfilename
instead of
.Pa STDOUT \.
.El
.Sh ABOUT
.Bl -tag -width "Version:"
.It Author:
Rainer Krienke
.It Email:
krienke@uni-koblenz.de
.It License:
GPL v2
.It Version:
0.6
.El
.Sh FILES
.Bl -tag -width "/usr/share/man/man1/geteltorito.1" -compact
.It Pa /usr/share/bin/geteltorito
The
.Nm
perl script.
.It Pa /usr/share/man/man1/geteltorito.1
This help file.
.El
.Sh SEE ALSO
.Xr perl 1

It lints fine and you can examine the output with man ./geteltorito.roff. You can use groff -mdoc to compile it to whatever.

Good luck!


stdenv.mkDerivation rec {
name = "geteltorito-${version}";
version = "0.5";
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Wow, the readme still said 0.5. Very inconsistent.

@Profpatsch
Copy link
Member Author

Profpatsch commented Sep 15, 2016

it's your own git... Just commit the .roff \ man page instead of depending on ronn :/

It’s nice, but I’m not particularly fond of adding my own stuff to the repo. This means I’d have to manually adapt it each time upstream updates. Computers are better at doing this than I am.

@Profpatsch Profpatsch changed the title geteltorito: init at 0.5 geteltorito: init at 0.6 Sep 15, 2016
@RamKromberg
Copy link
Contributor

RamKromberg commented Sep 15, 2016

Your call.

For reference:

{ stdenv, perl, fetchFromGitHub }:

stdenv.mkDerivation rec {
  name = "geteltorito-${version}";
  version = "0.6";

  src = fetchFromGitHub {
    owner = "Profpatsch";
    repo = "geteltorito";
    rev = version;
    sha256 = "05bcn3pam29xmsz1ykyqsdbkz8y23kcrvvhm987f65wd1g741f75";
  };

  nativeBuildInputs = [ perl ];
  dontBuild = true;
  geteltorito_mdoc = ''
    .Dd 2015-02-25
    .Dt GETELTORITO 1
    .Os Unix
    .Sh NAME
    .Nm geteltorito
    .Nd an El Torito boot image extractor
    .Sh SYNOPSIS
    .Nm
    .Op Fl hv
    .Op Fl o Ar outputfilename
    .Ar cd-image
    .Nm
    .Ar cd-image
    >
    .Ar outputfilename
    .Sh DESCRIPTION
    .Nm
    will try to extract the initial (default) El Torito image from a bootable CD (or cd-image) given by
    .Ar cd-image
    and write the data extracted to STDOUT or to
    .Ar outputfilename \.
    All other information is written to STDERR (e.g. type and size of image).
    .Pp
    .Nm
    will not extract any of other possibly existing bootimages that are allowed by the El Torito standard.
    .Pp
    .Bl -tag -width "outputfilename" -compact
    .It cd-image
    bootable CD or cd-image
    .It outputfilename
    optional output file name
    .El
    .Bl -tag -width -indent
    .It Fl h
    Build-in help.
    .It Fl v
    Print version of script and exit.
    .It Fl o
    Write extracted data to
    .Pa outputfilename
    instead of
    .Pa STDOUT \.
    .El
    .Sh ABOUT
    .Bl -tag -width "Version:"
    .It Author:
    Rainer Krienke
    .It Email:
    krienke@uni-koblenz.de
    .It License:
    GPL v2
    .It Version:
    0.6
    .El
    .Sh FILES
    .Bl -tag -width "/usr/share/man/man1/geteltorito.1" -compact
    .It Pa /usr/share/bin/geteltorito
    The
    .Nm
    perl script.
    .It Pa /usr/share/man/man1/geteltorito.1
    This help file.
    .El
    .Sh SEE ALSO
    .Xr perl 1

  '';

  installPhase = ''
    mkdir -p $out/man/man1
    echo "${geteltorito_mdoc}" > $out/man/man1/geteltorito.1
    install -vD geteltorito $out/bin/geteltorito
  '';

  meta = with stdenv.lib; {
    description = "Extract the initial/default boot image from a CD image if existent";
    homepage = "https://userpages.uni-koblenz.de/~krienke/ftp/noarch/geteltorito/";
    maintainer = with maintainers; [ profpatsch ];
    license = licenses.gpl2;
    platforms = with platforms; all;
  };

}

Though I'm not sure it will pass the manual checks...

@Profpatsch Profpatsch merged commit c535924 into NixOS:master Oct 4, 2016
bjornfor pushed a commit that referenced this pull request Feb 16, 2017
(cherry picked from commit c535924)
adrianpk added a commit to adrianpk/nixpkgs that referenced this pull request May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants