From c98f04213ed354d0116092e87a30db5dc69c5709 Mon Sep 17 00:00:00 2001 From: Robert Roebling Date: Thu, 3 Sep 1998 13:58:56 +0000 Subject: [PATCH] make install git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@654 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- .cvsignore | 3 + Makefile | 6 + configure | 8 +- configure.in | 6 +- docs/gtk/install.txt | 420 +++++++++++++++++++++++++++++++++ docs/gtk/welcome.html | 292 ----------------------- include/wx/setup.h | 2 +- mkinstalldirs | 36 +++ src/Makefile.in | 39 +++ utils/glcanvas/src/Makefile.in | 23 ++ utils/serialize/Makefile.in | 25 +- utils/wxprop/src/Makefile.in | 24 ++ 12 files changed, 583 insertions(+), 301 deletions(-) create mode 100644 docs/gtk/install.txt delete mode 100644 docs/gtk/welcome.html create mode 100644 mkinstalldirs diff --git a/.cvsignore b/.cvsignore index a61591ad04..93f47969ce 100644 --- a/.cvsignore +++ b/.cvsignore @@ -2,3 +2,6 @@ system.list bin .gdb_history Test +config.cashe +config.status +system.list diff --git a/Makefile b/Makefile index 5d3dd8e373..c35ef5ea06 100644 --- a/Makefile +++ b/Makefile @@ -53,6 +53,12 @@ user:: @echo "entering directory user building all" @cd user; ${MAKE} all +install:: + @echo "entering directory src for installing" + @cd src; ${MAKE} install + @echo "entering directory utils for installing" + @cd utils; ${MAKE} install + # the following ones recreate all Makefiles. makefiles:: recreate diff --git a/configure b/configure index bd16458ac5..792f25a624 100755 --- a/configure +++ b/configure @@ -4199,11 +4199,11 @@ touch ${OSTYPE}.system.cache.tmp touch ${OSTYPE}.system.cache -DEFAULT_USE_GTK=0 +DEFAULT_USE_GTK=1 DEFAULT_USE_QT=0 DEFAULT_USE_MOTIF=0 -DEFAULT_USE_SHARED=0 +DEFAULT_USE_SHARED=1 DEFAULT_USE_OPTIMISE=1 DEFAULT_USE_PROFILE=0 DEFAULT_USE_DEBUG_FLAG=0 @@ -6881,7 +6881,7 @@ done ac_given_srcdir=$srcdir ac_given_INSTALL="$INSTALL" -trap 'rm -fr `echo "./setup/substit ./setup/setup.h:./setup/setup.hin" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +trap 'rm -fr `echo "./setup/substit ./include/wx/gtk/setup.h:./setup/setup.hin" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF fi diff --git a/configure.in b/configure.in index 1316938f32..230bcbdcb8 100644 --- a/configure.in +++ b/configure.in @@ -642,11 +642,11 @@ dnl ------------------------------------------------------------------------ AC_OVERRIDES_PREPARE -DEFAULT_USE_GTK=0 +DEFAULT_USE_GTK=1 DEFAULT_USE_QT=0 DEFAULT_USE_MOTIF=0 -DEFAULT_USE_SHARED=0 +DEFAULT_USE_SHARED=1 DEFAULT_USE_OPTIMISE=1 DEFAULT_USE_PROFILE=0 DEFAULT_USE_DEBUG_FLAG=0 @@ -1546,7 +1546,7 @@ dnl ------------------------------------------------------------------------ dnl add OS to list of configured echo $OS >> system.list -AC_CONFIG_HEADER(./setup/setup.h:./setup/setup.hin) +AC_CONFIG_HEADER(./include/wx/gtk/setup.h:./setup/setup.hin) AC_OUTPUT(./setup/substit,./setup/general/createall) AC_OVERRIDES_DONE diff --git a/docs/gtk/install.txt b/docs/gtk/install.txt new file mode 100644 index 0000000000..24286b8abf --- /dev/null +++ b/docs/gtk/install.txt @@ -0,0 +1,420 @@ +* 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): + +./configure --with-gtk --with-shared --without-threads +make + +and drink 10 coffees. + + +* General +----------------------- + +The Unix variants of wxWindows use GNU configure. If you have problems +with your make use GNU make instead. + +Read my homepage at + + http://wesley.informatik.uni-freiburg.de/~wxxt + +for newest information. + +* 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. + +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. + +* 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. + +* 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. + + +* Create your configuration +----------------------------- + +Usage: + ./configure options + +If you want to use system's C and C++ compiler, +set environment variables CC and CCC as + + % setenv CC cc + % setenv CCC CC + % ./configure options + +Using the SGI native compilers, it is recommended that you +also set CFLAGS and CXXFLAGS before running configure. These +should be set to : + +CFLAGS="-mips3 -n32" +CXXFLAGS="-mips3 -n32" + +This is essential if you want to use the resultant binaries +on any other machine than the one it was compiled on. If you +have a 64bit machine (Octane) you should also do this to ensure +you don't accidently build the libraries as 64bit (which is +untested). + +The SGI native compiler support has only been tested on Irix 6.5. + +to see all the options please use: + + ./configure --help + +The basic philosophy is that if you want to use different +configurations, like a debug and a release version, +or use the same source tree on different systems, +you have only to change the environment variable OSTYPE. +(Sadly this variable is not set by default on some systems +in some shells - on SGI's for example). So you will have to +set it there. This variable HAS to be set before starting +configure, so that it knows which system it tries to +configure for. + +Configure will complain if the system variable OSTYPE has +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 + + --with-gtk Use the GIMP ToolKit (GTK) + + --with-qt Use Qt from TrollTec + + --with-motif Use either Motif or Lesstif + Configure will look for both. + +The following options handle the kind of library you want to build. + + --without-threads Compile without thread support. + + --with-shared Create shared libraries. + + --without-optimise Do not optimise the code. + + --with-profile Add profiling info to the object + files. Currently broken, I think. + + --with-mem_tracing Add built-in memory tracing. + This doesn't work well with gcc. + + --with-dmalloc Use the dmalloc memory debugger. + Read more at www.letters.com/dmalloc/ + + --with-debug_info Add debug info to object files and + executables. + + --with-debug_flag Define __DEBUG__ and __WXDEBUG__ when + compiling. + +* 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. + +* 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 + + 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: + + make + +make yourself some coffee, as it will try to compile +ALL the files in this distribution. + +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 + +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: + + bin/$(OSTYPE) and + lib/$(OSTYPE) respectively + +"local" binaries and libraries will be placed in: + + (basedir of that application)/$(OSTYPE). + +This is also the place where all the object-files will go. + +If you want to conserve disk space by removing unnecessary +object-files: + + make clean_obj + +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. + +This directory then should include the following files: + +Makefile (You can copy this one from any application in samples + probably you will not need to edit this one. There is + only one case where you might be interested in changing + this file, but about that see later.) +Makefile.in (This is the base application-Makefile template, from + which the actual Makefile for each system is created. + More about this later) + +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 +------------------------------ + +On general principle it should only contain ONE line, which is as follows: + + include ../../setup/general/makeapp + +this will include all the necessary definitions for creating the applications + +the only case where you might want to add another line is the following: +this version of configure also supports creation of source archives of the +application for easy distribution and updates to newer version of wxWindows. + For this purpose all files in the application-directory will be put into +a gziped tar-file in the full notation user//* +if you want to include some other files that you want "more visible", like +a README. or a shell script for easy +compilation/installation/distribution, then you have to add a variable + + DISTRIBUTE_ADDITIONAL= + +to the Makefile. +So it would look like this: + + DISTRIBUTE_ADDITIONAL=README.TheApp + include ../../setup/general/makeapp + +As we have already talked about distribution the command to create a +distribution is: + + make distrib + +NOTE: If you are in the base directory of wxWindows it will create +distribution packages for wxWindows as well as for all packages in the +user directory. + So if you want to create only packages for the files in user, +then go to the directory other and type: + + make distrib + +or if you only want one application to be created then +enter the specific directory and type there: +make distrib + +All the distribution files will be put in the directory +distrib at the base of the wxWindows-tree (where also configure +and template.mak can be found). + +** Something about Makefile.in +-------------------------------- + +As you have already seen with Makefile, configure makes a lot of use +if the include statement in make to keep the Makefiles as simple as +possible. + +So basically there are only variables to define and then a include command. +Exception to this rule is if you have special rules for some stuff... +These rules should go AFTER the include statement!!! + +so the general header looks like this: + + # wxWindows base directory + WXBASEDIR=@WXBASEDIR@ + # set the OS type for compilation + OS=@OS@ + # compile a library only + RULE=bin + +and the general footer will look like this: + + # include the definitions now + include ../../../template.mak + +the key variable is RULE, which defines what make should create +in this directory. + +here are some examples: + + RULE description + =========================================================================== + bin creates a local binary (for a global binary prefix bin with g) + additional variables needed: + BIN_TARGET this gives the name of your application + BIN_OBJ this gives the object files needed to + link the application + optional variables are: + BIN_SRC this gives the list of c/c++ files for + which dependencies will be checked. + (This can be achieved with: make depend) + BIN_LINK this gives commands for additional + libraries needed to link the application + --------------------------------------------------------------------------- + bin2 creates two local binaries (for global binaries prefix bin2 with g) + in addition to the variables specified above you MUST also + provide the same variables with BIN2_ instead of BIN_ + --------------------------------------------------------------------------- + lib creates a local library (for a global binary prefix bin with g) + additional variables needed: + LIB_TARGET this gives the name of your library + LIB_OBJ this gives the object files needed for + the library to be build. + optional variables are: + LIB_SRC this gives the list of c/c++ files for + which dependencies will be checked. + libbin and libgbin are also possible and will need in addition + the variables from bin + --------------------------------------------------------------------------- + gslib is similar to lib, but it creates a shared library if the system + supports it. + additional variables needed: + LIB_MAJOR major number of the shared library + LIB_MINOR minor number of the shared library + --------------------------------------------------------------------------- + other additional variables: + + ADD_COMPILE define additional includes/defines that + are needed to compile the object files + (if you need to reference some directory + utils - like wxGrid -, then please + reference them with the variables defined + in template.mak - e.g.: $(SRCDIR),$(UTILS), + $(SAMPLES),$(OTHERS)) + + NEEDED_DEFINES lists all the defines that HAVE to be set in + /include/wx/setup.h to compile correctly. + + SRC_DIR lists all directories that are needed to + compile. (i.e: lists all the directories, + where there are source-files.) But it is + also needed to clean an object and for + machines, for which make does not support + VPATH + +currently there are the following compiling rules provided: +object files are created for the following file extensions: +.c .cc .cpp + +Please have a closer look at the Makefiles in this distribution. + +* Platforms configure is working with +--------------------------------------- + +Please report build succes on any machine. Especially non- +Linux operating systems (which I don't have). + +Original author of the autoconf system for wxxt-1.66 and for this INSTALL +file: + + Martin Sperl sperl@dsn.ast.univie.ac.at + +Ported to wxGTK 0.1: + + Wolfram Gloger wmglo@dent.med.uni-muenchen.de + +Thanks alot to both of them. + +In the hope that it will be useful, + + Robert Roebling roebling@sun2.ruf.uni-freiburg.de + + diff --git a/docs/gtk/welcome.html b/docs/gtk/welcome.html deleted file mode 100644 index ac59b63028..0000000000 --- a/docs/gtk/welcome.html +++ /dev/null @@ -1,292 +0,0 @@ - -wxGTK Homepage - - -

