Remove the basically-empty C library for now.
This commit is contained in:
parent
cbeb736e8c
commit
0915cf45dc
|
@ -1,3 +1,2 @@
|
||||||
add_subdirectory(glacier)
|
add_subdirectory(glacier)
|
||||||
add_subdirectory(libc)
|
|
||||||
add_subdirectory(mammoth)
|
add_subdirectory(mammoth)
|
||||||
|
|
|
@ -1,15 +0,0 @@
|
||||||
|
|
||||||
add_library(c STATIC
|
|
||||||
src/string.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
target_include_directories(c
|
|
||||||
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}
|
|
||||||
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include)
|
|
||||||
|
|
||||||
target_link_libraries(c
|
|
||||||
zion_stub
|
|
||||||
)
|
|
||||||
|
|
||||||
set_target_properties(c PROPERTIES
|
|
||||||
COMPILE_FLAGS "${CMAKE_CXX_FLAGS} ${BASE_COMPILE_FLAGS}")
|
|
|
@ -1,5 +0,0 @@
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include <stdint.h>
|
|
||||||
|
|
||||||
typedef uint64_t size_t;
|
|
|
@ -1,5 +0,0 @@
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include "stddef.h"
|
|
||||||
|
|
||||||
void* memcpy(void* dest, const void* src, size_t count);
|
|
|
@ -1,10 +0,0 @@
|
||||||
#include "string.h"
|
|
||||||
|
|
||||||
void* memcpy(void* dest, const void* src, size_t count) {
|
|
||||||
uint8_t* d = (uint8_t*)dest;
|
|
||||||
const uint8_t* s = (uint8_t*)src;
|
|
||||||
for (size_t i = 0; i < count; i++) {
|
|
||||||
d[i] = s[i];
|
|
||||||
}
|
|
||||||
return dest;
|
|
||||||
}
|
|
|
@ -23,7 +23,6 @@ target_include_directories(mammoth
|
||||||
|
|
||||||
target_link_libraries(mammoth
|
target_link_libraries(mammoth
|
||||||
glacier
|
glacier
|
||||||
c
|
|
||||||
victoriafalls_yunq
|
victoriafalls_yunq
|
||||||
yellowstone_yunq
|
yellowstone_yunq
|
||||||
zion_stub
|
zion_stub
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
#include <glacier/status/error.h>
|
#include <glacier/status/error.h>
|
||||||
#include <mammoth/util/debug.h>
|
#include <mammoth/util/debug.h>
|
||||||
#include <string.h>
|
|
||||||
#include <zcall.h>
|
#include <zcall.h>
|
||||||
|
|
||||||
AhciDevice::AhciDevice(AhciPort* port) : port_struct_(port) {
|
AhciDevice::AhciDevice(AhciPort* port) : port_struct_(port) {
|
||||||
|
|
|
@ -1,9 +1,20 @@
|
||||||
#include "ahci/command.h"
|
#include "ahci/command.h"
|
||||||
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include "ahci/ahci.h"
|
#include "ahci/ahci.h"
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
void* memcpy(void* dest, const void* src, uint64_t count) {
|
||||||
|
uint8_t* d = (uint8_t*)dest;
|
||||||
|
const uint8_t* s = (uint8_t*)src;
|
||||||
|
for (uint64_t i = 0; i < count; i++) {
|
||||||
|
d[i] = s[i];
|
||||||
|
}
|
||||||
|
return dest;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
||||||
Command::~Command() {}
|
Command::~Command() {}
|
||||||
|
|
||||||
DmaReadCommand::DmaReadCommand(uint64_t lba, uint64_t sector_cnt,
|
DmaReadCommand::DmaReadCommand(uint64_t lba, uint64_t sector_cnt,
|
||||||
|
|
Loading…
Reference in New Issue