At first I did not post anything because I can go on and on about this topic. But try to put my thoughts about this…
First, I do agree about everyday conversational Japanese appears a lot of grouping terminology of people. I cannot speak of people from other places, but for people from the U.S. this grouping of people in everyday Japanese conversation can some time get to the point of not totally comfortable. Hakujinn (白人), kokujinn (黒人), kankokujinn (韓国人), chuugokujinn (中国人), oubeijinn (欧米人), etc. I said conversational Japanese, because if you see written Japanese those terms appear less frequently. I am talking the same person who use those grouping terminology, but when it comes to writing the same person will use the grouping terminology far less frequently.
Also, I think it is important to note that on everyday social situations, at work or among friends, the belonging to group is far more emphasized than individual compare with many other societies. So it is easy to see that most people engaging in this group calling because everybody else is doing.
But get back to the definition of gaijinn (外人) or gaikokujinn (外国人), I do not think there is difference between gaijinn and gaikokujinn, gaijinn is simply short version of gaikokujinn. As some may realized Japanese also love to shorten words a lot, so it may end up as gaikokujinn sounds more proper than gaijinn.
I do think the bottom line definition of gaijinn is a foreigner(s) as in people who are not Japanese. “Gaijinn” may not be used as frequently in everyday conversation by Japanese, but tend to hear grouping terminology more like hakujinn, kokujinn, tokuojinn, obeijinn. When reading or watching news media, which tend to use more proper Japanese, gaijinn is used for reference to all foreign people. Chinese is gaijinn, Korean is gaijinn, Russian is gaijinn, French is gaijinn, etc.
I do not think this is difference between news media Japanese vs. every day conversational Japanese. Because if you know a Japanese person who use grouping term frequently and do not use the term "gaijinn" a lot, then simply ask the person 韓国人は外人ですか。 (which means “Are Koreans gaijinn?”) then most likely the answer you get will be yes.
So it is not like Japanese do not consider Far East Asian people as gaijinn. I think it is simply conversational Japanese uses more grouping terminology of people than using gaijinn to refer to all foreign people. Same time most Japanese do consider definition of gaijinn as all foreign people, but does not use as often or as same manner as in your native language.
Alright, then why it is like this in conversational Japanese? This is where I can go on and on, if you did not think what I wrote so far is long…

I do think there is a lot in cultural and historical background. How Koreans came to play in Japanese history, how Chinese came to play in Japanese history, and this is not just World War II of 70-80 years ago, but it goes back all the way 300-500 years ago where Japanese did travel around Far East Asia. Obviously, picture may not be always pretty, how Japanese perceived and treated people in Asia. This includes how Ainu (アイヌ民族) people in Hokkaido and Ryukyu (琉球) people in Okinawa were treated by Japanese Bakufu (幕府) in mainland. How arrival of Christianity to Japan had part in Japan closing the country for 300 years, except to Holland in Nagasaki Deshima (出島) (the reason for that may be also interesting, but that is for another time...).
Yes, a lot of thing may not be pretty and may not be right what happened in the history. You can even start totally new post about how women are treated in Japan today. But I do think it is very important to learn cultural and historical background to understand the language. How language evolved and how people end up using such terms today, as language is living, changing and evolving constantly. Can show how young Japanese in 20s talked in ‘80s is quite different from how young Japanese in 20s talk today, this include how the term "gaijin" was used in conversational Japanese 20 years ago and today.