LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-13-2013, 11:10 AM   #1
tuto
LQ Newbie
 
Registered: Aug 2013
Posts: 11

Rep: Reputation: Disabled
GTK# installed but not recognized


I just moved from C# programming on Windows to C# on Linux and I tried a simple Hello World application that uses GTK# for GUI. However, the first time I tried to built it MonoDevelop complained that package Gtk cannot be found. I installed "GTK and GNOME bindings for Mono" from yum (along with other GTK-related packages) but the problem persisted. Then I type in the terminal
Code:
pkg-config --list-all
but no GTK package was listed. I found in another forum that pkg-config lists only packages that have *.pc file. I tried
Code:
locate gtk-sharp-2.0.pc
but no file was found. Finally I added manually inside MonoDevelop an assembly reference to 'gtk-sharp.dll' (which is in /usr/lib/mono/gtk-sharp-2.0). The program compiled but now crashed with uncaught exception.
Code:
public static void Main (string[  ] args)

  {

    Application.Init ( );
  }
Application.init(); causes System.DllNotFoundException.
A file named libglib-2.0-0.dll is referenced in the report.
 
Old 08-13-2013, 03:28 PM   #2
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
i would move all that Microsoft windows .net code over to c++
mono is always going to be 3 or MORE versions behind .net-framework , and missing a lot of the api's that are in Microsoft's code for use on a MS os


as per your problem you are likely missing the "-dev.deb's" if this is a Debian OS
or the "-devel.rpm's" if this is a red hat os

you mention "yum"
so this is one of the red hat family of os's
Fedora 18 or 19
CentOS 5.9 or 6.4 ( mono is version 2.4.3.1 in rhel6 )
RHEL 5.9 or 6.4
ScientificLinux 5.9 or 6.4

Last edited by John VV; 08-13-2013 at 03:33 PM.
 
1 members found this post helpful.
Old 08-21-2013, 10:27 AM   #3
tuto
LQ Newbie
 
Registered: Aug 2013
Posts: 11

Original Poster
Rep: Reputation: Disabled
Installing developer packages of GTK and GTK# solved the problem.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Shift-Fn keys not recognized with GTK applications philanc Slackware 1 09-22-2012 05:30 PM
OpenSuse: build is installed but not recognized by make. StefanB46 Linux - Newbie 6 07-06-2010 04:12 AM
Installed software not recognized Carunkumar Linux - Software 7 09-14-2007 07:38 AM
nVidia drivers installed but not recognized mmaleck Linux - Newbie 5 03-16-2007 02:28 PM
?? installed memory is not recognized kaz2100 Linux - General 6 07-13-2006 01:38 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:12 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration