| delorie.com/archives/browse.cgi | search |
| X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
| X-Received: | by 2002:a0c:f387:0:b0:572:1044:dafe with SMTP id i7-20020a0cf387000000b005721044dafemr318482qvk.55.1677077836090; |
| Wed, 22 Feb 2023 06:57:16 -0800 (PST) | |
| X-Received: | by 2002:a05:6870:d62c:b0:16d:eb44:c70 with SMTP id |
| a44-20020a056870d62c00b0016deb440c70mr2099356oaq.48.1677077835702; Wed, 22 | |
| Feb 2023 06:57:15 -0800 (PST) | |
| Newsgroups: | comp.os.msdos.djgpp |
| Date: | Wed, 22 Feb 2023 06:57:15 -0800 (PST) |
| In-Reply-To: | <e968bcf9-dc60-48cf-b071-51186badd430@googlegroups.com> |
| Injection-Info: | google-groups.googlegroups.com; posting-host=114.5.241.95; posting-account=ChV2iAoAAADZk8Usbgzl1z77-oviXA_b |
| NNTP-Posting-Host: | 114.5.241.95 |
| References: | <43bcdb29-6ac3-4cdf-a0ca-e73adb60bf91 AT googlegroups DOT com> <e968bcf9-dc60-48cf-b071-51186badd430 AT googlegroups DOT com> |
| User-Agent: | G2/1.0 |
| MIME-Version: | 1.0 |
| Message-ID: | <e2405853-1614-4aae-b290-9f094171af07n@googlegroups.com> |
| Subject: | Re: compilation of sqlite3 on dos using djgpp |
| From: | "HILMAN AHWAS A. (hilmanahwaa AT gmail DOT com) [via djgpp AT delorie DOT com]" <djgpp AT delorie DOT com> |
| Injection-Date: | Wed, 22 Feb 2023 14:57:16 +0000 |
| X-Received-Bytes: | 2549 |
| Bytes: | 2780 |
| Lines: | 49 |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
| Errors-To: | nobody AT delorie DOT com |
| X-Mailing-List: | djgpp AT delorie DOT com |
| X-Unsubscribes-To: | listserv AT delorie DOT com |
On Monday, February 18, 2013 at 2:02:33 AM UTC+7, <@email omitted> wrote:
> Well, on a lazy Sunday afternoon I tried to compile SQLite too.
>
> The following steps allowed to compile it:
>
> 1. run "configure --disable-threadsafe"
>
> 2. modify this in sqlite3.c:
>
> #ifdef __DJGPP__
> { "fstat", 0, 0 },
> //#define osFstat(a,b,c) 0
> #define osFstat(a,b) 0 //djgpp - replacing above
> #define MAP_SHARED 0
> #define MAP_FAILED 0
> #define ETIMEDOUT 9000 //unused number
> #define ENOTCONN 9001 //unused number
>
> #else
>
> 3. take out munmap:
>
> for(i=0; i<p->nRegion; i++){
> if( p->h>=0 ){
> //djgpp munmap(p->apRegion[i], p->szRegion);
> }else{
> sqlite3_free(p->apRegion[i]);
> }
> }
>
> 4. take out mmap:
>
> if( pShmNode->h>=0 ){
> /* djgpp
> pMem = mmap(0, szRegion,
> pShmNode->isReadonly ? PROT_READ : PROT_READ|PROT_WRITE,
> MAP_SHARED, pShmNode->h, szRegion*(i64)pShmNode->nRegion
> );
> */
> if( pMem==MAP_FAILED ){
> rc = unixLogError(SQLITE_IOERR_SHMMAP, "mmap", pShmNode->zFilename);
> goto shmpage_out;
> }
>
>
> Then it did compile and seemed to work so far. The library does not use mmap, only the shell program sqlite3.exe does and I guess that will work so far without mmap in DOS.
>
> Georg
Where do I place those lines of code?
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |