News:

Download Pelles C here: http://www.smorgasbordet.com/pellesc/

Main Menu

Windows 11

Started by TimoVJL, December 11, 2024, 04:29:15 PM

Previous topic - Next topic

HellOfMice

Hi John


I always am afraid when modifying this part of Windows. RegEdit can be dangerous


Thank You


PhR

John Z

#16
Also found at Microsoft link below -


https://answers.microsoft.com/en-us/windows/forum/all/how-to-stop-or-block-windows-11-update/9f271456-51dd-4716-b69d-0834d552ca83

John Z

Attached pdf in case it disappears from the MS site.

Update - well maybe not going to work on a home system.

Checked registry and the full path
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate
does not exist in my system no "\WindowsUpdate" segment so it would need to be added as well although the instructions do not say that and assume the full path is there.  Perhaps adding it won't matter and it won't work unless system is using GROUP policies.


Update 2 - I've set the registry to "23H2" we'll see.  Need to reboot now
Update 3 - I'm back up no crash  :) ;D whew!  Doesn't mean it really works though - time will tell

TimoVJL

#17
Here is pocc.exe v11 for testing.

This code don't need headers, to test a bare pocc.exe.
int __cdecl main(void)
{
return 0;
}
May the source be with you

HellOfMice

I made the changes in powershell. Seems to be good

alderman2

I only compile in 32bit, Windows 11 24H2 get the same error no matter what I do.

As I, and others, have pointed out before, if you click "run" once and wait for the error message to appear, then click "Run" again and it works.
You therefore do not need to downgrade the Windows version to program in Pelles-C.

HellOfMice

#20
If I understood Pelle forgot to do this:

Quotevoid *AllignData(void *data)
{
  return (void *)(((int) data + 15) &~ 0x0F) ;
}

It is too big! He is able to write programming tools and forgot something essential, I suppose he made a lot of case on this.

When do you come back Mr Orinius? I will not wait for your return a lot of time.

John Z

Hi Alderman2,

Quote from: alderman2 on January 06, 2025, 07:57:22 PM
I only compile in 32bit, Windows 11 24H2 get the same error no matter what I do.

As I, and others, have pointed out before, if you click "run" once and wait for the error message to appear, then click "Run" again and it works.
You therefore do not need to downgrade the Windows version to program in Pelles-C.

Two things
1) AFAIK the 'click run twice' has not been mentioned to work for 64 bit programs
2) Why should 'click run twice' work at all? That does not make sense to me.

John Z

alderman2

I haven't tested 64 bit.

I click "Run" first and wait for the job to finish.
I get the error message.
I then click "Run" again and the compiled program runs.

To me it seems that the program compiles on first "Run" but fails to start.
At second "Run" the program starts.

TimoVJL

#23
@alderman2
What happens, when you push "Compile" button ? Any errors ?

"Run" is just a poide feature.

I want to know, how pocc.exe, porc.exe and polink.exe works in Windows 11 24H2 system.

pocc.exe have a one bug report already.
May the source be with you

dezmand07

Quote from: alderman2 on January 07, 2025, 12:24:53 AM
I click "Run" first and wait for the job to finish.
I get the error message.
I then click "Run" again and the compiled program runs.
The first time the error occurs if changes were made to the code.
But when you compile the second time, there are no changes in the code, and the compiler compiles an exe-file for you from the existing obj-files.
Delete (or move) the obj-files from the output folder of your project and try to rebuild the project completely.
Maybe get lucky and the stack pointer will be valid, then the compiler will work.

dezmand07

Quote from: TimoVJL on January 07, 2025, 04:25:38 AM
I want to know, how pocc.exe, porc.exe and polink.exe works in Windows 11 24H2 system.

pocc.exe have a one bug report already.
I didn't notice any problems with porc.exe
Resources compile perfectly on any Windows.

TimoVJL

Hopefully pocrt don't have any problems with Windows 11 24H2.

Windows 11 might belong same series as Vista and 8, so we have to wait Windows 12, if it is more stable  :P
May the source be with you

alderman2

#27
I've been programming for many years, and in all these years I've never been introduced to how the programs are created. Therefore, I might answer a little differently than everyone who is familiar with how programs are created in Pelles-C (= I can watch TV but don't know how it works). Hope you understand what I mean.

I wildly test:

1. If I change the code and then compile, I get an error message every time.
2. If I change the code and then build xxx.exe I get error the first time but works the second time with the changes also in the exe file.
3. If I change the code and then build xxx.exe I get an error message. After that I compile and get error message.
4. If I change the code and then compile, I get an error message. After that I build xxx.exe it works with the changes also in the exe file.
If I delete the .obj and .res and do as above I get the same result.

I noticed one thing:
When I click Build xxx.exe the first time, the .obj file is created.
When I click Build xxx.exe the second time, the .res file is created and the changes in the code are also changed in the xxx.exe file.

Could it have something to do with the resource file?

Otherwise I have no problem with creating exe software, it works as before the error with the difference that I have to build twice, the second time it works.

The difference between "Build" and "Run" is that "Run" first builds and then starts the .exe file as well?!

HellOfMice

When I tried to compile I had the error message: :-[


File system error (-1073741819)

John Z

#29
Hi Alderman2,

Quoteauthor=alderman2 link=topic=11435.msg40342#msg40342 date=1736272788

I noticed one thing:
When I click Build xxx.exe the first time, the .obj file is created.
When I click Build xxx.exe the second time, the .res file is created and the changes in the code are also changed in the xxx.exe file.

Could it have something to do with the resource file?

No - nothing to do with the .res file or processing of it.  All the results you reported are consistent with the issue.  In the flow of creating the exe the .obj files are first created, then the .res file is processed see this exerpt from a ppj file.

# Build Hello_World.exe.
#
Hello_World.exe: \
output\main.obj \
output\main.res
$(LINK) $(LINKFLAGS) -out:"$@" $**

#
# Build main.obj.
#
output\main.obj: \
main.c \
main.h
$(CC) $(CCFLAGS) "$!" -Fo"$@"

#
# Build main.res.
#
output\main.res: \
main.rc \
main.h \
main.ico \
res1.ico
$(RC) $(RCFLAGS) "$!" -Fo"$@"

.EXCLUDEDFILES:

.SILENT:

After it crashes out the first time the object files are already created, so the '2nd' time the build only needs to process the .res file so the final program is then finished.  This does seem to point to the build process otherwise it would crash out after each object - instead it only crashes out when transitioning out of building object files. 

If you are adventurous you could make a backup copy of the ppj file. then edit the original moving the Build xxx.res section to the top leaving obj last. like this

# Build Hello_World.exe.
#
Hello_World.exe: \
output\main.obj \
output\main.res
$(LINK) $(LINKFLAGS) -out:"$@" $**

#
# Build main.res.
#
output\main.res: \
main.rc \
main.h \
main.ico \
res1.ico
$(RC) $(RCFLAGS) "$!" -Fo"$@"

#
# Build main.obj.
#
output\main.obj: \
main.c \
main.h
$(CC) $(CCFLAGS) "$!" -Fo"$@"

.EXCLUDEDFILES:

.SILENT:
 

In theory the build should complete with a crash but the executable might still be created. This change (moving the .res file) worked perfectly on WIN 11 23H2 so moving is worth testing IMO.
>>>> BE sure to create a backup copy of the ppj first !! <<<<

John Z