"wxWindows for the GTK" Homepage

- -
-

Current version

-15th May '98: wxGTK v0.12 (alpha-) -

-This release is hardly more stable than the one before, but it -has many new features. It's main purpose is actually to prepare -the final merge of the Windows port and the GTK port source -trees into a common tree, developed using CVS. The growing -number of demos which compile and run with wxGTK "although" -being written for wxMSW shows that we seem to be on the right -track. One nice new feature for many potential users is that -wxGTK no longer needs any extra libraries to be installed, -other than the GTK. -

-If you have a compiler -better than gcc 2.7.2.2 then you can uncomment a line in src/common/prntbase.cpp -which defines __GOOD_COMPILER__. This should make the printing demo work. -I haven't got such a compiler, so I actually don't know. Somebody reported -problems with version 2.7.2.3 as well. -

-


-

Acknowledgements

-I'd like to thank the -Freiburg Linux User Group - for kindly providing -this site and Christian Wetzel in particular for helping me with -this site's administration. -

- -


-

What is wxWindows?

-wxWindows is a C++ cross-platform GUI toolkit written mainly by Julian Smart. -More information about wxWindows can be found at the -wxWindows Homepage. - -

-The current version of wxWindows (v1.68) supports Windows ('95 and NT), Motif and -XView (aka OpenLook). There is another port (wxXt) available, which uses the -free-ware widget set from the Free Widget Foundation (FSF). Ports have been -started for the Mac, OS/2 and NextStep. -

-For different reasons, it was decided to start a complete rewrite of wxWindows, -which will then be called wxWindows 2.0. For a list of new features and changes -from the current version, you may read the wxWindows Homepage (see above). -

-Currently, work is being done on four ports of wxWindows 2.0: -

-
  • Windows (wxMSW, main author Julian Smart) -
  • Unix, Motif (wxMotif, main author Markus Holzhem) -
  • Unix, GIMP Toolkit (wxGTK, main author Robert Roebling) -
  • Macintosh (wxMac, main author Greg Whitehead) -
  • -

    -wxWindows provides a rich set of classes which help to make cross-platform -GUI programming easy. In many aspect, it is modelled after MFC, making transition -from MFC to wxWindows relatively painless. The main technical -difference between most other free or commercial cross platform libraries is -that wxWindows is a wrapper around existing widget sets, whereas the other -toolkits (Qt, Tk, Java, Amulet, OPaC, JX, Fresko) draw their widgets themselves, -which results in applications having a different look than native applications -for that specific platform. -

    -There are classes for the following categories -

    -
  • Window classes: wxWindow, wxFrame, wxDialogBox, wxPanel, wxCanvas etc. -
  • Widget classes: wxButton, wxCheckbox, wxChoice, wxListBox, wxListCtrl, wxText, wxGauge etc. -
  • Data structures: wxList, wxString, wxHashTable, wxDate etc. -
  • Layout/constraint system -
  • GDI classes: wxPen, wxBrush, wxFont, wxBitmap etc. -
  • Events: wxCommandEvent, wxMouseEvent, wxKeyEvent etc. -
  • Devices contexts: wxCanvasDC, wxPostScriptDC, wxMemoryDC, wxPrinterDC -
  • Base classes for runtime-type information: wxObject -
  • Interprocess communication: wxClient, wxConnection, wxSocket, wxServer etc. -
  • Document-view architecture: wxDocument, wxView, wxDocManager etc. -
  • Printing framework: wxPreviewFrame, wxPrintDialog, wxPrinter etc. -
  • Many helper classes, wxApplication, wxTypeTree, wxPathList etc. -
  • Classes for internationalization -
  • Built-in memory leak checking, log-files -
  • A multitude of functions and macros -
  • - -
    -

    Copyright

    -The choice of a suitable copyright has been subject to endless discussions. It -has always been the aim, to put wxWindows under a copyright, which protects -the work of its authors while at the same time encouraging the use of wxWindows -in as many projects as possible. -

    -The (so far) last decision has been to put the whole of wxWindows -under a modified (less restrictive) version of the GNU library general -public license. -

    -The only exception is that wxGTK now contains code (gdk_imlib) which is -under the GNU library general public license. When you make changes to -this part of wxGTK, you'll have to make these changes public (in contrast -to changes to the rest). -

    -It is obviously encouraged that anybody who uses wxWindows and who -makes any improvements to it will make these changes available to -wxWindows' authors. -

    -


    -

    What can I do with wxWindows 2.0?

    -wxWindows is still in alpha stage, which means that there are still bugs -waiting for you and several features are not yet (fully) implemented, but -you can expect the interface to be more or less stable, so no major -modifications will have to be made to your source code. wxGTK is already -used in a number of medium sized projects and is it being developped -in close cooperation with the authors of these applications. -

    -


    -

    Can I write a GNOME application with wxGTK 2.0?

    -Good question. The idea to use wxGTK for the GNOME desktop environment is -quite obvious. When this topic came up on the GNOME mailing list, the GNOME -people have shown an amazingly negative opinion about wxWindows. One reason -might be that several of the main authors of the GNOME-project consider -C++ a "broken language". I don't share that view and I am sure many people -find C++ easier to handle and better suited for GUI programming than C. -

    -Just recently, the topic of C++ in general and wxGTK in particular appeared -again on the GNOME list. It has shown that - at least - the opinion on C++ -on the GNOME list is split. -

    -There is already a C++ wrapper for the GTK called GTK-- written by Tero Pulkkinen. -It is very small and adds very little overhead to the GTK. If platform -independence is no issue for you and you want to write a small tool -for Linux, you should probably use GTK--. Of course you can use wxGTK -for that, too :-) -

    -


    -

    Screenshots

    -What would a home page of a GUI be without a screenshot? Well, as wxWindows -is a wrapper around existing widget/item sets, a wxWindows application will -look like any other native Windows, Motif, GTK or Mac application. -

    -But for those of you, who wouldn't download wxGTK only because there -is no screenshot, -here it comes. -

    -


    -

    Download 1.68

    -Go to the -FTP -section directly. -

    -There is documentation for version 1.68 in html available. -here. Not yet. -

    -You can download current wxWindows version 1.68 for Windows, Motif and -XView from -here. Not yet. -

    -You can download wxXt 1.66d from -here. -

    -


    -

    Download 2.0 alpha

    -There is documentation for version 2.0 in html available. -here. -

    -You can download the first alpha for wxWindows 2.0 for Windows from -here. Not yet. -

    -You can download the current alpha for wxWindows 2.0 for GTK from -here. -

    - -


    -

    News from wxGTK 0.12

    -

    -PNG, zlib and gdk_imlib code included. -

    -MDI implementation. More a basis for further testing -than of real value. -

    -Split "--with-debug" option into two options: "--with-debug_info" -and "--with-debug_flag". The first one sets the "-g" flag when -compiling, the second defines "DEBUG" in setup.h (which is included -from defs.h). -

    -Merged DocView framework. The sample doesn't compile yet, because -it uses features from wxTextCtrl, which I haven't implemented yet. -

    -Merged TabCtrl. Doesn't look perfect, but it seems to work. -

    -Merged remaining classes from the newest wxMSW alpha. (wxDynArray, -wxModule etc.). -

    -Further updates, bug fixes or additions: -

    -

    -
  • wxYield() (again) -
  • postscript support for bitmaps -
  • spline code merged -
  • several bug fixes -
  • new samples -
  • - -

    -


    -

    Known problems

    - -Missing implementation of: -
    -
  • Impossible to set new font in GTK's widgets -
  • Items containing bitmaps -
  • Masks, bitmap handlers (partially done) -
  • Gauge -
  • Combobox -
  • Palettes (colormaps) -
  • Keyboard accelerators for menus -
  • Validation -
  • Clipboard functions -
  • Resources (for use with wxIDE-to-be) -
  • Drag and Drop -
  • Threads, Interprocess communication -
  • Sockets -
  • Database classes -
  • - -

    -


    -

    Installation of wxGTK under Linux

    - -GTK requires an up-to-date version of the -
    -
  • GTK (GIMP ToolKit) -
  • -to be installed as a shared lib on your system. wxGTK is being developped with -version 1.0.1 and it is known not to work with earlier versions. -The GTK library is available from -somewhere here (gtk.org). -After having typed "make install" the GTK header files should be -in "/usr/local/include". Correct me, if I am wrong. -

    -Compilation itself works as usual with autoconf: -

    -
  • Unpack it to a suitable subdirectory, let's say ~/wxGTK -
  • Type "cd wxGTK" -
  • Type "configure" -
  • Type "make" -
  • -Some demos use files stored in the source directory of those demos -(e.g. internat uses files in samples/internat) whereas the binaries -will end up in samples/internat/linux. You'll have to copy the binaries -down or call them like "linux/test" from samples/internat. This is -also the case for wxTest (which should display a horse). -

    -You can create a shared library by adding the option "--with-shared" to -the "configure" command. Afterwards, you'll have to copy the library -~/wxGTK/lib/linux (if you have Linux) to a directory in your LDPATH (e.g. /usr/X11R6/lib) -and run "ldconfig". -

    - -


    -

    Mailing list for wxGTK

    -The mailing list (as well as this page) is called wxxt for more -or less historical reasons. -

    -You can subsribe to the mailing list by sending a mail to -majordomo@wesley.informatik.uni-freiburg.de. -This mail must contain the text "subscribe wxxt" in the body (not the subject) of the -mail. You will then get a confirmation that somebody asked majordomo to put you -on the list and you will have to confirm this once again by sending back -the authentisation, which comes in the confirmation mail. The last step -is also described in the actual confirmation mail (I think). -

    -You can send a mail to the mailing list to the address -wxxt@www.freiburg.linux.de. - -

    -Unsubscribe by sending "unsubscribe wxxt" to majordomo (see above). Not to -the actual mailing list. -

    -


    -
    -
    This page is maintained by Robert Roebling. -Comments, in contrast to junk and flames, welcome. -

    -Last changed 15th Mai '98. -

    - - - - - diff --git a/include/wx/setup.h b/include/wx/setup.h index a3f5007bfe..54936598ae 100644 --- a/include/wx/setup.h +++ b/include/wx/setup.h @@ -19,7 +19,7 @@ #elif defined(__WXSTUBS__) #include "wx/stubs/setup.h" #elif defined(__WXGTK__) -#include "wx/../../setup/setup.h" +#include "wx/gtk/setup.h" #endif #endif diff --git a/mkinstalldirs b/mkinstalldirs new file mode 100644 index 0000000000..fef1eb9418 --- /dev/null +++ b/mkinstalldirs @@ -0,0 +1,36 @@ +#! /bin/sh +# mkinstalldirs --- make directory hierarchy +# Author: Noah Friedman +# Created: 1993-05-16 +# Last modified: 1994-03-25 +# Public domain + +errstatus=0 + +for file in ${1+"$@"} ; do + set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` + shift + + pathcomp= + for d in ${1+"$@"} ; do + pathcomp="$pathcomp$d" + case "$pathcomp" in + -* ) pathcomp=./$pathcomp ;; + esac + + if test ! -d "$pathcomp"; then + echo "mkdir $pathcomp" 1>&2 + mkdir "$pathcomp" > /dev/null 2>&1 || lasterr=$? + fi + + if test ! -d "$pathcomp"; then + errstatus=$lasterr + fi + + pathcomp="$pathcomp/" + done +done + +exit $errstatus + +# mkinstalldirs ends here diff --git a/src/Makefile.in b/src/Makefile.in index 401e958daa..c9dac31733 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -38,6 +38,45 @@ all:: @if test ! -d gdk_imlib; then mkdir gdk_imlib; fi @if test ! -d iodbc; then mkdir iodbc; fi +install:: + @echo "Installing library files and headers.." + @echo " Creating directories.." + @$(WXBASEDIR)/mkinstalldirs \ + /usr/local/include/wx \ + /usr/local/include/wx/gtk \ + /usr/local/include/wx/common \ + /usr/local/include/wx/generic + @echo " Copying headers from /include/wx" + @cd $(WXBASEDIR)/include/wx ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx/$$f ; \ + done + @echo " Copying headers from /include/wx/gtk" + @cd $(WXBASEDIR)/include/wx/gtk ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx/gtk/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx/gtk/$$f ; \ + done + @echo " Copying headers from /include/wx/generic" + @cd $(WXBASEDIR)/include/wx/generic ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx/generic/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx/generic/$$f ; \ + done + @echo " Copying static libraries files to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_gtk.a ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/lib/$$f ; \ + done + @echo " Copying shared libraries to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_gtk.so* ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_PROGRAM) $$f /usr/local/lib/$$f ; \ + done + clean:: $(RM) -rf gtk $(RM) -rf qt diff --git a/utils/glcanvas/src/Makefile.in b/utils/glcanvas/src/Makefile.in index da1865a403..2bed8a867e 100644 --- a/utils/glcanvas/src/Makefile.in +++ b/utils/glcanvas/src/Makefile.in @@ -42,3 +42,26 @@ ADD_COMPILE= # include the definitions now include ../../../../template.mak +install:: + @echo "Installing library files and headers for libwx_opengl_gtk.." + @echo " Creating directory.." + @$(WXBASEDIR)/mkinstalldirs /usr/local/include/wx_opengl + @echo " Copying headers from /include/wx" + @cd $(WXBASEDIR)/utils/glcanvas/src ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx_opengl/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx_opengl/$$f ; \ + done + @echo " Copying static library files to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_opengl_gtk.a ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/lib/$$f ; \ + done + @echo " Copying shared libraries to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_opengl_gtk.so* ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_PROGRAM) $$f /usr/local/lib/$$f ; \ + done + diff --git a/utils/serialize/Makefile.in b/utils/serialize/Makefile.in index de3d25ffef..7a8beeebb6 100644 --- a/utils/serialize/Makefile.in +++ b/utils/serialize/Makefile.in @@ -9,7 +9,7 @@ RULE=gslib # define common stuff # define library name -LIB_TARGET=wxserial +LIB_TARGET=wx_serial_gtk LIB_MAJOR=2 LIB_MINOR=0 # define library sources @@ -23,3 +23,26 @@ sermain.o sercore.o sergdi.o serwnd.o serctrl.o serext.o # include the definitions now include ../../../template.mak + +install:: + @echo "Installing library files and headers for libwx_serial_gtk.." + @echo " Creating directory.." + @$(WXBASEDIR)/mkinstalldirs /usr/local/include/wx_serial + @echo " Copying headers from /include/wx" + @cd $(WXBASEDIR)/utils/serialize ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx_serial/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx_serial/$$f ; \ + done + @echo " Copying static library files to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_serial_gtk.a ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/lib/$$f ; \ + done + @echo " Copying shared libraries to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_serial_gtk.so* ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_PROGRAM) $$f /usr/local/lib/$$f ; \ + done diff --git a/utils/wxprop/src/Makefile.in b/utils/wxprop/src/Makefile.in index 776e1703c3..7661897fcc 100644 --- a/utils/wxprop/src/Makefile.in +++ b/utils/wxprop/src/Makefile.in @@ -37,6 +37,30 @@ all:: clean:: +install:: + @echo "Installing library files and headers for libwx_prop_gtk.." + @echo " Creating directory.." + @$(WXBASEDIR)/mkinstalldirs /usr/local/include/wx_prop + @echo " Copying headers from /include/wx" + @cd $(WXBASEDIR)/utils/wxprop/src ; \ + for f in *.h ; do \ + rm -f /usr/local/include/wx_prop/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/include/wx_prop/$$f ; \ + done + @echo " Copying static library files to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_prop_gtk.a ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_DATA) $$f /usr/local/lib/$$f ; \ + done + @echo " Copying shared libraries to /usr/local/lib" + @cd $(WXBASEDIR)/lib/$(OS) ; \ + for f in libwx_prop_gtk.so* ; do \ + rm -f /usr/local/lib/$$f ; \ + $(INSTALL_PROGRAM) $$f /usr/local/lib/$$f ; \ + done + + #additional things needed for compile ADD_COMPILE= -- 2.45.2