compile util-linux from github

News and discussion about development of the Debian OS itself

compile util-linux from github

Postby tuxxie » 2018-04-27 19:13

Here running debian testing. How can I compile util-linux from github and make it work?

https://github.com/karelzak/util-linux/
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby debiman » 2018-04-27 20:01

a) clone the repo to your machine
b) run ./autogen.sh
c) run make
with a little luck it will Just Work (tm).
i would not install it, since it might conflict with likely already installed util-linux.
User avatar
debiman
 
Posts: 2927
Joined: 2013-03-12 07:18

Re: compile util-linux from github

Postby stevepusser » 2018-04-27 20:47

Why exactly do you need the version from git?

If you really need some bug fix that's only available there, my first inclination would be to try to cherry-pick the fix, patch, and rebuild the version you have in Buster. My thoughts are that you can really mess up your system by trying the manual build and install, since it's an essential "required" package, and you cannot remove the Debian version from your system.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Kdenlive 18.08.1, Pale Moon 28.1.0, wine-staging 3.17, qBittorrent 4.1.3, Liquorix kernel 4.18-13, Audacity 2.3.0
User avatar
stevepusser
 
Posts: 10013
Joined: 2009-10-06 05:53

Re: compile util-linux from github

Postby tuxxie » 2018-04-27 22:06

stevepusser wrote:Why exactly do you need the version from git?

If you really need some bug fix that's only available there, my first inclination would be to try to cherry-pick the fix, patch, and rebuild the version you have in Buster. My thoughts are that you can really mess up your system by trying the manual build and install, since it's an essential "required" package, and you cannot remove the Debian version from your system.

How can I exactly get, compile and install the Buster version, provided that I know what exact lines have to be patched?
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby debiman » 2018-04-28 08:19

please tell us why you think you need to do this.
"i just want to" is a valid answer, but if you think you need this to fix some problem, your approach is likely wrong.
http://xyproblem.info/
User avatar
debiman
 
Posts: 2927
Joined: 2013-03-12 07:18

Re: compile util-linux from github

Postby tuxxie » 2018-04-28 09:27

debiman wrote:please tell us why you think you need to do this.
"i just want to" is a valid answer, but if you think you need this to fix some problem, your approach is likely wrong.
http://xyproblem.info/

i want to test latest commits, which are not yet available with apt install. I've tried installing gentoo but it's a total nightmare with the emerge system and dependencies and masked packages and whatnot.

Tried also compiling directly from github with ./autogen.sh && ./configure && make, but messes the system, had to revert to previous snapshot. I'm used to work on user small programs with git checkout && make install && ldconfig but util-linux is too way embedded on the system.
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby debiman » 2018-04-28 13:40

tuxxie wrote:i want to test latest commits, which are not yet available with apt install.
ok.
then see my previous answer.
Tried also compiling directly from github with ./autogen.sh && ./configure && make, but messes the system, had to revert to previous snapshot.
i don't see how this would mess up your system.
all these commands do not require superuser privileges, don't change your system, and do not install anything (as i wrote you shouldn't).
util-linux is too way embedded on the system.

i'll say it a third time, if you don't install it, you can use most utilities straight from the git directory, after compiling.
User avatar
debiman
 
Posts: 2927
Joined: 2013-03-12 07:18

Re: compile util-linux from github

Postby stevepusser » 2018-04-28 16:30

Basically rebuilding the present package is the same as backporting, except you're just using the deb-src URL for testing.

https://wiki.debian.org/SimpleBackportCreation

After you have run "apt-get source", you want to go in and change the source files as you wish. Then you back out to the root of the source, and have dpkg-source convert your changes into a patch in debian/patches:

Code: Select all
dpkg-source --commit


After you name your patch, it will open it up in nano for editing, but you can just "Ctrl X" to exit nano without any edits at this point. Make sure to edit your new stanza in debian/changelog and remove the "~", which make it lower than the Debian version, and make yours higher.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Kdenlive 18.08.1, Pale Moon 28.1.0, wine-staging 3.17, qBittorrent 4.1.3, Liquorix kernel 4.18-13, Audacity 2.3.0
User avatar
stevepusser
 
Posts: 10013
Joined: 2009-10-06 05:53

Re: compile util-linux from github

Postby tuxxie » 2018-04-28 18:26

debiman wrote:
util-linux is too way embedded on the system.
i'll say it a third time, if you don't install it, you can use most utilities straight from the git directory, after compiling.

Ok you got me there, didn't know that was possible. I would like to run lsblk, blkid, fdisk and so on. Hope I can run them from my home user folder (with sudo if necessary). If that works I just don't need to make a custom deb.
Last edited by tuxxie on 2018-04-28 20:30, edited 1 time in total.
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby debiman » 2018-04-28 18:47

tuxxie wrote:I would like to run lsblk, blkid, fdisk and so on. Hope I can run them from my home user folder (with sudo if necessary). If that works I just didn't need to make a custom deb.

why the "need" of these particular utilities?
previously you said "want", which sounds like some sort of just-for-fun project.
i still suspect an x-y-problem.
User avatar
debiman
 
Posts: 2927
Joined: 2013-03-12 07:18

Re: compile util-linux from github

Postby tuxxie » 2018-04-28 20:31

Ok what I need works for now, all utilities are just inside the util-linux/ folder just after compiling. Now I can test the commands properly with sudo ./command
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby tuxxie » 2018-04-28 22:32

bypassing the debuild nightmare:
dpkg-buildpackage -b
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby tuxxie » 2018-04-29 09:36

This guide is great:
Ubuntu Packaging Guide »
tuxxie
 
Posts: 21
Joined: 2016-01-03 14:04

Re: compile util-linux from github

Postby debiman » 2018-04-29 16:34

tuxxie wrote:This guide is great:
Ubuntu Packaging Guide »

please don't spread unsuitable recommendations.
this is the debian forum, and debian is not compatible with ubuntu: https://wiki.debian.org/DontBreakDebian

imo, x-y-problems are a waste of everyone's time, but it seems you are set to not tell us what problem you are actually trying to solve.
whatever. :shrugs:
User avatar
debiman
 
Posts: 2927
Joined: 2013-03-12 07:18

Re: compile util-linux from github

Postby stevepusser » 2018-04-29 22:11

The commands are essentially the same in Ubuntu and Debian, though.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Kdenlive 18.08.1, Pale Moon 28.1.0, wine-staging 3.17, qBittorrent 4.1.3, Liquorix kernel 4.18-13, Audacity 2.3.0
User avatar
stevepusser
 
Posts: 10013
Joined: 2009-10-06 05:53

Next

Return to Debian Development

Who is online

Users browsing this forum: No registered users and 1 guest

fashionable