Compiling multi-module package with Clipper

Issues and Discussions related to Harbour

Moderator: Rathinagiri

User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Compiling multi-module package with Clipper

Post by esgici »

Hi All

This may be considered off topic; still may interest people;

because one side of problem very old, related to Clipper, other side is very fresh, related to latest Windows versions.

One of my friend ask help me. He has a Clipper compiled application (with full source) and disaster : customer past to Windows 64 bit :x

I have Clipper 5.2 this is good news.

And I couldn't compile the application despite all my effort :evil:

First problem is : too many .prg file ( more than 30 )

So required using RMAKE and .rmk file; fortunately .rmk file exist :mrgreen:

And required .lnk file for RTLINK;

I don't know how many friends experienced with this : excellency Windows keep .lnk file extension for very special manner:
  • - don't display file extension (lnk)
    - display file size 0 (zero)
    - don't allow open with any program
    - even though the changed extension, continue this evil protection :twisted:

I need desperately your help especially by who experienced this problem.

TIA
Viva INTERNATIONAL HMG :D
User avatar
Agil Abdullah
Posts: 204
Joined: Mon Aug 25, 2014 11:57 am
Location: Jakarta, Indonesia
Contact:

Re: Compiling multi-module package with Clipper

Post by Agil Abdullah »

I have Clipper 5.2 this is good news.

And I couldn't compile the application despite all my effort

First problem is : too many .prg file ( more than 30 )

So required using RMAKE and .rmk file; fortunately .rmk file exist
No problemo. 30 PRGs or more is not problem. I compiled nearly 100 PRGs ( devided into 5 modules to produce 5 *.EXE) for a Hotel Management System in period 1991-2005 (commercial version).

Perhaps, your friend compiled them using *.RMK as I did in the past. See below ( I take it from my doc). If it's the case, I wish I could help.

Code: Select all

//  Fosc.rmk
//  Make file for Fosc00, Module Guest Accounting program  for  IBIS Hotel Cikarang, Bekasi, Indonesia.
//  Copyright (c) 1991 Agil, @all rights reserved.
//
// Define macros

makepath[.h]   = "include\; IBISCKR\"
makepath[.prg] = "IBISCKR\"
makepath[.obj] = "obj\"

.prg.obj:
    clipper $** 

// Dependency statement for .OBJ files
FOSC500.OBJ:  Fosc500.prg
FOSK0.OBJ:    Fosk0.prg
FOSDBASE.OBJ: Fosdbase.prg
FOSLIB.OBJ:   FosLib.prg
FOSRRPT.OBJ:  Fosrrpt.prg
FOSR04.OBJ:   Fosr04.prg
FOSC04.OBJ:   Fosc04.prg
FOSS05.OBJ:   Foss05.prg
FOSCRPT.OBJ:  Foscrpt.prg
//FOSTRANS.OBJ: FosTrans.prg
PRGLIB.OBJ:   Prglib.prg
MEMOEDIT.OBJ: MemoEdit.prg
FOSLOGBK.OBJ: FOSLogbk.prg
//
FOSC00.EXE: FOSC500.obj FOSLIB.obj FOSCRPT.OBJ \
FOSR04.obj FOSS05.obj MEMOEDIT.obj TBROWSE5.OBJ FOSDBASE.obj PRGLIB.obj \
FOSC04.OBJ FOSlogbk.obj FOS_AR.OBJ FOSK0.OBJ
    BLINKER @IBISCKR\FOSC
Agil Abdullah Albatati (just call me Agil)
Programmer Never Surrender
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: Compiling multi-module package with Clipper

Post by esgici »

Agil Abdullah wrote: No problemo. 30 PRGs or more is not problem. I compiled nearly 100 PRGs ( devided into 5 modules to produce 5 *.EXE) for a Hotel Management System in period 1991-2005 (commercial version).

Perhaps, your friend compiled them using *.RMK as I did in the past. See below ( I take it from my doc). If it's the case, I wish I could help.
Thanks to interest and help :)

Problem isn't count of file, but .lnk file.

More, your sample .rmk seem for Clp53 and probably last line indicate a .lnk file :(
BLINKER @IBISCKR\FOSC
Did you tried recompile your system under actual conditions ( FE on Win 7 ) ?

Anyway thanks again.

Regards
Viva INTERNATIONAL HMG :D
User avatar
Agil Abdullah
Posts: 204
Joined: Mon Aug 25, 2014 11:57 am
Location: Jakarta, Indonesia
Contact:

Re: Compiling multi-module package with Clipper

Post by Agil Abdullah »

1) You're right, FOSC.LNK exists (I just took a look at my laptop in old directory) of CLIP52E, see below:

Code: Select all

