Jump to content

Welcome to MSFN Forum
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account



Photo

MSVC, .NET, and C# on 98SE

- - - - -

  • Please log in to reply
9 replies to this topic

#1
Yushatak

Yushatak

    Newbie

  • Member
  • 18 posts
  • Joined 17-September 10
  • OS:98SE
  • Country: Country Flag

I've got MSVC6 set up on my Libretto 110CT (daw.. it's so cute! :3).

 

Anyway, I don't know any of the languages it supports (except a tiny amount of VB6), so while I do intend to learn them, I was looking for a way to use what I already know to code for 98SE.

 

My favored languages are Python and C#, and I am aware that Python 2.5 can run on 9x and have used that in the past. I'm looking for ways to get C# going on there, but I'm rusty on some details and never had/can't find others.

 

I need:

- Max version of .NET runtime that will work on 9x.

- Max version of .NET runtime that will work on 9x with KernelEx (if different).

- Max version of MSVC that will work on 9x with KernelEx.

- Can Mono work on 9x, perhaps with KernelEx? This might be a more feasible way to go about things, because it's open source and can be modified if necessary, perhaps frankenstein a solution out of .NET and Mono to get what I want/need.

 

Ultimate goal is to get C# with LINQ compiling under 9x, but I'd settle for compiling for a KernelEx-equipped 9x from another platform if that's what works. I imagine that targeting Win2k might prove to be a good way to go about that approach.

 

I'll update the thread with any info I come up with on my own, and I'd "just try things" but I'm at work currently. IIRC .NET 3.0 is the last version for 98SE, and it doesn't have LINQ until either 3.0SP1 or 3.5, and trying to manually add LINQ didn't work out for existing applications written to target higher .NET - granted I was a noob to .NET then, and I might have better luck now by modifying manifests and such or building to target that amalgam of assemblies rather than the newer ones that include the feature out of the box.

 

Alternatively I could find LINQ in Mono and perhaps backport it to .NET 3.0..

 

Thoughts? Know something from my list? Please share. :3

 

Thanks. :D

 




How to remove advertisement from MSFN

#2
Yushatak

Yushatak

    Newbie

  • Member
  • 18 posts
  • Joined 17-September 10
  • OS:98SE
  • Country: Country Flag

Here's the stuff I've learned:

 

Visual Studio .NET (2002) is the first version to contain C#.

 

