large project for testing #395
urbanjost
started this conversation in
Show and tell
Replies: 1 comment 2 replies
-
Great stuff @urbanjost! I'll be using this as a performance metric for fpm among other things. Over 2000 objects to build! ~/git/fpm_packages/general-purpose-fortran$ fpm build --list 2>&1|wc -l
2165 I ran into a few problems when building in parallel which I think are down to there being multiple module definitions called Also |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
For testing I put GPF in the form of an
fpm
project; as it has a lot of files; so it tests things typical packages might not. Thought I would mention it in case anyone else wants an atypical test package to play with.I have tried that a few times before but this time it worked, and worked well with a few limitations.
In the past there were problems with building C, with the time it took to scan for a rebuild with a
run
ortest
command, and so on when I tried that. Terrific improvement in speed since the last test It requires having several packages installed to build but if anyone wants a test case with hundreds of files in it to test with there it is. Requires a POSIX system. Requires several commonly available libraries (see the apt-get list on the github page if interested). With those restrictions it worked really well!Just half-formed ideas from using GPF as a test so far ...
should there be an equivalent of "make -k" that keeps going on a build and builds as much as possible?
gfortran will pass C code as well as Fortran, but a lot of compilers will not. Do we need to specify a C compiler and defaults for the Fortran compilers we have listed as well,
or maybe a list of compilers with associated file suffixes? That is, if I specify "-compiler ifort" should it automatically select the C C++ coprocessors for ifort and options; or should there be a --c_compiler option; or something like
--compiler "ifort:.f,f90 icc:.c bash:.sh" or some other scheme? Some of that has come up before; but right now I have to
hack some odd scripts together to use fpm to build Fortran/C with compilers that will not cross-compile multiple languages.
Should we be thinking of making a generic "compile" command that handles different compilers? I mention that because in my own environment I use a ccall(1) command that looks to determine what system it is on via uname and some other commands and what compilers are available (which can all be overridden by environment variables) and then using the file suffix builds or installs a file (*.f, *.f90, *.man, *.[1-8], *.c, *.cc, *.md, ...). that has worked well for me for a long time. A generic compile command as a separate utility would free the core fpm machine up from having to know programming-environment-specific information to a large degree.
That works
now in a fashion for
fpm
if you create a command called "mycompiler" in your path and use "fpm --compiler mycompiler", assuming your script can handle some common compiler switches. Sort of like the Cygwin "cygstart" command or (depending on the system) "start", "open", ... except just for compiling, loading, installing and translating.run
andtest
to not do a rebuild (in earlier versions only an explicitbuild
did a build anyway; then I was convinced it was needed due to speed; now with a decent sized build it seems amazingly good at doing the check all the time -- nice).fpm
easily to only build certain files or only build from a certain directory if my OS type were MSWindows or Solaris, for example. If using preprocessing it would be nice if the compilers were passed the equivalent ofI also tried hookingthis test package up to
ford
but I have a few non-ANSI and/or unicode characters in there that seem to crash it; and some non-ford non-doxygen comments that are coincidentally already in "ford-context" so I did not get too far; but plan on taking a second swipe at that.Beta Was this translation helpful? Give feedback.
All reactions