Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
44 user(s) are online (34 user(s) are browsing Forums)

Members: 0
Guests: 44

more...

Support us!

Headlines

Forum Index


Board index » All Posts (salass00)




Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


@cygnusEd

The mount command's string parsing is rather simplistic and does not support an escape character so using a mount list it is not currently possible to specify arguments with spaces in them. The semicolon for the domain in the smb:// url is problematic for similar reasons (mount command sees it as starting a comment even if it's enclosed within double quotes).

A solution that would avoid these issues would be to add a smb2fs command that takes the same arguments and passes them as is to MountDeviceTags().

Go to top


Re: boopsi: how to make button with 2 lines with centered text in ?
Just can't stay away
Just can't stay away


@kas1e

You need to set LABEL_DrawInfo on the label to a valid DrawInfo obtained with IIntuition->GetScreenDrawInfo(screen). If you don't it won't be able to layout properly.

Go to top


Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


@FlynnTheAvatar

Quote:

Just one question regarding the AmigaOS3 version: what compiler do you use for the AmigaOS3 version? I tried Bebbo's gcc 6 on Linux, but it failed to link because of a missing exit() definition.


This should be fixed now by the latest change to use inet_aton() instead of sscanf() to check/parse a static IP address in smb2_getaddrinfo().

Go to top


Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


Not quite recuperated yet but I managed to fix the ntlmssp auth issue on big endian a few days ago. I was going to make a pull request to libsmb2 from my forked repo but to my surprise a fix had already been added there.

I've also just finished adding utimens() support. A feature that I initially started work on in September 2024 on a local branch (experimental_utimens).

Since the libsmb2-20250607 branch seems to be working now I've merged it into the master branch and it will be used for the upcoming 53.10 release.

Go to top


Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


I've had a flu since yesterday morning. It wasn't so bad initially but it has gradually gotten worse since then, so I probably won't be doing too much work until it gets better.

Anyway, I did manage to find what was causing the AmigaOS3 build to fail (a stray printf(), which was optimized into a puts() by gcc, in libsmb2.c was causing __initstdio.o to be brought in from libnix). I also managed to fix the crashing which was caused by mistakenly freeing the password that was obtained from ReadArgs().

After adding these fixes the AROS version connects successfully to my Ubuntu samba server, but the AmigaOS3 version fails during auth in a similar way to the AmigaOS4 version suggesting that the problem might be related to different endianness.

Go to top


Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


@FlynnTheAvatar

Quote:

$ m68k-amigaos-gcc -v
Using built-in specs.
COLLECT_GCC=m68k-amigaos-gcc
COLLECT_LTO_WRAPPER=/usr/local/amiga/bebbo-20230625/libexec/gcc/m68k-amigaos/6.5.0b/lto-wrapper
Target: m68k-amigaos
Configured with: /home/salass00/Development/Projects/devtools/bebbo/amiga-gcc/projects/gcc/configure --prefix=/usr/local/amiga/bebbo-20230625 --target=m68k-amigaos --enable-languages=c,c++,objc --enable-version-specific-runtime-libs --disable-libssp --disable-nls --with-headers=/home/salass00/Development/Projects/devtools/bebbo/amiga-gcc/projects/newlib-cygwin/newlib/libc/sys/amigaos/include/ --disable-shared --enable-threads=no --with-stage1-ldflags='-dynamic-libgcc -dynamic-libstdc++' --with-boot-ldflags='-dynamic-libgcc -dynamic-libstdc++'
Thread model: single
gcc version 6.5.0b 230607174548 (GCC)


It is a gcc 6.5.0b cross compiler built from bebbo's repo, but almost two years old by now. I built it 25-Jun-2023 from what was likely the current state of his git repo at that time.

I think there may have been some changes to libnix since then that broke the building of smb2-handler.

Go to top


Re: AmigaOS port of libsmb2
Just can't stay away
Just can't stay away


I released version 53.9 of smb2-handler yesterday containing reconnection support changes from Walter Licht.

https://github.com/salass00/smb2fs/releases

I have also started a new branch for updating the used libsmb2 version to the latest git revision at:

https://github.com/salass00/smb2fs/tree/libsmb2-20250607

