Yes and no. As Lennart said, the FDA verifies that generic drugs have the same ACTIVE ingredients in the same amounts as name-brand drugs are. So for most of us, the answer is a simple "yes."
However, if you have problems with certain common ingredients, like those with celiac disease, the filler (excipients), or INACTIVE ingredients can be problematic. A lot of drug fillers contain gluten, which will damage the intestinal lining of anyone with celiac disease. Name-brand drug manufacturers can generally tell you whether any of their fillers contain a certain ingredient (such as gluten) if you call their customer service (my wife has to do this for her clients periodically). In prescriptions, where only active ingredients are generally listed, generic manufacturers use whatever fillers are cheapest at a given moment, so a generic drug made this week might have different inactive ingredients than the same pharmacy's generic brand of the same drug made last week or the week before (according to some of the manufacturers when called by medical professionals asking on behalf of their clients). None of the labeling requirements for food with respect to common allergens apply to drugs. (Celiac is not an allergy, but since wheat is a common allergen, those with celiac benefit from the food labeling requirements). With non-prescription drugs, where inactive ingredients are listed, you should be able to scour through the label and find out if its ingredients will be problematic, but you'll need to read the label, since, as your question asks, the generics are not "really equivalent" to name-brand drugs in terms of their inactive ingredients.
I suspect the same is true for some other conditions, but the amount of inactive ingredient in your typical drug is unlikely to be enough to be a problem for people with food sensitivities or allergies. A person would need to have a condition that makes them sensitive to very small amounts of an ingredient (or take a very large quantity of a given drug) for this to be an issue. Again, to emphasize the point, for the vast majority of us, this is not a problem, and we only need to be concerned about the active ingredients, which ARE equivalent between generic and name-brand drugs.
A few points of reference:
- The Food Allergen Labeling and Consumer Protection Act of 2004 provides some help to those with Celiac by requiring foods containing wheat products to be clearly labeled (unless a food contains barley or rye, which aren't wheat but contain the type of gluten that celiacs must avoid), but drugs are not included in this regulation.
- A 2007 article from the journal Practical Gastroenterology titled Medications and Celiac Disease—Tips From a Pharmacist discusses the challenges celiac patients have with drugs. One key quote related to the response above: "The drug manufacturers must utilize only FDA approved excipients, but the quantity and type of excipient is not specifically regulated. This is important to understand, especially in the manufacturing of generic drug products, since generic product does not have to contain the same excipients as the brand name product. The generic drug manufacturers must demonstrate certain absorption characteristics when they reproduce a drug, but all other aspects can differ."
- Last year, my wife presented at an FDA hearing on the Development of Articles for Rare Diseases on behalf of the Celiac Sprue Association to make a case for celiac-friendly labeling on drugs. If you can load the morning presentation (it seems to promt for a login, but offer no way of registering), the relevant material starts at about 2h14m into the recording.
- The National Center for Celiac Awareness's article, Gluten in Medications for Patients goes over some of these same issues.