BLINKER EXTMEM BLOCK 512
BLINKER CACHE XMS 50%, 2048
BLINKER CACHE EMS 25%, 512
BLINKER SEGMENT THRESHOLD 16384
OUTPUT FOSC00.EXE
FILE FOSC100
BEGIN AREA
   FILE FOSC04
    FILE FOSCRPT
    FILE FOSK0
    FILE FOSYSID
   FILE FOSDBASE
    FILE FOSLIB
    FILE FOSRRPT2
    FILE FOSRRPT3
    FILE FOSR04
    FILE FOSS05
    FILE TBROWSE5
    FILE PRGLIB
    FILE OMENUXTD
ENDAREA
LIBRARY FAST
LIBRARY BLXCLP52
@cl520mid

2) You said the problem is *.lnk files because Windows protects them from opening. You're partly right and partly wrong. Indeed Win-7 in my laptop recognizes *.lnk files as "shortcut", no opportunity to open them as text files.

But, It's a magic that I managed to open fosc.lnk smoothly... You see, I happened to use TextReader that I modified from Grigory Filatof.

Still remember my post 2 days ago ? [READ TEXT FILE STRARTREK STYLE]

Hope this fixes your problem.

Cheers.
Attachments
ReadText.rar
(2.47 KiB) Downloaded 306 times
Agil Abdullah Albatati (just call me Agil)
Programmer Never Surrender
User avatar
Agil Abdullah
Posts: 204
Joined: Mon Aug 25, 2014 11:57 am
Location: Jakarta, Indonesia
Contact:

Re: Compiling multi-module package with Clipper

Post by Agil Abdullah »

Open the ReadText.exe, select "All Files",,,,, pick the *.lnk file,,, you will see the actual prove like below:
Attachments
ReadLNKfile.png
ReadLNKfile.png (47.47 KiB) Viewed 6048 times
Agil Abdullah Albatati (just call me Agil)
Programmer Never Surrender
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: Compiling multi-module package with Clipper

Post by esgici »

Neither wrong nor magic;

