Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
Who's Online
3 user(s) are online (2 user(s) are browsing Forum)

Members: 2
Guests: 1

Fats, navya, more...

Browsing this Thread:   1 Anonymous Users



« 1 2 3 (4) 5 6 »


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
ive checked out your sources but its a bit more difficult than i expected as im completely unfamiliar with bison.

so far i see there is two steps while building. aros srosscompiler system should actually be well suited to automate this. i assume first step is to generate sources in build from sources in src using host version of bison, then crosscompile these.

Posted on: 7/8 18:33
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
btw should we need bison on target platform, we are building it in contribs, fairly old version, but the diff isnt big and needs adjustments anyway, as it only covers i386 as aros platform it seems.

Posted on: 7/8 18:43
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
found a handy template of mmakefile using bison in:
AROS/contrib/aminet/text/edit/xdme/Util/var

Posted on: 7/8 18:55
Transfer the post to other applications Transfer


Re: installer?

Joined:
2017/4/8 5:23
From Sweden
Group:
Member
Posts: 27
Offline
Since parser.c, parser.h and lexer.c are a part of the repo, it's not necessary to use Bison and Flex. They're only needed whenever you need to make changes to the grammar rules, which should be *very* rare and then you definitely want to build it outside of the AROS tree anyway, to run all the tests and so on.

Posted on: 7/9 1:37
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
it would be easy if it was just these both files, but then i get undefined symbols in linking stage, which must evidently be the result of sources on src not being compiled and inked with, right? or how is that supposed to work?

Quote:

Linking AROS/C/installer...
Link failed: /home/wawa/aros-x86-630/bin/linux-i386/tools/crosstools/i386-aros-gcc /home/wawa/aros-x86-630/bin/pc-i386/gen/local/InstallerLG/build/parser.o /home/wawa/aros-x86-630/bin/pc-i386/gen/local/InstallerLG/build/lexer.o -o /home/wawa/aros-x86-630/bin/pc-i386/AROS/C/installer -ldebug
There are undefined symbols in '/home/wawa/aros-x86-630/bin/pc-i386/gen/local/InstallerLG/build/installer':
U arg_argc
U arg_done
U arg_get
U arg_init
U error
U init
U m_abort
U m_add
U m_and
U m_askbool
U m_askchoice
U m_askdir
U m_askdisk
...


here is the current content of my mmakefile in build subdir:
Quote:

include $(SRCDIR)/config/aros-contrib.cfg

NOWARN_FLAGS := $(NOWARN_UNUSED_FUNCTION)

USER_CFLAGS := $(NOWARN_FLAGS) -Os -std=c99 -DAMIGA

USER_LDFLAGS := -ldebug

USER_INCLUDES := -I$(SRCDIR)/$(CURDIR)/../src

%build_prog mmake=local-installer \
progname=installer targetdir=$(AROS_C) \
files="parser lexer"


the content of CFLAGS and LDFLAGS is a matter of experiment, you just need that nowarn flag necessarily.

if you put the content of your source along with that makefile somewhere within your aros source, for instance in local subdir, after configure you can simply invoke "make local-installer" to build this program, or at least attempt it so far.

Posted on: 7/9 8:25
Transfer the post to other applications Transfer


Re: installer?

Joined:
2017/4/8 5:23
From Sweden
Group:
Member
Posts: 27
Offline
Yes, indeed. Everything in 'src' is missing so when you try to link the parser all references to the actual implementations (m_*) are dangling.

It's not clear to me how much mmake needs to know about the details in the underlying Makefile. But you do specify 'files' in there, containing 'parser' and 'lexer' . All the files in 'src' should perhaps be in that list as well? But I don't understand why this list is needed in the first place :) All those details are taken care of by the underlying Makefile.

I keep postponing setting up an AROS hosted environment. It's probably time to stop postponing soon.

Posted on: 7/9 14:53
Transfer the post to other applications Transfer


Re: installer?

Joined:
2017/4/8 5:23
From Sweden
Group:
Member
Posts: 27
Offline

Posted on: 7/9 15:37
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
Quote:

sTix wrote:
It's not clear to me how much mmake needs to know about the details in the underlying Makefile.


