LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   What is a repository and dependency? (https://www.linuxquestions.org/questions/linux-newbie-8/what-is-a-repository-and-dependency-702280/)

QueenZ 02-04-2009 11:56 AM

What is a repository and dependency?
 
I see these things very often in Linux but i don't know what they mean.. :( repositories.. dependencies.. they're all the same to me.. are these some kind of programs or something?

r3sistance 02-04-2009 12:01 PM

Repositories are simply as they say, Repositories... In terms of package managers which this term generally comes up in, they are areas that store applications and updates.

Dependencies are simply programs or libaries that are required for a certain application to work correctly. You can't run the php module for Apache without having apache, so apache is the dependency of the php module.

pljvaldez 02-04-2009 12:09 PM

A repository is a collection of programs. In linux, each distribution maintains a collection of the software included. This makes it easy to install and make sure that it works well with that linux distribution. So instead of googling around the web for a *.exe file in Windows, then installing it, you just point your package manager at this collection (repository) and say "install openoffice and firefox" and it installs both. There are usually "official" and "unofficial" repositories. For example, the main Debian repositories are maintained by the Debian project, but Debian Multimedia is maintained by some guy in his basement (though he does a great job) and includes things that the Debian project won't due to legal, freedom, or other reasons (like proprietary codecs and drivers, etc).

Now, linux is a modular system and developers are encouraged to avoid "re-inventing the wheel" when they write new programs. So if a developer is writing a program called "foo", he might need a certain library of functions for graphics display or math or something else. So in his program, instead of re-creating these functions, he might use this other guy's program, "bar". So "foo" depends on "bar". So a good reason to use the repositories and the distro package managers are that whenever you install a program, it also installs all the programs that are required to make it run properly.

QueenZ 02-04-2009 12:21 PM

Quote:

Originally Posted by pljvaldez (Post 3432123)
Now, linux is a modular system and developers are encouraged to avoid "re-inventing the wheel" when they write new programs. So if a developer is writing a program called "foo", he might need a certain library of functions for graphics display or math or something else. So in his program, instead of re-creating these functions, he might use this other guy's program, "bar". So "foo" depends on "bar". So a good reason to use the repositories and the distro package managers are that whenever you install a program, it also installs all the programs that are required to make it run properly.

Hmm.. that is interesting.. So in windows it would be like making VLC and installing Skype as well or something like that?

pljvaldez 02-04-2009 01:59 PM

I don't know much about VLC or skype so I can't comment.

But you can look at this site for Debian programs and see the dependency trees.

Here's a dependency map for openoffice.org. As you can see, when you install openoffice, they built openoffice by using a bunch of little parts other people already had done, and then tied them all together to make a great office suite.

digerati1338 02-04-2009 11:04 PM

Quote:

Hmm.. that is interesting.. So in windows it would be like making VLC and installing Skype as well or something like that?
Not really. Those are independent applications. It would be more like you asking to have Frostwire installed. Frostwire requires Java or it won't run. So Java is a dependency of frostwire. Your package manager will install Java before it installs frostwire since frostwire won't run otherwise.

IndyGunFreak 02-04-2009 11:42 PM

Quote:

Originally Posted by digerati1338 (Post 3432632)
Not really. Those are independent applications. It would be more like you asking to have Frostwire installed. Frostwire requires Java or it won't run. So Java is a dependency of frostwire. Your package manager will install Java before it installs frostwire since frostwire won't run otherwise.

Very good example and explanation.. :cool:

GibsoneanNode 02-05-2009 12:12 AM

Quote:

Originally Posted by pljvaldez (Post 3432123)
Debian Multimedia is maintained by some guy in his basement (though he does a great job) and includes things that the Debian project won't due to legal, freedom, or other reasons (like proprietary codecs and drivers, etc).

pljvaldez, coincidence can be funny as I was just asking about this particular issue of legality and codecs just hours ago in the thread Looking for media streaming distro. Is the person who maintains Debian Multimedia then liable? It seems as though they could be taking on a troubling array of legal problems. Yet, I don't often hear this being discussed. True, on the grounds of integrity or personal gratification one will subscribe to the belief of abstaining from or indulging in the use of Debian Multimedia, but where is the friction between these two groups?

salasi 02-05-2009 04:13 AM

Quote:

Originally Posted by GibsoneanNode (Post 3432673)
Is the person who maintains Debian Multimedia then liable?

Probably not. He (she?) didn't know the legal rules applicable in the jurisdiction applicable to your computer and as far as the ethical problem of using non-free software is concerned, surely that is on the head of the person who installs or uses the software.

pljvaldez 02-05-2009 12:39 PM

He has a disclaimer on the site about "codecs may be illegal in your country", etc. So I think that's how he covers his bases and puts the onus on the end user to know whether it's okay to install them.

GibsoneanNode 02-05-2009 11:00 PM

Quote:

Originally Posted by salasi (Post 3432823)
He (she?) didn't know the legal rules applicable in the jurisdiction applicable to your computer.

Quote:

Originally Posted by pljvaldez (Post 3433266)
He has a disclaimer on the site about "codecs may be illegal in your country", etc.

This is all good stuff to know because for those of us who use operating systems whose licensing attributes freedoms but, due to shared values and a not for profit model, limits commercial licenses in the software, these become more than just theoretical law questions.


All times are GMT -5. The time now is 10:27 AM.