X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf7a7e133be36522ec3afd0417f1d2bd860b4f6c..b0f1bdde5a4e8559078a566fb93e050b64940f32:/docs/gtk/install.txt diff --git a/docs/gtk/install.txt b/docs/gtk/install.txt index 0eb9f235a2..32b44fe053 100644 --- a/docs/gtk/install.txt +++ b/docs/gtk/install.txt @@ -17,7 +17,7 @@ Unix that comes with Posix threads or SGI threads. Now create your super-application myfoo.app and compile anywhere with -gcc -o -c myfoo.cpp -I/usr/local/include -L/usr/local/lib -lwx_gtk +g++ myfoo.cpp `wx-config --libs` `wx-config --cflags` -o myfoo * General ----------------------- @@ -188,15 +188,11 @@ 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 ------------- @@ -204,19 +200,14 @@ implemented. The following must be done in the base directory (e.g. ~/wxGTK or ~/wxWin or whatever) -Dependencies are generated automatically using - - make depend - -(For some reason, this doesn't seem to work.) - -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. +files in this distribution. During compilation, you'll get +a few warning messages. if you want to be more selective: @@ -256,10 +247,34 @@ will do the work for you. * Creating a new Project -------------------------- -There are two ways to create your own project. The first 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. +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: @@ -274,12 +289,6 @@ 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). -The other way uses the installed libraries and header files in -/usr/local/include/wx and /usr/local/lib. In this case, just -compile your program like this: - -gcc -o -c myfoo.cpp -I/usr/local/include -L/usr/local/lib -lwx_gtk - ** Something about Makefiles ------------------------------