The AmigaOS4 version compiles but fails during auth at libsmb2-git/lib/ntlmssp.c line 670. The i386 AROS ABIv0 version also compiles but crashes hard during init (I haven't looked further into where exactly it happens yet) and the AmigaOS3 version still needs some fixes before it will compile.

Go to top


Re: Difference pthreads.library/threads.library and -athread=native (extended)
Just can't stay away
Just can't stay away


@kas1e

As said by MickJT earlier the SDK doesn't include a libpthread.so because it should already be installed in SOBJS:. Instead the SDK installer just creates a soft link from "SDK:local/newlib/lib/libpthread.so" to "SOBJS:libpthread.so".

Go to top


Re: bitmap object from a memory block and not from a file ?
Just can't stay away
Just can't stay away


@kas1e

You can do that with the filler.image class:

Image IIntuition->NewObject(FillerClassNULL,
                              
FILLER_Screenscreen,
                              
FILLER_ImageAddressbuffer,
                              
FILLER_ImageSizebufferSize,
                              
TAG_END);


The buffer should point to a datatypes supported image format.

Go to top


Re: texteditor.gadget and copy/paste
Just can't stay away
Just can't stay away


@kas1e

Not sure what you are trying to do, but if it's just connecting a vertical scroller to a texteditor you can just do:

SetAttrs(textEditorObject,
         
GA_TEXTEDITOR_VertScrollerscrollerObject,
         
TAG_END);


and the text editor class will handle updating the scroller as necessary, as well as setting ICA_TARGET and ICA_MAP so that it gets updates from the scroller when it's moved.

Go to top


Re: texteditor.gadget and copy/paste
Just can't stay away
Just can't stay away


@kas1e

You can check if the window object is opened with WINDOW_Window:

struct Window *windowPtr NULL;
GetAttr(WINDOW_WindowwindowObject, (Tag *)&windowPtr);
if (
windowPtr != NULL)
{
   
/* Window opened */
}
else
{
   
/* Window closed/iconified */
}

Go to top


Re: speedbar.gadget and 16bit IDs
Just can't stay away
Just can't stay away


@kas1e

That's because you are defining code wrong. It should be a 16-bit variable (e.g. uint16/int16) not an int32.

Go to top


Re: RadeonHD V.5 driver
Just can't stay away
Just can't stay away


@sailor

I'm using a Radeon HD card in my A1222, but with the RadeonHD v3 driver as it's an older card (not SI) so not supported by the v5 driver.

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


As the .ctors and .dtors sections themselves don't need more than 4-byte/32-bit alignment wouldn't it make more sense to move them to the end of the segment?

Also do they really need to be writable?

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


@LiveForIt

Quote:

its not a string, so why do you want on less char?


I'm not allocating one byte less, I'm allocating sizeof(double)-1 bytes more than needed. This is to ensure that a double (8-byte) aligned address of the required size can always be found within the aligned buffer no matter what the alignment of the array itself is.

Quote:

GCC should automatilcy allign data, and you can use compiler options for it, "packed".


It should but it doesn't.

Using my own compiled test code as example:

While the .data section itself is 16-byte aligned to the start of the executable file:
Section Headers:
  [
NrName              Type            Addr     Off    Size     
  
6] .ctors            PROGBITS        01011094 001094 000008 00  WA  0   0  4
  
7] .dtors            PROGBITS        010110900109000008 00  WA  0   0  4
  
8] .data             PROGBITS        010110b0 0010b0 000010 00  WA  0   0 16


it is preceeded in the segment by .ctors and .dtors sections which are only 4-byte aligned (see above):
Section to Segment mapping:
  
Segment Sections...
   
00     .text .rodata .__newlib_version 
   01     
.ctors .dtors .data .sbss


The result is that when elf.library loads the entire segment 32-byte aligned the .data section gets loaded into it at offset 10b0-1094=1c which is only 4-byte aligned.

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


@sailor

I could be wrong but I don't think definining a pointer to a multi-dimensional array will work. In my experience multi-dimensional arrays in C are quite limited in how they can be used so I almost never use them in my code.

What should work however is something like (not quite as elegant):
static char align_buffer[(A*B*C+1)*sizeof(double)-1];
double *array[A][B];
__attribute__((constructor))
static 
void __init_array(void)
{
    
double *= (double *)(((uintptr_t)align_buffer sizeof(double) - 1) & ~(sizeof(double) - 1));
    
int ij;

    for (
0Ai++)
    {
        for (
0Bj++)
        {
            array[
i][j] = p;
            
+= C;
        }
    }
}

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


@sailor

You could use a method similar to what has been used in m68k-amigaos C code to allocate long word aligned structures like FileInfoBlock from the stack:

static char align_buffer[3*sizeof(double)-1];
double *T1ptr;
double *T2ptr;
#define T1 (*T1ptr)
#define T2 (*T2ptr)

__attribute__((constructor))
static 
void __init_T1T2(void)
{
    
T1ptr = (double *)(((uintptr_t)align_buffer sizeof(double) - 1) & ~(sizeof(double) - 1));
    
T2ptr T1ptr 1;
}


If T1 and T2 were arrays instead of simple double variables you could even make use of C's pointer/array equivalence to get rid of the ugly macros.

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


@sailor

I don't think I tested it since I thought it was an issue with how the executable was loaded at the time, but you could try compiling the object files with ppc-amigaos-gcc-6.4.0 and then linking them with a newer version.

This is how the graphics.library.kmod with SPE support is created. Only the source files that need it are compiled with ppc-amigaos-gcc-6.4.0 and ppc-amigaos-gcc is used to compile everything else and for linking the final executable.

Go to top


Re: A1222 support in the SDK and problems
Just can't stay away
Just can't stay away


@sailor

Quote:

If I declared double variables like globals, they are aligned allways to 4 Bytes ( I even used __aligned__ attribute). If I declared them inside main(), they are aligned correctly to 8 Bytes. SPE needs 8 byte alignment.


I encountered a similar problem when testing libcfsl code (SPE optimized versions of some standard string functions) in that the static LUTs (declared in assembler code here) would not always be aligned correctly when loaded even though .align was used in the code. I filed a bug report for this for elf.library but IIRC the verdict was that the issue was somewhere in the gcc linker script.

Go to top


Re: AOS 4.1 FE reinstall and preparation for update 3
Just can't stay away
Just can't stay away


@kas1e

Quote:

LIBS: install all, just one by one, to not overwrite of what you already have. I.e. no datatypes.library overwrite should be done, no z.library overwrite as they originals.


The z.library, expat.library, filesysbox.library and lzma.library are okay to replace (as long as they are newer versions, which they likely will be) as they are based on the same source code as the OS included ones.

Go to top



TopTop
(1) 2 3 4 ... 88 »




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project