diff --git a/libraries/mbed/capi/analogin_api.h b/libraries/mbed/src/capi/analogin_api.h similarity index 100% rename from libraries/mbed/capi/analogin_api.h rename to libraries/mbed/src/capi/analogin_api.h diff --git a/libraries/mbed/capi/analogout_api.h b/libraries/mbed/src/capi/analogout_api.h similarity index 100% rename from libraries/mbed/capi/analogout_api.h rename to libraries/mbed/src/capi/analogout_api.h diff --git a/libraries/mbed/capi/board.c b/libraries/mbed/src/capi/board.c similarity index 100% rename from libraries/mbed/capi/board.c rename to libraries/mbed/src/capi/board.c diff --git a/libraries/mbed/capi/can_api.h b/libraries/mbed/src/capi/can_api.h similarity index 100% rename from libraries/mbed/capi/can_api.h rename to libraries/mbed/src/capi/can_api.h diff --git a/libraries/mbed/capi/can_helper.h b/libraries/mbed/src/capi/can_helper.h similarity index 100% rename from libraries/mbed/capi/can_helper.h rename to libraries/mbed/src/capi/can_helper.h diff --git a/libraries/mbed/capi/error.h b/libraries/mbed/src/capi/error.h similarity index 100% rename from libraries/mbed/capi/error.h rename to libraries/mbed/src/capi/error.h diff --git a/libraries/mbed/capi/ethernet_api.h b/libraries/mbed/src/capi/ethernet_api.h similarity index 100% rename from libraries/mbed/capi/ethernet_api.h rename to libraries/mbed/src/capi/ethernet_api.h diff --git a/libraries/mbed/capi/exit.c b/libraries/mbed/src/capi/exit.c similarity index 100% rename from libraries/mbed/capi/exit.c rename to libraries/mbed/src/capi/exit.c diff --git a/libraries/mbed/capi/gpio_api.h b/libraries/mbed/src/capi/gpio_api.h similarity index 100% rename from libraries/mbed/capi/gpio_api.h rename to libraries/mbed/src/capi/gpio_api.h diff --git a/libraries/mbed/capi/gpio_irq_api.h b/libraries/mbed/src/capi/gpio_irq_api.h similarity index 100% rename from libraries/mbed/capi/gpio_irq_api.h rename to libraries/mbed/src/capi/gpio_irq_api.h diff --git a/libraries/mbed/capi/i2c_api.h b/libraries/mbed/src/capi/i2c_api.h similarity index 100% rename from libraries/mbed/capi/i2c_api.h rename to libraries/mbed/src/capi/i2c_api.h diff --git a/libraries/mbed/capi/mbed_debug.h b/libraries/mbed/src/capi/mbed_debug.h similarity index 100% rename from libraries/mbed/capi/mbed_debug.h rename to libraries/mbed/src/capi/mbed_debug.h diff --git a/libraries/mbed/capi/mbed_interface.c b/libraries/mbed/src/capi/mbed_interface.c similarity index 100% rename from libraries/mbed/capi/mbed_interface.c rename to libraries/mbed/src/capi/mbed_interface.c diff --git a/libraries/mbed/capi/mbed_interface.h b/libraries/mbed/src/capi/mbed_interface.h similarity index 100% rename from libraries/mbed/capi/mbed_interface.h rename to libraries/mbed/src/capi/mbed_interface.h diff --git a/libraries/mbed/capi/pinmap.h b/libraries/mbed/src/capi/pinmap.h similarity index 100% rename from libraries/mbed/capi/pinmap.h rename to libraries/mbed/src/capi/pinmap.h diff --git a/libraries/mbed/capi/pinmap_common.c b/libraries/mbed/src/capi/pinmap_common.c similarity index 100% rename from libraries/mbed/capi/pinmap_common.c rename to libraries/mbed/src/capi/pinmap_common.c diff --git a/libraries/mbed/capi/port_api.h b/libraries/mbed/src/capi/port_api.h similarity index 100% rename from libraries/mbed/capi/port_api.h rename to libraries/mbed/src/capi/port_api.h diff --git a/libraries/mbed/capi/pwmout_api.h b/libraries/mbed/src/capi/pwmout_api.h similarity index 100% rename from libraries/mbed/capi/pwmout_api.h rename to libraries/mbed/src/capi/pwmout_api.h diff --git a/libraries/mbed/capi/rtc_api.h b/libraries/mbed/src/capi/rtc_api.h similarity index 100% rename from libraries/mbed/capi/rtc_api.h rename to libraries/mbed/src/capi/rtc_api.h diff --git a/libraries/mbed/capi/rtc_time.c b/libraries/mbed/src/capi/rtc_time.c similarity index 100% rename from libraries/mbed/capi/rtc_time.c rename to libraries/mbed/src/capi/rtc_time.c diff --git a/libraries/mbed/capi/rtc_time.h b/libraries/mbed/src/capi/rtc_time.h similarity index 100% rename from libraries/mbed/capi/rtc_time.h rename to libraries/mbed/src/capi/rtc_time.h diff --git a/libraries/mbed/capi/semihost_api.c b/libraries/mbed/src/capi/semihost_api.c similarity index 100% rename from libraries/mbed/capi/semihost_api.c rename to libraries/mbed/src/capi/semihost_api.c diff --git a/libraries/mbed/capi/semihost_api.h b/libraries/mbed/src/capi/semihost_api.h similarity index 100% rename from libraries/mbed/capi/semihost_api.h rename to libraries/mbed/src/capi/semihost_api.h diff --git a/libraries/mbed/capi/serial_api.h b/libraries/mbed/src/capi/serial_api.h similarity index 100% rename from libraries/mbed/capi/serial_api.h rename to libraries/mbed/src/capi/serial_api.h diff --git a/libraries/mbed/capi/sleep_api.h b/libraries/mbed/src/capi/sleep_api.h similarity index 100% rename from libraries/mbed/capi/sleep_api.h rename to libraries/mbed/src/capi/sleep_api.h diff --git a/libraries/mbed/capi/spi_api.h b/libraries/mbed/src/capi/spi_api.h similarity index 100% rename from libraries/mbed/capi/spi_api.h rename to libraries/mbed/src/capi/spi_api.h diff --git a/libraries/mbed/capi/toolchain.h b/libraries/mbed/src/capi/toolchain.h similarity index 100% rename from libraries/mbed/capi/toolchain.h rename to libraries/mbed/src/capi/toolchain.h diff --git a/libraries/mbed/capi/us_ticker_api.c b/libraries/mbed/src/capi/us_ticker_api.c similarity index 100% rename from libraries/mbed/capi/us_ticker_api.c rename to libraries/mbed/src/capi/us_ticker_api.c diff --git a/libraries/mbed/capi/us_ticker_api.h b/libraries/mbed/src/capi/us_ticker_api.h similarity index 100% rename from libraries/mbed/capi/us_ticker_api.h rename to libraries/mbed/src/capi/us_ticker_api.h diff --git a/libraries/mbed/capi/wait_api.c b/libraries/mbed/src/capi/wait_api.c similarity index 100% rename from libraries/mbed/capi/wait_api.c rename to libraries/mbed/src/capi/wait_api.c diff --git a/libraries/mbed/capi/wait_api.h b/libraries/mbed/src/capi/wait_api.h similarity index 100% rename from libraries/mbed/capi/wait_api.h rename to libraries/mbed/src/capi/wait_api.h diff --git a/libraries/mbed/cpp/AnalogIn.h b/libraries/mbed/src/cpp/AnalogIn.h similarity index 100% rename from libraries/mbed/cpp/AnalogIn.h rename to libraries/mbed/src/cpp/AnalogIn.h diff --git a/libraries/mbed/cpp/AnalogOut.h b/libraries/mbed/src/cpp/AnalogOut.h similarity index 100% rename from libraries/mbed/cpp/AnalogOut.h rename to libraries/mbed/src/cpp/AnalogOut.h diff --git a/libraries/mbed/cpp/BusIn.cpp b/libraries/mbed/src/cpp/BusIn.cpp similarity index 100% rename from libraries/mbed/cpp/BusIn.cpp rename to libraries/mbed/src/cpp/BusIn.cpp diff --git a/libraries/mbed/cpp/BusIn.h b/libraries/mbed/src/cpp/BusIn.h similarity index 100% rename from libraries/mbed/cpp/BusIn.h rename to libraries/mbed/src/cpp/BusIn.h diff --git a/libraries/mbed/cpp/BusInOut.cpp b/libraries/mbed/src/cpp/BusInOut.cpp similarity index 100% rename from libraries/mbed/cpp/BusInOut.cpp rename to libraries/mbed/src/cpp/BusInOut.cpp diff --git a/libraries/mbed/cpp/BusInOut.h b/libraries/mbed/src/cpp/BusInOut.h similarity index 100% rename from libraries/mbed/cpp/BusInOut.h rename to libraries/mbed/src/cpp/BusInOut.h diff --git a/libraries/mbed/cpp/BusOut.cpp b/libraries/mbed/src/cpp/BusOut.cpp similarity index 100% rename from libraries/mbed/cpp/BusOut.cpp rename to libraries/mbed/src/cpp/BusOut.cpp diff --git a/libraries/mbed/cpp/BusOut.h b/libraries/mbed/src/cpp/BusOut.h similarity index 100% rename from libraries/mbed/cpp/BusOut.h rename to libraries/mbed/src/cpp/BusOut.h diff --git a/libraries/mbed/cpp/CAN.cpp b/libraries/mbed/src/cpp/CAN.cpp similarity index 100% rename from libraries/mbed/cpp/CAN.cpp rename to libraries/mbed/src/cpp/CAN.cpp diff --git a/libraries/mbed/cpp/CAN.h b/libraries/mbed/src/cpp/CAN.h similarity index 100% rename from libraries/mbed/cpp/CAN.h rename to libraries/mbed/src/cpp/CAN.h diff --git a/libraries/mbed/cpp/DigitalIn.h b/libraries/mbed/src/cpp/DigitalIn.h similarity index 100% rename from libraries/mbed/cpp/DigitalIn.h rename to libraries/mbed/src/cpp/DigitalIn.h diff --git a/libraries/mbed/cpp/DigitalInOut.h b/libraries/mbed/src/cpp/DigitalInOut.h similarity index 100% rename from libraries/mbed/cpp/DigitalInOut.h rename to libraries/mbed/src/cpp/DigitalInOut.h diff --git a/libraries/mbed/cpp/DigitalOut.h b/libraries/mbed/src/cpp/DigitalOut.h similarity index 100% rename from libraries/mbed/cpp/DigitalOut.h rename to libraries/mbed/src/cpp/DigitalOut.h diff --git a/libraries/mbed/cpp/DirHandle.h b/libraries/mbed/src/cpp/DirHandle.h similarity index 100% rename from libraries/mbed/cpp/DirHandle.h rename to libraries/mbed/src/cpp/DirHandle.h diff --git a/libraries/mbed/cpp/Ethernet.cpp b/libraries/mbed/src/cpp/Ethernet.cpp similarity index 100% rename from libraries/mbed/cpp/Ethernet.cpp rename to libraries/mbed/src/cpp/Ethernet.cpp diff --git a/libraries/mbed/cpp/Ethernet.h b/libraries/mbed/src/cpp/Ethernet.h similarity index 100% rename from libraries/mbed/cpp/Ethernet.h rename to libraries/mbed/src/cpp/Ethernet.h diff --git a/libraries/mbed/cpp/FileBase.cpp b/libraries/mbed/src/cpp/FileBase.cpp similarity index 100% rename from libraries/mbed/cpp/FileBase.cpp rename to libraries/mbed/src/cpp/FileBase.cpp diff --git a/libraries/mbed/cpp/FileBase.h b/libraries/mbed/src/cpp/FileBase.h similarity index 100% rename from libraries/mbed/cpp/FileBase.h rename to libraries/mbed/src/cpp/FileBase.h diff --git a/libraries/mbed/cpp/FileHandle.h b/libraries/mbed/src/cpp/FileHandle.h similarity index 100% rename from libraries/mbed/cpp/FileHandle.h rename to libraries/mbed/src/cpp/FileHandle.h diff --git a/libraries/mbed/cpp/FileLike.cpp b/libraries/mbed/src/cpp/FileLike.cpp similarity index 100% rename from libraries/mbed/cpp/FileLike.cpp rename to libraries/mbed/src/cpp/FileLike.cpp diff --git a/libraries/mbed/cpp/FileLike.h b/libraries/mbed/src/cpp/FileLike.h similarity index 100% rename from libraries/mbed/cpp/FileLike.h rename to libraries/mbed/src/cpp/FileLike.h diff --git a/libraries/mbed/cpp/FilePath.cpp b/libraries/mbed/src/cpp/FilePath.cpp similarity index 100% rename from libraries/mbed/cpp/FilePath.cpp rename to libraries/mbed/src/cpp/FilePath.cpp diff --git a/libraries/mbed/cpp/FilePath.h b/libraries/mbed/src/cpp/FilePath.h similarity index 100% rename from libraries/mbed/cpp/FilePath.h rename to libraries/mbed/src/cpp/FilePath.h diff --git a/libraries/mbed/cpp/FileSystemLike.cpp b/libraries/mbed/src/cpp/FileSystemLike.cpp similarity index 100% rename from libraries/mbed/cpp/FileSystemLike.cpp rename to libraries/mbed/src/cpp/FileSystemLike.cpp diff --git a/libraries/mbed/cpp/FileSystemLike.h b/libraries/mbed/src/cpp/FileSystemLike.h similarity index 100% rename from libraries/mbed/cpp/FileSystemLike.h rename to libraries/mbed/src/cpp/FileSystemLike.h diff --git a/libraries/mbed/cpp/FunctionPointer.cpp b/libraries/mbed/src/cpp/FunctionPointer.cpp similarity index 100% rename from libraries/mbed/cpp/FunctionPointer.cpp rename to libraries/mbed/src/cpp/FunctionPointer.cpp diff --git a/libraries/mbed/cpp/FunctionPointer.h b/libraries/mbed/src/cpp/FunctionPointer.h similarity index 100% rename from libraries/mbed/cpp/FunctionPointer.h rename to libraries/mbed/src/cpp/FunctionPointer.h diff --git a/libraries/mbed/cpp/I2C.cpp b/libraries/mbed/src/cpp/I2C.cpp similarity index 100% rename from libraries/mbed/cpp/I2C.cpp rename to libraries/mbed/src/cpp/I2C.cpp diff --git a/libraries/mbed/cpp/I2C.h b/libraries/mbed/src/cpp/I2C.h similarity index 100% rename from libraries/mbed/cpp/I2C.h rename to libraries/mbed/src/cpp/I2C.h diff --git a/libraries/mbed/cpp/I2CSlave.cpp b/libraries/mbed/src/cpp/I2CSlave.cpp similarity index 100% rename from libraries/mbed/cpp/I2CSlave.cpp rename to libraries/mbed/src/cpp/I2CSlave.cpp diff --git a/libraries/mbed/cpp/I2CSlave.h b/libraries/mbed/src/cpp/I2CSlave.h similarity index 100% rename from libraries/mbed/cpp/I2CSlave.h rename to libraries/mbed/src/cpp/I2CSlave.h diff --git a/libraries/mbed/cpp/InterruptIn.cpp b/libraries/mbed/src/cpp/InterruptIn.cpp similarity index 100% rename from libraries/mbed/cpp/InterruptIn.cpp rename to libraries/mbed/src/cpp/InterruptIn.cpp diff --git a/libraries/mbed/cpp/InterruptIn.h b/libraries/mbed/src/cpp/InterruptIn.h similarity index 100% rename from libraries/mbed/cpp/InterruptIn.h rename to libraries/mbed/src/cpp/InterruptIn.h diff --git a/libraries/mbed/cpp/LocalFileSystem.cpp b/libraries/mbed/src/cpp/LocalFileSystem.cpp similarity index 100% rename from libraries/mbed/cpp/LocalFileSystem.cpp rename to libraries/mbed/src/cpp/LocalFileSystem.cpp diff --git a/libraries/mbed/cpp/LocalFileSystem.h b/libraries/mbed/src/cpp/LocalFileSystem.h similarity index 100% rename from libraries/mbed/cpp/LocalFileSystem.h rename to libraries/mbed/src/cpp/LocalFileSystem.h diff --git a/libraries/mbed/cpp/PortIn.h b/libraries/mbed/src/cpp/PortIn.h similarity index 100% rename from libraries/mbed/cpp/PortIn.h rename to libraries/mbed/src/cpp/PortIn.h diff --git a/libraries/mbed/cpp/PortInOut.h b/libraries/mbed/src/cpp/PortInOut.h similarity index 100% rename from libraries/mbed/cpp/PortInOut.h rename to libraries/mbed/src/cpp/PortInOut.h diff --git a/libraries/mbed/cpp/PortOut.h b/libraries/mbed/src/cpp/PortOut.h similarity index 100% rename from libraries/mbed/cpp/PortOut.h rename to libraries/mbed/src/cpp/PortOut.h diff --git a/libraries/mbed/cpp/PwmOut.h b/libraries/mbed/src/cpp/PwmOut.h similarity index 100% rename from libraries/mbed/cpp/PwmOut.h rename to libraries/mbed/src/cpp/PwmOut.h diff --git a/libraries/mbed/cpp/SPI.cpp b/libraries/mbed/src/cpp/SPI.cpp similarity index 100% rename from libraries/mbed/cpp/SPI.cpp rename to libraries/mbed/src/cpp/SPI.cpp diff --git a/libraries/mbed/cpp/SPI.h b/libraries/mbed/src/cpp/SPI.h similarity index 100% rename from libraries/mbed/cpp/SPI.h rename to libraries/mbed/src/cpp/SPI.h diff --git a/libraries/mbed/cpp/SPISlave.cpp b/libraries/mbed/src/cpp/SPISlave.cpp similarity index 100% rename from libraries/mbed/cpp/SPISlave.cpp rename to libraries/mbed/src/cpp/SPISlave.cpp diff --git a/libraries/mbed/cpp/SPISlave.h b/libraries/mbed/src/cpp/SPISlave.h similarity index 100% rename from libraries/mbed/cpp/SPISlave.h rename to libraries/mbed/src/cpp/SPISlave.h diff --git a/libraries/mbed/cpp/Serial.cpp b/libraries/mbed/src/cpp/Serial.cpp similarity index 100% rename from libraries/mbed/cpp/Serial.cpp rename to libraries/mbed/src/cpp/Serial.cpp diff --git a/libraries/mbed/cpp/Serial.h b/libraries/mbed/src/cpp/Serial.h similarity index 100% rename from libraries/mbed/cpp/Serial.h rename to libraries/mbed/src/cpp/Serial.h diff --git a/libraries/mbed/cpp/Stream.cpp b/libraries/mbed/src/cpp/Stream.cpp similarity index 100% rename from libraries/mbed/cpp/Stream.cpp rename to libraries/mbed/src/cpp/Stream.cpp diff --git a/libraries/mbed/cpp/Stream.h b/libraries/mbed/src/cpp/Stream.h similarity index 100% rename from libraries/mbed/cpp/Stream.h rename to libraries/mbed/src/cpp/Stream.h diff --git a/libraries/mbed/cpp/Ticker.cpp b/libraries/mbed/src/cpp/Ticker.cpp similarity index 100% rename from libraries/mbed/cpp/Ticker.cpp rename to libraries/mbed/src/cpp/Ticker.cpp diff --git a/libraries/mbed/cpp/Ticker.h b/libraries/mbed/src/cpp/Ticker.h similarity index 100% rename from libraries/mbed/cpp/Ticker.h rename to libraries/mbed/src/cpp/Ticker.h diff --git a/libraries/mbed/cpp/Timeout.cpp b/libraries/mbed/src/cpp/Timeout.cpp similarity index 100% rename from libraries/mbed/cpp/Timeout.cpp rename to libraries/mbed/src/cpp/Timeout.cpp diff --git a/libraries/mbed/cpp/Timeout.h b/libraries/mbed/src/cpp/Timeout.h similarity index 100% rename from libraries/mbed/cpp/Timeout.h rename to libraries/mbed/src/cpp/Timeout.h diff --git a/libraries/mbed/cpp/Timer.cpp b/libraries/mbed/src/cpp/Timer.cpp similarity index 100% rename from libraries/mbed/cpp/Timer.cpp rename to libraries/mbed/src/cpp/Timer.cpp diff --git a/libraries/mbed/cpp/Timer.h b/libraries/mbed/src/cpp/Timer.h similarity index 100% rename from libraries/mbed/cpp/Timer.h rename to libraries/mbed/src/cpp/Timer.h diff --git a/libraries/mbed/cpp/TimerEvent.cpp b/libraries/mbed/src/cpp/TimerEvent.cpp similarity index 100% rename from libraries/mbed/cpp/TimerEvent.cpp rename to libraries/mbed/src/cpp/TimerEvent.cpp diff --git a/libraries/mbed/cpp/TimerEvent.h b/libraries/mbed/src/cpp/TimerEvent.h similarity index 100% rename from libraries/mbed/cpp/TimerEvent.h rename to libraries/mbed/src/cpp/TimerEvent.h diff --git a/libraries/mbed/cpp/mbed.h b/libraries/mbed/src/cpp/mbed.h similarity index 100% rename from libraries/mbed/cpp/mbed.h rename to libraries/mbed/src/cpp/mbed.h diff --git a/libraries/mbed/cpp/platform.h b/libraries/mbed/src/cpp/platform.h similarity index 100% rename from libraries/mbed/cpp/platform.h rename to libraries/mbed/src/cpp/platform.h diff --git a/libraries/mbed/cpp/stdio.cpp b/libraries/mbed/src/cpp/stdio.cpp similarity index 100% rename from libraries/mbed/cpp/stdio.cpp rename to libraries/mbed/src/cpp/stdio.cpp diff --git a/libraries/net/EthernetInterface/EthernetInterface.cpp b/libraries/net/eth/EthernetInterface/EthernetInterface.cpp similarity index 100% rename from libraries/net/EthernetInterface/EthernetInterface.cpp rename to libraries/net/eth/EthernetInterface/EthernetInterface.cpp diff --git a/libraries/net/EthernetInterface/EthernetInterface.h b/libraries/net/eth/EthernetInterface/EthernetInterface.h similarity index 100% rename from libraries/net/EthernetInterface/EthernetInterface.h rename to libraries/net/eth/EthernetInterface/EthernetInterface.h diff --git a/libraries/net/EthernetInterface/lwipopts_conf.h b/libraries/net/eth/EthernetInterface/lwipopts_conf.h similarity index 100% rename from libraries/net/EthernetInterface/lwipopts_conf.h rename to libraries/net/eth/EthernetInterface/lwipopts_conf.h diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc17_emac.c b/libraries/net/eth/lwip-eth/arch/lpc17_emac.c similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc17_emac.c rename to libraries/net/eth/lwip-eth/arch/lpc17_emac.c diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc17_emac.h b/libraries/net/eth/lwip-eth/arch/lpc17_emac.h similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc17_emac.h rename to libraries/net/eth/lwip-eth/arch/lpc17_emac.h diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc17xx_emac.h b/libraries/net/eth/lwip-eth/arch/lpc17xx_emac.h similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc17xx_emac.h rename to libraries/net/eth/lwip-eth/arch/lpc17xx_emac.h diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc_emac_config.h b/libraries/net/eth/lwip-eth/arch/lpc_emac_config.h similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc_emac_config.h rename to libraries/net/eth/lwip-eth/arch/lpc_emac_config.h diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc_phy.h b/libraries/net/eth/lwip-eth/arch/lpc_phy.h similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc_phy.h rename to libraries/net/eth/lwip-eth/arch/lpc_phy.h diff --git a/libraries/net/EthernetInterface/lwip-eth/arch/lpc_phy_dp83848.c b/libraries/net/eth/lwip-eth/arch/lpc_phy_dp83848.c similarity index 100% rename from libraries/net/EthernetInterface/lwip-eth/arch/lpc_phy_dp83848.c rename to libraries/net/eth/lwip-eth/arch/lpc_phy_dp83848.c