From mboxrd@z Thu Jan 1 00:00:00 1970 From: Laura Lazzati Subject: Re: [outreach] Help trying to create R package Date: Thu, 18 Oct 2018 14:26:50 -0300 Message-ID: References: <20181016074412.54757b18@alma-ubu> <20181016082350.75757e6b@alma-ubu> <20181017001851.71543cc9@alma-ubu> <20181017091750.1c408b8d@alma-ubu> <20181018085424.541e9287@alma-ubu> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45286) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gDC5D-0002EF-9P for guix-devel@gnu.org; Thu, 18 Oct 2018 13:27:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gDC5A-0000jQ-Ct for guix-devel@gnu.org; Thu, 18 Oct 2018 13:27:39 -0400 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]:40846) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gDC55-0000dk-E0 for guix-devel@gnu.org; Thu, 18 Oct 2018 13:27:34 -0400 Received: by mail-pf1-x436.google.com with SMTP id g21-v6so8194811pfi.7 for ; Thu, 18 Oct 2018 10:27:28 -0700 (PDT) In-Reply-To: List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: =?UTF-8?Q?G=C3=A1bor_Boskovits?= Cc: Guix-devel , Ricardo Wurmus On Thu, Oct 18, 2018 at 1:18 PM Laura Lazzati wrote: > > On Thu, Oct 18, 2018 at 12:40 PM G=C3=A1bor Boskovits wrote: > > > > Laura Lazzati ezt =C3=ADrta (id=C5=91pont:= 2018. > > okt. 18., Cs, 17:26): > > > > > > On Thu, Oct 18, 2018 at 12:15 PM G=C3=A1bor Boskovits wrote: > > > > > > > > Hi Laura, > > > > > > > > Laura Lazzati ezt =C3=ADrta (id=C5=91p= ont: 2018. > > > > okt. 18., Cs, 16:49): > > > > > > > > > > On Thu, Oct 18, 2018 at 4:50 AM G=C3=A1bor Boskovits wrote: > > > > > > > > > > > > Wow, Bj=C3=B6rn, you were so fast again :) > > > > > > > > > > > > I just got around this right now. > > > > > Again, thank both for being so kind :) > > > > > > > > > > > > Bj=C3=B6rn H=C3=B6fling ezt= =C3=ADrta (id=C5=91pont: > > > > > > 2018. okt. 18., Cs, 8:54): > > > > > > > > > > > > > > Hi Laura, > > > > > > > > > > > > > > On Wed, 17 Oct 2018 22:36:02 -0300 > > > > > > > Laura Lazzati wrote: > > > > > > > > > > > > > > > > > > > > > > > https://www.gnu.org/software/guix/manual/en/html_node/Con= tributing.html#Contributing > > > > > > > > I have already read this chapter, but I am messed up. I hav= e already > > > > > > > > cloned from git, but I have some questions: > > > > > > > > 1) Do I need to install everything from the git repo in my = distro? > > > > > > > > > > > > > > I'm not sure if I understand you right. You ask if you "need = to install > > > > > > > everything from the git in my distro?". I don't get that. Let= me tell > > > > > > > what I mean: > > > > > > > > > > > > > > You cloned that one, right? > > > > > > > > > > > > > > git clone https://git.savannah.gnu.org/git/guix.git > > > > > > > > > > > > > > That is the source code of Guix. I.e. when you do a > > > > > > > > > > > > > > guix package -i hello > > > > > > > > > > > > > > then you use the binary "guix" command that you installed in = the > > > > > > > beginning. And the repository you cloned is just the source c= ode, there > > > > > > > is nothing in there that you need to install. > > > > > > > > > > > > > > > > > > > > > Maybe you ment the list of software that is written here: > > > > > > > > > > > > > > https://www.gnu.org/software/guix/manual/en/guix.html#Buildin= g-from-Git > > > > > > > > > > > > > > When building Guix from a checkout, the following packages ar= e required in addition to those mentioned in the installation instructions = (see Requirements). > > > > > > > > > > > > > > GNU Autoconf; > > > > > > > GNU Automake; > > > > > > > GNU Gettext; > > > > > > > GNU Texinfo; > > > > > > > Graphviz; > > > > > > > GNU Help2man (optional). > > > > > > > > > > > > > > So, yeah. In order to compile Guix from source, you need all = these. > > > > > I was indeed trying to do this. > > > > > > > > > > > > > > > > > > > But wait, read the next sentence. You have guix already insta= lled. Guix > > > > > > > provides a VERY nice command, `guix envirionment `. = With that, > > > > > > > Guix prepares an "environment" that can be directly used to b= uild > > > > > > > . > > > > > > > > > > > > > > So, if you enter: > > > > > > > > > > > > > > guix environment guix > > > > > I have just did this :) > > > > Great. > > > > > > > > > > > > > > then Guix will know best what software in which version it ne= eds in > > > > > > > order to build guix (in this case, itself, don't get trapped = by that > > > > > > > self-circularity :-)) > > > > > > > > > > > > > > When you are in, you can just follow the next steps described= : > > > > > > > > > > > > > > ./bootstrap > > > > > This worked fine. > > > > > > > ./configure --localstatedir=3D/var > > > > > > > > > > This did not, I am getting this error: > > > > > > > > > > configure: checking for guile 2.2 > > > > > configure: found guile 2.2 > > > > > checking for guile-2.2... /usr/bin/guile-2.2 > > > > > checking for Guile version >=3D 2.2... 2.2.3 > > > > > checking for guild-2.2... no > > > > > checking for guile-config-2.2... no > > > > > checking for guile-tools-2.2... no > > > > > configure: error: 'guild' binary not found; please check your > > > > > guile-2.x installation. > > > > > > > > > > > > > I don't know what to make of this, but you could try guix environme= nt > > > > guix --ad-hoc guild. > > > > Please see if that helps, if not then I will have a closer look at = this. > > > I restored everything to the snapshot where I ended cloning guix. > > > I get this error when trying to run guix environme guix --ad-hoc guil= d: > > > guix environment: error: guild: unknown package > > > > > > > Oops, my bad, yes. I've checked this more thoroughly, on my system > > guild is provided by guile, which should be provided by guile. Could yo= u run > > a which guild and a which guile inside the guix environment guix? > I went back to the previous snapshot several times. > > I was cloning the guix and throwing guix environment guix without doing = cd guix > After several times, I realized that I had a warning in the output: > > building /gnu/store/ilscbls919b78vn9l7b2jb72jmalbxm8-profile.drv... > warning: collision encountered: > /gnu/store/b5x786d3h552j2zp4ppvlz9dkbiqy2ng-ld-wrapper-0/bin/ld > /gnu/store/srmqh29dpm50j8kj1pbqg2rgh053wgyp-binutils-2.30/bin/ld > warning: choosing > /gnu/store/b5x786d3h552j2zp4ppvlz9dkbiqy2ng-ld-wrapper-0/bin/ld > successfully built /gnu/store/ilscbls919b78vn9l7b2jb72jmalbxm8-profile.dr= v > But I did not paid attention to that, echo $? was OK (0). > And then ran everything as I stated, facing all that issues. > > Now I've cloned the repo again, removing previously the guix directory. > did cd guix > and ran guix environment guix > Did not have that warning anymore, just the usual locale warning that > happens all the time. > ran ./bootstrap > > And in both cases (before restoring my VM state, and now) the result > of the which commands are: > > /gnu/store/2w5kxhmkq4zkamsgx1b40vr3ii1z4dxb-profile/bin/guild > and > /gnu/store/2w5kxhmkq4zkamsgx1b40vr3ii1z4dxb-profile/bin/guile > > I don't know if this is relevant or not, and if I should run the > .configure or not before you seing this. I answer myself: ran $./configure --localstatedir=3D/var And same output. > > > > > > > > > > > > > > Then ran > > > > > $guix package -i guile > > > > > Same error running configure. > > > > > $guix package -s guild > > > > > $guix package -i guildhall > > > > > And my output of guix -I, however, is: > > > > > hello 2.10 out /gnu/store/bihfrh609gkxb9dp7n96wlpigiv3kr= fy-hello-2.10 > > > > > recutils 1.7 out > > > > > /gnu/store/6h02na6yz9smc7c7g62ss03kp4yhqpc1-recutils-1.7 > > > > > glibc-locales 2.27 out > > > > > /gnu/store/s28fmfrq8r0c688x59cj0fcyh2pv87nj-glibc-locales-2.27 > > > > > glibc-utf8-locales 2.27 out > > > > > /gnu/store/mbns811n696fl7g060cx6jqjh75mlj8i-glibc-utf8-locales-2.= 27 > > > > > nss-certs 3.36.1 out > > > > > /gnu/store/h8qlwgwhg6jr0kp5ihy90cgb6h0q1fj9-nss-certs-3.36.1 > > > > > r-ade4 1.7-11 out > > > > > /gnu/store/980xl9a58nd6f22wzwsmv9mkhv7pq3hh-r-ade4-1.7-11 > > > > > guile 2.2.4 out /gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4= w9d-guile-2.2.4 > > > > > guildhall 0-1.2fe2cc539 out > > > > > /gnu/store/kd2mvhr18yphrkiqgavw0w0r0n5bfchn-guildhall-0-1.2fe2cc5= 39 > > > > > > > > > > Something weird is that in configure output I see there is a /us= r/bin > > > > > mentioned, so I went to that dir, ran > > > > > $ ll | grep guile > > > > > lrwxrwxrwx 1 root root 23 oct 10 22:55 guile -> > > > > > /etc/alternatives/guile* > > > > > lrwxrwxrwx 1 root root 43 jul 17 10:42 guile-2.2 -> > > > > > ../lib/x86_64-linux-gnu/guile-2.2/bin/guile* > > > > > > > > > > And can't figure out why I have that links. > > > > > > > > > > > > make > > > > > > > > > > > > > > When that went all through well, you can install the "hello" > > > > > > > application: > > > > > > > > > > > > > > ./pre-inst-env guix package -i hello > > > > > > > > > > > > > > The "./pre-inst-env" tells that you want to use the guix comm= and that > > > > > > > you just built, not the one that is somewhere else on your pa= th. > > > > > > > > > > > > > > Now you just go on: > > > > > > > > > > > > > > > 2) How do I convert my template into a package? I can't fig= ure out > > > > > > > > that part. > > > > > > > > > > > > > > You don't have to CONVERT. That template IS a package: > > > > > > > > > > > > > > > > (define-public r-aspi > > > > > > > > > (package > > > > > > > > > (name "r-aspi") > > > > > > > > > > > > > > What you do is you just open the file gnu/packages/r.scm and = add your > > > > > > > "(define... " at the end. > > > > > > > > > > > > > > Ehh, wait, there is no file r.scm. It is either cran.scm or > > > > > > > bioinformatics.scm. > > > > > > > > > > > > > > Then you are done. Try to build it: > > > > > > > > > > > > > > ./pre-inst-env guix build r-aspi > > > > > > > > > > > > > > Bj=C3=B6rn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Thank you! > > > > > > g_bor > > > > > > > > > > Regards :) > > > > > Laura > > > > Best regards, > > > > g_bor > Regards! > Laur