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 07-15-2010, 07:44 AM   #1
cvr
LQ Newbie
 
Registered: Jun 2010
Posts: 18

Rep: Reputation: 0
What are the types of API's?


Sir,

What are the different types of API's in linux?

How can we predict the kind of API we are using?
And what are API layers related to?

Are API's and system calls ,both are same?

Pls Let me know the good website regarding the API's .

Thanks in advance...bye
 
Old 07-15-2010, 08:18 AM   #2
bpogi
LQ Newbie
 
Registered: May 2009
Location: Georgia, USA
Distribution: Ubuntu, Debian, Gentoo
Posts: 15

Rep: Reputation: 1
There are dozens of API's that you could use, depending on what you are trying to do. Just google "Linux API" to see what I mean. There is an API for writing kernel software, a couple different ones that you could use for manipulating and mixing sound, a couple for drawing GUI's, and so on. GNU/Linux by itself is a relatively bare system, and that provides it some strength. Most of the API's can be installed on top of the basic system to provide extra functionality to programmers. You'll need to be a little more specific about what you are trying to accomplish to get any truly useful advice.
 
Old 07-15-2010, 08:40 AM   #3
PhantasyConcepts
LQ Newbie
 
Registered: May 2009
Posts: 19

Rep: Reputation: 3
Cool

cvr,

I think you may have some terms confused. API stands for Application Programming Interface. It does not necessarily have anything to do with system calls. It is basically a library of commonly used code segments that allow developers to write applications more easily.

Now with a working definition of API, your questions about different types of APIs seems to be an attempt to classify the many APIs into groups based upon functionality, such as "graphics, sound, and networking." This is not the case. Linux libraries are often created to combine functionality for a particular purpose. For example, although there is no "gaming" API on Linux, there is a 'driver API' that is loosely standardized. I say loosely because there is no specific document that says "all drivers must be signed by the kernel team." That being said, if it is included in the kernel, it has been approved by the kernel team, but they do not micromanage the coding style of the driver developer. There are basic standards that say that it cannot adversely affect other drivers within reasonable assurance, but until someone comes up with that WDC XT hard drive controller conflicting with the Intel X5904 802.11q card (no, I just made that up, it does not exist, although the WDC XT hard drive controller does, and was the HDC on the original IBM PC - I have one hidden in the basement somewhere) you cannot be certain that it will be 100% bug-free.

As for predicting the APIs that are being used, the answer is that you need to read as much as possible about the application you intend to run. For example, the Borland Delphi for Linux used a certain version of glibc as well as other libraries. If you were using a more recent one, you got the same error as if you were using an older version. IBM has some programs that are like that as well. The requirements are documented, however, and the best thing you can do is go to your linux distribution's package version tracker and find out what is installed in the libraries. (On Slackware, that is /var/log/packages, and in Red Hat, it is the rpm catalog, though I am not sure how to read that, as I don't use Red Hat.)
 
0 members found this post helpful.
Old 07-15-2010, 01:59 PM   #4
jhonkevin
LQ Newbie
 
Registered: Jul 2010
Posts: 3

Rep: Reputation: 0
API Types are three in linux
1. Constants
2. Declares and
3. Types
 
0 members found this post helpful.
Old 07-15-2010, 02:09 PM   #5
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,235

Rep: Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320
Quote:
Originally Posted by cvr View Post
Pls Let me know the good website regarding the API's
I'll give you two.

Quote:
What are the different types of API's in linux?

How can we predict the kind of API we are using?

And what are API layers related to?

Are API's and system calls ,both are same?
Why do I get the feeling that you have a question sheet in front of you containing these exact sentences? And that the answers are in the course materials that you were supposed to be studying?

The first three are not answerable as asked (not outside the context of the course, at least), and the fourth can be answered by definition. Learn what an API is and what a system call is.

Last edited by dugan; 07-15-2010 at 02:42 PM.
 
Old 07-15-2010, 07:26 PM   #6
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
Moving to Programming
 
  


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
sys/types.h & linux/types.h conflict while compiling johnnyhal Linux - Software 1 12-28-2008 06:39 PM
conflicting redeclaration of sys/types.h and linux/types.h schmil Programming 6 12-11-2008 02:02 PM
3D Api's....? resetreset Linux - Software 2 06-01-2008 12:34 PM
Linux API's hazzyb Programming 1 07-23-2005 10:50 AM
How to get Linux API's poda Linux - Newbie 4 07-19-2005 04:05 AM

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

All times are GMT -5. The time now is 06:55 PM.

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