LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   pre-compile configuring for x.org source (https://www.linuxquestions.org/questions/linux-software-2/pre-compile-configuring-for-x-org-source-502214/)

lbdgwgt 11-16-2006 09:24 AM

pre-compile configuring for x.org source
 
hi all,

i am building small linux system. i am trying to compile my X windows, downloaded fro X.org version X11R6.8.2.

the only installation guide i can found is from the site.
it seems that when i run "make world" it compiles everything.
how can i configure the installation, so the size will be quiet small? since i will install it on a Compact Flash Card. (e.g. selecting only the appropriate driver, etc.)

from an article found in the internet :

http://linuxdevices.com/articles/AT9202043619.html

it says that it is possible to create X windows system with the size 5MB RAM and 16MB disk. and clues how to do it?

thanks for the help.

weibullguy 11-16-2006 10:59 AM

Xorg 6.8.2 is a monolithic or meta package. I would recommend you use Xorg 7.1 as it is modular. This way you only have to build the parts you really need. You can get the 7.1 tarballs here. Here are some instructions for building Xorg 7.1. You'll have to adapt the instructions, but that shouldn't be too difficult.

studioj 11-17-2006 09:31 AM

yea dividing xorg up like that into different packages is a nightmare and not many people even know what the different packages are not even the developers. But you sure can experiment with leavng stuff out.

osor 11-17-2006 09:43 AM

Ever tried tinyx?

lbdgwgt 11-17-2006 02:58 PM

Hi,

thanks for the reply. I guess I will try with X windows first, since later i will try to run java GUI application which has been setup before. My target memory is not too bad anyway with 512 MB Flash Card and 256 RAM.

I am still trying to install the xorg 6.x. but still lack of references.
:newbie: :p

osor 11-17-2006 08:09 PM

If you need resources to install xorg 6.8.x, try looking at some of the old BLFS guides.

lbdgwgt 11-20-2006 05:24 AM

Quote:

Originally Posted by osor
If you need resources to install xorg 6.8.x, try looking at some of the old BLFS guides.

i have BLFS guide for 6.8.2 with me, but it doesnt explain too much for newbee like me.

anyway i tried to compile the x.org packages and it seems like mess.
i configure the host.def the run:
Code:

make CROSSCOMPILEDIR=<CROSS_COMPILER_DIR> World
the first error i got is the same with this one:
http://www.linuxquestions.org/questi...d.php?t=285074

then i look into the lbx_zlib.h file, and the line of error is:
Code:

#include "zlib.h"
i looked into the directory, but there was no file "zlib.h"
tried to copy it to the same directory, then another file "zconf.h" was missing. tried to copy again it, then another was missing.

i wonder why does this source package of x.org contains thoses error.
so any other suggestion to start compiling this package?

thanks for the help

osor 11-20-2006 09:51 AM

Quote:

Originally Posted by lbdgwgt
i wonder why does this source package of x.org contains thoses error.
so any other suggestion to start compiling this package?

thanks for the help

I haven't done monolithic X in awhile, and I don't have the book in front of me, but isn't there a way to force X to use the system zlib instead of its own?

weibullguy 11-20-2006 10:48 AM

Quote:

make CROSSCOMPILEDIR=<CROSS_COMPILER_DIR> World
Are you cross-compiling the X server? If so, I'm sure you know that this <CROSS_COMPILER_DIR> needs to be replaced with the actual path.

Anyway, config/cf/host.def is the file that you can tell X to use the system zlib rather than build it's own. There needs to be a line in host.def #define HasZlib YES. There is one provided in the BLFS instructions (version 6.1) for building Xorg 6.8.2 that may have to be tweaked for your exact application.

lbdgwgt 11-21-2006 02:08 AM

Quote:

Originally Posted by Arow
Are you cross-compiling the X server?

Yes, im trying to do that.

I am using the X11R6.7.0. and I am planning to do:
- make the shadow directory build using lndir command
- configure the host.def file
- build the X windows:
Code:

make CROSSCOMPILEDIR=<PATH_TO_CROSS_COMPILER> World
- install to the CF card (supposed it is mounted on /mnt/cf):
Code:

make install DESTDIR=/mnt/cf
can i do this?

i read the BLFS guide, but one question is that which documents should i refer to, if i want to configure the host.def file?
where can i find the complete options for this configuration file to tweak my application?

thanks,

lbdgwgt 11-24-2006 08:52 AM

Hi all,

so after one week i finally made to compile the X11R6.7.0 packages and installed to my linux system on CF card.

here is my config/cf/host.def file (comments excluded):
Code:

#define HasFreetype2    NO
#define HasFontconfig  NO
#define HasExpat        NO
#define HasLibpng      NO
#define HasZlib        NO
#define InstallFontconfigLibrary  NO
#define XnestServer    NO
#define XVirtualFramebufferServer  NO
#define XprtServer      NO
#define BuildXprintClients  NO
#define XF86CardDrivers savage
#define XInputDrivers  NO

this would compile the necessary extras packages needed like zlib, etc. but then i got problem with that GNU linker (ld) of my cross compiler doesnot support the ncurses library and no reference for ncurses.h.

Basically i installed the crosstool cross compiler (i386, gcc 3.4.4, binutils 2.15, glibc 2.3.2).
so i found out the solution:
- create a directory with symlinks to the cross compile binaries without prefix (eg: gcc links to the crosstool i686-unknown-linux-gnu-gcc, etc.)
- download and extract without installing (command: rpm2cpio <RPM_PACK> | cpio -id) rpm package of ncurses and ncurses devel (i use the 5.2-28.i386 version) which contain the libncurses library and ncurses.h
- make a symlink form the cross compiler lib/ directory with the name libncurses.so to the libncurses.so got from rpm package
- compile the whole package:
Code:

make CROSSCOMPILEDIR=<DIR_CONTAIN_SYMLINK_TO_CROSSTOOL_BIN> C_INCLUDE_PATH=<PATH_TO_DIR_CONTAIN_NCURSES.H_FROM RPM_PACKAGE> World
besides that, i had an error when compiling the xc/programs/Xserver/hw/xfree86/fbdevhw/fbdevhw.c file.
i found a patch on the internet somewhere and patch the file. it will excludes the "asm/page.h" file during compilation.

after a long time, it finished without error, then install to CF card:
Code:

make install DESTDIR=<CF_CARD_MOUNT_DIR>
then i copied the fonts from my host target /usr/X11R6/lib/X11/fonts. the size of whole things is around 45 MB.anyway i am using 512MB CF for the project :)

sorry to make such a long thread. but i hope this will be usefull for someone later.
i still have some error during the runtime. and i ask this in another thread.

regards,


All times are GMT -5. The time now is 11:56 AM.