Re: LAPACK vs. OpenBLAS
Hi Ludo, > A surprisingly large number of packages depend on ‘lapack’: > Perhaps we could have a lint checker warning against the use of lapack. Good idea. Possibly with a helpful message along the lines of 'the openblas package provides a LAPACK interface'. I encountered this issue when packaging an optimization package [0] recently. The build system, cmake, requires a path to the BLAS_LIBRARY and also a path to the LAPACK_LIBRARY. One can see how the shared library liblapack.so, provided by the lapack package, could be the first (but mistaken) choice for the packager. I notice that Debian [1] use NO_LAPACK=1 as an extra make option for openblas. This has the effect of generating a liblapack.so file. For the case of optizelle, the package I was working on, I labelled the openblas input as "blas/lapack" to make it clear that the package has a dual purpose. Best regards, Paul. [0] https://hpc.guix.info/package/optizelle [1] https://sources.debian.org/src/openblas/0.3.13+ds-3/debian/rules/
Re: git-fetch for emacs-auctex?
Hi Nicolas, On Tue, 2021-05-25 at 22:10 +0200, Nicolas Goaziou wrote: > Hello, > > There are no tags in the ELPA repository, but new releases are > triggered by a bump of "Version:" keyword. So, it is technically > possible to map a version to a commit hash by looking for such > changes. This has been suggested already in bug#46489. > Thank you for pointing to the bug report https://issues.guix.gnu.org/issue/46849 It is the same issue as found in Nix. This does not seem to be fixed yet. I imagine there is a choice between an auctex-only fix and a general ELPA fix. Best regards, Paul.
Re: git-fetch for emacs-auctex?
Hi Leo, On Tue, 2021-05-25 at 22:00 +0200, Leo Prikler wrote: > > What it this auctex and how does it differ from the one packaged in > ELPA? > This is the repository for the AUCTeX project. The home page is https://www.gnu.org/software/auctex/ The ELPA package is derived from the upstream version. It has its own version numbering scheme. For example, the current version on ELPA is 13.0.11. The current upstream version is 12.3. Every so often the upstream development branch is merged into the ELPA branch and a new ELPA version is released. One option for the Guix package would be to bypass ELPA and use the upstream repository directly. However, the version string would change from "13.0.11" to something like "12.3-commit", where 'commit' identifies the git reference of the upstream branch. This would solve the reproducibility problem. However, a one-off update resulting in a smaller version number might cause confusion. Are there views on this point? Best regards, Paul.
git-fetch for emacs-auctex?
Hi Guix, I recently attempted to reproduce a profile containing emacs-auctex, only to find a '404: not found' error. The reason is that elpa.gnu.org archives previous auctex versions with a .tar.lz extension. This throws out the Guix package source definition, which expects a .tar extension. I have considered a few ideas to solve this: i) track the last-but-one auctex version in Gnu Elpa. This way all versions would have the same extension. However, would the url-fetch method cope with the .tar.lz format? ii) use the git-fetch method with the upstream repository. However, the upstream version tag at http://git.savannah.gnu.org/cgit/auctex.git is a smaller number than the Gnu Elpa version tag. This would result in an apparent downgrade. Would that be permissible? iii) use the git-fetch method to clone the auctex branch of the elpa.git repository (along the lines of 'git clone --single-branch -- branch externals/auctex .../elpa.git). As far as I can see this is not currently possible. Are there any insights or suggestions? Best regards, Paul.
Re: Adding Trilinos to dealii package
Dear Paul, > I would like to eventually package the Lethe CFD library Nice! Trilinos has many bells and whistles. I imagine that there will be some significant effort required to package it. One option would be to subdivide the library and initially package only the elements you need for Lethe. See the Debian approach to packaging Trilinos for example [1]. If Lethe does not use PETSc there would be no risk of conflict. The choice between including the new Trilinos (sub)package as a dependency of dealii and dealii-openmpi or creating new dealii-trilinos and dealii-trilinos-openmpi packages would be marginal. How many models need to use PETSc and Trilinos at the same time? > This assumes people won't mind having to build Trilinos as a > dependency for dealii even if they don't need it. The model run times are usually very much longer than the library build times. I expect this would be true for Trilinos and Lethe too. Best regards, Paul. [1]: https://packages.debian.org/source/buster/trilinos
Re: configure: error: A recent Guile-zlib could not be found; please install it.
Hi Roel, > How can I get a working development environment to work on Guix? A 'guix pull' within your profile will update the guile-zlib version that is used by 'guix environment ...'. Then the configure script requirement will be met. Best regards, Paul.
Re: gpg key expiration time
Hi Tobias, On Mon, 2021-03-15 at 18:24 +0100, Tobias Geerinckx-Rice wrote: > The expiry date is not embedded in your cryptographic key, merely > attached to it as a signed ‘packet’. Thanks. Got it! Best regards, Paul.
gpg key expiration time
Hi Guix, After renewing the expiration time of one's gpg key, and uploading the updated key to Savannah, is it also necessary to update the corresponding file in the keyring branch? I notice from the log that, so far, none of the original files have been updated. Does this mean that the original validation is accepted for new commits signed with an updated key? Best regards, Paul.
Re: bug#45069: BUG: Re: guix environment: error: cannot create container: unprivileged user cannot create user namespaces
Hi Pierre, > # echo 1 > /proc/sys/kernel/unprivileged_userns_clone > -bash: /proc/sys/kernel/unprivileged_userns_clone: No such file or > directory Thanks, that gives us a clue. So all or part of the path '/proc/sys/kernel' is missing? Best regards, Paul.
Re: bug#45069: BUG: Re: guix environment: error: cannot create container: unprivileged user cannot create user namespaces
Hi Pierre, Can you try, as root on Guix System: $ echo 1 > /proc/sys/kernel/unprivileged_userns_clone If you could report success or failure that would be helpful; the unprivileged-user-namespace-supported? test in gnu/build/linux- container.scm should be the same irrespective of the underlying distribution (Debian, CentOS, Guix System ...). Best regards, Paul. On Mon, 2020-12-07 at 12:57 +0100, Pierre Neidhardt wrote: > Hi! > > I can reproduce the issue since I 'recondigure'd my Guix System. > I'm on cebfb29abb151ede95696181d2446c63504593d7. > > Guix' bug? > >
Re: Licensing issue with Gmsh?
Hi Simon, > There is only a parmetis.c file included in the metis directory. > However, it is commented out in CMakeLists.txt. > To be "Guix compliant", this parametis.c file should be removed, > right? The file is part of METIS and thereby covered by the Apache license. It only provides entry points for ParMETIS, so ignoring it in the build stage, in the way that Gmsh does, seems to be appropriate. However, I notice from the patch that the Guix package metis is included as an input. This means that the whole of the bundled 'contrib/metis' directory could be deleted after all. If I remember correctly CMake gives preference to the 'system' packages ahead of the bundled packages. Best regards, Paul.
Re: Licensing issue with Gmsh?
Hi Simon, Thank you for working on the Gmsh package. There have been a great many changes since the last update. > I am inclined to enable METIS because it appears to me fine. However, > since freedom is essential, it would like another advice and/or comment > on. There is a distinction between METIS (free) and ParMETIS (non-free) which may have influenced the decision to remove the whole metis directory. As far as I can see Gmsh does not use any files from the ParMETIS library. There is only a parmetis.c file included in the metis directory. However, it is commented out in CMakeLists.txt. Best regards, Paul.
Re: getting started with the texlive importer
Hi Ricardo, Hi John, > Looks good to me. Please push! Cheers! Pushed as 735808b12cc23909b421e10e212a07e7aa69a5eb Best regards, Paul.
Re: getting started with the texlive importer
Hi Guix, Ok, I have found a fix. It turns out that the 'svn export' command throws an error if the target directory already exists. Initially I set the 'log' argument of 'download-svn-to-store' to 'current-output-port' to see the error message from svn: svn: E155000: Destination directory exists; please remove the directory or use - -force to overwrite This error is generated because a temporary directory is created by the 'call-with-temporary-directory' procedure (from svn-download.scm). The name of the directory is used as an argument for the 'svn export' command. The fix I have tested is the following: --- a/guix/svn-download.scm +++ b/guix/svn-download.scm @@ -159,10 +159,11 @@ reports to LOG." (parameterize ((current-output-port log)) (build:svn-fetch (svn-reference-url ref) (svn-reference-revision ref) - temp + (string-append temp "/svn") #:user-name (svn-reference-user-name ref) #:password (svn-reference-password ref) (and result -(add-to-store store name #t "sha256" temp)) +(add-to-store store name #t "sha256" + (string-append temp "/svn"))) ;;; svn-download.scm ends here The effect is to add a subdirectory to the temporary directory. This is used as the target to download the files to. It does not exist until created by the 'svn export' command. WDYT? If there are no objections I will push a commit early next week. Best regards, Paul.
Re: getting started with the texlive importer
Hi Guix, I have been able to run the texlive importer after making some changes to guix/import/texlive.scm: @@ -148,20 +148,22 @@ expression describing it." ((lst ...) (map string->license lst (home-page (string-append "http://www.ctan.org/pkg/"; id)) (ref(texlive-ref component id)) - (checkout (download-svn-to-store store ref))) + ;; (checkout (download-svn-to-store store ref)) + ) `(package (name ,(guix-name component id)) (version ,version) (source (origin (method svn-fetch) (uri (texlive-ref ,component ,id)) - (sha256 -(base32 - ,(bytevector->nix-base32-string - (let-values (((port get-hash) (open-sha256- port))) - (write-file checkout port) - (force-output port) - (get-hash))) + ;; (sha256 + ;; (base32 + ;; ,(bytevector->nix-base32-string + ;; (let-values (((port get-hash) (open-sha256- port))) + ;; (write-file checkout port) + ;; (force-output port) + ;; (get-hash) + )) (build-system texlive-build-system) (arguments ,`(,'quote (#:tex-directory ,(string-join (list component id) "/" (home-page ,home-page) This successfully produces a definition, albeit without the hash field. So it seems that the procedure 'download-svn-to-store ' is the source of the original error. Any ideas on how to fix? Paul.
getting started with the texlive importer
Hi Guix, I have been trying to use the texlive importer to package some TeXLive packages. Using the example from the manual, I try: $ guix import texlive fontspec I get: following redirection to `https://ctan.org/xml/1.2/pkg/fontspec'... Backtrace: 13 (primitive-load "/usr/local/bin/guix") In guix/ui.scm: 2050:12 12 (run-guix-command _ . _) In guix/scripts/import.scm: 116:11 11 (guix-import . _) In guix/scripts/import/texlive.scm: 91:19 10 (guix-import-texlive . _) In guix/memoization.scm: 98:0 9 (mproc "fontspec" "latex") In unknown file: 8 (_ # …) In ice-9/boot-9.scm: 1736:10 7 (with-exception-handler _ _ #:unwind? _ # _) In guix/store.scm: 631:37 6 (thunk) In guix/import/texlive.scm: 151:23 5 (_ #) In guix/utils.scm: 705:8 4 (call-with-temporary-directory #) In guix/svn-download.scm: 160:14 3 (_ "/tmp/guix-directory.nfum2k") In guix/build/svn.scm: 39:2 2 (svn-fetch _ _ _ #:svn-command _ #:recursive? _ # _ # _) In guix/build/utils.scm: 654:6 1 (invoke _ . _) In ice-9/boot-9.scm: 1669:16 0 (raise-exception _ #:continuable? _) ice-9/boot-9.scm:1669:16: In procedure raise-exception: ERROR: 1. &invoke-error: program: "svn" arguments: ("export" "--non-interactive" "--trust-server-cert" "- r" "51265" "svn:// www.tug.org/texlive/tags/texlive-2019.3/Master/texmf-dist/source/latex/fontspec " "/tmp/guix-directory.nfum2k") exit-status: 1 term-signal: #f stop-signal: #f So the 'svn export' command is causing an error. Interestingly, if I run the same command from the shell it succeeds; the files are downloaded to the temporary directory. Are others seeing the same thing? I wonder whether a recent change in guix has jiggered the importer. Best regards, Paul.
Re: Reproducible Research Hackathon: Friday, July 3rd
Hi Simon, On Fri, 2020-07-03 at 20:19 +0200, zimoun wrote: > > I do not know if it is the best but I do: > > guix build -L path/to/clone the-package > guix install -L path/to/clone the-package -p /tmp/test > /tmp/test/bin/the-package This works for me if I use the command: $guix build -L /path/to/guix-past-checkout/modules the-package Many thanks for the tip. Best regards, Paul.
Re: Reproducible Research Hackathon: Friday, July 3rd
Hi Ricardo, Many thanks for this tip. > I did this from the checkout of “guix-past”: > > GUIX_PACKAGE_PATH=$PWD guix build my-package > First, I changed directory to the 'modules' directory in the guix-past checkout. Then the 'guix build' command can follow the subdirectories and find the package definitions. Best regards, Paul.
Re: Reproducible Research Hackathon: Friday, July 3rd
Hi Simon, Thank you for organising the day. > We are interested to hear your feedback. Especially about what pass, > what fail and what you have learnt, if you enjoyed the experience, or on > the contrary if you not, what could be improved for the next round. One outstanding puzzle for me is to figure out how to test a package definition in a new channel. For example, I have cloned the guix-past repository and started to add a new package. However, what is the best workflow to attempt a build from the channel? Do you add the channel to the git checkout of guix? Best regards, Paul.
Re: 01/03: gnu: ikiwiki: Revert to standard wrapper.
Hi Chris, > I don't think there was ever a bug report for this, but I think I've > found the IRC conversation for context: > > http://logs.guix.gnu.org/guix/2017-10-17.log#203630 Thank you for this link and taking a look at this patch. I have been adding the missing inputs to ikiwiki. In the process I noticed that the cgi script needs a way of finding the perl dependencies. The Debian way of packaging the perl modules allows ikiwiki to see its dependencies immediately. In Guix, as you said, it needs some help via PERL5LIB. In using ikiwiki I found that I needed to add the PERL5LIB variable to the setup file anyway, so that the cgi script can see extra modules that are not needed at build time. In my setup file there is an 'ENV' section which contains: PERL5LIB: /home/paul/.guix-profile/lib/perl5/site_perl This means that there is no need to have PERL5LIB in the wrapper. Instead the dependencies can be propagated in the normal way. This fits in with the PREREQ_PM section of ikiwiki's Makefile.PL. So far,everything I have tested works as expected. After the latest commit e642f78f2eaf1d53d656ff3cd86d4dd186e8eb52 all the main tests pass. Best regards, Paul.
Re: Building R Packages
Hi Daniela, Have you tried './pre-inst-env guix build ...' instead of 'guix build ...'? The difference is that the former command will look for package definitions in your checked out, and modified, version of Guix. The latter command looks for package definitions in your installed version of Guix. Your modifications will be seen by this command after you submit a patch, it is committed, then you update your installed version with a 'guix pull'. Best regards, Paul.
Re: Packaging FreeCAD
Hi John, > I'm excited to announce that I opened FreeCAD for the first time this > evening thanks most recently to support on the FreeCAD forum! Great news! > Now where do I put the package definition in gnu/packages? How about engineering.scm for FreeCAD? This module already contains other CAD-related packages such as LibreCAD and KiCad. Best regards, Paul.
Re: Video license
Hello Björn, > For the code I would suggest GPL v3+, for the voices (currently Paul) > and videos I would suggest CC-BY-SA 4.0 > > What do you think? Does every contributor agree to that? That looks good to me. For the source code we could add copyright statements at the top of the files in a similar way to the rest of the Guix code. Also, would you like to take a look at the CREDITS file and add entries for the work that you have done?. The idea is twofold: to acknowledge the contributions made and also to make the steps more visible. Potential future contributors could then say ' hey, I could do that in my language'. Best regards, Paul.
Re: Documentation videos are being uploaded!
Hi Laura, > Yes, sure! I also agree that it is important giving credits :) > Would you mind asking them if they want to have their name there? I have made a start and pushed a new CREDITS file to the repository. There are entries in the list for the contributors that I know about (thanks, Ricardo!) but I suspect that there has been more work done than I am aware of. Would you like to take a look and fill in the gaps? I have seen the names of Gabor and Bjorn in the logs, for example. Best regards, Paul.
Re: Packaging FreeCAD
Hi John, > Another question: do we tend to try to use guix packages whenever a package > ships bundled with some third party source? Yes. The preference is to use Guix packages where possible. Best regards, Paul.
Re: Packaging FreeCAD
Hi John, It is good to hear that you have made such good progress on packaging FreeCAD. > we would need to also package opencascade-occt I can help with this part. I am planning to introduce the opencascade- occt package in order to upgrade gmsh, which also depends on OpenCASCADE. All being well, I should be able to start on this within the next two weeks. I will update this thread when the package is ready. Best regards, Paul.
Re: Documentation videos are being uploaded!
Hi All, > Kudos Laura & Paul! > I am cc'ing Paul :) It is good to hear that the end result is being well received :) I am thinking of adding a CREDITS file to the repository, primarily to acknowledge the help given by the sound engineer. The use of the studio equipment and the editing work made this part much easier than it would otherwise have been. Also, if all the other contributors would like to add in a record for their work on workflow design, scripting, slide production and so on it would help future contributors understand how the videos are made. Best regards, Paul.
Re: Video narration
Hi Laura, > I found the reason for this. Great. > I wanted to take a look at how totem was packaged but I can't find > it. The method I use to track packages is to search at https://guix-hpc.bordeaux.inria.fr/browse In this case a search for 'totem' points to the definition at gnu/packages/gnome.scm, line 3845. If you take a look at the definition you can see how the dependencies are specified. I am not very familiar with the Gnome packages but I could imagine there may be a difference between the Debian list of dependencies and the Guix list. Perhaps your test has revealed a bug in the Guix packaging of totem. Best regards, Paul.
Re: Video narration
Hi Laura, > BTW, I finished generating the videos. > Sth weird happens with totem. I end up having a segmentation fault, Did this problem resolve itself? I tested 01-installation-from-script on my system without seeing any interruption. I am testing with totem version 3.26.0 on Ubuntu 18.04. Best regards, Paul.
Re: Video narration
Hi Laura, > Could you re-build the other videos and check the internal timings? > This is the fine adjustment that synchronizes the audio with the > command line output. > By this, do you mean checking that the audio matches the video, > taking into account that if I have to add some silence in between I > have to remove the same amount of time somewhere else? Yes. I think that the total duration of each cli session is now good. However, there may be improvements in a few places to further synchronize the narration with the screen output. For example, if a particular output is displayed slightly ahead of the narration one could add some extra sleep before the section and remove the same amount after. That way the total duration, of each session, will stay the same. Best regards, Paul.
Re: Video narration
Hi Laura, > I see the only one that needs to be finished is 04-packaging3. > Would you like me to adjust it? I can do the coarse adjustment on that one, to set the overall duration and make sure that the audio streams are not truncated. Could you re-build the other videos and check the internal timings? This is the fine adjustment that synchronizes the audio with the command line output. I have briefly checked that this is sensible but there could be improvements to be made. The overall duration should stay the same. So if you remove 1000 ms of sleep from one section, for example, it needs to be added back in elsewhere. Best regards, Paul.
Re: Video narration
Hi Laura, > Now I am generating all the videos and will be pushing the changes > asap. Great stuff. I have made a start, setting the durations for the first three videos. If you pull the changes you can check the inner timings as well. The sum of the sleep commands should now be correct for these videos. I plan to finish the coarse level sleep settings for the remaining videos in the next few days. Best regards, Paul.
Re: Video narration
Hi Ricardo, > Are you saying you want to take snapshots in larger intervals and pad > the intermediate frames with duplicates of previous frames? Thank you for writing the snap! procedure. It is writing the output as intended. The problem we ran into was to do with the timing. If you go back in this thread you will see the history. In order to produce .webm files that are compatible with the Firefox browser it is necessary to eliminate gaps in the audio streams. ffmpeg can do this automatically using the 'apad' filter. However, it will truncate the audio stream if the video stream is shorter in duration than the audio stream. So, in preparing the cli session files we need to be able to accurately set the duration of the last 'sleep' command. Since we know the frame rate (25 fps) it is straightforward to calculate the number of repeated frames we need for any given duration. This is the job of the new 'repeat' procedure. In this way we effectively replace the timer with a counter. The session files now need to be checked to tune the sleep commands to synchronize with the audio stream. I will be able to look at 02-daily- use1 again tomorrow. Best regards, Paul.
Re: Video narration
Hi Laura, > My good news are that I get the 10 secs difference, the bad ones that > the timing is different: > 00:01:18.40800 > and > 00:01:28.40700 > Any clue? Great. These are the same, my timings expressed in seconds yours in minutes and seconds. I think we can live the millisecond difference in the last significant digit! So we should be able to finish from here without major obstacles. However, I suspect that the cli timings that you did previously will need to be re-checked as we will now be using the accurate 'sleep' command. If you could check the inner sleep commands in the way that you did before I can adjust the ending sleep to make sure that the 'apad' filter works correctly. How about that? Best regards, Paul.
Re: Video narration
Hi Laura, > I like testing (and trying to break) stuff - I > wished this worked well though :/ I have a new version to test. It's unbreakable though, this one! I have implemented the repeat procedure and pushed the commit to the repository. > I definitely HAVE TO learn Guile. This is a good example. There is some arithmetic needed to convert the sleep durations, in milliseconds, to frames, using the frame rate. If you have seen reverse polish notation before you will recognise the way the arithmetic expressions are built up. The function comes first and the arguments afterwards. So (/ wait 1000), for example, means divide the variable 'wait' by one thousand. The repeat procedure uses a 'named let' for recursion. This calls the snap! procedure the correct number of times to generate the extra frames. The slightly tricky part was making sure that the snap! procedure and the repeat procedure are in the same scope. Otherwise, an 'unbound variable' error is generated. I was able to do this by moving the repeat procedure, plus the other procedures that are needed for processing the session files, inside the same let construct in the main body. To test I used the firstCli session file from 02-daily-use1. I changed the last line from '#:sleep 3' to '#:sleep 4'. The time durations were: before: 78.408000 after: 88.408000 That's more like it! a delay of ten seconds, as it should be. Can you confirm that you get the same result? Best regards, Paul.
Re: Video narration
Hi Laura, > firstCli originally gives me a length of 00:01:54.84700 > Then, adding the sleep metacommand I get 00:02:18.24800 > > As regards secondCli, originally: 00:00:59.60800 > And adding the sleep metacommand: 00:01:11.64800 Thank you for testing. The results are different from my system. I think we are seeing a difference between wall-clock time and cpu time. In the screen file I can see there is a snap! procedure that writes a frame to disk after each interval. It looks as if the disk i/o is interrupting the sleep counter and introducing a delay that depends on the system activity. We may need to change tack to get accurate time delays. One thought is to replace the timer with a 'repeat' procedure that repeats the previous frame. If we know the sleep duration, s, and the interval, i, we can calculate the number of repeats, N, needed: N = s / i This method would be unaffected by disk write times or rounding errors. Best regards, Paul.
Re: Video narration
Hi Laura, > With the new changes, right? Yes. In my case I was noticing erratic intervals produced by the sleep commands. So '#:sleep 1000' gave a 6 s pause and '#:sleep 13000' gave a 26 s pause, for example. After the changes the commands produce the expected results. Best regards, Paul.
Re: Video narration
Hi Laura, > I see. I was testing with the current screen file. Please, let me > know when you push the changes so that I make all the videos again > and adjust what is necessary. Many thanks. I have pushed the changes to the repository. It would be great if you can test the accuracy on your system too. If you add '#:sleep 1' to one of the session files, for example, does it make the cli video 10 seconds longer? If so, I think it will make finishing off the timings and checking the durations much easier. Best regards, Paul.
Re: Video narration
Hi Laura, > > I have made a start with the 01-installation-from-script video. I > > am using Firefox version 66.0.3 to test. > Ok I will go on with the followings then! Working on the timings for 02-daily-use1 I have found that I have needed to make a couple of changes to the 'hesitate' procedure in the screen script. I have been finding that the pause introduced by the sleep command is not accurate, making it difficult to set the right values in the sessions files. I wonder whether you have noticed the same effect? To improve the accuracy I have changed the procedure definition to use a scaling factor of one thousand, to go from milliseconds to microseconds, and have increased the chunk size to 2 ms. The Guile documentation for usleep notes that many systems round the interval specified up or down and are unable to achieve accuracy to the microsecond level. After some testing on the system I am using to build the videos I found that 2 ms was the optimum value. With this value '#:sleep 3', for example, produces a pause of 30 s. I will commit the change so that you can test it too. If we keep the change it will mean re-checking the timings in the session files. However, I think that this will be necessary to make the adjustments in the total durations for Firefox. Best regards, Paul.
Re: Video narration
Hi Laura and All, I have determined the cause of the playback problems with Firefox and pushed a fix to the videos.git repository. Essentially, a limitation of the treatment of opus audio streams in Firefox means that videos with gaps in the audio stream are not played properly. There were two parts to the fix. First, the audio streams need to be padded with silence to match the duration of the video streams. Then, the concatenation of the audio streams needs to be done separately from the video streams. The two streams are the same duration and may be joined without re-encoding. A consequence of the new approach is that the cli sessions need to be checked to ensure that the duration of the video streams are (slightly) longer than the audio streams. Otherwise, the audio streams will be truncated. I have made a start with the 01-installation-from-script video. I am using Firefox version 66.0.3 to test. Can others confirm that the new method works with their browsers and players? Best regards, Paul.
Re: Video narration
Hi Laura, > I deleted all the videos and made them again > and now I don't see that issue anymore. Ah, good news! > For this, what I could do is generate the cli sesison video with the > "silence1.mp3" to have duration1, and then compare it with the > duration of cli1.mp3 (for instance). Then, run a script comparing > the durations while duration2 < duration1 append silence1.mp3 to > cli1.mp3. And finally use the generated cli1.mp3 as the input > matching the video stream. > I find a little bit manual, but I don't mind doing it if you find it > OK. > WDYT? We may have to experiment a little to solve the question of combining the cli and nocli videos in a manner than can be replayed by Firefox/Icecat. One test I can try tomorrow is to concatenate the nocli videos on their own. Will the combined video play in Firefox? If so, it would suggest that the mismatch of the audio and video stream durations is the cause of the stoppage. There is a way to concatenate audio files with ffmpeg. So if we know we need an extra seconds of silence, say, we can generate the file with the command I previously posted and join the silence to the end of the narration. This would be a script-free alternative method. Best regards, Paul.
Re: Video narration
Hi Laura, > Now, as regards the colours, it works with totem too :) > But the cli sessions are at kind of super speed now, it happens > watching the full video, or the separate cli session videos. I've > tried it with totem, mvp and vlc. Any clue about it? I have not seen this effect on the playback speed. I am using the first video for testing. I do: $ make clean VIDEO=01-installation-from-script then, $ ./build-video.sh 01-installation-from-script This plays at the right speed for me in Videos/Totem (version 3.26). However, the concatenation question (for Firefox) may also be related to the speed question. Is super-speed very different from the expected speed? In the case of the first cli session for the first video there is a difference between the duration of the audio and video streams: duration1 (video stream): 1 minute 29 seconds duration2 (audio stream): 1 minute 18 seconds This difference may be treated in a different manner by different players. It may be necessary to add silence to the audio stream to equalize the durations and allow reliable concatenation without re- encoding. Best regards, Paul.
Re: Video narration
Hi Laura and Ludo, > the colours are changed. Ie: the dark gray turns > green, and the white turns somewhat pink. Commit 4bd2e78b893fef5ce1f12bec895ee8234cabaf1f fixes the colors. ffmpeg needed a different pixel format to set the chroma subsampling correctly [1]. I have been able to play the newly built cli and nocli videos in Firefox. Also, the combined video now starts in Firefox but stops just before the first transition. I think the concatenation step in the Makefile could be the cause. Best regards, Paul. 1. https://trac.ffmpeg.org/wiki/Encode/VP9
Re: Video narration
Hi Laura, > Can you tell me which players work for you? I tried with my browser > and it still tells me that the file is corrupt :/ I have tested Parole and Videos media players and Firefox and Midori browsers. All work except Firefox, which gives the message: 'Video can't be played because the file is corrupt' Is Firefox the browser you are testing with? Possibly another tweak to the ffmpeg encoding might be needed to support Firefox. > I didn't notice this. Is it possible to make the audio shorter than > the first duration? Ah, the expression for duration1 should be: duration1 (in seconds) = number of frames / 25 What I was thinking was that the cli sessions should end with a short pause. This will be the case as long as either duration1 is greater than duration2 or the audio file has a silent section at the end. If any of the transitions are too abrupt we can add some silence to the relevant audio file. The command I used for the silent slide in 02- daily-use2 was: $ ffmpeg -f lavfi -i anullsrc=r=4800:cl=mono -t -q:a 9 -c:a libmp3lame .mp3 This creates an mp3 file with seconds of silence. So a one second pause, say, could be concatenated (with ffmpeg) at the beginning or end of an audio file to improve the transition. Best regards, Paul.
Re: Video narration
Hi Laura, > Thank you so much for fixing this. It was in my TODO list, but it is > GREAT and if you can share your knowledge we can work and make the > videos available asap :) I have been able to match the aspect ratio of the cli videos to the nocli videos. With ffmpeg there is a filtergraph that can be added to pad the images. The result is a smooth transition between the two types. There is no longer flickering or crashing in the players I have tested. The fix is commit 7c5db139081c37cbd4896628e38f5bff8dc5427e. > I will go back tomorrow with fixing the timing Great. One thought I had on the timing of the cli videos is that there are two durations at work. Firstly, the frame rate and the number of frames: duration1 (in seconds) = number of frames x 25 Secondly, there is the duration of the audio file (duration2). Should we check that duration1 approximately equals duration2? Or possibly the audio file should always be slightly shorter than the duration of the frame display. WDYT? Best regards, Paul.
Re: Video narration
Hi Ricardo, > This is probably my mistake. I didn’t pay much attention to frame > rates when I first built the scripts for generating the CLI videos. > Ok, thanks. This is fixed in commit 7180fff4ecb46cfed41c6214579a53af6a636a21. The new frame rate is 25 fps. This is the European standard for PAL/HD video. The file sizes are not dramatically affected by the change. The first video is reduced in size from 11MB to 10 MB, for example. Best regards, Paul.
Re: Video narration
Hi All, > Yes! I am working on them to have the best match we can :) Nice, thanks Laura! I have pushed all of the new audio recordings to guix/videos.git. There were two extra svg images needed (for 02-daily-use2 and 04- packaging1) to match up with the audio. I have added templates for them. One question that cropped up was about the frame rate of the videos. I checked the cli and nocli videos and noticed that the nocli videos have a frame rate of 30 frames per second (fps) and the cli videos have a frame rate of 20 fps. Was there a reason for the difference? It may make it easier for the players to have a constant frame rate throughout. I gather that 25 fps is a common standard. Best regards, Paul.
Re: Video narration
Hi Laura, The recording session went very well yesterday. We were able to make all the recordings in a studio without having to worry about background noise. I had help from a sound engineer who is familiar with the microphone set-up and the recording process. > Great! :) Let me know when you have time to push them - no rush, > just to test :) - I have pushed the first set of audio files, for the 01-installation- from-script video. I have been able to re-build the video to check that it works. It does! For the cli sessions we used the timings in your recordings as a guide to synchronize my voice with the screen. I notice that there are 'sleep' commands in the session files so it might be possible to fine- tune the timing if necessary. Best regards, Paul.
Re: Video narration
Hi Laura, > Great! Could you remind me in UTC at which time of the day? Because I > generally have to record them at 00 UTC to reduce the environmental > noise. And then match them. > Thank you for uploading the cli audios for the packaging3 video. That completes the set! I will be going to the studio in half an hour (11.00am UTC). They have a space with low background noise. However, I will ask for a short 'silence' recording too, so that we can use it for joining sections if we need to. Best regards, Paul.
Re: Video narration
Hi Laura, I have finished updating the transcripts and I am preparing to do the recordings tomorrow. One question about the makefile: am I right in thinking that the makefile automatically adjusts the duration of each slide according to the duration of the corresponding audio file? In other words it would not matter if I supply audio files that are slightly longer (or shorter) than your originals? > Shouldn't the 'guix environment' step be later in the list of steps? > If I was packaging the aspi package I would do: > > $ guix environment --pure r-aspi > The environment was set up in the first packaging video. As far as I > am concerned, the idea is to have a clean guix environment and > package > everything there. If you are using a foreign distro then I believe > that it could not be reproducible if you package it first. > Please, let the others correct me if I am wrong. I think that this question has to do with the complexity of the package. The aspi example is a simple case that does not have any dependencies outside the R build system. For a more complex package (newPackage, for example) using: $ guix environment --pure guix $ guix build newPackage would fail if newPackage has extra inputs. Instead, the commands should be: $ guix environment --pure newPackage $ guix build newPackage I think this would be easy to communicate to new users if steps 1 and 2 are switched on Slide 2 and I add some extra words to the transcript. Do you (and others) agree? Best regards, Paul.
Re: Video narration
Hi Laura, I am working on the 04-packaging2 transcript. I have a question on Slide 2. Shouldn't the 'guix environment' step be later in the list of steps? If I was packaging the aspi package I would do: $ guix environment --pure r-aspi after defining the package first. Then I would attempt to build the package. WDYT? Best regards, Paul.
Re: Video narration
Hi Laura, I am 4/7ths of the way through the transcripts :) On the latest one , 02-daily-use2, line 9, there is the URL: https://audio.video.gnu.org/guix/everyday-use-part1.webm Is this correct? The output in the videos subdirectory is '02-daily- use1.webm' Best regards, Paul.
Re: Video narration
Hi Laura, > If others could test with their own players that may give us clue. > Sure, as many players, the better. I have found that the flickering is caused by the change in aspect ratio as the video moves from the slide view to the screen view (and back). Parole and Videos have a default 'Auto' setting for aspect ratio that re-sets the aspect ratio during playback. If I change to a constant aspect ratio (4:3, for example) the flickering stops. The snag with a constant aspect ratio is that one or other of the views then looks stretched. Padding on the left and right of the screen view might be the best fix. Then the two views could share the same aspect ratio. Is this something that you could look into? Best regards, Paul.
Re: Video narration
Hi Laura, > I have just thought, may you see the transcripts of all the videos, > and arrange them if you find a better way of saying things in native > English, and then I record the CLI session videos and create > subtitles for them? Do you find this workflow fine? Yes, sounds a good plan. I will aim to work through the videos to build each one, then listen to the playback and then edit the transcript at a rate of one-per-day this week. That should mean finishing them all by the end of this week. If you can do the cli sessions as well that would fit in perfectly. I have put back the recording session to next Tuesday 2nd April so that there is a little more time to get everything finished. The question about flickering could take some investigation. Do we know yet whether this is consistent across all players? or are there examples where flickering does not happen? If others could test with their own players that may give us a clue. One other suggestion was to check the codecs. Do the slides and the cli sessions use the same codec? Best regards, Paul.
Re: Video narration
Hi Laura, > Which player are you using? I have tried with Parole (XFCE) and Videos (GNOME). The flicker seems to display something like slide-screen-slide-screen in rapid succession. I would expect a simple slide->screen jump at the beginning of the session and a screen->slide jump at the end. Have you seen this too? Best regards, Paul.
Re: Video narration
Hi Laura, I have updated the transcript for the 03-help video and the changes are ready to view in the repo. Next I have built the 01-installation-from-script video. I notice that there is no sound for the cli sessions. Will you adding transcripts for these? Also, there is a brief flicker in the transition from slide view to screen view. Can anything be done about that? Best regards, Paul.
Re: Video narration
Hi Laura, > I have just pushed the last video. > Please, let me know if everything is fine. 'git pull' and 'git push' are working for me. I have updated the README file as an initial test commit. Please check that you are happy with the changes. Also, I have provisionally booked next Friday 29th March to do the recordings. I will be getting some help from a sound engineer to use the gear in the studio. All being well it should be possible to do all the recordings in one session :) Best regards, Paul.
Re: Video narration
Hi Laura, > I have realized that I have a typo and have to make a minor change in > 04-packaging2, that will affect the audio and of course the > transcript. Just wanted to let you know. Will push it ASAP. Thank you. I will also check through the transcripts and make any slight changes needed to make the narration more-natural-for-me to speak. I will be careful not to alter the timings or meanings. Also, I will have more information on Wednesday about the time slots available for the recording process. Best regards, Paul.
Re: Video narration
Hi Laura, > If you want, you can build them by cloning > git.savannah.gnu.org/git/guix/videos.git. I have cloned the repository and built the first video with: $ ./build-video.sh 03-help This generates 03-help.webm which I can play with Parole, for example. Very nice work! I can see that there is an 'audios' subdirectory with one audio file per svg file. So my task, if I understand correctly, is to move 'audios' to 'audios_laura' and create a new 'audios' subdirectory with new audio files and then re-build. On the question of total speaking time, 03-help.webm is about 4 minutes long. There are six videos, so is 6x4=24mins a reasonable estimate of the total speaking time? Also, are the transcripts available for all the videos? I will need these before I go in to do the recordings. Best regards, Paul.
Re: Request for commit access
Hi Laura, I am looking forward to viewing the videos after I have cloned the repository as a member. Initially, I am not planning to make any changes, just to make an estimate of the total speaking time. I will update on progress and post any questions or comments on the 'Video narration' thread. Best regards, Paul.
Re: Request for commit access
Hi Ludo, > welcome aboard! :-) Great, many thanks. I will use the attached OpenPGP subkey for signing commits. Best regards, Paul. signature.asc Description: This is a digitally signed message part
Request for commit access
Hi Guix, May I request commit access for the Guix repositories? This access would be primarily for maintaining and addding packages in the (gnu packages maths/engineering/simulation) modules. Also, I am preparing to do the narration for the Guix videos. With commit access, I will be able to push the audio files directly to videos.git. I have an account on Savannah and have uploaded my OpenPGP key. Best regards, Paul Garlick.
Re: Video narration
Hi Laura, > I just wanted to ask you if you are still interested in contributing > being the narrator of our videos. Sure. Can you give me a few more details about what is required: i) how many videos are there? ii) are there two types of video, one for command line sessions and one for slides? iii) how big are the files? Best regards, Paul.
Re: Packaging FreeCAD
Hi John, > I have been getting a little stuck building the pyside2 dependencies There has been an effort to package pyside2 for Debian. This has been completed in the last six months. A good place to look for information is https://tracker.debian.org/pkg/pyside2 You can browse the source code and follow the links to the 'debian' directory, which contains the files that govern the packaging process. In general for Debian packages, the 'rules' file is worth reading and the 'patches' directory has the changes to the upstream code. One element that could be important in Guix is an update of patchelf to a recent commit (see 'update-patchelf.patch' in the patches directory). Best regards, Paul.
Re: English Voice Wanted
Hi Laura, > Paul me know if a .srt file is fine. Sure, .srt should be fine. I will find out more details of the recording equipment and the process. Best regards, Paul.
Re: English Voice Wanted
Hi Bjorn, Yes, I can be a candidate. I was born in London and I have a native English voice. Also, I can arrange access to professional recording equipment at the local university. The voiceover could be supplied in the format of your choice (AIFF, WAV, ...). Best regards, Paul.
Re: Packaging FreeCAD
Hi John, > I did not know Debian changed their version of opencascade There are two versions of OpenCASCADE in Debian, named 'liboce' and 'libocct'. 'occt' is the upstream variant, 'oce' is the community maintained variant. Historically, Debian has switched between the two as licence requirements dictated. Currently, both are packaged and FreeCAD version 0.17 depends on liboce. However, libocct is being more actively maintained and I believe the intention for Debian FreeCAD version 0.18 is for the dependency to switch to libocct. Best regards, Paul.
Re: Packaging FreeCAD
Hi John, This is good news indeed for Guix-using engineers and architects. I shall follow developments with interest. I can look after the OpenCASCADE dependency too. This package is due an update but upstream development has been slow of late. Debian have switched to the OCCT version for FreeCAD and I am thinking that it would be best for Guix to follow suit. This would entail the introduction of a new opencascade-occt package, which I plan to do soon, if no-one beats me to it! Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
Hi Ludo, > Or am I missing something? > No, I don't think so. Everything is working again after your bug fix. I have just needed to introduce a couple of concepts in order to use the ./pre-inst-env commands in the git checkout. Firstly, I use a development environment created by: $ guix environment --ad-hoc guile gnutls guile-gcrypt guile-json nss- certs This adds the guile-gcrypt dependency and prevents the 'no code for module (gcrypt hash)' error. Then, for working on a new package ('my-new-package'), I create a new environment: $ ./pre-inst-env guix environment --pure my-new-package --ad-hoc guile- gcrypt Lastly, to build the package I need to define GUILE_LOAD_PATH: $ GUILE_LOAD_PATH=$GUIX_ENVIRONMENT/share/guile/site/2.2 ./pre-inst-env guix build -K my-new-package An alternative would perhaps be to install guile-gcrypt in the user profile (or a separate profile as suggested by Pjotr). Then use GUILE_LOAD_PATH=/home/paul/.guix-profile/share/guile/site/2.2. Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
Hi Pjotr, Thank you. > Guix is built with Guile and Guile has trouble finding the gcrypt > package. Having successfully upgraded my root and user Guix installations I now find that my development installation is unable to locate guile-gcrypt: $ ./pre-inst-env guix --version ERROR: In procedure scm-error: no code for module (gcrypt hash) If I use my root guix profile, in a simlar way to your suggestion, it works: $ sudo GUILE_LOAD_PATH=/root/.guix-profile/share/guile/site/2.2 ./pre- inst-env guix --version guix (GNU Guix) 0.15.0.1558-b0632 Is there a best way to notify the ./pre-inst-env commands about guile- gcrypt? Using sudo seems like the wrong approach. Would installing guile-gcrypt as the development user suffice? Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
Hi Ludo, Success! I have been able to upgrade the root Guix installation. The steps I have taken were: i) remove the 'latest' symlink ii) re-create the symlink to point to the previous installation iii) use 'guix gc --delete' to delete the guile-gcrypt package components iv) run 'GUILE_LOAD_PATH=/root/.guix-profile/share/guile/site/2.2 guix pull' v) run 'GUILE_LOAD_COMPILED_PATH=/gnu/store/3yvsd7w79a8rl42rxfg0xqzh9s14f3si- guile-gcrypt-0.1.0/lib/guile/2.2/site-ccache guix package --upgrade' This time the '... guix pull' command did not generate the ' Failed to autoload make-session in (gnutls)' errors. In retrospect, I think the only missing element from the first attempt was the GUILE_LOAD_PATH variable. The last piece of the jigsaw was setting GUILE_LOAD_COMPILED_PATH so that the gcrypt module could be found. This was required for all of the guix commands that I tried. Now: $ guix package --list-installed guix0.15.0- 3.3d43017out /gnu/store/sa9xj13i0568xajsjh78g3pnlsww8x8g- guix-0.15.0-3.3d43017 ... Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
> > Pushed as 3ffcad7df3ab8947010814f61b32ce14ea80e780, thanks! > Hi Ludo, I tried a 'guix pull' as root and this time it completes. However, there were warnings generated: WARNING: compilation of /gnu/store/38553wfz0jwlgbw13pk99xl79pbfx58d- guile-2.2.3/bin/guild failed and Failed to autoload make-session in (gnutls) I think the GUILE_LOAD_PATH variable needed to be set before running 'guix pull' Now all the guix commands I have tried generate: ERROR: In procedure scm-error: no code for module (gcrypt hash) How best to recover? Ideally I would undo the 'guix pull' and re-do the command with GUILE_LOAD_PATH set. Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
On Wed, 2018-09-05 at 22:58 +0200, Ludovic Courtès wrote: > > Indeed, that may well be the reason. Can you try to apply the patch > below in a local branch, and then run “make as-derivation”? > Hi Ludo, Many thanks. I have applied the patch in a new branch. $ git describe v0.15.0-1390-gca71942 However, 'make as-derivation' is not working yet. Do I need an ad-hoc environment to run this command? So far, I have tried using the system (Centos 7) make but this fails since system guile (v2.0.9) is not installed. Best regards, Paul.
Re: Heads-up: New dependency on Guile-Gcrypt
Hi Ludo, > ‘guix pull’ will happily perform the transition. For me, I have an older Guix (16th May) that fails to install guile- gcrypt. As root: $ guix --version guix (GNU Guix) 6f84dc4314cd84550d9fc7e7afa11c495edc45a5 When I try 'guix pull' there is an attempt to build guile-gcrypt locally that fails with the message './configure: No such file or directory'. I can see that the build procedure moves from the 'unpack' phase straight to the 'patch-usr-bin-file' phase with no 'bootstrap' phase in between. Aha, another chicken-and-egg, I thought; my older Guix does not have a 'bootstrap' phase. However, I can see that the commit for adding the new phase was made on 11th March, so perhaps 'guix pull' is failing for a different reason. Maybe there is a workaround for this scenario. WDYT? Best regards, Paul.
Re: [PATCH] gnu: Add openfoam
Hello Ludo, > I think it might make sense to create a new “simulation” module, and > eventually move OpenCascade there as well, WDYT? > Sure. I will create a new module and put the OpenFOAM package definition in there as the first one. > Some comments: > > > > > > +(build-system trivial-build-system) > > > > > Did you consider using ‘gnu-build-system’? I think this would save > quite a few lines corresponding to the initial setup (set-paths, unpack, > patch-shebang, etc.), and also ensure that the final phases (strip, > compress-documentation, etc.) are run. In addition you wouldn’t need to > list all the usual build inputs (GCC, Coreutils, Make, etc.). WDYT? > I did consider both options, removing and modifying stages in the gnu- build-system or starting from scratch with the trivial-build-system. I can give the gnu-build-system option a go, reverting to the trivial- build-system if the new attempt proves too troublesome. One aspect I will need to investigate in the gnu-build-system is using the "./Allwmake" command to trigger the build process. In OpenFOAM, wmake is short for "wrapped-make" and the package has its own configuration step. In brief, it has its own sequence and does not follow the standard "./configure && make && make install" steps. Using the trivial-build-system the patch-shebang section is indeed a little extended. I found this was necessary to avoid a failure of the patch-shebang command using a simple 'find-files "."' from top-level directory. There is a scenario where sub-directories named '0', in the 'tutorials' directory, identified by the find-files command, being passed to 'patch-shebang', which should only receive files, not directories. This causes 'patch-shebang' to stop and the build fails. > > > > + ) > > +) > > + ) > > + ) > > > > > Please listen to what ‘guix lint’ has to say about these. :-) > Interestingly, 'guix lint' let me get away with this without making comment. However, I shall condense things accordingly in the new patch. > What about wrapping the resulting binaries so that they have > ‘FOAM_INST_DIR’ set to %output? > > In fact, FOAM_INST_DIR is used in multiple places to navigate around the installed files (not just the binaries), so I think this variable may need to remain available as is. > > You could make it “if true”, thereby avoiding the need to define > $READLINE_ROOT. > > Could you elaborate on this idea a little? At the moment the test is "if file exists". > Could you send an updated patch to guix-patc...@gnu.org, where it will > , where it will > be visible in the patch tracker? > > > Aha, a new system! Best, Paul.
[PATCH] gnu: Add openfoam
tch)) +(setenv "METISVERSION" ,(package-version metis)) +;; set environment variables to define library paths +(map (lambda (library) + (setenv (string-append + (string-upcase library) "_ROOT") + (assoc-ref %build-inputs library))) libraries) +(setenv "LIBRARY_PATH" (string-append + (getenv "GLIBC_ROOT") "/lib" ":" + (getenv "ZLIB_ROOT") "/lib")) +;; set environment variables to define header paths +(setenv "CPATH" (string-append + (getenv "LINUX-LIBRE-HEADERS_ROOT") + "/include")) +(setenv "CPLUS_INCLUDE_PATH" (string-append + (getenv "METIS_ROOT") "/include" ":" + (getenv "FLEX_ROOT") "/include" ":" + (getenv "ZLIB_ROOT") "/include")) +;; compile OpenFOAM libraries and applications +(system (format #f "source ./etc/bashrc && ./Allwmake -j~a" + (parallel-job-count))) +;; update configuration files +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$CGAL_ROOT" "etc/config.sh/CGAL")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$BOOST_ROOT" "etc/config.sh/CGAL")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$METIS_ROOT" "etc/config.sh/metis")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$METISVERSION" "etc/config.sh/metis")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$SCOTCH_ROOT" "etc/config.sh/scotch")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$SCOTCHVERSION" "etc/config.sh/scotch")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$GMP_ROOT" "etc/config.sh/settings")) +(system (format #f "sed -i 's|~a|'~:*~s'|' ~a" + "$MPFR_ROOT" "etc/config.sh/settings")) +;; set write permission on tutorial files +(system (format #f "chmod -R u+w ~a" "tutorials")) +;; create install directory +(mkdir-p install-dir) +;; move contents of build directory to install directory +(copy-recursively "." install-dir) + ) +) + ) + ) +(native-search-paths + ;; define the FOAM_INST_DIR variable + (list (search-path-specification +(variable "FOAM_INST_DIR") +(files '(".") +(synopsis "Framework for numerical simulation of fluid flow") +(description "OpenFOAM provides a set of solvers and methods for tackling +problems in the field of Computational Fluid Dynamics (CFD). It is written in +C++. Discrete versions of governing equations such as the Navier-Stokes +equations can be solved in integral form. OpenFOAM implements the Finite +Volume Method for discretizing the spacial dimensions. Grids are accepted that +define complex geometries in two- and three-dimensional domains. Grids may be +unstructured in layout and may contain any combination of polyhedral cells. +Large problems can be split into connected smaller problems for efficient +solution on parallel systems") +(license license:gpl3+) +(home-page "https://openfoam.org";))) + (define-public maxflow (package (name "maxflow") diff --git a/gnu/packages/patches/openfoam-cleanup.patch b/gnu/packages/patches/openfoam-cleanup.patch new file mode 100644 index 0..e7760b7a5 --- /dev/null +++ b/gnu/packages/patches/openfoam-cleanup.patch @@ -0,0 +1,267 @@ +# This patch removes all need for the ThirdParty files of OpenFOAM + +# Derived from easybuild patch: Ward Poelm
[PATCH] gnu: gmsh: Add opencascade-oce to propagated-inputs
* gnu/packages/maths.scm (gmsh) [propagated-inputs]: Add opencascade-oce [arguments]: Remove #:phases parameter for component8_in_a_box test --- gnu/packages/maths.scm | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index d479472..c3cedbb 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -1035,6 +1035,7 @@ Open CASCADE library.") ("lapack" ,lapack) ("mesa" ,mesa) ("glu" ,glu) + ("opencascade-oce" ,opencascade-oce) ("libx11" ,libx11) ("libxext" ,libxext))) (inputs @@ -1043,15 +1044,7 @@ Open CASCADE library.") (arguments `(#:configure-flags `("-DENABLE_METIS:BOOL=OFF" "-DENABLE_BUILD_SHARED:BOOL=ON" - "-DENABLE_BUILD_DYNAMIC:BOOL=ON") - #:phases (modify-phases %standard-phases - (replace - 'check - (lambda _ - (zero? (system* "make" "test" - ;; Disable this test. See - ;; https://geuz.org/trac/gmsh/ticket/271 - "ARGS=-E component8_in_a_box"))) + "-DENABLE_BUILD_DYNAMIC:BOOL=ON"))) (home-page "http://www.geuz.org/gmsh/";) (synopsis "3D finite element grid generator") (description "Gmsh is a 3D finite element grid generator with a built-in -- 2.7.4
[PATCH] gnu: gmsh: Update to 2.16.0
* gnu/packages/maths.scm (gmsh): Update to 2.16.0 --- gnu/packages/maths.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 11b8181..d479472 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -1014,14 +1014,14 @@ Open CASCADE library.") (define-public gmsh (package (name "gmsh") -(version "2.15.0") +(version "2.16.0") (source (origin (method url-fetch) (uri (string-append "http://gmsh.info/src/gmsh-"; version "-source.tgz")) (sha256 - (base32 "02h7fk4vv8qwnq3ymm409c5sp4nksd0m9h2vkxqmy42l0ic4nalr")) + (base32 "1slf0bfkwrcgn6296wb4qhbk4ahz6i4wfb10hnim08x05vrylag8")) (modules '((guix build utils))) (snippet ;; Remove non-free METIS code -- 2.7.4
[PATCH] fix test-skip typo
--- tests/syscalls.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/syscalls.scm b/tests/syscalls.scm index 92e02f3..1934704 100644 --- a/tests/syscalls.scm +++ b/tests/syscalls.scm @@ -456,7 +456,7 @@ (eof-object? (read-utmpx (%make-void-port "r" (unless (access? "/var/run/utmpx" O_RDONLY) - (tes-skip 1)) + (test-skip 1)) (test-assert "read-utmpx" (let ((result (call-with-input-file "/var/run/utmpx" read-utmpx))) (or (utmpx? result) (eof-object? result -- 2.7.4
Re: [PATCH] gnu: Add opencascade-oce
On Sat, 2017-01-21 at 16:13 +0100, Ludovic Courtès wrote: > Marius Bakke skribis: > > > > > Paul Garlick writes: > [...] > > > > > Libtool and file should likely be native-inputs, not sure about the > > others. Could you check whether they are required and send an > > updated > > patch? > ‘file’ is already an implicit input, so I’m not why it needs to be > added > (perhaps OpenCascade depends on libmagic?). > > As for Libtool, I wonder why it is needed at all, especially given > that > OpenCascade is built with CMake. > > Ludo’. Hi Marius and Ludo, Thank you for your comments. I have checked the dependencies and here are the results: ftgl: not needed qt: not needed libtool: not needed file: not needed tcl: required by the DRAW test harness tk: required by the DRAW test harness I have amended the patch to remove the extra dependencies. The public domain licence information is now included. Also, there is an extra configuration flag required to successfully build the DRAW libraries and executable. The '-UCMAKE_INSTALL_RPATH' flag is required for the validate-runpath stage to succeed. This is to do with the way the global variable is initialized. There is a distinction in CMake between lists and strings, which was new to me so I will document it here. Essentially, if a variable is initialized as a single string it cannot subsequently be overriden by a list of strings. The cmake instructions in OpenCascade (in adm/cmake/BuildToolKit.cmake) attempt to do this at the install stage. The DRAW harness needs a RUNPATH including both .../lib and .../lib/oce-0.17. With the standard definition of CMAKE_INSTALL_RPATH (from cmake-build-system.scm) the substitution of the INSTALL_RPATH property only includes the first string. Consequently, the validate-runpath phase fails (error: library ... not in RUNPATH ...). The configuration flag -UCMAKE_INSTALL_RPATH unsets the global variable and allows the opencascade cmake rules to do the work instead, setting the RUNPATH correctly for each target. On the subject of the 0.18 version, perhaps this could be the subject of a separate patch. There could be an argument to just update in the normal way (instead of having two packages at once). The issue is related to the hardware requirements of recent versions of OpenGL. It is useful to start with 0.17 as this imposes the least restriction on older graphics card. I can do some testing on the new version, later on, to determine how important this is. The amended patch is attached. Best, Paul. From a5f64ac9b488249027fc92c46d737d4572e57d02 Mon Sep 17 00:00:00 2001 From: Paul Garlick Date: Wed, 18 Jan 2017 10:01:36 + Subject: [PATCH] gnu: Add opencascade-oce * gnu/packages/maths.scm: Add opencascade-oce --- gnu/packages/maths.scm | 48 1 file changed, 48 insertions(+) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 313f6ac..c8e280f 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -15,6 +15,7 @@ ;;; Copyright © 2016 Ludovic Courtès ;;; Copyright © 2016 Leo Famulari ;;; Copyright © 2016 Thomas Danckaert +;;; Copyright © 2017 Paul Garlick ;;; ;;; This file is part of GNU Guix. ;;; @@ -956,6 +957,53 @@ Work may be performed both at the interactive command-line as well as via script files.") (license license:gpl3+))) +(define-public opencascade-oce + (package +(name "opencascade-oce") +(version "0.17.2") +(source + (origin +(method url-fetch) +(uri (string-append + "https://github.com/tpaviot/oce/archive/OCE-"; + version + ".tar.gz")) +(sha256 + (base32 +"0vpmnb0k5y2f7lpmwx9pg9yfq24zjvnsak5alzacncfm1hv9b6cd" +(build-system cmake-build-system) +(arguments + '(#:configure-flags +(list "-DOCE_TESTING:BOOL=ON" + "-DOCE_USE_TCL_TEST_FRAMEWORK:BOOL=ON" + "-DOCE_DRAW:BOOL=ON" + (string-append "-DOCE_INSTALL_PREFIX:PATH=" +(assoc-ref %outputs "out")) + "-UCMAKE_INSTALL_RPATH"))) +(inputs + `(("freetype" ,freetype) +("glu" ,glu) +("libxmu" ,libxmu) +("mesa" ,mesa) +("tcl" ,tcl) +("tk" ,tk))) +(native-inputs + `(("python" ,python-wrapper))) +(home-page "https://github.com/tpaviot/oce";) +(synopsis + "Libraries for 3D modeling and numerical simulation") +(description "OCE stands for Open CASCADE Community Edition. The project +gathers patches/improvements/experiments contributed by users over the official +Open CASCADE libr
[PATCH] gnu: Add opencascade-oce
* gnu/packages/maths.scm: Add it --- gnu/packages/maths.scm | 49 + 1 file changed, 49 insertions(+) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 313f6ac..62415e7 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -15,6 +15,7 @@ ;;; Copyright © 2016 Ludovic Courtès ;;; Copyright © 2016 Leo Famulari ;;; Copyright © 2016 Thomas Danckaert +;;; Copyright © 2017 Paul Garlick ;;; ;;; This file is part of GNU Guix. ;;; @@ -43,6 +44,7 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system r) #:use-module (gnu packages algebra) + #:use-module (gnu packages autotools) #:use-module (gnu packages bison) #:use-module (gnu packages boost) #:use-module (gnu packages check) @@ -52,6 +54,7 @@ #:use-module (gnu packages cyrus-sasl) #:use-module (gnu packages documentation) #:use-module (gnu packages elf) + #:use-module (gnu packages file) #:use-module (gnu packages flex) #:use-module (gnu packages fltk) #:use-module (gnu packages fontutils) @@ -78,6 +81,7 @@ #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages qt) #:use-module (gnu packages readline) #:use-module (gnu packages tbb) #:use-module (gnu packages shells) @@ -2843,3 +2847,48 @@ instruction sets. Thus, an application written with Vc can be compiled for: @end enumerate\n") (home-page "https://github.com/VcDevel/Vc";) (license license:bsd-3))) + +(define-public opencascade-oce + (package +(name "opencascade-oce") +(version "0.17.2") +(source + (origin +(method url-fetch) +(uri (string-append + "https://github.com/tpaviot/oce/archive/OCE-"; + version + ".tar.gz")) +(sha256 + (base32 +"0vpmnb0k5y2f7lpmwx9pg9yfq24zjvnsak5alzacncfm1hv9b6cd" +(build-system cmake-build-system) +(arguments + '(#:configure-flags +(list "-DOCE_TESTING:BOOL=ON" + (string-append "-DOCE_INSTALL_PREFIX:PATH=" +(assoc-ref %outputs "out") +(inputs + `(("freetype" ,freetype) +("ftgl" ,ftgl) +("glu" ,glu) +("qt" ,qt) +("libtool" ,libtool) +("libxmu" ,libxmu) +("file" ,file) +("tk" ,tk) +("tcl" ,tcl) +("mesa" ,mesa))) +(native-inputs + `(("python" ,python-wrapper))) +(home-page "https://github.com/tpaviot/oce";) +(synopsis + "Libraries for 3D modeling and numerical simulation") +(description "OCE stands for Open CASCADE Community Edition. The project +gathers patches/improvements/experiments contributed by users over the official +Open CASCADE library.") +(license (list license:lgpl2.1; OCE libraries, with an exception for the + ; use of header files; see + ; OCCT_LGPL_EXCEPTION.txt + license:expat; file src/OpenGl/OpenGl_glext.h + license:bsd-3; test framework gtest -- 2.7.4
Re: [PATCH] gnu: Add opencascade-oce
Hello Marius, Thank you for your review. > I wonder if this could fit in "engineering.scm". Or maybe > "geometry.scm" > or "3d.scm". We try to avoid "single program" modules. What do you > think? Perhaps maths.scm is the best place, in order to avoid creating a new module. The Gmsh package is already there. To check; am I right in saying that a library in one module can be used as an input for a package in another module? For example, if FreeCAD were to be packaged, and placed in engineering.scm, could it use opencascade-oce as an input from maths.scm? > > > > +(define-public opencascade-oce > > + (package > > +(name "opencascade-oce") > > +(version "0.17.2") > > > > > Version 0.18 was released a few days ago! > It would be useful to package both versions. There is a difference in the OpenGL graphics card requirements in going from version 0.17.2 to 0.18. > > > > +(license license:lgpl2.1))) ; plus header files exception > > > > > Please expand on the exception comment and mention > OCCT_LGPL_EXCEPTION.txt. There are also some public domain files, and > the bundled "gtest" is bsd-3. src/OpenGl/OpenGl_glext.h is distributed > under the expat license. Some files generated by "bison" has GPL3+. > I have added the information about the expat and BSD-3 licenses. Can you elaborate on the public domain files and Bison? Best, Paul.
[PATCH] gnu: Add opencascade-oce
* gnu/packages/opencascade.scm: New file * gnu/local.mk (GNU_SYSTEM_MODULES): Add it --- The OpenCASCADE library is used for defining 3D geometry. It can be incorporated as a build option in other packages. Examples of such packages (and the subject domains in which they are used) are Gmsh (mathematics), IfcOpenShell (architecture) and FreeCAD (engineering). There are two versions of OpenCASCADE; the upstream version and the community- maintained version. OCE is the community-maintained version. gnu/local.mk | 1 + gnu/packages/opencascade.scm | 75 2 files changed, 76 insertions(+) create mode 100644 gnu/packages/opencascade.scm diff --git a/gnu/local.mk b/gnu/local.mk index c6cb55b..c879f32 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -281,6 +281,7 @@ GNU_SYSTEM_MODULES =\ %D%/packages/ocr.scm \ %D%/packages/onc-rpc.scm \ %D%/packages/openbox.scm \ + %D%/packages/opencascade.scm \ %D%/packages/openldap.scm\ %D%/packages/openstack.scm \ %D%/packages/orpheus.scm \ diff --git a/gnu/packages/opencascade.scm b/gnu/packages/opencascade.scm new file mode 100644 index 000..3c4b9b5 --- /dev/null +++ b/gnu/packages/opencascade.scm @@ -0,0 +1,75 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2017 Paul Garlick +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. + +(define-module (gnu packages opencascade) + #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix packages) + #:use-module (guix download) + #:use-module (guix build-system cmake) + #:use-module (gnu packages) + #:use-module (gnu packages autotools) + #:use-module (gnu packages file) + #:use-module (gnu packages fontutils) + #:use-module (gnu packages gl) + #:use-module (gnu packages python) + #:use-module (gnu packages qt) + #:use-module (gnu packages tcl) + #:use-module (gnu packages xorg)) + +(define-public opencascade-oce + (package +(name "opencascade-oce") +(version "0.17.2") +(source + (origin +(method url-fetch) +(uri (string-append + "https://github.com/tpaviot/oce/archive/OCE-"; + version + ".tar.gz")) +(sha256 + (base32 +"0vpmnb0k5y2f7lpmwx9pg9yfq24zjvnsak5alzacncfm1hv9b6cd" +(build-system cmake-build-system) +(arguments + '(#:configure-flags +(list + (string-append +"-DOCE_INSTALL_PREFIX:PATH=" (assoc-ref %outputs "out")) + "-DOCE_TESTING:BOOL=ON") + #:tests? #t)) +(inputs + `(("freetype" ,freetype) +("ftgl" ,ftgl) +("glu" ,glu) +("qt" ,qt) +("libtool" ,libtool) +("libxmu" ,libxmu) +("file" ,file) +("tk" ,tk) +("tcl" ,tcl) +("mesa" ,mesa))) +(native-inputs + `(("python" ,python-wrapper))) +(home-page "http://www.opencascade.org/";) +(synopsis + "Open CASCADE OCE; libraries for 3D modeling and numerical simulation") +(description "OCE stands for Open CASCADE Community Edition. The project +gathers patches/improvements/experiments contributed by users over the official +Open CASCADE library.") +(license license:lgpl2.1))) ; plus header files exception -- 2.7.4
[PATCH] gnu: gmsh: Update to 2.15.0
* gnu/packages/maths.scm (gmsh): Update to 2.15.0 --- gnu/packages/maths.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index fc98eae..313f6ac 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -959,14 +959,14 @@ script files.") (define-public gmsh (package (name "gmsh") -(version "2.14.1") +(version "2.15.0") (source (origin (method url-fetch) (uri (string-append "http://gmsh.info/src/gmsh-"; version "-source.tgz")) (sha256 - (base32 "1vsxp47j6srmy8kqb3p1z9pmlm42whhhz7r0vzpa2a86gga4zx17")) + (base32 "02h7fk4vv8qwnq3ymm409c5sp4nksd0m9h2vkxqmy42l0ic4nalr")) (modules '((guix build utils))) (snippet ;; Remove non-free METIS code -- 2.7.4
[PATCH] gnu: gmsh: Update to 2.14.1
* gnu/packages/maths.scm (gmsh): Update version, hash and uri --- gnu/packages/maths.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 64e53e2..c9792a1 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -949,14 +949,14 @@ script files.") (define-public gmsh (package (name "gmsh") -(version "2.11.0") +(version "2.14.1") (source (origin (method url-fetch) - (uri (string-append "http://www.geuz.org/gmsh/src/gmsh-"; + (uri (string-append "http://gmsh.info/src/gmsh-"; version "-source.tgz")) (sha256 - (base32 "1ilplibvjgf7a905grpnclrvkmqy9fgrpl7xyp3w4yl1qc682v9b")) + (base32 "1vsxp47j6srmy8kqb3p1z9pmlm42whhhz7r0vzpa2a86gga4zx17")) (modules '((guix build utils))) (snippet ;; Remove non-free METIS code -- 2.7.4