X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c98f04213ed354d0116092e87a30db5dc69c5709..dc9e1e56917ad9b448bd0087a2d1ae3c632c4db1:/docs/gtk/install.txt?ds=inline diff --git a/docs/gtk/install.txt b/docs/gtk/install.txt index 24286b8abf..728fd2f749 100644 --- a/docs/gtk/install.txt +++ b/docs/gtk/install.txt @@ -1,96 +1,94 @@ * The most simple case ----------------------- -If you compile wxWindows on Unix for the first time and don't like -to read install instructions just do (in the base dir): +If you compile wxWindows on Unix for the first time and don't +like to read install instructions just do (in the base dir): -./configure --with-gtk --with-shared --without-threads +./configure --without-threads make -and drink 10 coffees. +and drink 10 coffees. Then you may log in as root and type +make install + +You can leave out the --without-threads option if you have +a NEW Linux distribution based on glibc (e.g. RedHat 5.1 or +Debian 2.0) or any other Unix that comes with Posix threads +or SGI threads. + +Now create your super-application myfoo.app and compile anywhere +with + +g++ myfoo.cpp `wx-config --libs` `wx-config --cflags` -o myfoo * General ----------------------- -The Unix variants of wxWindows use GNU configure. If you have problems -with your make use GNU make instead. +The Unix variants of wxWindows use GNU configure. If you have +problems with your make use GNU make instead. -Read my homepage at +If you have general problems with installation, read my +homepage at http://wesley.informatik.uni-freiburg.de/~wxxt -for newest information. +for newest information. If you still don't have any success, +please send a bug report to one of our mailing lists (see +my homepage) INCLUDING A DESCRIPTION OF YOUR SYSTEM AND +YOUR PROBLEM, SUCH AS YOUR VERSION OF GTK, WXGTK, WHAT +DISTRIBUTION YOU USE AND WHAT ERROR WAS REPORTED. I know +this has no effect, but I tried... * GUI libraries ----------------------- -wxWindows requires a GUI toolkit to be installed. Does that make -sense? So far only the GTK is supported, but we hope to provide -the choice between GTK, Qt, Motif/Lesstif in the not so distant -future. +wxWindows/GTK requires the GTK+ library to be installed on your system. +It has to be a stable version, preferebly version 1.0.6. When using +a version previous to 1.0.6 you'll get crashes here and there. -You can get the newest version of the GTK from the GTK homepage +wxWindows/GTK does NOT work with the 1.1.X versions of the GTK+ library +and we will wait until the 1.2 version comes out and has stabilized +until we'll work with that library. + +You can get the newest version of the GTK+ from the GTK homepage at http://www.gtk.org -The newest versin of Qt can be downloaded for free from the Trolltec's -site at - http://www.troll.no - -Lesstif can be downloaded from their site -at - http://www.lesstif.org - -If you want to develop using Motif, you need to buy it, unless it comes -with your operating system such as all commercial Unices, as well as -RedHat's, SuSe's and probably other's Linux Motif editions. - +We also mirror GTK+ 1.0.6 at our ftp site. You'll find information +about downloading at my homepage. + * Additional libraries ----------------------- -There will be a few more features of wxWindows, which will -require further libraries (on some platforms). These -features will be optional. I hope to teach configure -to check that out automatically. - -Thread support: - - Requires pthreads under Linux with glibc 2. pthreads are - always present on such systems, so just compile, unless - you have RedHat 5.0, which has a broken combination of - glibc 2 and X. In this case, you have to run configure - with "--without-threads". - - Requires PCthreads under Linux with libc 5. If you - haven't installed pcthreads, there will be no thread - support in wxWindows, but the library will compile. - - Requires Posix threads on commercial Unix system, - which are always present. Just compile. - - On SGI Irix we first look for sprocs, then pthreads and - use the last one found. - -Python scripting language support: - - Requires Python. Soon to come. +wxWindows/Gtk requires a thread library and X libraries +known to work with threads. This is the case on all +commercial Unix-Variants and all Linux-Versions that +are based on glibc 2 except RedHat 5.0 which is broken +in many aspects. As of writing this, these Linux +distributions have correct glibc 2 support: + + - RedHat 5.1 + - Debian 2.0 + - Stampede + +The next major version of SuSE will also support glibc 2, +but version 5.X does not. Also Caldera and Slackware +don't yet support glibc 2. + +On IRIX you can also use SGI threads if Posix-Threads +are not present. The SGI threads will be detected by +configure automatically. + +You can always disable thread support by running + +./configure "--without-threads" +make clean +make -* Other things to do ------------------------------ - -wxGTK and wxMotif/wxLesstif require the built-in -ImLib/GdkImlib to be configured. For that purpose -copy the two files from /misc/imlib to your -home directory and rename "imrc" -> ".imrc". -You may also edit imrc by hand as you like. -The palette file is required when using -wxWindows in 256-colour mode. - -If you want to use wxWindows's ODBC support, you'll have -to create a .odbc.ini file. The readme file in -~/src/iodbc tells you what to do. - +NB: I included thread support in wxWindows/Gtk, as this +problem will disappear in the near future when all major +Linux Variants have moved to glibc 2. Also, the Linux +Base Standard will include glibc 2. * Create your configuration ----------------------------- @@ -141,8 +139,10 @@ not been defined. And Make in some circumstances as well... * General options ------------------- -Obviously, you have to choose a toolkit. You must do this by -running configure with either of +Normally, you won't have to choose a toolkit, because when +you download wxGTK, it will default to --with-gtk etc. But +if you use all of our CVS repository you have to choose a +toolkit. You must do this by running configure with either of: --with-gtk Use the GIMP ToolKit (GTK) @@ -155,7 +155,7 @@ The following options handle the kind of library you want to build. --without-threads Compile without thread support. - --with-shared Create shared libraries. + --without-shared Do not create shared libraries. --without-optimise Do not optimise the code. @@ -177,48 +177,41 @@ The following options handle the kind of library you want to build. * Feature Options ------------------- -When using the Windows version of wxWindows, it is possible -to edit the file /include/wx/msw/setup.h in order to enable -or disable some features of wxWindows so that the resulting -binaries get smaller. - As I don't yet care for binary size and target mainly at producing a shared library, wxWindows's configure system auto- matically enables all features, as long as they are already -implemented. +implemented. It is currently NOT possible to disable these +options (in contrast to what configure tells you). * Compiling ------------- The following must be done in the base directory (e.g. ~/wxGTK -or ~/wxWin) - -First you have to create all makefiles in all subdirectories: - - make Makefiles - -Dependencies are generated automatically using +or ~/wxWin or whatever) - make depend - -(For some reason, this doesn't seem to work completely.) - -Now the makefiles are created you can compile everything is as simple -as typing: +Now the makefiles are created and you can compile everything +by typing: make -make yourself some coffee, as it will try to compile -ALL the files in this distribution. +make yourself some coffee, as it will try to compile ALL the +files in this distribution. During compilation, you'll get +a few warning messages. if you want to be more selective: make src will build only the base libraries - make utils will build the utils make samples will build the samples - make other will build the other samples - make user will build the files in the directory other + make other will build everything in other + make user will build everything in user + +Then you may install the library and it's header files under +/usr/local/include/wx and /usr/local/lib respectively. You +have to log in as root (i.e. run "su" and enter the root +password) and type + make install + Depending on the configuration of some files, the libraries and binaries will be placed in different directories. The "global" binaries and libraries will be placed in: @@ -242,8 +235,34 @@ will do the work for you. * Creating a new Project -------------------------- -I propose to put all contributed programs in the directory -"~/wxWin/user", with a directory of its own. +There are two ways to create your own project: + +1) The first way uses the installed libraries and header files +automatically using wx-config + +g++ myfoo.cpp `wx-config --libs` `wx-config --cflags` -o myfoo + +Using this way, a make file for the minimal sample would look +like this + +CC = g++ + +minimal: minimal.o + $(CC) -o minimal minimal.o `wx-config --libs` + +minimal.o: minimal.cpp mondrian.xpm + $(CC) `wx-config --cflags` -c minimal.cpp -o minimal.o + +clean: + rm -f *.o minimal + +This is certain to become the standard way unless we decide +to sitch to tmake. + +2) The other way creates a project within the source code +directories of wxWindows: In this case I propose to put +all contributed programs in the directory "/user", with a +directory of its own. This directory then should include the following files: @@ -258,6 +277,7 @@ Makefile.in (This is the base application-Makefile template, from put ALL your source code along with all the other stuff you need for your application in this directory (subdirectories are welcome). + ** Something about Makefiles ------------------------------