project.conf: register the compilation modes

This commit is contained in:
Pierre Pronchery 2022-07-11 05:24:47 +02:00
parent eb365e3132
commit 4315189049
8 changed files with 101 additions and 8 deletions

View File

@ -7,6 +7,19 @@ subdirs=data,doc,include,po,src/lib,src,src/plugins,src/widget,tests,tools
targets=tests
dist=Makefile,COPYING,README.md,TODO,config.ent,config.h,config.sh
#modes
[mode::debug]
title=Debug
[mode::embedded-debug]
title=Debug (embedded UI)
[mode::embedded-release]
title=Release (embedded UI)
[mode::release]
title=Release
#targets
[tests]
type=command

View File

@ -1,12 +1,23 @@
targets=browser
cppflags_force=-I../../include
#cppflags=-D EMBEDDED
cflags_force=`pkg-config --cflags libDesktop`
cflags=-W -Wall -g -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
ldflags_force=`pkg-config --libs libDesktop` -lintl -L$(OBJDIR)../lib -Wl,-rpath,$(PREFIX)/lib -lBrowser
ldflags=-pie -Wl,-z,relro -Wl,-z,now
dist=Makefile,browser.h,callbacks.h,window.h
#modes
[mode::embedded-debug]
cppflags_force=-I../../include -DEMBEDDED
[mode::embedded-release]
cppflags_force=-I../../include -DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-I../../include -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[browser]
type=binary

View File

@ -1,12 +1,23 @@
targets=desktop,desktopctl,handler/mimeapp.o
cppflags_force=-I../../include
#cppflags=-D EMBEDDED
cflags_force=`pkg-config --cflags libDesktop`
cflags=-W -Wall -g -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
ldflags_force=`pkg-config --libs libDesktop` -lintl
ldflags=-pie -Wl,-z,relro -Wl,-z,now
dist=Makefile,desktop.h,desktopicon.h,desktopiconwindow.h,handler.h,handler/applications.c,handler/categories.c,handler/files.c,handler/homescreen.c,handler/mimeapp.h
#modes
[mode::embedded-debug]
cppflags_force=-I../../include -DEMBEDDED
[mode::embedded-release]
cppflags_force=-I../../include -DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-I../../include -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[desktop]
type=binary

View File

@ -5,6 +5,18 @@ ldflags_force=`pkg-config --libs libDesktop` -lintl
ldflags=-Wl,-z,relro -Wl,-z,now
dist=Makefile
#modes
[mode::embedded-debug]
cppflags_force=-DEMBEDDED
[mode::embedded-release]
cppflags_force=-DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-DNDEBUG
cflags=-W -Wall -O2 -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[libBrowser]
type=library

View File

@ -1,12 +1,24 @@
targets=backup,cvs,dirtree,favorites,git,make,places,preview,properties,selection,subversion,template,trash,undelete,volumes
cppflags_force=-I../../include
cppflags=
cflags_force=`pkg-config --cflags libDesktop` -fPIC
cflags=-W -Wall -g -O2 -D_FORTIFY_SOURCE=2 -fstack-protector
ldflags_force=`pkg-config --libs libDesktop`
ldflags=-Wl,-z,relro -Wl,-z,now
dist=Makefile,common.c
#modes
[mode::embedded-debug]
cppflags_force=-DEMBEDDED
[mode::embedded-release]
cppflags_force=-DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-DNDEBUG
cflags=-W -Wall -O2 -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[backup]
type=plugin
sources=backup.c

View File

@ -1,17 +1,28 @@
subdirs=browser,desktop
targets=copy,delete,move,open,properties,view
cppflags_force=-I../include
#cppflags=-D EMBEDDED
cflags_force=`pkg-config --cflags libDesktop`
cflags=-W -Wall -g -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
ldflags_force=`pkg-config --libs libDesktop` -lintl
ldflags=-pie -Wl,-z,relro -Wl,-z,now
dist=Makefile,common.c,common.h
#modes
[mode::embedded-debug]
cppflags_force=-I../include -DEMBEDDED
[mode::embedded-release]
cppflags_force=-I../include -DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-I../include -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[copy]
type=binary
sources=copy.c
cppflags=-I../include
ldflags=-L$(OBJDIR)lib -Wl,-rpath,$(PREFIX)/lib -lBrowser
depends=$(OBJDIR)lib/libBrowser.a
install=$(BINDIR)
@ -22,7 +33,6 @@ depends=../include/Browser/vfs.h
[delete]
type=binary
sources=delete.c
cppflags=-I../include
ldflags=-L$(OBJDIR)lib -Wl,-rpath,$(PREFIX)/lib -lBrowser
depends=$(OBJDIR)lib/libBrowser.a
install=$(BINDIR)
@ -33,7 +43,6 @@ depends=../include/Browser/vfs.h
[move]
type=binary
sources=move.c
cppflags=-I../include
ldflags=-L$(OBJDIR)lib -Wl,-rpath,$(PREFIX)/lib -lBrowser
depends=$(OBJDIR)lib/libBrowser.a
install=$(BINDIR)

View File

@ -6,6 +6,18 @@ ldflags_force=`pkg-config --libs libDesktop`
ldflags=-pie -Wl,-z,relro -Wl,-z,now
dist=Makefile,clint.sh,embedded.sh,fixme.sh,htmllint.sh,pkgconfig.sh,tests.sh,xmllint.sh
#modes
[mode::embedded-debug]
cppflags_force=-DEMBEDDED
[mode::embedded-release]
cppflags_force=-DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[clint.log]
type=script

View File

@ -5,6 +5,19 @@ ldflags_force=`pkg-config --libs libDesktop`
ldflags=-pie -Wl,-z,relro -Wl,-z,now
dist=Makefile,subst.sh
#modes
[mode::embedded-debug]
cppflags_force=-DEMBEDDED
[mode::embedded-release]
cppflags_force=-DEMBEDDED -DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
[mode::release]
cppflags_force=-DNDEBUG
cflags=-W -Wall -O2 -fPIE -D_FORTIFY_SOURCE=2 -fstack-protector
#targets
[dirtree]
type=binary
sources=dirtree.c