simply Windows "Security Privilege settings" :(

I can't change my authority settings in my own computer; because I haven't this privilege :x
esgici wrote: ...
- don't allow open with any program
...
That is not program issue.

Your .lnk file is for Blinker; if you have a .lnk file for RTLink please send me its content.

TIA
Viva INTERNATIONAL HMG :D
User avatar
Agil Abdullah
Posts: 204
Joined: Mon Aug 25, 2014 11:57 am
Location: Jakarta, Indonesia
Contact:

Re: Compiling multi-module package with Clipper

Post by Agil Abdullah »

Hehehehe.... I am very very sorry for misunderstanding. I wrongly read your post.

Oke. Below is a sample of *.lnk file for RTlink from my old doc of early 1991 (hope this time is correct): It's to create fin71000.exe

file fin71000
file gl710000
file gldbase6
FILE GLGENLIB
file glgenlb6
file glinq6
file gllogo7
file glrpt7
file glrpt72
file ap610000
file apdbase6
file apgenlb6
file apinq6
file aprpt6
file ar610000
file ardbase6
file argenlb6
file arinq6
file arrpt6

file prglib
file tbrowse5
verbose
Agil Abdullah Albatati (just call me Agil)
Programmer Never Surrender
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: Compiling multi-module package with Clipper

Post by esgici »

Agil Abdullah wrote: Oke. Below is a sample of *.lnk file for RTlink from my old doc of early 1991 (hope this time is correct): It's to create fin71000.exe
Wow :o
You are a true treasure :D

I know, it's late for you, but if you are reading this post, would you give me .rmk file of this project (fin71000.exe) :oops:

TIA
Viva INTERNATIONAL HMG :D
User avatar
Agil Abdullah
Posts: 204
Joined: Mon Aug 25, 2014 11:57 am
Location: Jakarta, Indonesia
Contact:

Re: Compiling multi-module package with Clipper

Post by Agil Abdullah »

I guess, FIN71.RMK below is what you are looking for (once again hopefully this time i'am correct, InshaAllah wa billahi taufik wal hidayah, Amen.). Let me summarize & explain very clearly, in case you forget the old version system, as follows:

- It's original structure *.rmk last update 1997. "\" for continue code, "//" for comments.
- It's to generate Fin71000.exe without overlays (*.ovl) with Clipper52e.
- It's to place topmost procedure at Fin71000.prg as the main procedure, the rest everywhere are sub-procs.
- Its compiling is under MS-DOS.6.x or under Win98 at DOS-prompt.
- its *.exe run under any Windows.
- the lib of "INCLUDE" is directory-default under Clipper, the rest are my own libs and 3rd party ones.
- the "OBJ" is to place OBJs in directory to recognize by compiler (i put OBJs separately for every system).

BEFORE COMPILING, [fardhu 'ain] make sure to declare directive commands at DOS-prompt (see sample of my Setcl52.bat from my doc year 1997)

Code: Select all

SET CLIPPER=//F120 //DYNF:8
SET INCLUDE=\CL52\INCLUDE;\cl52\fastlib;\cl52\fastgt15
SET LIB=\CL52\LIB;\cl52\fastlib;\cl52\fastgt15
SET OBJ=\CL52\OBJ
SET PLL=\C52\PLL
SET CLIPPERCMD=/O\CL52\OBJ\ /M /W /N
SET PATH=\CL52\BIN;C:\WINDOWS;\WINDOWS\COMMAND
SET

Code: Select all

//-- FIN71.rmk [tailor made for client]: RESOR PANTAI CARITA BEACH HOTEL, West Java, Indonesia
//  Make file for FIN71000.exe   :General Office ACCOUNTING System (Back Office Package).
//  Copyright (c) 1997 Agil,,, @all rights reserved.
//
// Define macros
makepath[.h]   = "INCLUDE\;GLv7\"
makepath[.prg] = "GLv7\;FOSYS\"
makepath[.obj] = "OBJ\"

// Inference rule for compiling (.prg) to .OBJ files
.prg.obj:
    clipper $**

// Dependency statement for .OBJ files
FIN71000.OBJ:      FIN71000.PRG
GL710000.OBJ:     GL710000.PRG
GLDBASE6.OBJ:     GLDBASE6.PRG
GLGENLIB.OBJ:     GLGENLIB.PRG
GLGENLB6.OBJ:    GLGENLB6.PRG
GLRPT7.OBJ:        GLRPT7.PRG
GLRPT72.OBJ:      GLRPT72.PRG
GLINQ6.OBJ:        GLINQ6.PRG
GLLOGO7.OBJ:     GLLOGO7.PRG
PRGLIB.OBJ:         PRGLIB.PRG
TBROWSE5.OBJ:   TBROWSE5.PRG
AP610000.OBJ:     AP610000.PRG
APDBASE6.OBJ:     APDBASE6.PRG
APGENLB6.OBJ:     APGENLB6.PRG
APRPT6.OBJ:         APRPT6.PRG
APINQ6.OBJ:         APINQ6.PRG
AR610000.OBJ:     AR610000.PRG
ARDBASE6.OBJ:     ARDBASE6.PRG
ARGENLB6.OBJ:     ARGENLB6.PRG
ARRPT6.OBJ:        ARRPT6.PRG
ARINQ6.OBJ:        ARINQ6.PRG
//
// Dependency rule for linking .OBJ files to a .EXE file
  FIN71000.EXE: FIN71000.OBJ GLDBASE6.OBJ GLGENLB6.OBJ GLRPT7.OBJ GLINQ6.OBJ \
                GLRPT72.OBJ GLLOGO7.OBJ GLGENLIB.OBJ GL710000.OBJ PRGLIB.OBJ \
                TBROWSE5.OBJ APDBASE6.OBJ APGENLB6.OBJ APRPT6.OBJ APINQ6.OBJ \
                AP610000.OBJ ARDBASE6.OBJ ARGENLB6.OBJ ARRPT6.OBJ ARINQ6.OBJ AR610000.OBJ 
 RTLINK @FIN71
        
//      rtlink FILE $(objs) VERBOSE

Code: Select all

// Fin71.lnk
file fin71000
file gl710000
file gldbase6
FILE GLGENLIB
file glgenlb6
file glinq6
file gllogo7
file glrpt7
file glrpt72
file ap610000
file apdbase6
file apgenlb6
file apinq6
file aprpt6
file ar610000
file ardbase6
file argenlb6
file arinq6
file arrpt6

file prglib
file tbrowse5
verbose
Hope this fixes your problem. :)

NB: Believe it or not, a copy of this Accounting System still runs till today at one of Indonesia's National Foundation who bought from me. While the copies of the above sys (for Hotel Front Office System in Accor-Ibis Reporting Standard) still runs at 3 hotels (my clients). The Ibis uninstalled it in 2010. Next year it'is scheduled to reinstall them with HMG331-build :lol: :lol: :lol:
Agil Abdullah Albatati (just call me Agil)
Programmer Never Surrender
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: Compiling multi-module package with Clipper

Post by esgici »

Agil Abdullah wrote:InshaAllah wa billahi taufik wal hidayah, Amen.).
Amen :arrow:
you forget the old version system
Absolutely correct :(

More, I didn't use frequently multiple-modules system; .rmk and .lnk files :(
its *.exe run under any Windows.
Did you tried under 64 bit machine :!: :?

Your explanations and samples are perfect;
in case of failure this time too; this means that it's time to retire for me ( whereas still I feel young myself :lol: ).

I will apply all your advice and will report insha-allah.
NB: Believe it or not, a copy of this Accounting System still runs till today at one of Indonesia's National Foundation who bought from me. While the copies of the above sys (for Hotel Front Office System in Accor-Ibis Reporting Standard) still runs at 3 hotels (my clients). The Ibis uninstalled it in 2010.
Please, there isn't any cause for not believing; we have many examples here.
Next year it'is scheduled to reinstall them with HMG331-build.
I'm sure, you will success, InshaAllah wa billahi taufik wal hidayah, Amen.

Because HMG and you are perfect :!: :arrow: 8-)

Maa-as-salaam
Viva INTERNATIONAL HMG :D
Post Reply