Skip to content

Support multiple compilers side-by-side in build #66

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
LKedward opened this issue Apr 29, 2020 · 2 comments
Closed

Support multiple compilers side-by-side in build #66

LKedward opened this issue Apr 29, 2020 · 2 comments

Comments

@LKedward
Copy link
Member

Currently compiled binaries are placed in build/debug/ and build/release.
Would it be possible to make this build path dependent on compiler (and maybe architecture)?

e.g. build/gfortran-9.2.0-x86_64_debug/

This reason for this being that I like to build and test my projects on multiple compilers during development; separating the binary output paths allows incremental builds using multiple compilers and allows tests on each compiler to run simultaneously and without clean and rebuild.
This may be considered an 'ugly' directory structure, however since fpm handles all compiler/linker paths and offers the fpm run command, this has no effect on end-user experience.

The workflow for using a non-default compiler could then be along the lines of:

$> export FC=ifort
$> fpm run

or

$> FC=ifort fpm run

or

$> fpm run --compiler=ifort
@everythingfunctional
Copy link
Member

Yeah, this shouldn't be too difficult. Good idea.

@awvwgk
Copy link
Member

awvwgk commented Dec 9, 2020

This has been resolved with #255 in Fortran fpm and #220 in the Haskell version.

@awvwgk awvwgk closed this as completed Dec 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants