Re: '--load-path' option not working for 'guix system' command

2018-11-18 Thread Taegil Bae
Dear Oleg,

At that time, spice-vdagent package had a bug. So I modified spice.scm to
fix it. To make it applied to the system, I put that file into
~/my-guix/gnu/packages and ran `guix system reconfigure /etc/config.scm -L
~/my-guix`. But it took long time because there were many packages to be
built without substitutes. So I just did dry-run.

Now, spice-vdagent's bug is fixed. Thus, just for test, I modified the
spice.scm in ~/my-guix/gnu/packages and try reconfiguring the system.
Spice.scm is modified as:

--- spice.scm.orig2018-11-19 04:05:33.543753567 +0900
+++ spice.scm2018-11-19 03:09:09.283971057 +0900
@@ -252,7 +252,7 @@
 (substitute* "data/spice-vdagent.desktop"
   (("Exec=/usr/bin/spice-vdagent")
(string-append "Exec=" (assoc-ref outputs "out")
-  "/bin/spice-vdagent")))
+  "/bin/spice-vdagent\n")))
  #t)
 (inputs
   `(("alsa-lib" ,alsa-lib)

I have dry-run's.
[1] guix system reconfigure /etc/config.scm -n -L ~/my-guix :
with_spice_with_loadpath.log
(12K)


[2] export GUIX_PACKAGE_PATH=~/my-guix; guix system reconfigure
/etc/config.scm -n :
with_spice_with_guix_package_path.log
(15K)


I think the two should give the same output. But as you see, those are
different. First, [1] does not have commented lines:
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/gnu/store/k7lvym1xl87p156jd459k36ddbb1msvm-guix-a7b7d48cc-modules/gnu/packages/spice.go
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/run/current-system/profile/lib/guile/2.2/site-ccache/gnu/packages/spice.go

And derivations to be built and packages to be downloaded are different.
But the same test for 'guix build' is positive.
build_with_spice_with_loadpath.log
(2K)

build_with_spice_with_guix_package_path.log
(2K)


Finally, I have real build run's.
[3] guix system reconfigure /etc/conf.scm -L ~/my-guix :
real_with_spice_with_loadpath.log
(10K)


[4] export GUIX_PACKAGE_PATH=~/my-guix; guix system reconfigure
/etc/config.scm
real_with_spice_with_guix_package_path.log
(12K)


Run [3] does not build spice-vdagent, but just grub.cfg. Run [4] does what
I want. Only [4] makes change in
/run/current-system/profile/etc/xdg/autostart/spice-vdagent.desktop .


Regards,

Taegil

substitute: 
substitute: updating substitutes from 'https://mirror.hydra.gnu.org'...   0.0%
substitute: updating substitutes from 'https://mirror.hydra.gnu.org'...  33.3%
substitute: updating substitutes from 'https://mirror.hydra.gnu.org'...  66.7%
substitute: updating substitutes from 'https://mirror.hydra.gnu.org'... 100.0%
The following derivations would be built:
   /gnu/store/g5rjmaz09hfx1rq61sf91xnzrx8f571y-system.drv
   /gnu/store/q4cdlqvinr16nwhvy8abnbj2fwgjv5wa-grub.cfg.drv
   /gnu/store/xmc42wbcv3vc1hznp2hca18ahs960xm5-fonts-dir.drv
   /gnu/store/q4p74p9znadsqhl26akhj77ardkhyhvq-gtk-im-modules.drv
   /gnu/store/ij2shvq53jvj6mj9h39i2pmf5yj2qgl7-xdg-desktop-database.drv
   /gnu/store/hmka84xfqllch0v9r3g61rsd0cn83mg9-gtk-icon-themes.drv
   /gnu/store/bx2ara3jcy896y23v83w5mwhkbkkbi79-xdg-mime-database.drv
   /gnu/store/a76aqr3275sc92b6z0si2v9q8v3cdhqn-info-dir.drv
   /gnu/store/7fihyq1j648xlhj06xzv609fbm611dsb-ca-certificate-bundle.drv
   /gnu/store/3drwac89rl5m8pkwqbz98ipp9znb8777-glib-schemas.drv
   /gnu/store/rva7x9v0vcdizznay2vhjabbkv9p6sl9-manual-database.drv
   /gnu/store/wy671ksif5jwg0zmafa8ag2g853vicni-profile.drv
   /gnu/store/r2hnqc5hgcpzkdiqjvmc98fwq8c15jci-geoclue-program-wrapper.drv
   /gnu/store/7lxjrywfk1qp1gd2shv93dha8sn2baiy-dbus-system-services.drv
   /gnu/store/qdl298zg6j29idi9yjrscc0fk8b9x7di-geoclue-wrapper.drv
   /gnu/store/948pxsrj8vqqnxz4apmfisms8bm2b0yb-asound.conf.drv
   /gnu/store/brma56cm1i2hxay3qrrnqx5sj9qkm5sq-dbus-configuration.drv
   /gnu/store/zgkn7ppbi5rhszif4mcqay08fhwmqnkq-etc-polkit-1.drv
   /gnu/store/wjvqpdlfp6n1q44svylnh3i1c9ccpzar-shepherd-dbus-system.scm.drv
   /gnu/store/mg2c7fv9f2pbljil4skfqvg1wzzcdk24-shepherd-wpa-supplicant.scm.drv
   /gnu/store/hgcdc5yfpvjk9jjmaahfxb

Re: '--load-path' option not working for 'guix system' command

2018-11-14 Thread Taegil Bae

Dear Oleg,

On 11/14/18 6:20 PM, Oleg Pykhalov wrote:

Could you place a (pk '%load-path %load-path) sexp before the
(operating-system ...) to see what does Guile load?


Here is the output:

# guix system reconfigure /etc/config.scm -L $HOME/my-guix -n

;;; (%load-path ("/root/my-guix" 
"/gnu/store/xykmv219fysc8rkb0bwqkkw64a37sm58-guix-e740a9022-modules" 
"/gnu/store/qbzw2ygy1nq2h0nq6sl9cgg1c5mq5g8z-guile-gcrypt-0.1.0/share/guile/site/2.2" 
"/gnu/store/c63g5242rs04ipx1zrkma9zxvs8782sj-gnutls-3.5.18/share/guile/site/2.2" 
"/gnu/store/n45hylmwfy6gdkxxdx8qpq55sh8rgml8-guile-git-0.1.0/share/guile/site/2.2" 
"/gnu/store/1aglyrvw57cbw4njc2q4blmbqin3r7k2-guile-bytestructures-1.0.3/share/guile/site/2.2" 
"/gnu/store/sw3wxk3ylxd1kc2z4z4kb5191x9pf17n-guile-json-1.2.0/share/guile/site/2.2" 
"/gnu/store/vni6jwl3hxn97i9sk2a9fdd4b7fhjvlb-guile-ssh-0.11.3/share/guile/site/2.2" 
"/gnu/store/rjp81r0sgvix8cplfgqyhyhmyxxk35a6-guile-sqlite3-0.1.0/share/guile/site/2.2" 
"/gnu/store/9970qxhisnrr8cq4rq25zrc4698b037b-module-import" 
"/gnu/store/9970qxhisnrr8cq4rq25zrc4698b037b-module-import" 
"/run/current-system/profile/share/guile/site/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/site/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/site" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile"))

The following derivations would be built:
   /gnu/store/14cww1f93h0zh6rylr18wsb8l16j7ipn-system.drv
/gnu/store/qk1ninhablh8ax7633gppwj447czc04r-grub.cfg.drv
/gnu/store/jk0c7vly17k8azbpzbcpd1lrhpmk7hig-bootloader-installer.drv
/gnu/store/bp735l7fzyv86rwps1ajdap2k9gvyvr1-module-import-compiled.drv
/gnu/store/s04i207w7k22sgl9qfss551cp3d5cgvf-gtk-icon-themes.drv
   .

# export GUIX_PACKAGE_PATH=~/my-guix
# guix system reconfigure /etc/config.scm -n
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled 
/gnu/store/6gjbbs9d68626j05h1ff3yya3nlizsc0-guix-e740a9022-modules/gnu/packages/spice.go

;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled 
/run/current-system/profile/lib/guile/2.2/site-ccache/gnu/packages/spice.go


;;; (%load-path ("/root/my-guix" 
"/gnu/store/xykmv219fysc8rkb0bwqkkw64a37sm58-guix-e740a9022-modules" 
"/gnu/store/qbzw2ygy1nq2h0nq6sl9cgg1c5mq5g8z-guile-gcrypt-0.1.0/share/guile/site/2.2" 
"/gnu/store/c63g5242rs04ipx1zrkma9zxvs8782sj-gnutls-3.5.18/share/guile/site/2.2" 
"/gnu/store/n45hylmwfy6gdkxxdx8qpq55sh8rgml8-guile-git-0.1.0/share/guile/site/2.2" 
"/gnu/store/1aglyrvw57cbw4njc2q4blmbqin3r7k2-guile-bytestructures-1.0.3/share/guile/site/2.2" 
"/gnu/store/sw3wxk3ylxd1kc2z4z4kb5191x9pf17n-guile-json-1.2.0/share/guile/site/2.2" 
"/gnu/store/vni6jwl3hxn97i9sk2a9fdd4b7fhjvlb-guile-ssh-0.11.3/share/guile/site/2.2" 
"/gnu/store/rjp81r0sgvix8cplfgqyhyhmyxxk35a6-guile-sqlite3-0.1.0/share/guile/site/2.2" 
"/gnu/store/9970qxhisnrr8cq4rq25zrc4698b037b-module-import" 
"/gnu/store/9970qxhisnrr8cq4rq25zrc4698b037b-module-import" 
"/run/current-system/profile/share/guile/site/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/site/2.2" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile/site" 
"/gnu/store/p9wm67w3rfw3hlb9iljgvsfn84mz4w9d-guile-2.2.4/share/guile"))

The following derivations would be built:
   /gnu/store/14cww1f93h0zh6rylr18wsb8l16j7ipn-system.drv
   /gnu/store/qk1ninhablh8ax7633gppwj447czc04r-grub.cfg.drv
/gnu/store/jk0c7vly17k8azbpzbcpd1lrhpmk7hig-bootloader-installer.drv

However, I think that load-path of 'guix system' have nothing to do with 
config.scm. If I run 'guix system --help' with GUIX_PACKAGE_PATH 
defined, I have the output below:


# guix system --help
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled 
/gnu/store/6gjbbs9d68626j05h1ff3yya3nlizsc0-guix-e740a9022-modules/gnu/packages/spice.go

;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled 
/run/current-system/profile/lib/guile/2.2/site-ccache/gnu/packages/spice.go

Usage: guix system [OPTION ...] ACTION [ARG ...] [FILE]
Build the operating system declared in FILE according to ACTION.
Some ACTIONS support additional ARGS.

The valid values for ACTION are:
  


Thanks,

Taegil




Re: '--load-path' option not working for 'guix system' command

2018-11-12 Thread Taegil Bae
Dear Pierre,

Thank you for the reply.
I didn't know that '~' does not expands to $HOME in the case. But
actually I have used '-L ./my-guix'.
This option is not working with 'guix system', but is working with
'guix build' and 'guix package'.

root@antelope ~# guix build spice-vdagent --load-path=~/my-guix
/gnu/store/5wk50f4zhhmg0s599z3d6v5zraxp72jp-spice-vdagent-0.17.0
root@antelope ~# guix build spice-vdagent --load-path=./my-guix
;;; note: source file ./my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/gnu/store/6gjbbs9d68626j05h1ff3yya3nlizsc0-guix-e740a9022-modules/gnu/packages/spice.go
;;; note: source file ./my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/run/current-system/profile/lib/guile/2.2/site-ccache/gnu/packages/spice.go
/gnu/store/d5l0idaszbb5dbxm072gmaknrhrh4bc9-spice-vdagent-fixed-0.17.0
root@antelope ~# guix system reconfigure /etc/config.scm -L ./my-guix/ -n
The following derivations would be built:
   /gnu/store/14cww1f93h0zh6rylr18wsb8l16j7ipn-system.drv
 .
root@antelope ~# guix system reconfigure /etc/config.scm -L ~/my-guix/ -n
The following derivations would be built:
   /gnu/store/14cww1f93h0zh6rylr18wsb8l16j7ipn-system.drv
..
root@antelope ~# export GUIX_PACKAGE_PATH=~/my-guix
root@antelope ~# guix system reconfigure /etc/config.scm -n
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/gnu/store/6gjbbs9d68626j05h1ff3yya3nlizsc0-guix-e740a9022-modules/gnu/packages/spice.go
;;; note: source file /root/my-guix/gnu/packages/spice.scm
;;;   newer than compiled
/run/current-system/profile/lib/guile/2.2/site-ccache/gnu/packages/spice.go
The following derivations would be built:
   /gnu/store/14cww1f93h0zh6rylr18wsb8l16j7ipn-system.drv
   

Regards,

Taegil
2018년 11월 13일 (화) 오후 4:25, Pierre Neidhardt 님이 작성:
>
>
> > 'guix system reconfigure /etc/config.scm --load-path=~/my-guix'
>
> This because the shell only expands '~' to $HOME if it's a starting character.
> Here you should either use
>
> guix system reconfigure /etc/config.scm --load-path=$HOME/my-guix
>
> or
>
> guix system reconfigure /etc/config.scm -L ~/my-guix
>
> --
> Pierre Neidhardt
> https://ambrevar.xyz/



'--load-path' option not working for 'guix system' command

2018-11-12 Thread Taegil Bae
Hi,

I have modified a package and tried 'guix system reconfigure
/etc/config.scm --load-path=~/my-guix'. But it did not load the path.
If I do 'export GUIX_PACKAGE_PATH=~/my-guix', 'guix system reconfigure
/etc/config.scm' loads that path. Is this guix's bug?

Regards,

Taegil