Celebrate fc6's successful compilation of GTK + 2.14.1 x86 and helloworld

Source: Internet
Author: User
Tags cairo gtk

Fc6 compiled GTK + 2.14.1 x86 and helloworld records
Note: The order of Cairo and pango cannot be changed. It is best to follow this order.
Run

Compile pixman-0.11.10
./Configure
Make
Make install

Editing
Translated by Cairo-1.6.4
Export
Pkg_config_path =/usr/local/lib/pkgconfig: $ pkg_config_path
./Configure
Make
Make
Install

Compile glib-2.18.0.
./Configureu
Make
Make install

Editing
Translation pango-1.20.5
Export
Pkg_config_path =/usr/local/lib/pkgconfig: $ pkg_config_path
./Configure
Make
Make
Install

Compile atk-1.22.0
Export
Pkg_config_path =/usr/local/lib/pkgconfig: $ pkg_config_path
./Configure
Make
Make
Install

Compile GTK + 2.14.1
Export
Pkg_config_path =/usr/local/lib/pkgconfig: $ pkg_config_path
./Configure
-- Without-libjasper
Make
Make install

Execute helloworld
Export
LD_LIBRARY_PATH =/usr/lib:/usr/local/lib: $ LD_LIBRARY_PATH
Gcc
Helloword. C-o helloword 'pkg-config -- cflags -- libs GTK +-1000'
Note: Symbol
'Is the one under ESC, not a single quotation mark

Add prefix compilation as follows:

Fc8
Compiled GTK + 2.14.1 x86 and helloworld records
Note: The order of Cairo and pango cannot be changed. It is best to execute it in this order.

Editing
Translation pixman-0.11.10
./Configure -- prefix =/work/x86/gtklib
Make
Make
Install

Compile Cairo-1.6.4.
Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig: $ pkg_config_path
./Configure
-- Prefix =/work/x86/gtklib
Make
Make install

Compile glib-2.18.0
Translate ORBit2-2.14.16:
# The g_gnuc_pretty_function is undefined if the export variable is not found.
# Export
Pkg_config_path =/work/x86/gtklib/lib/P
Kgconfig
# Export
Gnome2_dir =/work/x86/gtklib
# Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
# Export
Path =/work/x86/gtklib/bin: $ path
# Fc8 compiled by (gcc-4.1.2)
./Configure
-- Prefix =/work/x86/gtklib -- enable-purify
./Configure
-- Prefix =/work/x86/gtklib
Make
Make install

Compile pango-1.20.5
Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig: $ pkg_config_path
./Configure
-- Prefix =/work/x86/gtklib
Make
Make install

Compile atk-1.22.0
Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig: $ pkg_config_path
Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
./Configure
-- Prefix =/work/x86/gtklib
Make
Make install

Compile GTK + 2.14.1
Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig: $ pkg_config_path
Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
./Configure
-- Without-libjasper -- prefix =/work/x86/gtklib
Make
Make install

Executive
Line helloworld
Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig: $ pkg_config_path
Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
Gcc
Helloword. C-o helloword 'pkg-config -- cflags -- libs GTK +-1000'
Note: Symbol
'Is the one under ESC, not a single quotation mark

 

 


 

Times when valgriand is used to test memory leakage
There was a large amount of memory leakage. Some articles on the Internet explained "improving our memory debugging Infrastructure ",
You can search for "GTK improving our memory debugging Infrastructure" by keyword on Google"
1.
Recompile orbit with the parameter -- enable-purify
2. Test

Compile ORBit2-2.14.16:
# No
Export variable... the g_gnuc_pretty_function is not defined.
# Export
Pkg_config_path =/work/x86/gtklib/lib/pkgconfig
# Export
Gnome2_dir =/work/x86/gtklib
# Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
# Export
Path =/work/x86/gtklib/bin: $ path
# Fc8 compiled by (gcc-4.1.2)
./Configure
-- Prefix =/work/x86/gtklib -- enable-purify

Test Memory Leak:
Export
LD_LIBRARY_PATH =/work/x86/gtklib/lib: $ LD_LIBRARY_PATH
Export
G_debug = GC-friendly
Export g_slice = always-malloc
Valgrind
-- Leak-check = full -- show-reachable = yes./helloword

Shift
Dynamic shared library location:
E.g. Move the path of gtklib from/work/x86/gtklib to/work/gtklib
1. mv
/Work/x86/gtklib/work/gtklib

2. Replace the string:
(Modify the library path)
CD
/Work/gtklib/lib/pkgconfig
Sed-I's;/work/x86/gtklib;/work/gtklib ;'
'LS'
Note: The symbol 'is under ESC, not a single quotation mark

3. Test
Export
Pkg_config_path =/work/gtklib/lib/pkgconfig: $ pkg_config_path
Export
LD_LIBRARY_PATH =/work/gtklib/lib: $ LD_LIBRARY_PATH
GCC helloword. C-o
Helloword 'pkg-config -- cflags -- libs GTK +-2.0'

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.