I don’t think even in the U.S. very many teachers have guns with them outside their school.
I’d be surprised if these cartoons are part of the standard curriculum in French schools, but if I was holding them up in a class that included moslims then I would sure want the means to defend myself. At least in the U.S. teachers have a choice - just as they do in case of these mass school shootings.