The Wayback Machine - https://web.archive.org/web/20201130094022/https://github.com/AOP-PHP/AOP/issues/78
Skip to content
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

PHP Error: Unable to load dynamic library '/usr/lib/php5/20100525/AOP.so' - /usr/lib/php5/20100525/AOP.so: cannot open shared object file: No such file or directory in Unknown on line 0 #78

Open
chrissound opened this issue Nov 3, 2013 · 1 comment

Comments

@chrissound
Copy link

@chrissound chrissound commented Nov 3, 2013

Hi guys. I'm getting the above error.

I've just installed this by going through this:

git clone https://github.com/AOP-PHP/AOP
cd AOP
phpize
./configure
make
make test
make install

I also added "extension=AOP.so" to the END of /etc/php5/fpm/php.ini

That file does not exist either (/usr/lib/php5/20100525/AOP.so)
I've also failed to find any AOP.so file anywhere on my filesystem (sudo find / -name "AOP.so").

I'm running Linux Mint 15. I'm also using Nginx.
PHP version: PHP 5.4.9-4ubuntu2.3 (cli) (built: Sep 4 2013 19:32:25)

I did get some tests that failed:

=====================================================================
PHP         : /usr/bin/php 
PHP_SAPI    : cli
PHP_VERSION : 5.4.9-4ubuntu2.3
ZEND_VERSION: 2.4.0
PHP_OS      : Linux - Linux chris-desktop 3.8.0-19-generic #30-Ubuntu SMP Wed May 1 16:35:23 UTC 2013 x86_64
INI actual  : /home/webroot/aop/AOP/tmp-php.ini
More .INIs  :  
CWD         : /home/webroot/aop/AOP
Extra dirs  : 
VALGRIND    : Not used
=====================================================================
TIME START 2013-11-03 17:25:02
=====================================================================
PASS aop_add_after_returning triggers only when functions / methods ends properly [tests/after_returning/001.phpt] 
PASS aop_add_after_returning triggers only when functions / methods ends properly [tests/after_throwing/001.phpt] 
PASS Args overload arguments call (try in the first around declared) [tests/arguments_overload/001.phpt] 
PASS args overload arguments call (try in the second around declared) [tests/arguments_overload/002.phpt] 
FAIL Fluent interface fun with aop [tests/articles/001.phpt] 
PASS No autoload for selector [tests/autoload/001.phpt] 
PASS Two call to getTriggeringMethodName doesn't segfault [tests/bugs/001.phpt] 
PASS Call tostring is property is object [tests/bugs/002.phpt] 
PASS aop on private property [tests/bugs/003.phpt] 
PASS aop on private property [tests/bugs/004.phpt] 
PASS Try using finfo_open [tests/bugs/005.phpt] 
PASS Try using new finfo() [tests/bugs/006.phpt] 
PASS Try using finfo_open (may cause segmentation fault) [tests/bugs/007.phpt] 
PASS Test if cache is refresh [tests/cache/001.phpt] 
PASS Test if handle number is enought and realloc if problem [tests/cache/002.phpt] 
PASS Test if handle number is enought and realloc if problem [tests/cache/003.phpt] 
PASS Caching example with multiple objects with advices on [tests/complete/001.phpt] 
PASS Testing AOP_KIND_AROUND constant [tests/consts/001.phpt] 
PASS Testing AOP_KIND_BEFORE constant [tests/consts/002.phpt] 
PASS Testing AOP_KIND_AFTER constant [tests/consts/003.phpt] 
PASS Testing that AOP_* consts are different [tests/consts/004.phpt] 
PASS Verify this context in method caught (private version) [tests/context/001.phpt] 
PASS Verify this context in method caught (public version) [tests/context/002.phpt] 
PASS Docs Test 0 [tests/docsexample/0.phpt] 
PASS Docs Example 1 [tests/docsexample/001.phpt] 
PASS Docs Example 2 [tests/docsexample/002.phpt] 
PASS Internal Return [tests/docsexample/003.phpt] 
PASS Docs Test 1 [tests/docsexample/1.phpt] 
PASS Docs Test 10 [tests/docsexample/10.phpt] 
PASS Docs Test 11 [tests/docsexample/11.phpt] 
PASS Docs Test 12 [tests/docsexample/12.phpt] 
PASS Docs Test 13 [tests/docsexample/13.phpt] 
PASS Docs Test 14 [tests/docsexample/14.phpt] 
PASS Docs Test 15 [tests/docsexample/15.phpt] 
PASS An advice that knows you're dealing with an object's property [tests/docsexample/16.phpt] 
PASS An advice that is interested only in properties writing [tests/docsexample/17.phpt] 
PASS An advice that knows what happened on the hooked properties [tests/docsexample/18.phpt] 
PASS An advice that updates the assigned value of a property [tests/docsexample/19.phpt] 
PASS Docs Test 2 [tests/docsexample/2.phpt] 
PASS setAssignedValue [tests/docsexample/21.phpt] 
PASS First doc example in aop_add_after in phpdoc [tests/docsexample/22.phpt] 
PASS Pointcut syntax for functions [tests/docsexample/23.phpt] 
PASS Pointcut syntax for methods [tests/docsexample/24.phpt] 
PASS Test of method syntax for pointcuts [tests/docsexample/25.phpt] 
PASS Docs Test 3 [tests/docsexample/3.phpt] 
PASS Docs Test 4 [tests/docsexample/4.phpt] 
PASS Docs Test 5 [tests/docsexample/5.phpt] 
PASS Docs Test 6 [tests/docsexample/6.phpt] 
PASS Docs Test 7 [tests/docsexample/7.phpt] 
PASS Docs Test 8 [tests/docsexample/8.phpt] 
PASS Docs Test 9 [tests/docsexample/9.phpt] 
PASS Exception in method caught [tests/exception/001.phpt] 
PASS getArguments return caught method call arguments [tests/getargs/001.phpt] 
PASS getArguments return method caught arguments (in all arounder) [tests/getargs/002.phpt] 
PASS Method getTriggeringObject can overload public data [tests/getthis/001.phpt] 
PASS In function context getTriggeringObject return null [tests/getthis/002.phpt] 
PASS Not Parent class, not caucht [tests/inheritance/001.phpt] 
PASS Herited class is caught (with selector on parent) [tests/inheritance/002.phpt] 
PASS Herited class is caught (with selector on child) [tests/inheritance/003.phpt] 
PASS Herited class is caught (with selector on interface on parent) [tests/inheritance/005.phpt] 
PASS Herited class is caught (with selector on interface on child) [tests/inheritance/006.phpt] 
PASS Inheritance of interfaces are caught (with selector on parent interface) [tests/inheritance/007.phpt] 
PASS Tests if the directive aop.enable is correctly handled [tests/ini_directives/001.phpt] 
PASS No segfault with selector just * [tests/issues/001.phpt] 
PASS Testing that the use of static is still enabled [tests/issues/002.phpt] 
PASS Validate that aop does not disturb create_function [tests/issues/003.phpt] 
PASS Exception propagation is not correct [tests/issues/004.phpt] 
PASS Exceptions thrown by a before is caught by an around [tests/issues/005.phpt] 
PASS extract symbol table reset after method call [tests/issues/006.phpt] 
PASS private method and properties in parent class [tests/issues/007.phpt] 
PASS Issue 34 [tests/issues/008.phpt] 
PASS Issue 37 on GitHub [tests/issues/009.phpt] 
FAIL Issue 58 on GitHub [tests/issues/010.phpt] 
PASS Issue 58 on GitHub [tests/issues/011.phpt] 
FAIL getPropertyValue with private properties [tests/issues/47.phpt] 
FAIL getPropertyValue with protected properties [tests/issues/47_2.phpt] 
PASS Absolute namespaces [tests/issues/52.phpt] 
PASS Absolute namespaces [tests/issues/52_2.phpt] 
PASS Absolute namespaces in functions [tests/issues/65.phpt] 
PASS Absolute namespaces in functions [tests/issues/65_2.phpt] 
PASS Method in selector is just a Joker [tests/joker/001.phpt] 
PASS Function call with a Joker in selector [tests/joker/002.phpt] 
PASS Method in selector is partial with a Joker [tests/joker/003.phpt] 
PASS Class in selector is partial with a Joker [tests/joker/004.phpt] 
PASS Class in selector is partial with a Joker [tests/joker/005.phpt] 
PASS Just a joker and test no bug with recursion [tests/joker/006.phpt] 
PASS Joker at the begining [tests/joker/007.phpt] 
PASS Joker at the begining [tests/joker/008.phpt] 
PASS Joker at the end [tests/joker/009.phpt] 
SKIP Testing if include, include_once, require and require_once are caught [tests/keywords/001.phpt] reason: "Not Implemented Yet"
SKIP Testing if echo is hooked [tests/keywords/002.phpt] reason: "Not Implemented Yet"
SKIP Testing if print is hooked [tests/keywords/003.phpt] reason: "Not Implemented Yet"
PASS Using a variable as a selector and unsetting it. [tests/misc/001.phpt] 
PASS Using a variable as a selector and updating its value. [tests/misc/002.phpt] 
PASS Trying to use an array as a selector (won't work) [tests/misc/003.phpt] 
PASS TU on namespace [tests/ns/001.phpt] 
PASS Test the hook on a property [tests/properties/001.phpt] 
PASS Test the hook on a property (write only) [tests/properties/002.phpt] 
PASS Test the hook on a property while writing data (write only) [tests/properties/003.phpt] 
PASS Test the hook on a property read / write [tests/properties/004.phpt] 
PASS Test the hook on a property after [tests/properties/005.phpt] 
PASS Tests on read property (setReturnedValue) [tests/properties/006.phpt] 
PASS Test the hook on a property while writing data (write only) after writing its value [tests/properties/007.phpt] 
PASS Scope on write and read property [tests/properties/008.phpt] 
PASS Accessing undefined properties [tests/properties/009.phpt] 
PASS getPropertyValue [tests/properties/010.phpt] 
PASS Read Property Test [tests/read_properties/001.phpt] 
PASS Read Property Test [tests/read_properties/003.phpt] 
PASS Scope [tests/scope/001.phpt] ]
PASS Scope [tests/scope/002.phpt] ]
PASS Scope with static [tests/scope/003.phpt] 
PASS Just an around method test (version with echo) [tests/simple/001.phpt] 
PASS Just an around method test (version with return) [tests/simple/002.phpt] 
PASS An around method test without call to process [tests/simple/003.phpt] 
PASS Just an around method test (version with 2 Pointcuts) [tests/simple/004.phpt] 
PASS Function call (exact name) [tests/simple/005.phpt] 
PASS Testing alternative separator for selectors (-> instead of ::) [tests/simple/006.phpt] 
PASS Testing invalid callback given to aop_add_around() [tests/simple/007.phpt] 
PASS Testing invalid callback given to aop_add_before() [tests/simple/008.phpt] 
PASS Testing invalid callback given to aop_add_after() [tests/simple/009.phpt] 
PASS Traits test [tests/traits/001.phpt] 
PASS Write Property Test [tests/write_properties/001.phpt] 
PASS Write Property Test Test Recursion Loop [tests/write_properties/002.phpt] 
PASS Write Property Selector -> ->$ :: ::$ [tests/write_properties/003.phpt] 
PASS Read / Write Property with inc or dec [tests/write_properties/004.phpt] 
PASS Write Property Test [tests/write_properties/005.phpt] 
PASS Write Property Test [tests/write_properties/006.phpt] 
PASS Write General API [tests/write_properties/007.phpt] 
=====================================================================
TIME END 2013-11-03 17:25:04

