jed-users mailing list

[2005 Date Index] [2005 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

FW: New patches for slang-pre2-r7 and jed-B0.99-17.82.


[I tried to send this mail some days ago, but it didn't reach the mailing 
list... Maybe it was a bit too big? I'm resending with a smaller attachment,
and John in CC. Icons on a separate mail]

Hi, 
 
I have tried jed B0.99-17.82 and slang-pre2-r7 on Windows.

A lot of patches follow: I'm trying to push all I have before slang 2
final.

You can find a windows installer with all these patches applied, plus 
new icons from Marko Mahnic, from tonight (Europe time) on my jed page
(http://www.paneura.com/~dino/wjed.html).
[UPDATE: this is already there].
 
- slang-pre2-r7-fix-win-compile.diff
   - makefile.all: no more 'dll' target. If Makefile is generated
     without passing DLL to mkmake, a static library is created, and
     passing DLL the Makefile will build a dynamic library. This
     simplifies makefile.all, and works in a way more consistent to
     me. If john chooses not to apply this one, all the references to
     startup.c and startup.o shuld be removed, as the file doesn't
     exists. (my original patch has it, but John put it contents in
     slcommon.c).
   - slcommon.c: an #include <windows.h> was lost in the merge between
     slcommon.c and my old startup.c.
   - I changed things to use native vsnprintf() for visual studio, but
     that symbol doesn't exists, is called _vsnprintf()...
   - slang.h: add a missing SL_EXTERN to SLang_find_key_function(). To
     be able to build modules, SL_EXTERN is not enough in
     SLANG_MODULE() macro: we need a __declspec(dllexport), but we
     don't want to define SLANG_SOURCE_. So define SL_EXPORT,
     SL_IMPORT, use these to define SL_EXTERN, and use SL_EXPORT in
     SLANG_MODULE().

To succesfully compile and run slsh with a slang dll, I need
slang-slsh-win-makefile-fix-dll.diff:
   - makefile.all: Add DLL option, to tell if we are compiling against
     a dll slang (sadly we need to define SLANG_DLL=1 because
     variables imported from a dll MUST be declared 
     __declspec(dllimport)).
   - slsh.c: build a  default path for modules. This is a bit hackish.
     See next patch on why.

I have some fixes for small glitches in slang (slang-fix-glitches.diff)
   - slarith.c: Two variables (obj_a, obj_b), are declared on a block
     scope, their address is assigned to a wider scope pointer, and then
     dereferenced outside the declaration scope.
   - slarrfun.c: remove an unused variable.
   - slclass.c: visual studio compiler complains if taking the address
     of a function without & (I don't know why...).
   - slconfig.c: for visual studio, don't #define pid_t et al. as those
     are typedef'ed in system includes.
   - slposdir.c: add #include <direct.h> for windows, to avoid
     warnings (should be only for visual studio?)
   
To be able to build modules on windows, there is
(slang-win-modules-support.diff)
   - slimport.c: define dlopen() etc to their Windows equivalents.
   
And to actually build modules we need (slang-modules-win32-compile.diff):   
   - makefile.all: add.
   - slsmg-module.c (the only module I have compiled so far): fixes to
     compile on windows.

Needing to prepare makefiles from makefile.all in 3 different
directories, I prepared a simple .bat file to do this for me
(slang-dos-build-helper.diff):
   - add build.bat (usage: e.g. build.bat WIN32 VC).

And finally (on slang side), to add a bit of color to slsh, there's a
patch to use icons from Marko Mahnic
(slang-slsh-win-makefile-add-resource.diff). This needs also slsh.ico
and sldoc.ico in slsh directory.
   - slsh.rc: Add.
   - makefile.all: build .res from slsh.rc and link to slsh.exe.
  
Now the Jed side (is far shorter, I promise):

First the needed pieces: jed-B0.99-17.82-fix-win32.diff:
   - makefile.all: add DLL parameter, to use when linking with
     wslang32.dll.
   - wterm.c: Fix the same Batch typo already fixed in other places.
   
Now some glitches (jed-fix-glitches.diff):
   - buffer.c: add a missing SLfree().
   - file.c: fix a leak while reading a non existing (or empty?) file.
     (the patch seems big because reintendation, but is very simple).
     
And now the goodies (jed-add-icons.diff) add Marko's icons to jed and
wjed:
  - jed.rc, wjed.rc, resource.h: Add.
  - makefile.all: build .res and link in wjed and jed.
  - wterm.c: set application icon.
 

Thanks,
       						Dino
					

Attachment: jed-patches.zip
Description: Binary data


[2005 date index] [2005 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]