So the intrepid party enters a room only to find the wall is closing to squish them into goo at the end of the room. Fighter starts to push against it and calls for help. say the DC str check is 20. He pushes and rolls a 16, and +3 str gets a 19. the three companions all roll to aid and two get a 10 adding their str modifiers to achieve this. for a total of a +4 which meets or beats the DC20 so the wall is stopped that round. I'm guessing this is how the rules work.
the question is, if the fighter blows his roll and gets a 5, his feet were not set well on the stone floor I'd guess. but one of the others roll a 16, 11, and 12. would you then say that the 16 is the main pusher and the other two are aiding him for a total of 20 or was it a failure since they all said they were aiding the fighter.
and if the wall is wide enough for all 4 to push on their own is it a different matter on how this plays out?
or is this not a str check at all and a 'bull rush' or such with a CMB vs a CMD?
So, going on my reading of the Aid Another rules:
You can help someone achieve success on a skill check by making the same kind of skill check in a cooperative effort. If you roll a 10 or higher on your check, the character you're helping gets a +2 bonus on his or her check. (You can't take 10 on a skill check to aid another.) In many cases, a character's help won't be beneficial, or only a limited number of characters can help at once.
In cases where the skill restricts who can achieve certain results, such as trying to open a lock using Disable Device, you can't aid another to grant a bonus to a task that your character couldn't achieve alone. The GM might impose further restrictions to aiding another on a case-by-case basis as well.
In melee combat, you can help a friend attack or defend by distracting or interfering with an opponent. If you're in position to make a melee attack on an opponent that is engaging a friend in melee combat, you can attempt to aid your friend as a standard action. You make an attack roll against AC 10. If you succeed, your friend gains either a +2 bonus on his next attack roll against that opponent or a +2 bonus to AC against that opponent's next attack (your choice), as long as that attack comes before the beginning of your next turn. Multiple characters can aid the same friend, and similar bonuses stack.
You can also use this standard action to help a friend in other ways, such as when he is affected by a spell, or to assist another character's skill check.
In general, barring feats, class abilities and all that jazz, I would argue that by RAW, you can only aid another character's check. The rules text says you aid another persons check, there is no qualifier about everyone performing the same task and taking the highest roll.
That being said, in my games if the primary blows their roll and the secondary makes a good roll, I usually allow the secondary roll to be the primary. The blown roll can still aid if it could make a 10. I use this for knowledge checks or in some kind of communal effort like pushing against a trap wall. (I added the combat rules for aid another because I probably would not allow this to fly in combat).
So to summarize:
Scenario 1 - Fighter does well with aiding - How the rules work
Scenario 2 - Fighter whiffs, but others work just fine assuming the 16 is the new "primary" - Not how the rules work (pretty sure, I bet someone could make an argument), but a perfectly fine way to run it.
Scenario 3 - Wide wall - Still aiding another. Worth noting however, that if the wall isn't wide enough for people to aid that could get problematic.
Scenario 4 - STR check vs. CMD - I'd go with STR check.
I would probably just make a quick assumption on the wall's weight and ask for their lifting capacity (or str scores and check the table), if the total lifting capacity is equal or higher than the wall's weight, they can hold it in place.
I would ask for an str check only if they attempted to break the wall or something in that sense.
Usually two strong characters can pull something like hold a wall or failing ceiling, that kind of trap is meant to capture a single person or tomb thieves.