add taospack

This commit is contained in:
tickduan 2021-06-22 14:10:45 +08:00
parent 17d3392c98
commit 93154cfbd8
2 changed files with 15 additions and 1 deletions

View File

@ -4,3 +4,4 @@ PROJECT(TDengine)
ADD_SUBDIRECTORY(shell)
ADD_SUBDIRECTORY(taosdemo)
ADD_SUBDIRECTORY(taosdump)
ADD_SUBDIRECTORY(taospack)

View File

@ -21,6 +21,7 @@
#include "os.h"
#include "tscompression.h"
#include "tdataformat.h"
#define FT_CNT 8
@ -188,7 +189,19 @@ int memTest();
// main
//
int main(int argc, char *argv[]) {
printf("welcome to use taospack tools v1.1. \n");
printf("welcome to use taospack tools v1.1. sizeof(STColumn) = %lu\n", sizeof(STColumn));
FILE* fp = fopen("./a.out", "w+");
STColumn* pcol = malloc(sizeof(STColumn));
pcol->type = 1;
pcol->colId = 2;
pcol->bytes = 3;
pcol->offset = 4;
fwrite(pcol, 1, sizeof(STColumn), fp);
fwrite("aaa", 1, 3, fp);
fclose(fp);
printf(" write a.out ok.\n");
return 0;
if(argc == 3){
char algo = 0;