The last version able to run on 9x was Visual Studio 6.0 - .NET 2003 should work fine with KernelEx, and probably even 2005/2008, but they would be pushing it for modest 9x hardware like my L110, even with the unofficial RAM upgrade hack). However, perhaps I can hack around a bit and reduce their resource use (maybe decouple the compiler and UI And use the 2003 or 2005 UI with the 2008 compiler and other underlying bits? Not sure how possible that is, since I haven't looked at the file structure/etc.).

 

According to Wikipedia the last version able to *target* 98 was Visual Studio 2005.

 

Visual Studio 2008 is the last version able to target Win2k.

 

Visual Studio 2012 is the last version able to target WinXP (requires a post-release patch, might still have the feature in 2013, not sure).

 

The last .NET runtime to natively support 98 was 2.0 with no service packs.

 

The last .NET runtime to support Win2k was 2.0 with all service packs (provided Win2k was on SP4).

 

Most of the new features in C# 3.0 are "compiler magic", and the MSIL it compiles down to is still the same as C# 2.0. As such, code written in C# 3.0 can be compiled down to 2.0 (in most cases) and/or only requires .NET 2.0 in the first place.

 

Various projects (I'll put a list of links below) allow you to use LINQ on C# 3.0, basically providing the few changes to the CLR between 3.0 and 3.5 that are required for LINQ to function, then providing LINQ itself on top of that, or re-implementing LINQ without those requirements.

 

Note that this is just LINQ-to-objects, not SQL or XML - these are possible if 2.0 SP1 are running with some hacks (http://linqinaction....on-net-2.0.aspx), but that means a version of .NET that isn't supported on 98, so it may require KernelEx and would definitely require some hacking around.

 

https://code.google.com/p/linqbridge/ (Designed for 2008, will work on 2005 but less usable - this is a re-implementation of LINQ)

https://linq4you.codeplex.com/ ("Compiles" on 2010, not sure if that means it requires 2010 to be used in a project, or if that just means the assembly itself won't build on lower - this is a port of Mono's LINQ to C# 3.0)

 

There's also "Legacy Extender" (http://www.legacyextender.com/) - this plugs into 2005 or 2008 and provides various tools/fixes to let you target now-unsupported OSes, such as 98 on 2008 or 95 on 2005, etc.

 

Between the previous few points, it looks like using 2008 and targeting 98 (using Legacy Extender) with .NET 2.0 and one of the LINQ-adding projects (I'm leaning toward LINQBridge since it has a single-source-file implementation which you can just throw into your project) is optimal.

Edited by Yushatak, 15 November 2013 - 09:40 AM.


#3
jumper

jumper

    2014 All-American Masters HJ'er

  • Member
  • PipPipPip
  • 479 posts
  • Joined 21-January 11
  • OS:98SE
  • Country: Country Flag
This is excellent information :yes: -- much better than the guesses I almost posted yesterday!

I still use VC5 most of the time, but sometimes VC6. I have also been experimenting with Orwell Dev-C++ / MinGW32 4.7.2 with some success.
Design feedback requested:
IHAtool - IpHlpApi tester; call various functions and report results
--status-> framework is solid; 22 api's fully supported; preview release coming soon
ComDlg32 wrapper - ComDlgEx meets IpHlpApi wrapper
--status-> PrintDlgExW working in latest SumatraPDF 8^)
Future projects: ImportPatcher40 - dialog interface; Kexter - IP40+Ktree+Kexstubs

#4
dencorso

dencorso

    Adiuvat plus qui nihil obstat

  • Supervisor
  • 5,887 posts
  • Joined 07-April 07
  • OS:98SE
  • Country: Country Flag

Donator

MSVS 6.0 is the ideal programing environment for 9x/ME. While .NET 2.0 installs on 98+, most of the users avoid .NET completely on 9x/ME, because they're huge and add very little. OTOH, if one can program in C#, going down to C++ or even pure C, should be relatively easy (and quite worth the effort). These, of course, are just my 2¢... and, of course again, YMMV.



#5
ROTS

ROTS

    Member

  • Member
  • PipPip
  • 233 posts
  • Joined 22-September 12
  • OS:none specified
  • Country: Country Flag
From what I understand, 2005 is the last release to support normal ".exe" compiling, is that true? Every other release afterwards will not?

#6
M()zart

M()zart

    Member

  • Member
  • PipPip
  • 277 posts
  • Joined 17-June 08

From what I understand, 2005 is the last release to support normal ".exe" compiling, is that true? Every other release afterwards will not?

I'm not sure about it. AFAIK, there were official MS VC 2008 redistributables that could be installed on Windows 98 without KernelEx. With KernelEx it was possible to run some exes compiled with VS 2010. However all this is about unmanaged C++ applications.



#7
Yushatak

Yushatak

    Newbie

  • Member
  • 18 posts
  • Joined 17-September 10
  • OS:98SE
  • Country: Country Flag

MSVS 6.0 is the ideal programing environment for 9x/ME. While .NET 2.0 installs on 98+, most of the users avoid .NET completely on 9x/ME, because they're huge and add very little. OTOH, if one can program in C#, going down to C++ or even pure C, should be relatively easy (and quite worth the effort). These, of course, are just my 2¢... and, of course again, YMMV.

 

You're probably right, but I really love LINQ.

 

There's a lot of options here, really, and I plan to actually pursue them all independently. Getting things that aren't intended to run on older things or vice versa has always been a favorite pastime of mine - lol.

 

I have meant to learn C++ and C for years, but had trouble not hating its syntax. I came from GML (Gamemaker scripting language, lol), then Python, so C++/C seemed super-un-intuitive and nasty (and PHP, though that's unrelated). C# was much more approachable and I learned it for work, and feel more comfortable in it than I ever even did in Python at this point (8 hours a day does that, it seems). Anyway, now that I know C# I might be able to go do C++ and then C, learning in reverse-time-order. :P

 

Maybe I'll create a LINQ-equivalent for C++ (it'd be useless for proper C - yes I realize there are OO extensions for C but what the f***, that's what C++ and objective-C are..) to make things easier on myself once I'm more comfortable in C++. Then again, maybe there already is one, I should check. It would likely require backporting, though (but who knows).

 

A project that would be good when I try my hand at driver development (this will be a ways down the road, of course) would be taking the ndiswrapper project for Linux and adapting it into something that would work for running newer networking devices (particularly wireless) on 9x via translating/wrapping the driver. The primary idea there being CardBus and PCI, but it would be a general-purpose solution. Firstly I'll do some desktop applets/apps, and maybe a game (dunno if I'll have something spark my interest), then try simple drivers for things that either already work or are so simple that they may as well (like USB LCD display things in the G15/G13). That should give me the foundation I'll need for the madness that I of course will then descend into (and oh how I await the madness).

 

A tool that I really want created is something to take games (and apps, the hardcoded-size nastiness that sometimes comes around) that run in 800x600 and tweak them to work at 800x480 for my Libretto 110CT (and similar devices like the EeePC[79]0[01] - I learned regex recently at long last if you can't tell).


Edited by Yushatak, 24 November 2013 - 11:30 AM.


#8
dencorso

dencorso

    Adiuvat plus qui nihil obstat

  • Supervisor
  • 5,887 posts
  • Joined 07-April 07
  • OS:98SE
  • Country: Country Flag

Donator

If you're talking drivers, and you're really dead serious about it, then killing the DOSBox bug of Bearwindows VBEMP might be the single most valuable contribution you might make while getting a real tasting of the madness one, of course, must descend into ("Beware the Jubjub bird, and shun the frumious Bandersnatch!"). I don't have my 9x favorites in this machine I'm writing from right now, but I'm sure jaclaz, RLoew or LoneCrusader will gladly provide you the needed links to read more about that.



#9
trevor89

trevor89

    Junior

  • Member
  • Pip
  • 58 posts
  • Joined 31-December 08
  • OS:98SE
Goldeneye setup editor PerfectGold is compiled in msvc 2008 and runs under 9x with kex.
the official redist from ms installs under system32 which proves to be no problem. Moving to system folder can be done but has no advantage. (ive often thought to move all 32bit dlls to the system32 folder as an experiment)

the 3d window requires d3d31.dll in the editors folder set to 2k otherwise editor will crash when using 3d.
Posted Image

#10
M()zart

M()zart

    Member

  • Member
  • PipPip
  • 277 posts
  • Joined 17-June 08

While programs compiled in VS 2008 can run on Windows 98 (and I'm not sure that KernelEx is required, just the special version of MS VC runtime), this is about native apps, not .NET ones. I've heard something about patched .NET Framework 3 running with KernelEx on this forum, but I'm not sure about this. As for me, I always avoided .NET Framework on my Windows 98 machine.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users