=====================================================================
TEST RESULT SUMMARY
---------------------------------------------------------------------
Exts skipped    :    0
Exts tested     :   45
---------------------------------------------------------------------

Number of tests :  128               125
Tests skipped   :    3 (  2.3%) --------
Tests warned    :    0 (  0.0%) (  0.0%)
Tests failed    :    4 (  3.1%) (  3.2%)
Expected fail   :    0 (  0.0%) (  0.0%)
Tests passed    :  121 ( 94.5%) ( 96.8%)
---------------------------------------------------------------------
Time taken      :    2 seconds
=====================================================================

Cheers!

@chrissound
Copy link
Author

@chrissound chrissound commented Nov 24, 2013

Hello! I've had a bit of progress. I've tried doing a vanilla install of PHP5-Fpm and Nginix using virtual box and Linux Mint 32Bit (XFCE).

When running make I received the following error:

/bin/bash: lex: command not found
make: *** [/home/mintbox/dev/phpaop/Lexer.c] Error 127
mintbox@mintbox-VirtualBox ~/dev/phpaop $

This was fixed by running: sudo apt-get install flex

When running 'sudo make test' I received the following error:

/bin/bash /home/mintbox/dev/phpaop/libtool --mode=install cp ./aop.la /home/mintbox/dev/phpaop/modules
libtool: install: cp ./.libs/aop.so /home/mintbox/dev/phpaop/modules/aop.so
libtool: install: cp ./.libs/aop.lai /home/mintbox/dev/phpaop/modules/aop.la
libtool: finish: PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/sbin" ldconfig -n /home/mintbox/dev/phpaop/modules
----------------------------------------------------------------------
Libraries have been installed in:
   /home/mintbox/dev/phpaop/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the `LD_LIBRARY_PATH' environment variable
     during execution
   - add LIBDIR to the `LD_RUN_PATH' environment variable
     during linking
   - use the `-Wl,-rpath -Wl,LIBDIR' linker flag
   - have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------

Build complete.
Don't forget to run 'make test'.

ERROR: Cannot run tests without CLI sapi

make install ran fine however.

I then got the following error in the PHP log:

PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/20100525+lfs/AOP.so' - /usr/lib/php5/20100525+lfs/AOP.so: cannot open shared object file: No such file or directory in Unknown on line 0

Which I solved by changing 'extension=AOP.so' to 'extension=aop.so' in my php.ini file.

I'm stuck on the following PHP startup error:

PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/20100525+lfs/AOP.so' - /usr/lib/php5/20100525+lfs/AOP.so: cannot open shared object file: No such file or directory in Unknown on line 0

I hope this is helpful. I would greatly appreciate any input into this. Very eager to start using this AOP library!

Cheers!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.