Syllable Forum Index Syllable
Syllable Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

syllablized libxml source
Goto page 1, 2, 3  Next
 
Post new topic   Reply to topic    Syllable Forum Index -> Syllable Desktop
View previous topic :: View next topic  
Author Message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Wed Feb 04, 2015 7:49 am    Post subject: syllablized libxml source Reply with quote

I've been recompiling Webster, so as to look at the kernel memory exhaution problem. Additionally, I decided to incorporate polarssl into curl instead of openssl (hey - that's NL project!). PolarSSL compiled on Syllable Desktop with no changes at all to source, and only a change to drop -lsocket from config. Curl compiled with no change to source at all, and with minor config change to use libtool for shared libs.

After compiling the two new source bases, I could successfully use curl to do https with polarssl. Sweet!

Now, when compiling Webster, the JavaScriptCore shared lib compiles just fine, and very quickly. The WebCore library is a horse, and taking a long time. It has dependency of ICU and gperf, both of which I found in Syllable resources. Now, WebCore stopped and says it needs libxml.h - but libxml source is not installed. Is there a source resource from Syllable for this?
Back to top
View user's profile Send private message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Wed Feb 04, 2015 2:38 pm    Post subject: System Reply with quote

I'll bet that it can be had from the main Syllable system source CVS or tarball. Silly me.
Back to top
View user's profile Send private message
Kaj
The Knights of Syllable


Joined: 14 Sep 2007
Posts: 2202
Location: Friesland

PostPosted: Wed Feb 04, 2015 4:09 pm    Post subject: Reply with quote

cURL has been included in the base system for a very long time, with (Open)SSL enabled.

LibXML has also been available for long, as a separate resource package.

Both have build recipes in Builder, which are usually easy to update to the latest versions.

Congratulations on porting PolarSSL, though. Smile
Back to top
View user's profile Send private message Visit poster's website
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Wed Feb 04, 2015 8:03 pm    Post subject: Thanks Reply with quote

Thanks Kaj - Yes I see the resource download for libXML now. I'm not sure why I didn't see it the first time.

It'll be nice having the PolarSSL/cURL setup working with Webster. I like PolarSSL because it's so nicely structured, and that makes it far easier to see the high level plan. It's a simple thing to recompile PolarSSL to exclude all ciphers except the DHE (Diffie Hellman Ephemeral) ones, which I prefer to use.

And - maybe I can get better insight into the memory wasting issue.

- Thanks again,

Ron
Back to top
View user's profile Send private message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 8:35 am    Post subject: Some success, but Reply with quote

Well, the WebCore build didn't take as long as I thought. Maybe about 3 hours or so. Anyway, all of the Webkit libraries compiled fine, and so did the Webster executable. I was primed to go, but when I attempted to execute the new Webster executable, the ELF loader failed to load it. I noticed that the Webster build docs called for GCC3.4 as a requirement, but I think that was a statement relative to GCC 2.95. Right?

It seems that unlike Linux, Syllable does not complain about elf loader failures. The command prompt simply returned with no error. I didn't know what was happening until I used the GNU debugger to try to start Webster. Everything compiles and links real nice tho. Smile

Do I have some kind of ABI situation?

- Ron
Back to top
View user's profile Send private message
Kaj
The Knights of Syllable


Joined: 14 Sep 2007
Posts: 2202
Location: Friesland

PostPosted: Fri Feb 06, 2015 2:16 pm    Post subject: Reply with quote

We moved to GCC 4+ a long time ago, and had to adjust some sources here and there, but Webster should be built with it for quite some time.

Syllable's ELF loader is part of the kernel, unlike on Linux where it is part of the C library. So you should look for loading errors in the kernel log.

What did GDb say?
Back to top
View user's profile Send private message Visit poster's website
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 4:22 pm    Post subject: Differences in Webster executables Reply with quote

Thanks for responding Kaj. OK, I'll check the kernel log when I get back to the other machine. I had to change machines since I killed Webster with the installation of the new binaries! Sad

Maybe this thread should be renamed to "Compiling Webster" since that's more descriptive of what it is. One thing I noticed is that there are differences in the dependencies for the newly compiled libwebcore.so file versus the one that ships with the system. Here is the readelf dump of the NEEDED libs lines:


[code]
[Newly compiled lib]

[[email protected]:[email protected]js]
readelf -a ./libwebcore.so.1 |grep NEEDED
0x00000001 (NEEDED) Shared library: [libjavascriptcore.so.1]
0x00000001 (NEEDED) Shared library: [libz.so.1]
0x00000001 (NEEDED) Shared library: [libsqlite3.so.0]
0x00000001 (NEEDED) Shared library: [libsyllable.so.7]
0x00000001 (NEEDED) Shared library: [libcurl.so.4]
0x00000001 (NEEDED) Shared library: [libdl.so.3]
0x00000001 (NEEDED) Shared library: [libpthread.so.2]
0x00000001 (NEEDED) Shared library: [libssl.so.0.9.8]
0x00000001 (NEEDED) Shared library: [libcrypto.so.0.9.8]
0x00000001 (NEEDED) Shared library: [libjpeg.so.62]
0x00000001 (NEEDED) Shared library: [libstdc++.so.6]
0x00000001 (NEEDED) Shared library: [libm.so.2]
0x00000001 (NEEDED) Shared library: [libgcc_s.so.3]
0x00000001 (NEEDED) Shared library: [libc.so.2]

