Parolin 0.7.9 6796
Console (soon DLLs) to do a tar like job
Loading...
Searching...
No Matches
ar_main.c File Reference
#include <windows.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <errno.h>
#include <fcntl.h>
#include <ctype.h>
#include <math.h>
#include <wctype.h>
#include <wchar.h>
#include <stdarg.h>
#include <stddef.h>
#include <setjmp.h>
#include <locale.h>
#include <signal.h>
#include <limits.h>
#include <float.h>
#include <iso646.h>
#include <assert.h>
#include <stdbool.h>
#include <process.h>
#include "win64.h"
#include "aline_definitive_header_2_.h"

Macros

#define __attribute__(unused)
 
#define uchar   unsigned char
 
#define uint   unsigned int
 
#define ushort   unsigned short
 
#define AMARIC__VERSION   "3.1.8 build 186"
 
#define __attribute__(unused_ric)
 
#define AMANDA__SIZE   ((32767 * 6) + 2)
 
#define AMANDA__SIZE_w   (32767)
 
#define THESIZE   (300 * 6)
 

Functions

WCHAR * utf8_2_wide_dl (const char *pUTF8)
 my temporary utf8_2_wide_dl function to add full Unicode support and future (when modified) support to long filenames. (jan/2025)
 
void pedro_dprintf2 (int amanda_level, char *format,...)
 pedro_dprintf2 is my variant of my debug function because too much calls to pedro_dprintf these days, I am lazy, sorry....
 
void pedro_dprintf (int amanda_level, char *format,...)
 
int main_ar (int numArgs, char **)
 
char *__stdcall widetoutf8 (WCHAR *pUSC2)
 
int lgetpor_ar (__int64 max, __int64 fatia)
 
__int64 lffilesize_ar (const char *szFileName)
 simplistic function to get the size of a file, developed 30 years ago
 
int soc_lzma_compress_ar (char *myinfile__ar, char *myoutfile__ar, __attribute__((unused)) int level_ar)
 
int soc_lzma_uncompress_ar (char *myinfile__ar, char *myoutfile__ar)
 
int __stdcall compress_lzma_aakp_rspk (char *valquiria_input__file_utf_8, char *juliete___output_file_utf_8, int junior_compression_level___)
 function to compress in the standard lzma format
 
int __stdcall uncompress_lzma_aakp_rspk (char *valquiria_input__file_utf_8, char *juliete___output_file_utf_8)
 Function to uncompress a standard lzma compressed file.
 
int __stdcall Compress___lzma_c (char *infile_ar, char *outfile_ar)
 
int __stdcall Uncompress_no_no (char *infile_ar, char *outfile_ar)
 
int __stdcall Resume__lzma ()
 undocumented because not in use at this moment
 
int __stdcall Pause__lzma ()
 
int __stdcall Cancel__lzma ()
 
int __stdcall Returnvalue__lzma ()
 
int __stdcall Running__lzma ()
 
int __stdcall Progress__lzma ()
 

Variables

char myinfile_ar [MAX_PATH+1]
 
char myoutfile_ar [MAX_PATH+1]
 
int intreturn_ar_lzma = 0
 
int comando_ar_lzma = 0
 
int running_ar_lzma = 0
 
int intpause_ar_lzma = 0
 
int intcancel_ar_lzma = 0
 
int porcentagem_ar_lzma = 0
 
int unicodemode_ar_lzma = 1
 
__int64 file_tamanho_ar_lzma = 0
 

Macro Definition Documentation

◆ __attribute__ [1/2]

#define __attribute__ ( unused)
Value:
/* chloe */

◆ __attribute__ [2/2]

#define __attribute__ ( unused_ric)
Value:
/* 2004 */

◆ AMANDA__SIZE

#define AMANDA__SIZE   ((32767 * 6) + 2)

The maximum size of an utf-8 encoded filename with the max limit of a file in Windows

◆ AMANDA__SIZE_w

#define AMANDA__SIZE_w   (32767)

The maximum size of Unicode characters in a path in Windows, Linux is 1024 characters as far I know

◆ AMARIC__VERSION

#define AMARIC__VERSION   "3.1.8 build 186"

◆ THESIZE

#define THESIZE   (300 * 6)

◆ uchar

#define uchar   unsigned char

◆ uint

#define uint   unsigned int

◆ ushort

#define ushort   unsigned short

Function Documentation

◆ Cancel__lzma()

int __stdcall Cancel__lzma ( )