hardly an expert myself, but my understanding is that when there is no underlaying mmakefile (make wont count) then the parent one needs also particularly list the underlaying source files to compile. you might probably script it with a wildcard as you did in your makefile, but im neiher sure nor good finding out.

now back to debugging webkit on ppc ;(

Posted on: 7/9 15:49
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
btw, here a few warnings for you to fix;):
Quote:

Compiling local/InstallerLG/src/args.c
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/args.c: In function 'arg_init':
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/args.c:112:21: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
owd = CurrentDir(arg->wa_Lock);
^
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/args.c:151:20: warning: comparison between pointer and integer
if(owd != -1)
^~
Compiling local/InstallerLG/src/arithmetic.c
Compiling local/InstallerLG/src/bitwise.c
Compiling local/InstallerLG/src/comparison.c
Compiling local/InstallerLG/src/control.c
Compiling local/InstallerLG/src/error.c
Compiling local/InstallerLG/src/eval.c
Compiling local/InstallerLG/src/exit.c
Compiling local/InstallerLG/src/external.c
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/external.c: In function 'h_run':
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/external.c:127:48: warning: comparison between pointer and integer
if(getcwd(buf, buf_size()) == buf)
^~
Compiling local/InstallerLG/src/file.c
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/file.c: In function 'm_tooltype':
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/file.c:3469:41: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
*o = FindToolType(obj->do_ToolTypes, t);
^~~~~~~~~~~~
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/file.c:3650:42: warning: comparison of distinct pointer types lacks a cast
if(obj->do_ToolTypes != tts)
^~
/home/wawa/AROS-source/AROS/local/InstallerLG/build/../src/file.c:3653:43: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types]
obj->do_ToolTypes = tts;
^


Posted on: 7/10 9:31
Transfer the post to other applications Transfer


Re: installer?

Joined:
2010/8/30 7:20
Group:
Member
Posts: 1231
Offline
and here is my makefile in its current form. however i have still to look in all the errors gui.c produces within aros environment. (better take look at the file in attachment that preserves formatting)
Quote:


include $(SRCDIR)/config/aros-contrib.cfg

NOWARN_FLAGS := $(NOWARN_UNUSED_FUNCTION) $(NOWARN_IMPLICIT_FUNCTION_DECL) $(NOWARN_ERROR)

USER_CFLAGS := $(NOWARN_FLAGS) -Os -std=c99

USER_INCLUDES := -I$(AROS_INCLUDES)

USER_LDFLAGS :=
FILES := parser lexer
VPATH := ../src
##OBJ := $(subst .c,,$(wildcard $(VPATH)/*.c))

OBJ := \
$(VPATH)/alloc \
$(VPATH)/args \
$(VPATH)/arithmetic \
$(VPATH)/bitwise \
$(VPATH)/comparison \
$(VPATH)/control \
$(VPATH)/error \
$(VPATH)/eval \
$(VPATH)/exit \
$(VPATH)/external \
$(VPATH)/file \
$(VPATH)/gui \
$(VPATH)/information \
$(VPATH)/init \
$(VPATH)/probe \
$(VPATH)/procedure \
$(VPATH)/prompt \
$(VPATH)/resource \
$(VPATH)/strop \
$(VPATH)/symbol \
$(VPATH)/util

EXE := installer

USER_INCLUDES := -I$(SRCDIR)/$(CURDIR)/$(VPATH)

%build_prog mmake=local-installer \
progname=$(EXE) targetdir=$(AROS_C) \
files=" $(OBJ) $(FILES)"

Attach file:


src mmakefile.src Size: 0.93 KB; Hits: 0

Posted on: 7/10 9:35
Transfer the post to other applications Transfer



« 1 2 3 (4) 5 6 »



You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.

[Advanced Search]


Search
Top Posters
1 paolone
paolone
4433
2 magorium
magorium
4095
3 nikolaos
nikolaos
4018
4 phoenixkonsole
phoenixkonsole
3928
5 deadwood
deadwood
2917
6 ncafferkey
ncafferkey
2796
7 mazze
mazze
2221
8 clusteruk
clusteruk
2112
9 damocles
damocles
1789
10 BSzili
BSzili
1513
© 2004-2018 AROS Exec