-
Notifications
You must be signed in to change notification settings - Fork 701
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
cabal install silently ignores --enable-profiling flags. #8529
Comments
Indeed, |
This should be fixed by #9697. |
alt-romes
added a commit
to alt-romes/cabal
that referenced
this issue
Feb 6, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
alt-romes
added a commit
to alt-romes/cabal
that referenced
this issue
Feb 6, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
mpickering
pushed a commit
to alt-romes/cabal
that referenced
this issue
Feb 6, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
Mikolaj
pushed a commit
to alt-romes/cabal
that referenced
this issue
Feb 9, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
alt-romes
added a commit
to alt-romes/cabal
that referenced
this issue
Feb 9, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
alt-romes
added a commit
to alt-romes/cabal
that referenced
this issue
Feb 9, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
Fixed by #9697 |
erikd
pushed a commit
to erikd/cabal
that referenced
this issue
Apr 22, 2024
The target of `cabal install` is not considered to be a local package, which means local configuration (e.g. in cabal.project, or flags like --enable-profiling) does not apply to it. In 76670eb, we changed the behaviour to applying the local flags to cabal install targets, but it used the literal target string as a package name to which the flags were additionally applied. However, `cabal install` targets are NOT necessarily package names, so, e.g., if we did `cabal install exe:mycomp`, the local flags would not apply since "exe:mycomp" is not a recognized /package/. The solution is to parse the target selectors first, and apply the local flags to the package of the resolved targets. Fixes haskell#7297, haskell#8909, the install part of haskell#7236, haskell#8529, haskell#7832
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
TLDR
Installing a profiled version of an executable seems to be not supported.
Instead cabal seems to silently swallow the flag.
To Reproduce
This does install a non-profiled version of the executable.
I can build a profiled version of a package by running cabal build and copying over, but that seems unneccesary.
Expected behavior
I would have expected cabal to install a profiled version of the program if I ask it to. In absence of that I would at least expect it to complain about the flag being ignored/incompatible with install.
But I don't think there is a good reason to have profiling not work with the install command.
System information
cabal
,ghc
versions: HEAD/9.4.2Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: