Conversation
Needs rebased on master. |
Oops, sorry, thought I just forked, but I guess I had an old fork. Rebased now. |
|
||
depends_on :postgresql | ||
depends_on :cpanminus |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no symbol version of this dependency
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed, thanks!
Hrm, looking at this failure and wondering if it worked before. |
ENV.remove_from_cflags(/-msse\d?/) | ||
|
||
# Install TAP::Parser::SourceHandler::pgTAP. | ||
system "cpanm --local-lib '#{prefix}' --notest TAP::Parser::SourceHandler::pgTAP" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this interact with ~/.cpan
at all?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it will leave files in ~/.cpan
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can't modify the home directory during installation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hrm. Should I add a line to rm -rf ~/.cpan
? How does one usually install CPAN modules? @miyagawa, is there a cpanm flag to use a different directory? I couldn't find anything in a quick scan of the man page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See clipsafe.rb
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah ha! Switched to that approach in eaef0db. Wouldn't want to do that for something like Sqitch, which requires a shitload of modules, but for this narrow case, I think it makes a lot of sense. Thanks!
We still have this issue:
What are the permissions used by the Postgres build? Did this work for previous versions of pgTAP? Do we need to do |
I would guess there's a hardcoded path that needs fixed. |
Hrm. I have postgresql-9.2.3 installed. I ran the build on my box and it worked. The Perl stuff was included in |
There's no issue on the test host; it does a clean install every time. |
The non-server edition of OS X includes a postgres client (but not a server), which includes a |
Hey @mistydemeo. Hrm. Maybe this line doesn't do what I think it should?
|
Nope, that looks right. Drop in a |
Hrm. The scripts are not getting linked, either. That is, these three apps:
Do I need to do something else to tell brew to link those? |
Those are in libexec, which is usually not exposed publicly. |
Oh. So should I use |
On my box, |
Might as well, just to see what the bot is picking up. |
Wait, I see here: looks like it's picking up on a postgres in |
Ping @MikeMcQuaid - are the bots running OS X server? |
One of them has it installed. |
Yeah, this failure clearly shows that it is not picking up the right pg_config, even with the path prepend. WTF? I can pass |
Oh-ho! I switched to this:
And now get this complaint:
This is because I have 9.2 installed, not 9.3. So getting the bin dir from the postgresql formula is not reliable. Should I just use |
Use: pg_config = Formula.factory('postgresql').opt_prefix/'bin/pg_config' (The path objects you return from Formula instances are Pathname objects, which support concatenation using the |
Okay, c818ec2 should get it right! |
Also need to figure out how to get Test::Harness linked up before building TAP::Parser::SourceHandler::pgTAP, on which it depends. |
Oh, of course. This is a consequence of the symbol-form |
Rather than using cpanm. Idea borrowed from `clipsafe.rb`, with thanks to @MikeMcQuaid for the pointer.
So that the apps (prove, pg_prove, pg_tapgen) will be properly linked.
Because the latter allows the system postgres, but we cannot install into its directories.
The reason for setting $PERL5LIB is so that, when TAP::Parser::SourceHandler::pgTAP is built, it can find Test::Harness, which will have been built, but not yet symlinked.
Rebased. |
Closes Homebrew#25903. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
First commit updates pgTAP to v0.94.0. Second adds a method that installs pg_prove from CPAN, which simplifies the running of pgTAP tests.