Skip Menu |

This queue is for tickets about the Finance-TA CPAN distribution.

Report information
The Basics
Id: 70858
Status: resolved
Priority: 0/
Queue: Finance-TA

People
Owner: Nobody in particular
Requestors: chrisfluur [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Finance::TA won't install mac OSX
Date: Sat, 10 Sep 2011 02:45:44 -0500
To: bug-Finance-TA [...] rt.cpan.org
From: Chris Fluur <chrisfluur [...] gmail.com>

Message body is not shown because it is too large.

Message body is not shown because it is too large.

Hi Chris,

could you please check the version of your ta-lib installed via macports?

ta-lib v0.4.0 is required for the latest Finance::TA

--
kmx

Subject: Re: [rt.cpan.org #70858] Finance::TA won't install mac OSX
Date: Sat, 10 Sep 2011 09:58:27 -0500
To: bug-Finance-TA [...] rt.cpan.org
From: Chris Fluur <chrisfluur [...] gmail.com>
port info !$ port info ta-lib ta-lib @0.4.0 (finance) Variants: (+)universal Description: TA-Lib provides common functions for the technical analysis of financial market data, including more than 150 indicators such as ADX, MACD, RSI, Stochastic, Bollinger Bands and more. Homepage: http://ta-lib.org Platforms: darwin License: unknown Maintainers: cedstrom@gmail.com On Sat, Sep 10, 2011 at 8:00 AM, kmx via RT <bug-Finance-TA@rt.cpan.org>wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=70858 > > > Hi Chris, > > could you please check the version of your ta-lib installed via macports? > > ta-lib v0.4.0 is required for the latest Finance::TA > > -- > kmx > >
So:
- TA::Finance builds (compiles+links) OK
- ta-lib version is OK
- TA::Finance fails during 'make test'

My guess is that ta-lib related *.dylib file in /opt/local/lib cannot be loaded/found for some reason.

To be honest I have nearly zero experience with macosx - via google I have found kind of a hack using DYLD_FALLBACK_LIBRARY_PATH env variable or some dark magic with install_name_tool. But I am not sure how it can help to solve this issue.

--
kmx

Subject: Re: [rt.cpan.org #70858] Finance::TA won't install mac OSX
Date: Sat, 10 Sep 2011 23:34:59 -0500
To: bug-Finance-TA [...] rt.cpan.org
From: Chris Fluur <chrisfluur [...] gmail.com>
Okay, that's fine - I will just wait to install it. I'm getting the procs for my linux box on Monday. Thank you ! On Sat, Sep 10, 2011 at 1:25 PM, kmx via RT <bug-Finance-TA@rt.cpan.org>wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=70858 > > > So: > - TA::Finance builds (compiles+links) OK > - ta-lib version is OK > - TA::Finance fails during 'make test' > > My guess is that ta-lib related *.dylib file in /opt/local/lib cannot be > loaded/found for some reason. > > To be honest I have nearly zero experience with macosx - via google I have > found kind of a hack using DYLD_FALLBACK_LIBRARY_PATH env variable or some > dark > magic with install_name_tool. But I am not sure how it can help to solve > this > issue. > > -- > kmx > >
Subject: Re: [rt.cpan.org #70858] Finance::TA won't install mac OSX
Date: Sun, 11 Sep 2011 21:50:57 +0200
To: bug-Finance-TA [...] rt.cpan.org
From: kmx <karel.miko [...] gmail.com>
Show quoted text
> Then I tried manual compile. The variables $prefix and $exec_prefix in > ta-lib-config were populating with zero-length strings (blank). So I just > wrote-in what I think are the locations of my include files and lib files. > Now I see: > > ta-lib-config --cflags > -I/opt/local/include/ta-lib -DHAVE_CONFIG_H > > ta-lib-config --libs > -L/opt/local/lib -L/usr/local/lib -L/usr/lib -L/usr/X11/lib -lpthread -ldl >
BEWARE: --libs output is still wrong, it should be something like this: -L/opt/local/lib -lta_lib -lpthread -ldl Grrr, ta-lib-config is terribly broken :( -- lmx
Subject: Re: [rt.cpan.org #70858] Finance::TA won't install mac OSX
Date: Sun, 11 Sep 2011 22:06:50 +0200
To: bug-Finance-TA [...] rt.cpan.org
From: kmx <karel.miko [...] gmail.com>
I have noticed in your build log that you probably have 2 perls on your MacOSX box: /opt/local/bin/perl (v5.12.x) maybe from macports /usr/bin/perl (v5.10.x) the original macosx perl Which might be a trouble. Test please: 1/ fix ta-lib-config as mentioned in previous post (add -lta_lib to --libs) 2/ run: sudo cpan 3/ from cpan prompt run: look Finance::TA 4/ perl Makefile.PL 5/ make 6/ prove -bv t/ta_common.t If you see something like this: /# Running under perl version 5.012003 for darwin # Current time local: Sun Sep 11 13:00:07 2011 # Current time GMT: Sun Sep 11 20:00:07 2011 # Using Test.pm version 1.25_02 dyld: lazy symbol binding failed: Symbol not found: _Perl_Gthr_key_ptr Referenced from: /Users/bob/.cpan/build/Finance-TA-v0.4.0-ehwbUX/blib/arch/auto/Finance/TA/TA.bundle Expected in: flat namespace dyld: Symbol not found: _Perl_Gthr_key_ptr Referenced from: /Users/bob/.cpan/build/Finance-TA-v0.4.0-ehwbUX/blib/arch/auto/Finance/TA/TA.bundle Expected in: flat namespace/ then the trouble is in mixing different versions of perl 7/ to confirm my guess from point 6/ try to run: /usr/bin/perl -Mblib t/ta_common.t You should see something like this: # Running under perl version 5.010000 for darwin # Current time local: Sun Sep 11 13:03:25 2011 # Current time GMT: Sun Sep 11 20:03:25 2011 # Using Test.pm version 1.25 TA-Lib 0.4.0 (Sep 11 2011 12:09:35) Testing ta_common... ok 1 ok 2 ok 3 ok 4 ok 5 ok 6 Testing TA_SetRetCodeInfo()... ok 7 ok 8 ok 9 ok 10 ok 11 ok 12 Testing TA_Initialize and TA_Shutdown... ok 13 ok 14 ok 15 ok 16 ok 17 Unfortunately my knowledge about macosx is very low so I do not know what is the right way to fix this "double-perl-collision" -- kmx
Subject: Re: [rt.cpan.org #70858] Finance::TA won't install mac OSX
Date: Tue, 13 Sep 2011 21:07:56 -0500
To: bug-Finance-TA [...] rt.cpan.org
From: Chris Fluur <chrisfluur [...] gmail.com>
Yes! I do have more then one perl! Trying the fix... I first went to the cpan build dir, then I ran... sudo make realclean; sudo perl Makefile.PL; sudo make; sudo prove -bv t/ta_common.t I saw... # Running under perl version 5.014001 for darwin # Current time local: Tue Sep 13 21:01:01 2011 # Current time GMT: Wed Sep 14 02:01:01 2011 # Using Test.pm version 1.25_02 TA-Lib 0.4.0 (Sep 9 2011 23:49:25) Testing ta_common... ok 1 ok 2 ok 3 ok 4 ok 5 ok 6 Testing TA_SetRetCodeInfo()... ok 7 ok 8 ok 9 ok 10 ok 11 ok 12 Testing TA_Initialize and TA_Shutdown... ok 13 ok 14 ok 15 ok 16 ok 17 ok All tests successful. Files=1, Tests=17, 0 wallclock secs ( 0.03 usr 0.00 sys + 0.02 cusr 0.00 csys = 0.05 CPU) Result: PASS so I did a sudo make test... PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/ta_abstract.t .. ok t/ta_common.t .... ok t/ta_defs.t ...... ok t/ta_func.t ...... ok All tests successful. Files=4, Tests=172, 1 wallclock secs ( 0.05 usr 0.02 sys + 0.10 cusr 0.02 csys = 0.19 CPU) Result: PASS so I did a sudo make install! Then I ran this perl script: #!/usr/bin/perl use Finance::TA; my @series = ('91.500000','94.815000','94.375000','95.095000','93.780000','94.625000','92.530000','92.750000','90.315000','92.470000'); my ($retCode, $begIdx, $result) = TA_MAX(0, $#series, \@series, 4); if($retCode == $TA_SUCCESS) {print("max[$_] = ", $result->[$_], "\n") for ($begIdx .. scalar(@$result)-1);}else {die "error during TA_MAX";} and I saw... max[3] = 95.095 max[4] = 94.625 max[5] = 94.625 max[6] = 92.75 SO I THINK IT'S GONNA WORK! I'M SO HAPPY AND EXCITED THANK YOU VERY MUCH OMG I'M SERIOUS! WOO HOOOOO !!! On Sun, Sep 11, 2011 at 3:07 PM, kmx via RT <bug-Finance-TA@rt.cpan.org>wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=70858 > > > I have noticed in your build log that you probably have 2 perls on your > MacOSX box: > > /opt/local/bin/perl (v5.12.x) maybe from macports > /usr/bin/perl (v5.10.x) the original macosx perl > > Which might be a trouble. > > Test please: > > 1/ fix ta-lib-config as mentioned in previous post (add -lta_lib to --libs) > > 2/ run: sudo cpan > > 3/ from cpan prompt run: look Finance::TA > > 4/ perl Makefile.PL > > 5/ make > > 6/ prove -bv t/ta_common.t > > If you see something like this: > > /# Running under perl version 5.012003 for darwin > # Current time local: Sun Sep 11 13:00:07 2011 > # Current time GMT: Sun Sep 11 20:00:07 2011 > # Using Test.pm version 1.25_02 > dyld: lazy symbol binding failed: Symbol not found: _Perl_Gthr_key_ptr > Referenced from: > > /Users/bob/.cpan/build/Finance-TA-v0.4.0-ehwbUX/blib/arch/auto/Finance/TA/TA.bundle > Expected in: flat namespace > > dyld: Symbol not found: _Perl_Gthr_key_ptr > Referenced from: > > /Users/bob/.cpan/build/Finance-TA-v0.4.0-ehwbUX/blib/arch/auto/Finance/TA/TA.bundle > Expected in: flat namespace/ > > then the trouble is in mixing different versions of perl > > 7/ to confirm my guess from point 6/ try to run: /usr/bin/perl -Mblib > t/ta_common.t > > You should see something like this: > > # Running under perl version 5.010000 for darwin > # Current time local: Sun Sep 11 13:03:25 2011 > # Current time GMT: Sun Sep 11 20:03:25 2011 > # Using Test.pm version 1.25 > TA-Lib 0.4.0 (Sep 11 2011 12:09:35) > Testing ta_common... > ok 1 > ok 2 > ok 3 > ok 4 > ok 5 > ok 6 > Testing TA_SetRetCodeInfo()... > ok 7 > ok 8 > ok 9 > ok 10 > ok 11 > ok 12 > Testing TA_Initialize and TA_Shutdown... > ok 13 > ok 14 > ok 15 > ok 16 > ok 17 > > Unfortunately my knowledge about macosx is very low so I do not know > what is the right way to fix this "double-perl-collision" > > -- > kmx > >