fixed issues with the build order of files

The library files which do not require any order,
are moved into the 'libs' folder.

The build script now searches folders first,
and concatonates files second.