Bug #6768
closedChanges for r36338 are not complete
Description
The changes for r36338 are incomplete. TARGET is in enc/depend. The general strategy of going from TARGET to TARGET_NAME to TARGET_ENTRY I think will create more and more issues.
The current changes causes enc.mk to not have the -eInit_foo in the ld call at all. But changing the regular expression in depend from TARGET to TARGET_ENTRY will only lead to an error when make is called.
I'm wondering if enc/depend is a good idea at all. It uses regular expressions to change what it assumes will be in various CONFIG values to make them different. This makes things very fragile and the build process is not something that you want to introduce more fragility.
Files
Updated by pedz (Perry Smith) over 12 years ago
- File ruby-1.9.3-p194 ruby-1.9.3-p194 added
Attached is a diff starting from the ruby 1.9.3 p194 tarball. It includes the changes to SHLIB_PATH => LIBPATH as well as a method to solve this bug.
I am using features of GNU Make. I am not sure if that is permitted. In particular I am using $(shell .... ) construct to transform $(TARGET) so that dot.dot becomes just dot. I am also using target specific variables and reducing the amount of special case work that enc/depend is doing.
With these changes I can configure, make, and make test with only one test failure (which I hope to address next weekend).
I am still using my "ld" script which I have mentioned before: https://github.com/pedz/aix-build-scripts
The way that ruby passes in -blibpath:.... does not work. It needs to include other directories such as GCC's directories and, in the case of the pg extension, the library that the pgext.so library is in. The way I solved this was to have a script called "ld" in front of the real ld in my PATH. My ld does many things -- correcting issues of various open source packages have. These scripts are changing because I can't make up my mind on a few subtle features.
I also needed to create libruby.a and put libruby.so.1.9.1 inside of it or the typical extconf.rb fails with all of its conftests. It calls ld with -l ruby but does not include the flag to look for libruby.so. If I recall correctly, the flag to get ld to search for libruby.so instead of libruby.a has other side effects so I just created the libruby.a.
At this point, I can start rails 3.2.3 using the pg gem for postgress on AIX (which uses bundler).
Updated by nobu (Nobuyoshi Nakada) over 12 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
This issue was solved with changeset r36502.
Perry, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
enc/Makefile.in: TARGET_NAME TARGET_ENTRY
- enc/Makefile.in (TARGET_NAME, TARGET_ENTRY): needed for EXTDLDFLAGS
on some platforms. [ruby-core:46600] [Bug #6768] - enc/depend: no longer needs tweaking DLDFLAGS for TARGET names.
Updated by pedz (Perry Smith) over 12 years ago
Tested these on nightly build and they are working.
Thanks!