----------------

[Original system supplied lib]

[[email protected]:[email protected]js]
readelf -a /App*/We*/lib/libwebcore.so.1 |grep NEEDED
0x00000001 (NEEDED) Shared library: [libjavascriptcore.so.1]
0x00000001 (NEEDED) Shared library: [libz.so.1]
0x00000001 (NEEDED) Shared library: [libsyllable.so.7]
0x00000001 (NEEDED) Shared library: [libcurl.so.4]
0x00000001 (NEEDED) Shared library: [libdl.so.3]
0x00000001 (NEEDED) Shared library: [libpthread.so.2]
0x00000001 (NEEDED) Shared library: [libm.so.2]
0x00000001 (NEEDED) Shared library: [libgcc_s.so.3]
0x00000001 (NEEDED) Shared library: [libc.so.2] Confused Confused Confused Confused Sad Confused
[/code]

I noticed no C++ standard libary in the shipped lib deps. There's other differences, as you can see.

One thing that could make the elf loader unhappy with locally built libraries might be a system built with a gcc that's later than the one in the distro. I'm curious. Was the distro built by the self hosted Syllable with gcc 4.1, or cross built on a later gcc?

I'll check the kernel log. Thanks,

- Ron
Back to top
View user's profile Send private message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 4:31 pm    Post subject: Work to do Reply with quote

You can see in the first listing that Webster is calling for both libssl and libcurl. Normally, curl has libssl as a dependency itself, and the other libraries don't need to call it. So, the polarssl conversion obviously isn't done. I really haven't touched the webster source at all. I just linked to a new curl, which has a polarssl backend. So, I would need to find out why the Webster code base is doing looking at both libssl and libcurl. Work to do...
Back to top
View user's profile Send private message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 4:42 pm    Post subject: Reply with quote

One other thing...

The dependency differences could just be the way I configured Webster, so that's not necessarily very interesting.

But, curl and polarssl both compile, link and run with no problems, using the local (Syllable) gcc 4.1 compiler. So, maybe it's a C++ ABI issue only.
Back to top
View user's profile Send private message
Kaj
The Knights of Syllable


Joined: 14 Sep 2007
Posts: 2202
Location: Friesland

PostPosted: Fri Feb 06, 2015 4:43 pm    Post subject: Reply with quote

Yeah, I don't think the thread subject can be changed here.

Syllable can only be compiled on itself, so the only "cross-compiling" being done is from one development version to the next. That said, Webster is hard to build, so it's not done in the system build, but separately on a developer's machine.

Some of the extra library dependencies look like they should already have been there, but others point towards too many features compiled into WebCore. Are you using the latest Webster source package and following the build instructions precisely?
Back to top
View user's profile Send private message Visit poster's website
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 6:12 pm    Post subject: Reply with quote

Well, I tried to use builder. I did the followning:

build update
build log
package unregister builder
package register builder
build prepare
build unpack Webster...zip
build configure

The last item gave this:

Configuring Webster
Webster
Building dependencies
make deps
make: *** No rule to make target `deps'. Stop.
Error: 2

In response to the error, I just unzipped the source to another directory and used the default configure options in the source tree. I suppose that the configs used with the "shipped version" of Webster were likely not the defaults, but the defaults seem to work fine. I have all the dependencies for the default configuration, and since everything did compile and link, it doesn't occur to me that the configuration is the culprit. I could be wrong, of course.

Nothing of note was found in the kernel log.

C programs don't seem to have any problem compiling. Curl and PolarSSL sources are C, and not C++. The sources I have for Webster are C++ and use the standard library. I downloaded those sources from the "Get Webster Sources" link on the Syllable Desktop web page.

This is no big deal. It's only fun for me. So, don't sweat about it too much Smile
Back to top
View user's profile Send private message
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Fri Feb 06, 2015 6:15 pm    Post subject: Reply with quote

I should have said "Curl and PolarSSL are C progarms" - and they RUN. Webster is C++, and does not.
Back to top
View user's profile Send private message
Kaj
The Knights of Syllable


Joined: 14 Sep 2007
Posts: 2202
Location: Friesland

PostPosted: Fri Feb 06, 2015 6:58 pm    Post subject: Reply with quote

It could be, but there is no particular reason to think the problem is C++ instead of something else.

The Webster build procedure is so difficult that it is not supported by Builder - otherwise it could be included in the system build. There are build instructions in the Webster source package that you should follow.

Also,

build prepare

is used for compiling the system. It should not be used for separate applications or resource packages.
Back to top
View user's profile Send private message Visit poster's website
Ronaldlees



Joined: 15 Oct 2014
Posts: 145

PostPosted: Sat Feb 07, 2015 12:14 pm    Post subject: Reply with quote

Kaj:

Now I'm getting a different error. In GDB debugger I get "error 1" when I try to start the executable, and in the kernel log I get an "exec" error. So, I'm going to completely clean the system, start over, and then see what happens.
Back to top
View user's profile Send private message
Kaj
The Knights of Syllable


Joined: 14 Sep 2007
Posts: 2202
Location: Friesland

PostPosted: Sat Feb 07, 2015 1:33 pm    Post subject: Reply with quote

What exec error is that in the kernel log? Doesn't it give a file name?

You should definitely reconfigure the Webster source code according to its instructions.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Syllable Forum Index -> Syllable Desktop All times are GMT - 6 Hours
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group