gnu: Add r-abd.
[jackhill/guix/guix.git] / tests / profiles.scm
CommitLineData
a2078770 1;;; GNU Guix --- Functional package management for GNU
435603a1 2;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
343745c8 3;;; Copyright © 2014 Alex Kost <alezost@gmail.com>
a2078770
LC
4;;;
5;;; This file is part of GNU Guix.
6;;;
7;;; GNU Guix is free software; you can redistribute it and/or modify it
8;;; under the terms of the GNU General Public License as published by
9;;; the Free Software Foundation; either version 3 of the License, or (at
10;;; your option) any later version.
11;;;
12;;; GNU Guix is distributed in the hope that it will be useful, but
13;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15;;; GNU General Public License for more details.
16;;;
17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20(define-module (test-profiles)
c1bc358f 21 #:use-module (guix tests)
a2078770 22 #:use-module (guix profiles)
462f5cca
LC
23 #:use-module (guix store)
24 #:use-module (guix monads)
ef8de985 25 #:use-module (guix grafts)
462f5cca
LC
26 #:use-module (guix packages)
27 #:use-module (guix derivations)
a0dac7a0 28 #:use-module (guix build-system trivial)
462f5cca 29 #:use-module (gnu packages bootstrap)
e39d1461 30 #:use-module ((gnu packages base) #:prefix packages:)
dedb17ad 31 #:use-module ((gnu packages guile) #:prefix packages:)
a2078770 32 #:use-module (ice-9 match)
ef8993e2 33 #:use-module (ice-9 regex)
d664f1b4
LC
34 #:use-module (ice-9 popen)
35 #:use-module (rnrs io ports)
ccda8f7d 36 #:use-module (srfi srfi-1)
79601521 37 #:use-module (srfi srfi-11)
a654dc4b 38 #:use-module (srfi srfi-34)
a2078770
LC
39 #:use-module (srfi srfi-64))
40
343745c8 41;; Test the (guix profiles) module.
a2078770 42
462f5cca 43(define %store
c1bc358f 44 (open-connection-for-tests))
a2078770 45
ef8de985
LC
46;; Globally disable grafts because they can trigger early builds.
47(%graft? #f)
48
ebf5ad46
LC
49(define-syntax-rule (test-assertm name exp)
50 (test-assert name
51 (run-with-store %store exp
52 #:guile-for-build (%guile-for-build))))
53
22ef06b8
LC
54(define-syntax-rule (test-equalm name value exp)
55 (test-equal name
56 value
57 (run-with-store %store exp
58 #:guile-for-build (%guile-for-build))))
59
a2078770
LC
60;; Example manifest entries.
61
f7554030
AK
62(define guile-1.8.8
63 (manifest-entry
64 (name "guile")
65 (version "1.8.8")
66 (item "/gnu/store/...")
67 (output "out")))
68
a2078770
LC
69(define guile-2.0.9
70 (manifest-entry
71 (name "guile")
72 (version "2.0.9")
a54c94a4 73 (item "/gnu/store/...")
a2078770
LC
74 (output "out")))
75
76(define guile-2.0.9:debug
77 (manifest-entry (inherit guile-2.0.9)
78 (output "debug")))
79
79601521
LC
80(define glibc
81 (manifest-entry
82 (name "glibc")
83 (version "2.19")
84 (item "/gnu/store/...")
85 (output "out")))
86
a2078770
LC
87\f
88(test-begin "profiles")
89
90(test-assert "manifest-installed?"
91 (let ((m (manifest (list guile-2.0.9 guile-2.0.9:debug))))
92 (and (manifest-installed? m (manifest-pattern (name "guile")))
93 (manifest-installed? m (manifest-pattern
94 (name "guile") (output "debug")))
95 (manifest-installed? m (manifest-pattern
96 (name "guile") (output "out")
97 (version "2.0.9")))
98 (not (manifest-installed?
99 m (manifest-pattern (name "guile") (version "1.8.8"))))
100 (not (manifest-installed?
101 m (manifest-pattern (name "guile") (output "foobar")))))))
102
103(test-assert "manifest-matching-entries"
104 (let* ((e (list guile-2.0.9 guile-2.0.9:debug))
105 (m (manifest e)))
106 (and (null? (manifest-matching-entries m
107 (list (manifest-pattern
108 (name "python")))))
109 (equal? e
110 (manifest-matching-entries m
111 (list (manifest-pattern
112 (name "guile")
113 (output #f)))))
114 (equal? (list guile-2.0.9)
115 (manifest-matching-entries m
116 (list (manifest-pattern
117 (name "guile")
118 (version "2.0.9"))))))))
119
120(test-assert "manifest-remove"
121 (let* ((m0 (manifest (list guile-2.0.9 guile-2.0.9:debug)))
122 (m1 (manifest-remove m0
123 (list (manifest-pattern (name "guile")))))
124 (m2 (manifest-remove m1
125 (list (manifest-pattern (name "guile"))))) ; same
126 (m3 (manifest-remove m2
127 (list (manifest-pattern
128 (name "guile") (output "debug")))))
129 (m4 (manifest-remove m3
130 (list (manifest-pattern (name "guile"))))))
131 (match (manifest-entries m2)
132 ((($ <manifest-entry> "guile" "2.0.9" "debug"))
133 (and (equal? m1 m2)
134 (null? (manifest-entries m3))
135 (null? (manifest-entries m4)))))))
136
f7554030
AK
137(test-assert "manifest-add"
138 (let* ((m0 (manifest '()))
139 (m1 (manifest-add m0 (list guile-1.8.8)))
140 (m2 (manifest-add m1 (list guile-2.0.9)))
141 (m3 (manifest-add m2 (list guile-2.0.9:debug)))
142 (m4 (manifest-add m3 (list guile-2.0.9:debug))))
143 (and (match (manifest-entries m1)
144 ((($ <manifest-entry> "guile" "1.8.8" "out")) #t)
145 (_ #f))
146 (match (manifest-entries m2)
147 ((($ <manifest-entry> "guile" "2.0.9" "out")) #t)
148 (_ #f))
149 (equal? m3 m4))))
150
435603a1
LC
151(test-equal "manifest-add removes duplicates" ;<https://bugs.gnu.org/30569>
152 (list guile-2.0.9)
153 (manifest-entries (manifest-add (manifest '())
154 (list guile-2.0.9 guile-2.0.9))))
155
343745c8
AK
156(test-assert "manifest-perform-transaction"
157 (let* ((m0 (manifest (list guile-2.0.9 guile-2.0.9:debug)))
158 (t1 (manifest-transaction
159 (install (list guile-1.8.8))
160 (remove (list (manifest-pattern (name "guile")
161 (output "debug"))))))
162 (t2 (manifest-transaction
163 (remove (list (manifest-pattern (name "guile")
164 (version "2.0.9")
165 (output #f))))))
166 (m1 (manifest-perform-transaction m0 t1))
167 (m2 (manifest-perform-transaction m1 t2))
168 (m3 (manifest-perform-transaction m0 t2)))
169 (and (match (manifest-entries m1)
170 ((($ <manifest-entry> "guile" "1.8.8" "out")) #t)
171 (_ #f))
172 (equal? m1 m2)
173 (null? (manifest-entries m3)))))
174
79601521
LC
175(test-assert "manifest-transaction-effects"
176 (let* ((m0 (manifest (list guile-1.8.8)))
177 (t (manifest-transaction
178 (install (list guile-2.0.9 glibc))
179 (remove (list (manifest-pattern (name "coreutils")))))))
46b23e1a 180 (let-values (((remove install upgrade downgrade)
79601521 181 (manifest-transaction-effects m0 t)))
46b23e1a 182 (and (null? remove) (null? downgrade)
79601521 183 (equal? (list glibc) install)
ef8993e2
LC
184 (equal? (list (cons guile-1.8.8 guile-2.0.9)) upgrade)))))
185
46b23e1a
LC
186(test-assert "manifest-transaction-effects and downgrades"
187 (let* ((m0 (manifest (list guile-2.0.9)))
188 (t (manifest-transaction (install (list guile-1.8.8)))))
189 (let-values (((remove install upgrade downgrade)
190 (manifest-transaction-effects m0 t)))
191 (and (null? remove) (null? install) (null? upgrade)
192 (equal? (list (cons guile-2.0.9 guile-1.8.8)) downgrade)))))
193
3bea13bb
LC
194(test-assert "manifest-transaction-effects and pseudo-upgrades"
195 (let* ((m0 (manifest (list guile-2.0.9)))
196 (t (manifest-transaction (install (list guile-2.0.9)))))
197 (let-values (((remove install upgrade downgrade)
198 (manifest-transaction-effects m0 t)))
199 (and (null? remove) (null? install) (null? downgrade)
200 (equal? (list (cons guile-2.0.9 guile-2.0.9)) upgrade)))))
201
c8c25704
LC
202(test-assert "manifest-transaction-null?"
203 (manifest-transaction-null? (manifest-transaction)))
204
6d382339
LC
205(test-assert "manifest-transaction-removal-candidate?"
206 (let ((m (manifest (list guile-2.0.9)))
207 (t (manifest-transaction
208 (remove (list (manifest-pattern (name "guile")))))))
209 (and (manifest-transaction-removal-candidate? guile-2.0.9 t)
210 (not (manifest-transaction-removal-candidate? glibc t)))))
211
ebf5ad46
LC
212(test-assertm "profile-derivation"
213 (mlet* %store-monad
214 ((entry -> (package->manifest-entry %bootstrap-guile))
215 (guile (package->derivation %bootstrap-guile))
216 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
217 #:hooks '()
218 #:locales? #f))
ebf5ad46
LC
219 (profile -> (derivation->output-path drv))
220 (bindir -> (string-append profile "/bin"))
221 (_ (built-derivations (list drv))))
222 (return (and (file-exists? (string-append bindir "/guile"))
223 (string=? (dirname (readlink bindir))
224 (derivation->output-path guile))))))
462f5cca 225
e00ade3f
LC
226(test-assertm "profile-derivation relative symlinks, one entry"
227 (mlet* %store-monad
228 ((entry -> (package->manifest-entry %bootstrap-guile))
229 (guile (package->derivation %bootstrap-guile))
230 (drv (profile-derivation (manifest (list entry))
231 #:relative-symlinks? #t
232 #:hooks '()
233 #:locales? #f))
234 (profile -> (derivation->output-path drv))
235 (bindir -> (string-append profile "/bin"))
236 (_ (built-derivations (list drv))))
237 (return (and (file-exists? (string-append bindir "/guile"))
238 (string=? (readlink bindir)
239 (string-append "../"
240 (basename
241 (derivation->output-path guile))
242 "/bin"))))))
243
244(unless (network-reachable?) (test-skip 1))
245(test-assertm "profile-derivation relative symlinks, two entries"
246 (mlet* %store-monad
247 ((gnu-make-boot0 -> (@@ (gnu packages commencement) gnu-make-boot0))
248 (manifest -> (packages->manifest
249 (list %bootstrap-guile gnu-make-boot0)))
250 (guile (package->derivation %bootstrap-guile))
251 (make (package->derivation gnu-make-boot0))
252 (drv (profile-derivation manifest
253 #:relative-symlinks? #t
254 #:hooks '()
255 #:locales? #f))
256 (profile -> (derivation->output-path drv))
257 (bindir -> (string-append profile "/bin"))
258 (_ (built-derivations (list drv))))
259 (return (and (file-exists? (string-append bindir "/guile"))
260 (file-exists? (string-append bindir "/make"))
261 (string=? (readlink (string-append bindir "/guile"))
262 (string-append "../../"
263 (basename
264 (derivation->output-path guile))
265 "/bin/guile"))
266 (string=? (readlink (string-append bindir "/make"))
267 (string-append "../../"
268 (basename
269 (derivation->output-path make))
270 "/bin/make"))))))
271
e39d1461
LC
272(test-assertm "profile-derivation, inputs"
273 (mlet* %store-monad
274 ((entry -> (package->manifest-entry packages:glibc "debug"))
275 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
276 #:hooks '()
277 #:locales? #f)))
e39d1461
LC
278 (return (derivation-inputs drv))))
279
176febe3
LC
280(test-assertm "profile-derivation, cross-compilation"
281 (mlet* %store-monad
282 ((manifest -> (packages->manifest (list packages:sed packages:grep)))
283 (target -> "arm-linux-gnueabihf")
284 (grep (package->cross-derivation packages:grep target))
285 (sed (package->cross-derivation packages:sed target))
286 (locales (package->derivation packages:glibc-utf8-locales))
287 (drv (profile-derivation manifest
288 #:hooks '()
289 #:locales? #t
290 #:target target)))
ede121de
CM
291 (define (find-input package)
292 (let ((name (string-append (package-full-name package "-") ".drv")))
176febe3
LC
293 (any (lambda (input)
294 (let ((input (derivation-input-path input)))
295 (and (string-suffix? name input) input)))
296 (derivation-inputs drv))))
297
298 ;; The inputs for grep and sed should be cross-build derivations, but that
299 ;; for the glibc-utf8-locales should be a native build.
300 (return (and (string=? (derivation-system drv) (%current-system))
ede121de 301 (string=? (find-input packages:grep)
176febe3 302 (derivation-file-name grep))
ede121de 303 (string=? (find-input packages:sed)
176febe3 304 (derivation-file-name sed))
ede121de 305 (string=? (find-input packages:glibc-utf8-locales)
176febe3
LC
306 (derivation-file-name locales))))))
307
9e90fc77
LC
308(test-assert "package->manifest-entry defaults to \"out\""
309 (let ((outputs (package-outputs packages:glibc)))
310 (equal? (manifest-entry-output
311 (package->manifest-entry (package
312 (inherit packages:glibc)
313 (outputs (reverse outputs)))))
314 (manifest-entry-output
315 (package->manifest-entry packages:glibc))
316 "out")))
317
dedb17ad
LC
318(test-assertm "profile-manifest, search-paths"
319 (mlet* %store-monad
320 ((guile -> (package
321 (inherit %bootstrap-guile)
322 (native-search-paths
323 (package-native-search-paths packages:guile-2.0))))
324 (entry -> (package->manifest-entry guile))
325 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
326 #:hooks '()
327 #:locales? #f))
dedb17ad
LC
328 (profile -> (derivation->output-path drv)))
329 (mbegin %store-monad
330 (built-derivations (list drv))
331
332 ;; Read the manifest back and make sure search paths are preserved.
333 (let ((manifest (profile-manifest profile)))
334 (match (manifest-entries manifest)
335 ((result)
336 (return (equal? (manifest-entry-search-paths result)
337 (manifest-entry-search-paths entry)
338 (package-native-search-paths
339 packages:guile-2.0)))))))))
d664f1b4 340
ccda8f7d
LC
341(test-assert "package->manifest-entry, search paths"
342 ;; See <http://bugs.gnu.org/22073>.
343 (let ((mpl (@ (gnu packages python) python2-matplotlib)))
344 (lset= eq?
345 (package-transitive-native-search-paths mpl)
346 (manifest-entry-search-paths
347 (package->manifest-entry mpl)))))
348
55b4715f
LC
349(test-equal "packages->manifest, propagated inputs"
350 (map (match-lambda
351 ((label package)
352 (list (package-name package) (package-version package)
353 package)))
354 (package-propagated-inputs packages:guile-2.2))
355 (map (lambda (entry)
356 (list (manifest-entry-name entry)
357 (manifest-entry-version entry)
358 (manifest-entry-item entry)))
359 (manifest-entry-dependencies
360 (package->manifest-entry packages:guile-2.2))))
361
b3a00885
LC
362(test-assert "manifest-entry-parent"
363 (let ((entry (package->manifest-entry packages:guile-2.2)))
364 (match (manifest-entry-dependencies entry)
365 ((dependencies ..1)
366 (and (every (lambda (parent)
367 (eq? entry (force parent)))
368 (map manifest-entry-parent dependencies))
369 (not (force (manifest-entry-parent entry))))))))
370
55b4715f
LC
371(test-assertm "read-manifest"
372 (mlet* %store-monad ((manifest -> (packages->manifest
373 (list (package
374 (inherit %bootstrap-guile)
375 (native-search-paths
376 (package-native-search-paths
377 packages:guile-2.0))))))
378 (drv (profile-derivation manifest
379 #:hooks '()
380 #:locales? #f))
381 (out -> (derivation->output-path drv)))
382 (define (entry->sexp entry)
383 (list (manifest-entry-name entry)
384 (manifest-entry-version entry)
385 (manifest-entry-search-paths entry)
b3a00885
LC
386 (manifest-entry-dependencies entry)
387 (force (manifest-entry-parent entry))))
55b4715f
LC
388
389 (mbegin %store-monad
390 (built-derivations (list drv))
391 (let ((manifest2 (profile-manifest out)))
392 (return (equal? (map entry->sexp (manifest-entries manifest))
393 (map entry->sexp (manifest-entries manifest2))))))))
394
a654dc4b
LC
395(test-equal "collision"
396 '(("guile-bootstrap" "2.0") ("guile-bootstrap" "42"))
397 (guard (c ((profile-collision-error? c)
398 (let ((entry1 (profile-collision-error-entry c))
399 (entry2 (profile-collision-error-conflict c)))
400 (list (list (manifest-entry-name entry1)
401 (manifest-entry-version entry1))
402 (list (manifest-entry-name entry2)
403 (manifest-entry-version entry2))))))
404 (run-with-store %store
405 (mlet* %store-monad ((p0 -> (package
406 (inherit %bootstrap-guile)
407 (version "42")))
408 (p1 -> (dummy-package "p1"
409 (propagated-inputs `(("p0" ,p0)))))
410 (manifest -> (packages->manifest
411 (list %bootstrap-guile p1)))
412 (drv (profile-derivation manifest
413 #:hooks '()
414 #:locales? #f)))
415 (return #f)))))
416
417(test-equal "collision of propagated inputs"
418 '(("guile-bootstrap" "2.0") ("guile-bootstrap" "42"))
419 (guard (c ((profile-collision-error? c)
420 (let ((entry1 (profile-collision-error-entry c))
421 (entry2 (profile-collision-error-conflict c)))
422 (list (list (manifest-entry-name entry1)
423 (manifest-entry-version entry1))
424 (list (manifest-entry-name entry2)
425 (manifest-entry-version entry2))))))
426 (run-with-store %store
427 (mlet* %store-monad ((p0 -> (package
428 (inherit %bootstrap-guile)
429 (version "42")))
430 (p1 -> (dummy-package "p1"
431 (propagated-inputs
432 `(("guile" ,%bootstrap-guile)))))
433 (p2 -> (dummy-package "p2"
434 (propagated-inputs
435 `(("guile" ,p0)))))
436 (manifest -> (packages->manifest (list p1 p2)))
437 (drv (profile-derivation manifest
438 #:hooks '()
439 #:locales? #f)))
440 (return #f)))))
441
442(test-assertm "no collision"
443 ;; Here we have an entry that is "lowered" (its 'item' field is a store file
444 ;; name) and another entry (its 'item' field is a package) that is
445 ;; equivalent.
446 (mlet* %store-monad ((p -> (dummy-package "p"
447 (propagated-inputs
448 `(("guile" ,%bootstrap-guile)))))
449 (guile (package->derivation %bootstrap-guile))
450 (entry -> (manifest-entry
451 (inherit (package->manifest-entry
452 %bootstrap-guile))
453 (item (derivation->output-path guile))))
454 (manifest -> (manifest
455 (list entry
456 (package->manifest-entry p))))
457 (drv (profile-derivation manifest)))
458 (return (->bool drv))))
459
d664f1b4
LC
460(test-assertm "etc/profile"
461 ;; Make sure we get an 'etc/profile' file that at least defines $PATH.
462 (mlet* %store-monad
463 ((guile -> (package
464 (inherit %bootstrap-guile)
465 (native-search-paths
466 (package-native-search-paths packages:guile-2.0))))
467 (entry -> (package->manifest-entry guile))
468 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
469 #:hooks '()
470 #:locales? #f))
d664f1b4
LC
471 (profile -> (derivation->output-path drv)))
472 (mbegin %store-monad
473 (built-derivations (list drv))
474 (let* ((pipe (open-input-pipe
9e006fb3
TUBK
475 (string-append "unset GUIX_PROFILE; "
476 ;; 'source' is a Bashism; use '.' (dot).
477 ". " profile "/etc/profile; "
478 ;; Don't try to parse set(1) output because
479 ;; it differs among shells; just use echo.
480 "echo $PATH")))
481 (path (get-string-all pipe)))
d664f1b4
LC
482 (return
483 (and (zero? (close-pipe pipe))
9e006fb3 484 (string-contains path (string-append profile "/bin"))))))))
d664f1b4 485
a0dac7a0
LC
486(test-assertm "etc/profile when etc/ already exists"
487 ;; Here 'union-build' makes the profile's etc/ a symlink to the package's
488 ;; etc/ directory, which makes it read-only. Make sure the profile build
489 ;; handles that.
490 (mlet* %store-monad
491 ((thing -> (dummy-package "dummy"
492 (build-system trivial-build-system)
493 (arguments
494 `(#:guile ,%bootstrap-guile
495 #:builder
496 (let ((out (assoc-ref %outputs "out")))
497 (mkdir out)
498 (mkdir (string-append out "/etc"))
499 (call-with-output-file (string-append out "/etc/foo")
500 (lambda (port)
1e868858
MW
501 (display "foo!" port)))
502 #t)))))
a0dac7a0
LC
503 (entry -> (package->manifest-entry thing))
504 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
505 #:hooks '()
506 #:locales? #f))
a0dac7a0
LC
507 (profile -> (derivation->output-path drv)))
508 (mbegin %store-monad
509 (built-derivations (list drv))
510 (return (and (file-exists? (string-append profile "/etc/profile"))
511 (string=? (call-with-input-file
512 (string-append profile "/etc/foo")
513 get-string-all)
514 "foo!"))))))
515
113c17a0
LC
516(test-assertm "etc/profile when etc/ is a symlink"
517 ;; When etc/ is a symlink, the unsymlink code in 0.8.2 would fail
518 ;; gracelessly because 'scandir' would return #f.
519 (mlet* %store-monad
520 ((thing -> (dummy-package "dummy"
521 (build-system trivial-build-system)
522 (arguments
523 `(#:guile ,%bootstrap-guile
524 #:builder
525 (let ((out (assoc-ref %outputs "out")))
526 (mkdir out)
527 (mkdir (string-append out "/foo"))
528 (symlink "foo" (string-append out "/etc"))
529 (call-with-output-file (string-append out "/etc/bar")
530 (lambda (port)
1e868858
MW
531 (display "foo!" port)))
532 #t)))))
113c17a0
LC
533 (entry -> (package->manifest-entry thing))
534 (drv (profile-derivation (manifest (list entry))
a6562c7e
LC
535 #:hooks '()
536 #:locales? #f))
113c17a0
LC
537 (profile -> (derivation->output-path drv)))
538 (mbegin %store-monad
539 (built-derivations (list drv))
540 (return (and (file-exists? (string-append profile "/etc/profile"))
541 (string=? (call-with-input-file
542 (string-append profile "/etc/bar")
543 get-string-all)
544 "foo!"))))))
545
22ef06b8
LC
546(test-equalm "union vs. dangling symlink" ;<https://bugs.gnu.org/26949>
547 "does-not-exist"
548 (mlet* %store-monad
549 ((thing1 -> (dummy-package "dummy"
550 (build-system trivial-build-system)
551 (arguments
552 `(#:guile ,%bootstrap-guile
553 #:builder
554 (let ((out (assoc-ref %outputs "out")))
555 (mkdir out)
556 (symlink "does-not-exist"
557 (string-append out "/dangling"))
558 #t)))))
559 (thing2 -> (package (inherit thing1) (name "dummy2")))
560 (drv (profile-derivation (packages->manifest
561 (list thing1 thing2))
562 #:hooks '()
563 #:locales? #f))
564 (profile -> (derivation->output-path drv)))
565 (mbegin %store-monad
566 (built-derivations (list drv))
567 (return (readlink (readlink (string-append profile "/dangling")))))))
568
a2078770
LC
569(test-end "profiles")
570
a2078770
LC
571;;; Local Variables:
572;;; eval: (put 'dummy-package 'scheme-indent-function 1)
573;;; End: