From 0a8141bef5d589962a8147e1ab5e4193ac017639 Mon Sep 17 00:00:00 2001
From: scuri If you are going to build all the libraries, the makefiles and projects
expect the following directory tree: If you unpack all the source packages in the same directory, that structure will
be automatically created. If you want to use some of these libraries that are installed on the system
+(see Installation section bellow) you will have to define some environment
+variables before building them. For example: Although we use Lua from LuaBinaries, any Lua installation can also be used.
In Ubuntu, the Lua run time package is:/xxxx/
- cd/
+ lua5.1/ [optional, see note bellow]
im/
- iup/
- lua5.1/ [optional, see note bellow]
+ cd/
+ iup/
export IM_INC=/usr/include/im
+export IM_LIB=/usr/lib [not necessary, already included by gcc]
+
+export CD_INC=/usr/include/cd
+export CD_LIB=/usr/lib [not necessary, already included by gcc]
+
+export IUP_INC=/usr/include/iup
+export IUP_LIB=/usr/lib [not necessary, already included by gcc]
Lua
Do not extract different pre-compiled binaries in the same directory, create a subdirectory for each one, for example:
-mkdir iup -cd iup -tar -xpvzf ../iup-3.2_Linux26g4_lib.tar.gz +mkdir im +cd im +tar -xpvzf ../im-3.6.2_Linux26g4_lib.tar.gz cd .. mkdir cd @@ -125,11 +137,10 @@ cd cd tar -xpvzf ../cd-5.4_Linux26g4_lib.tar.gz cd .. -mkdir im -cd im -tar -xpvzf ../im-3.6.2_Linux26g4_lib.tar.gz +mkdir iup +cd iup +tar -xpvzf ../iup-3.2_Linux26g4_lib.tar.gz cd .. -For the installation instructions bellow, remove the "lib/Linux26g4" from the following examples if you are using the pre-compiled binaries.
@@ -137,23 +148,25 @@ following examples if you are using the pre-compiled binaries.After building you can copy the libraries files to the system directory. If you are inside the main directory, to install the run time libraries you can type, for example:
-sudo cp -f iup/lib/Linux26g4/*.so /usr/lib [script version: install ] -sudo cp -f cd/lib/Linux26g4/*.so /usr/lib -sudo cp -f im/lib/Linux26g4/*.so /usr/lib+sudo cp -f im/lib/Linux26g4/*.so /usr/lib [script version: install ] +sudo cp -f cd/lib/Linux26g4/*.so /usr/lib +sudo cp -f iup/lib/Linux26g4/*.so /usr/lib +To install the development files, then do:
-sudo mkdir -p /usr/include/iup [script version: install_dev ] -sudo cp -f iup/include/*.h /usr/include/iup -sudo cp -f iup/lib/Linux26g4/*.a /usr/lib ++sudo mkdir -p /usr/include/im [script version: install_dev ] +sudo cp -fR im/include/*.h /usr/include/im +sudo cp -f im/lib/Linux26g4/*.a /usr/lib sudo mkdir -p /usr/include/cd sudo cp -f cd/include/*.h /usr/include/cd sudo cp -f cd/lib/Linux26g4/*.a /usr/lib -sudo mkdir -p /usr/include/im -sudo cp -fR im/include/*.h /usr/include/im -sudo cp -f im/lib/Linux26g4/*.a /usr/lib-Then in your makefile use -Iiup -Icd -Iim for includes. There is no need to +sudo mkdir -p /usr/include/iup +sudo cp -f iup/include/*.h /usr/include/iup +sudo cp -f iup/lib/Linux26g4/*.a /usr/lib +
Then in your makefile use -Iim -Icd -Iiup for includes. There is no need to specify the libraries directory with -L. Development files are only necessary if you are going to compile an application or library in C/C++ that uses there libraries. To just run Lua scripts they are not necessary.
@@ -162,7 +175,7 @@ libraries. To just run Lua scripts they are not necessary. directory, you can use them from build directory. You will need to add the run time libraries folders to the LD_LIBRARY_PATH, for example: -export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/xxxx/iup/lib/Linux26g4:/xxxx/cd/lib/Linux26g4:/xxxx/im/lib/Linux26g4+export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/xxxx/im/lib/Linux26g4:/xxxx/cd/lib/Linux26g4:/xxxx/iup/lib/Linux26g4And in your makefile will will also need to specify those paths when linking using -L/xxxx/iup/lib/Linux26g4, and for compiling use -I/xxxx/iup/include.
-- cgit v1.2.3