IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

GTK+ avec C & C++ Discussion :

Compiler Gtk4 sur ubuntu 18 LTS


Sujet :

GTK+ avec C & C++

  1. #1
    Membre régulier
    Profil pro
    Inscrit en
    Mars 2008
    Messages
    147
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mars 2008
    Messages : 147
    Points : 88
    Points
    88
    Par défaut Compiler Gtk4 sur ubuntu 18 LTS
    Bonjour à tous
    je me suis lancé pour faire des tests de Gtk4 sous la forme de la version gtk+-3.94.0

    j’ai téléchargé les codes sources pour les compiler car je n’ai pas trouvé d’autre façon d’installer gtk 4

    J’ai déjà beaucoup de voyant au vert, mais je bute sur la compilation de Pango

    Une fois téléchargé pango-1.43.0.tar.xz et extrait, j’utilise meson

    voici le bilan
    au passage j’ai bien mis une version de meson >=0.48

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    The Meson build system
    Version: 0.51.0
    Source dir: /home/francis/Téléchargements/pango-1.43.0
    Build dir: /home/francis/Téléchargements/pango-1.43.0/pango_143
    Build type: native build
    Project name: pango
    Project version: 1.43.0
    C compiler for the build machine: cc (gcc 7.4.0 "cc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0")
    C++ compiler for the build machine: c++ (gcc 7.4.0 "c++ (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0")
    C compiler for the host machine: cc (gcc 7.4.0 "cc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0")
    C++ compiler for the host machine: c++ (gcc 7.4.0 "c++ (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0")
    Build machine cpu family: x86_64
    Build machine cpu: x86_64
    Compiler for C supports arguments -Wimplicit-function-declaration: YES 
    Compiler for C supports arguments -Wstrict-prototypes: YES 
    Compiler for C supports arguments -Wmissing-prototypes: YES 
    Compiler for C supports arguments -Wnested-externs: YES 
    Compiler for C supports arguments -Wold-style-definition: YES 
    Compiler for C supports arguments -Wno-int-conversion -Wint-conversion: YES 
    Compiler for C supports arguments -Wno-discarded-qualifiers -Wdiscarded-qualifiers: YES 
    Compiler for C supports arguments -fno-strict-aliasing: YES 
    Compiler for C supports arguments -Wpointer-arith: YES 
    Compiler for C supports arguments -Wmissing-declarations: YES 
    Compiler for C supports arguments -Wformat=2: YES 
    Compiler for C supports arguments -Wformat-nonliteral: YES 
    Compiler for C supports arguments -Wformat-security: YES 
    Compiler for C supports arguments -Wunused: YES 
    Compiler for C supports arguments -Wcast-align: YES 
    Compiler for C supports arguments -Wmissing-noreturn: YES 
    Compiler for C supports arguments -Wmissing-format-attribute: YES 
    Compiler for C supports arguments -Wmissing-include-dirs: YES 
    Compiler for C supports arguments -Wlogical-op: YES 
    Compiler for C supports arguments -Wno-uninitialized -Wuninitialized: YES 
    Compiler for C supports arguments -Wno-shadow -Wshadow: YES 
    Compiler for C supports arguments -Werror=redundant-decls: YES 
    Compiler for C supports arguments -Werror=implicit: YES 
    Compiler for C supports arguments -Werror=nonnull: YES 
    Compiler for C supports arguments -Werror=init-self: YES 
    Compiler for C supports arguments -Werror=main: YES 
    Compiler for C supports arguments -Werror=missing-braces: YES 
    Compiler for C supports arguments -Werror=sequence-point: YES 
    Compiler for C supports arguments -Werror=return-type: YES 
    Compiler for C supports arguments -Werror=trigraphs: YES 
    Compiler for C supports arguments -Werror=array-bounds: YES 
    Compiler for C supports arguments -Werror=write-strings: YES 
    Compiler for C supports arguments -Werror=address: YES 
    Compiler for C supports arguments -Werror=int-to-pointer-cast: YES 
    Compiler for C supports arguments -Werror=pointer-to-int-cast: YES 
    Compiler for C supports arguments -Werror=empty-body: YES 
    Compiler for C supports arguments -Werror=write-strings: YES (cached)
    Compiler for C supports arguments -Wundef: YES 
    Compiler for C supports arguments -fvisibility=hidden: YES 
    Compiler for C supports link arguments -Wl,-Bsymbolic: YES 
    Compiler for C supports link arguments -Wl,-z,relro: YES 
    Compiler for C supports link arguments -Wl,-z,now: YES 
    Checking for function "sysconf" : YES 
    Checking for function "getpagesize" : YES 
    Checking for function "flockfile" : YES 
    Checking for function "strtok_r" : YES 
    Has header "unistd.h" : YES 
    Has header "sys/mman.h" : YES 
    Has header "dirent.h" : YES 
    Library m found: YES
    Found pkg-config: /usr/bin/pkg-config (0.29.1)
    Run-time dependency glib-2.0 found: YES 2.56.4
    Run-time dependency gobject-2.0 found: YES 2.56.4
    Found CMake: /usr/bin/cmake (3.10.2)
    Run-time dependency fribidi found: NO (tried pkgconfig and cmake)
    Looking for a fallback subproject for the dependency fribidi
    Traceback (most recent call last):
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/mesonmain.py", line 127, in run
        return options.run_func(options)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/msetup.py", line 240, in run
        app.generate()
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/msetup.py", line 158, in generate
        self._generate(env)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/msetup.py", line 187, in _generate
        intr.run()
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreter.py", line 3917, in run
        super().run()
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 407, in run
        self.evaluate_codeblock(self.ast, start=1)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 431, in evaluate_codeblock
        raise e
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 425, in evaluate_codeblock
        self.evaluate_statement(cur)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 438, in evaluate_statement
        return self.assignment(cur)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 1048, in assignment
        value = self.evaluate_statement(node.value)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 436, in evaluate_statement
        return self.function_call(cur)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 773, in function_call
        return func(node, posargs, kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 285, in wrapped
        return f(*wrapped_args, **wrapped_kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 285, in wrapped
        return f(*wrapped_args, **wrapped_kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 285, in wrapped
        return f(*wrapped_args, **wrapped_kwargs)
      [Previous line repeated 1 more time]
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 155, in wrapped
        ret = f(*wrapped_args, **wrapped_kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreterbase.py", line 174, in wrapped
        return f(*wrapped_args, **wrapped_kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreter.py", line 3028, in func_dependency
        d = self.dependency_impl(name, display_name, kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreter.py", line 3088, in dependency_impl
        return self.dependency_fallback(display_name, kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreter.py", line 3139, in dependency_fallback
        self.do_subproject(dirname, 'meson', sp_kwargs)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/interpreter.py", line 2452, in do_subproject
        resolved = r.resolve(dirname, method)
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/wrap/wrap.py", line 154, in resolve
        self.get_git()
      File "/home/francis/.local/lib/python3.6/site-packages/mesonbuild/wrap/wrap.py", line 230, in get_git
        self.directory], cwd=self.subdir_root)
      File "/usr/lib/python3.6/subprocess.py", line 306, in check_call
        retcode = call(*popenargs, **kwargs)
      File "/usr/lib/python3.6/subprocess.py", line 287, in call
        with Popen(*popenargs, **kwargs) as p:
      File "/usr/lib/python3.6/subprocess.py", line 729, in __init__
        restore_signals, start_new_session)
      File "/usr/lib/python3.6/subprocess.py", line 1364, in _execute_child
        raise child_exception_type(errno_num, err_msg, err_filename)
    FileNotFoundError: [Errno 2] No such file or directory: 'git': 'git'
    Une anomalie
    Run-time dependency fribidi found: NO (tried pkgconfig and cmake)

    il me manque la librairie fribidi

    en tapant fribidi ubuntu me repond d’installer
    sudo apt-get install libfribidi-bin

    je l’ai installé mais sans resultat pour ma compilation sur Pango

    du coup je tente de compiler fribidi à partir des codes sources et j’obtiens bien fribidi

    fribidi --version
    fribidi (GNU FriBidi) 0.19.7
    interface version 3,
    Unicode Character Database version 6.2.0

    Même après un reboot je n'ai toujours pas fribidi installé au yeux de la commande meson.build

    Avez-vous une idée pour m’aider à avancer?

    Pardon d'avance si tout est déjà écrit quelque part (Qwant a bien chauffé avant ma question et je ne détaille pas les points intermédiaires)

  2. #2
    Expert confirmé
    Avatar de gerald3d
    Homme Profil pro
    Conducteur de train
    Inscrit en
    Février 2008
    Messages
    2 291
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 53
    Localisation : France, Côte d'Or (Bourgogne)

    Informations professionnelles :
    Activité : Conducteur de train
    Secteur : Transports

    Informations forums :
    Inscription : Février 2008
    Messages : 2 291
    Points : 4 941
    Points
    4 941
    Billets dans le blog
    5
    Par défaut
    Bonjour.

    Je n’ai jamais tenté cette compilation mais la dernière ligne que tu nous montres indique qu’il manque l’application git.

    Je ne sais pas si ça peut aider...

  3. #3
    Membre régulier
    Profil pro
    Inscrit en
    Mars 2008
    Messages
    147
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mars 2008
    Messages : 147
    Points : 88
    Points
    88
    Par défaut
    merci c'est effectivement un autre point à traiter. je vais regarder cela en attendant ma question initiale

  4. #4
    Membre régulier
    Profil pro
    Inscrit en
    Mars 2008
    Messages
    147
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mars 2008
    Messages : 147
    Points : 88
    Points
    88
    Par défaut
    après avoir installé git par sudo apt-get install git

    j'ai avancé d'un grand pas merci gerald3d
    j'ai du aussi installer un autre truc
    La commande «*g-ir-scanner*» n'a pas été trouvée, mais peut être installée avec*:

    sudo apt install gobject-introspection

    j'ai pu aller jusqu'a la compilation mais avec des erreurs. Sa devient compliqué je ne sais pas si je vais pouvoir m'en sortir. je vais creuser encore en détail et revient apres analyse et essai

    s'il y a plus simple je suis preneur car je ne suis pas un Pro du domaine.

  5. #5
    Modérateur

    Homme Profil pro
    Développeur informatique
    Inscrit en
    Juin 2009
    Messages
    1 395
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : Industrie

    Informations forums :
    Inscription : Juin 2009
    Messages : 1 395
    Points : 2 002
    Points
    2 002
    Par défaut
    Avant je t'aurais dit d'utiliser jhbuild pour compiler. C'était l'outil de référence pour compiler les composants de la stack GNOME. Maintenant, depuis la migration à BuildStream, je ne sais pas si c'est toujours d'actualité. Tu as peut être auss des version pré-compilées via BuildStream, à voir (je n'ai pas eu l'occasion de rentrer dedans).

    Cependant, normalement depuis la migration à Meson, builder GTK+ devrait être grandement simplifié, car Meson devrait lui même aller chercher les dépendances à compiler:
    http://nibblestew.blogspot.com/2018/...in-action.html

    Autre chose, je te conseille de récupérer les sources de GTK+ via git, et faire un checkout du tag correspondant à la version qui t'intéresse, et compiler cela, plutôt que récupérer des tarballs. C'est beaucoup plus facile à synchroniser et ça bouffe moins de bande passante et d'espace disque.
    Documentation officielle GTK+ 3:
    GTK en C, GTK en Python

    Tutoriels GTK+ 3:
    GTK en C, GTK en Python

    Tutoriels par l'exemple (platform-demos):
    GTK (tous langages)

Discussions similaires

  1. commande de compilation sur Ubuntu pour un fichier.f
    Par mgoumine dans le forum Fortran
    Réponses: 2
    Dernier message: 23/12/2011, 15h56
  2. installation de xen 3.0 sur ubuntu 6.06 LTS
    Par tithjy dans le forum Shell et commandes GNU
    Réponses: 1
    Dernier message: 23/08/2010, 08h28
  3. Questions sur la compilation Kernel sous Ubuntu
    Par jaymzwise dans le forum Administration système
    Réponses: 2
    Dernier message: 12/03/2008, 15h29
  4. problème de compilation sur Ubuntu
    Par mister bean dans le forum Linux
    Réponses: 2
    Dernier message: 15/02/2008, 22h38
  5. compilation libgz sur ubuntu
    Par chaying dans le forum Caml
    Réponses: 22
    Dernier message: 05/08/2007, 06h58

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo