It comes from mathematical game theory. "Chicken" in this usage means coward (we call people who are cowards "chickens" because chickens run away when people approach).
A game of chicken is any contest with two players where neither one wants to "back down" or let the other win, even though not backing down can be very dangerous. The classic game of chicken takes place when two people drive cars at very high speeds directly towards each other. Obviously, if neither one turns away, there will be a big crash and both will be harmed. The person that turns first is the chicken.
In mathematical game theory, not being a chicken can have very dire consequences, especially if the other player does not "turn away". The point is, "winning" or playing a game to its conclusion, may not always be in the best interest of the player.