◆ Compress___lzma_c()

int __stdcall Compress___lzma_c ( char * infile_ar,
char * outfile_ar )

◆ compress_lzma_aakp_rspk()

int __stdcall compress_lzma_aakp_rspk ( char * valquiria_input__file_utf_8,
char * juliete___output_file_utf_8,
int junior_compression_level___ )

function to compress in the standard lzma format

Parameters
valquiria_input__file_utf_8utf-8 encoded input file
juliete___output_file_utf_8utf-8 encoded output compressed file
junior_compression_level___not in use, and this version 24.09 uses 300 mb of memory to compress uncompress
Returns
int
0 - No error
1 - Cannot open input file
2 - Cannot open output file
3 - Error SZ_ERROR_MEM
4 - Error SZ_ERROR_DATA
5 - Error SZ_ERROR_WRITE
6 - Error SZ_ERROR_READ
7 - Unexpected error

◆ lffilesize_ar()

__int64 lffilesize_ar ( const char * szFileName)

simplistic function to get the size of a file, developed 30 years ago

Parameters
szFileNameutf-8 encoded file
Returns
__int64

◆ lgetpor_ar()

int lgetpor_ar ( __int64 max,
__int64 fatia )

◆ main_ar()

int main_ar ( int numArgs,
char **  )

◆ Pause__lzma()

int __stdcall Pause__lzma ( )

◆ pedro_dprintf()

void pedro_dprintf ( int amanda_level,
char * format,
... )

◆ pedro_dprintf2()

void pedro_dprintf2 ( int amanda_level,
char * format,
... )

pedro_dprintf2 is my variant of my debug function because too much calls to pedro_dprintf these days, I am lazy, sorry....

em brotli or brotli2

Parameters
amanda_levelif equal or above 0 print the string
formatprintf based format
...

◆ Progress__lzma()

int __stdcall Progress__lzma ( )

◆ Resume__lzma()

int __stdcall Resume__lzma ( )

undocumented because not in use at this moment

Returns
int 0

◆ Returnvalue__lzma()

int __stdcall Returnvalue__lzma ( )

◆ Running__lzma()

int __stdcall Running__lzma ( )

◆ soc_lzma_compress_ar()

int soc_lzma_compress_ar ( char * myinfile__ar,
char * myoutfile__ar,
__attribute__((unused)) int level_ar )

◆ soc_lzma_uncompress_ar()

int soc_lzma_uncompress_ar ( char * myinfile__ar,
char * myoutfile__ar )

◆ uncompress_lzma_aakp_rspk()

int __stdcall uncompress_lzma_aakp_rspk ( char * valquiria_input__file_utf_8,
char * juliete___output_file_utf_8 )

Function to uncompress a standard lzma compressed file.

Parameters
valquiria_input__file_utf_8utf-8 encoded compressed file
juliete___output_file_utf_8utf-8 encoded output file
Returns
int
0 - No error
1 - Cannot open input file
2 - Cannot open output file
3 - Error SZ_ERROR_MEM
4 - Error SZ_ERROR_DATA
5 - Error SZ_ERROR_WRITE
6 - Error SZ_ERROR_READ
7 - Unexpected error

◆ Uncompress_no_no()

int __stdcall Uncompress_no_no ( char * infile_ar,
char * outfile_ar )

◆ utf8_2_wide_dl()

WCHAR * utf8_2_wide_dl ( const char * pUTF8)

my temporary utf8_2_wide_dl function to add full Unicode support and future (when modified) support to long filenames. (jan/2025)

Parameters
pUTF8
Returns
WCHAR*

◆ widetoutf8()

char *__stdcall widetoutf8 ( WCHAR * pUSC2)

Variable Documentation

◆ comando_ar_lzma

int comando_ar_lzma = 0

◆ file_tamanho_ar_lzma

__int64 file_tamanho_ar_lzma = 0

◆ intcancel_ar_lzma

int intcancel_ar_lzma = 0

◆ intpause_ar_lzma

int intpause_ar_lzma = 0

◆ intreturn_ar_lzma

int intreturn_ar_lzma = 0

◆ myinfile_ar

char myinfile_ar[MAX_PATH+1]

◆ myoutfile_ar

char myoutfile_ar[MAX_PATH+1]

◆ porcentagem_ar_lzma

int porcentagem_ar_lzma = 0

◆ running_ar_lzma

int running_ar_lzma = 0

◆ unicodemode_ar_lzma

int unicodemode_ar_lzma = 1