This is the Star Force series of books by B.V. Larson. The blurb profile fits nicely and there are multiple reviews mentioning the "Marcos" as the enemies of humanity.
Earth arms marines with alien technology and builds its first battle
fleet!
Kyle Riggs is snatched by an alien spacecraft sometime after midnight.
The ship is testing everyone it catches and murdering the weak. The
good news is that Kyle keeps passing tests and staying alive. The bad
news is the aliens who sent this ship are the nicest ones out
there....
SWARM is the story of Earth’s annexation by an alien empire. Long
considered a primitive people on a backwater planet, humanity finds
itself in the middle of a war, and faced with extinction
Goodreads
and
The previous books in this series have been all out war. War with the
Macros, who are machines bent on eradicating all biotic life. They
have found Earth but one guy, Kyle Riggs, an “enhanced” human who has
overcome serious run-ins with Macros now leads the Earth Marine Force
and Fleet to track down and destroy the Macros. He does that with a
vengeance in the previous four books.
sci-fibookreviews.com - “Battle Station (Star Force Series #5)” by B.V. Larson