summaryrefslogtreecommitdiff
authorkergoth <kergoth>2003-01-16 04:39:25 (UTC)
committer kergoth <kergoth>2003-01-16 04:39:25 (UTC)
commit21cee2677c4a480f00675cdc9160e5d7e97e7122 (patch) (unidiff)
treea2e3b3f9675949fae2cf57e0f7b44441e7bfa06c
parent7ffd4623880396f07e34faf195f8c131218cf682 (diff)
downloadopie-21cee2677c4a480f00675cdc9160e5d7e97e7122.zip
opie-21cee2677c4a480f00675cdc9160e5d7e97e7122.tar.gz
opie-21cee2677c4a480f00675cdc9160e5d7e97e7122.tar.bz2
*** empty log message ***
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--Makefile.test2
-rw-r--r--config.in.in73
-rw-r--r--development/keyview/config.in8
-rw-r--r--example/config.in4
-rw-r--r--libopie/config.in3
-rw-r--r--libsql/test/config.in4
-rwxr-xr-xscripts/deps.pl2
-rw-r--r--share/opie-login/pre-session42
8 files changed, 47 insertions, 91 deletions
diff --git a/Makefile.test b/Makefile.test
index c15916d..7befb39 100644
--- a/Makefile.test
+++ b/Makefile.test
@@ -1,110 +1,110 @@
1#!/usr/bin/make -f 1#!/usr/bin/make -f
2export OPIEDIR:=$(shell pwd) 2export OPIEDIR:=$(shell pwd)
3export TOPDIR:=$(OPIEDIR) 3export TOPDIR:=$(OPIEDIR)
4export QMAKE:=$(OPIEDIR)/qmake/qmake 4export QMAKE:=$(OPIEDIR)/qmake/qmake
5 5
6export QMAKESPECSDIR=$(OPIEDIR)/mkspecs 6export QMAKESPECSDIR=$(OPIEDIR)/mkspecs
7 7
8noconfig_targets := xconfig menuconfig config oldconfig randconfig \ 8noconfig_targets := xconfig menuconfig config oldconfig randconfig \
9 defconfig allyesconfig allnoconfig allmodconfig 9 defconfig allyesconfig allnoconfig allmodconfig
10 10
11configs += $(TOPDIR)/core/applets/restartapplet2/config.in $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPDIR)/core/multimedia/config.in $(TOPDIR)/core/pim/config.in $(TOPDIR)/core/pim/today/plugins/config.in $(TOPDIR)/core/settings/config.in $(TOPDIR)/core/config.in $(TOPDIR)/development/config.in $(TOPDIR)/inputmethods/config.in $(TOPDIR)/libopie/ofileselector/config.in $(TOPDIR)/libopie/pim/config.in $(TOPDIR)/libsql/config.in $(TOPDIR)/noncore/applets/config.in $(TOPDIR)/noncore/apps/opie-console/test/config.in $(TOPDIR)/noncore/apps/config.in $(TOPDIR)/noncore/comm/config.in $(TOPDIR)/noncore/decorations/config.in $(TOPDIR)/noncore/games/config.in $(TOPDIR)/noncore/graphics/config.in $(TOPDIR)/noncore/multimedia/config.in $(TOPDIR)/noncore/net/config.in $(TOPDIR)/noncore/net/opietooth/config.in $(TOPDIR)/noncore/settings/config.in $(TOPDIR)/noncore/styles/config.in $(TOPDIR)/noncore/tools/calc2/config.in $(TOPDIR)/noncore/tools/config.in $(TOPDIR)/noncore/unsupported/opiemail/ifaces/config.in $(TOPDIR)/noncore/unsupported/config.in $(TOPDIR)/noncore/config.in $(TOPDIR)/noncore/todayplugins/config.in $(TOPDIR)/config.in 11configs += $(TOPDIR)/core/applets/restartapplet2/config.in $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPDIR)/core/multimedia/config.in $(TOPDIR)/core/pim/config.in $(TOPDIR)/core/pim/today/plugins/config.in $(TOPDIR)/core/settings/config.in $(TOPDIR)/core/config.in $(TOPDIR)/development/config.in $(TOPDIR)/inputmethods/config.in $(TOPDIR)/libopie/ofileselector/config.in $(TOPDIR)/libopie/pim/config.in $(TOPDIR)/libsql/config.in $(TOPDIR)/noncore/applets/config.in $(TOPDIR)/noncore/apps/opie-console/test/config.in $(TOPDIR)/noncore/apps/config.in $(TOPDIR)/noncore/comm/config.in $(TOPDIR)/noncore/decorations/config.in $(TOPDIR)/noncore/games/config.in $(TOPDIR)/noncore/graphics/config.in $(TOPDIR)/noncore/multimedia/config.in $(TOPDIR)/noncore/net/config.in $(TOPDIR)/noncore/net/opietooth/config.in $(TOPDIR)/noncore/settings/config.in $(TOPDIR)/noncore/styles/config.in $(TOPDIR)/noncore/tools/calc2/config.in $(TOPDIR)/noncore/tools/config.in $(TOPDIR)/noncore/unsupported/opiemail/ifaces/config.in $(TOPDIR)/noncore/unsupported/config.in $(TOPDIR)/noncore/config.in $(TOPDIR)/noncore/todayplugins/config.in
12 12
13# $(TOPDIR)/.config depends on .depends.cfgs, as it depends on $(configs) 13# $(TOPDIR)/.config depends on .depends.cfgs, as it depends on $(configs)
14# in order to have a full set of config.in files. 14# in order to have a full set of config.in files.
15# .depends depends on $(TOPDIR)/.config 15# .depends depends on $(TOPDIR)/.config
16# everything else depends on .depends, to ensure the dependencies are 16# everything else depends on .depends, to ensure the dependencies are
17# intact. 17# intact.
18# 18#
19# NOTE: The order in which things happen in this makefile is 19# NOTE: The order in which things happen in this makefile is
20 # -critical-. Do not rearrange this! 20 # -critical-. Do not rearrange this!
21 21
22all : $(TOPDIR)/.config 22all : $(TOPDIR)/.config
23 23
24$(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs 24$(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs
25 25
26all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs 26all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs
27 27
28clean-configs : $(TOPDIR)/.depends.cfgs 28clean-configs : $(TOPDIR)/.depends.cfgs
29 @echo "Wiping generated config.in files..." 29 @echo "Wiping generated config.in files..."
30 @-rm -f $(configs) 30 @-rm -f $(configs)
31 31
32-include $(TOPDIR)/.depends.cfgs 32-include $(TOPDIR)/.depends.cfgs
33 33
34all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs) 34all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs)
35 35
36$(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs) 36$(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs)
37 $(call descend,scripts/kconfig,conf) 37 $(call descend,scripts/kconfig,conf)
38 @if [ ! -e $@ ]; then \ 38 @if [ ! -e $@ ]; then \
39 cp $(TOPDIR)/def-configs/opie $@; \ 39 cp $(TOPDIR)/def-configs/opie $@; \
40 fi; 40 fi;
41 @$(MAKE) -C scripts/kconfig conf; 41 @$(MAKE) -C scripts/kconfig conf;
42 ./scripts/kconfig/conf -s ./config.in 42 ./scripts/kconfig/conf -s ./config.in
43 43
44# config rules must have the $(configs) var defined 44# config rules must have the $(configs) var defined
45# at the time that they run. we must ensure that .depends.cfgs 45# at the time that they run. we must ensure that .depends.cfgs
46# is built and included by the time we reach this point. 46# is built and included by the time we reach this point.
47 47
48xconfig : 48xconfig :
49 $(call descend,scripts/kconfig,qconf) 49 $(call descend,scripts/kconfig,qconf)
50 LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(TOPDIR)/scripts/kconfig \ 50 LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(TOPDIR)/scripts/kconfig \
51 ./scripts/kconfig/qconf ./config.in 51 ./scripts/kconfig/qconf ./config.in
52 52
53menuconfig : scripts/lxdialog/lxdialog 53menuconfig : scripts/lxdialog/lxdialog
54 $(call descend,scripts/kconfig,mconf) 54 $(call descend,scripts/kconfig,mconf)
55 ./scripts/kconfig/mconf ./config.in 55 ./scripts/kconfig/mconf ./config.in
56 56
57config : 57config :
58 $(call descend,scripts/kconfig,conf) 58 $(call descend,scripts/kconfig,conf)
59 ./scripts/kconfig/conf ./config.in 59 ./scripts/kconfig/conf ./config.in
60 60
61oldconfig : 61oldconfig :
62 $(call descend,scripts/kconfig,conf) 62 $(call descend,scripts/kconfig,conf)
63 ./scripts/kconfig/conf -o ./config.in 63 ./scripts/kconfig/conf -o ./config.in
64 64
65randconfig : 65randconfig :
66 $(call descend,scripts/kconfig,conf) 66 $(call descend,scripts/kconfig,conf)
67 ./scripts/kconfig/conf -r ./config.in 67 ./scripts/kconfig/conf -r ./config.in
68 68
69allyesconfig : 69allyesconfig :
70 $(call descend,scripts/kconfig,conf) 70 $(call descend,scripts/kconfig,conf)
71 ./scripts/kconfig/conf -y ./config.in 71 ./scripts/kconfig/conf -y ./config.in
72 72
73allnoconfig : 73allnoconfig :
74 $(call descend,scripts/kconfig,conf) 74 $(call descend,scripts/kconfig,conf)
75 ./scripts/kconfig/conf -n ./config.in 75 ./scripts/kconfig/conf -n ./config.in
76 76
77defconfig : 77defconfig :
78 $(call descend,scripts/kconfig,conf) 78 $(call descend,scripts/kconfig,conf)
79 ./scripts/kconfig/conf -d ./config.in 79 ./scripts/kconfig/conf -d ./config.in
80 80
81 81
82export 82export
83 83
84ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),) 84ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
85 85
86export include-config := 1 86export include-config := 1
87 87
88-include $(TOPDIR)/.config 88-include $(TOPDIR)/.config
89-include $(TOPDIR)/.depends 89-include $(TOPDIR)/.depends
90 90
91endif 91endif
92 92
93-include $(TOPDIR)/..config.cmd 93-include $(TOPDIR)/..config.cmd
94 94
95export QMAKESPEC=$(QMAKESPECSDIR)/$(patsubst "%",%,$(CONFIG_SPECFILE)) 95export QMAKESPEC=$(QMAKESPECSDIR)/$(patsubst "%",%,$(CONFIG_SPECFILE))
96 96
97ifdef CONFIG_OPTIMIZATIONS 97ifdef CONFIG_OPTIMIZATIONS
98export CFLAGS_RELEASE=$(patsubst "%,%,$(CONFIG_OPTIMIZATIONS)) 98export CFLAGS_RELEASE=$(patsubst "%,%,$(CONFIG_OPTIMIZATIONS))
99export CFLAGS_RELEASE:=$(patsubst %",%,$(CFLAGS_RELEASE)) 99export CFLAGS_RELEASE:=$(patsubst %",%,$(CFLAGS_RELEASE))
100endif 100endif
101 101
102all clean: $(subdir-y) 102all clean: $(subdir-y)
103 103
104$(subdir-y) : $(if $(CONFIG_LIBQPE),$(TOPDIR)/stamp-headers) \ 104$(subdir-y) : $(if $(CONFIG_LIBQPE),$(TOPDIR)/stamp-headers) \
105 $(if $(CONFIG_LIBQPE-X11),$(TOPDIR)/stamp-headers-x11) \ 105 $(if $(CONFIG_LIBQPE-X11),$(TOPDIR)/stamp-headers-x11) \
106 $(TOPDIR)/library/custom.h 106 $(TOPDIR)/library/custom.h
107 107
108clean : $(TOPDIR)/.config 108clean : $(TOPDIR)/.config
109 109
110include $(TOPDIR)/Rules.make 110include $(TOPDIR)/Rules.make
diff --git a/config.in.in b/config.in.in
deleted file mode 100644
index 679292f..0000000
--- a/config.in.in
+++ b/dev/null
@@ -1,73 +0,0 @@
1mainmenu "Opie Configuration"
2menu "Build Parameters"
3
4#choice
5# prompt "Build Processor family"
6# default BUILD_X86
7# help
8# Please select the architecture of the machine you will be
9# building the OpenZaurus buildroot on.
10#
11# config BUILD_X86
12# boolean "X86 Architecture"
13#
14#endchoice
15
16choice
17 prompt "Target Machine"
18 default TARGET_X86
19 help
20 Please select the architecture of the machine you will be
21 building the OpenZaurus buildroot for.
22
23 config TARGET_X86
24 boolean "Intel X86"
25
26 config TARGET_SHARP
27 boolean "Sharp Zaurus SL-5x00 - stock"
28
29# config TARGET_OZ
30# boolean "Sharp Zaurus SL-5x00 - OpenZaurus"
31
32 config TARGET_IPAQ
33 boolean "Ipaq"
34
35endchoice
36
37config OPTIMIZE
38 boolean "Use optimizations"
39 default "y" if ! TARGET_X86
40
41config SPECFILE
42 string
43 default "qws/linux-generic-g++" if TARGET_X86 && (! X11)
44 default "linux-g++" if TARGET_X86 && X11
45 default "qws/linux-sharp-g++" if TARGET_SHARP && (! X11)
46 default "linux-g++" if TARGET_SHARP && X11
47# default "linux-oz-g++" if TARGET_OZ
48 default "qws/linux-ipaq-g++" if TARGET_IPAQ && (! X11)
49 default "linux-g++" if TARGET_IPAQ && X11
50
51config CUSTOMFILE
52 string
53 default "custom-ipaq.h" if TARGET_IPAQ
54 default "custom-sharp.h" if TARGET_SHARP
55
56
57config OPTIMIZATIONS
58 string "Optimization flags"
59 depends OPTIMIZE
60 default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_IPAQ
61 default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_SHARP
62
63#config CROSS
64# string "Crosscompilation prefix"
65# default "arm-linux-"
66# help
67# Crosscompilation prefix is the prefix which will be prepended
68# to all compilation commands. For example, a crosscompilation prefix
69# of arm-linux-, results in the build calling arm-linux-gcc as its CC.
70
71endmenu
72
73@sources@
diff --git a/development/keyview/config.in b/development/keyview/config.in
index ce934d3..6c29e1d 100644
--- a/development/keyview/config.in
+++ b/development/keyview/config.in
@@ -1,4 +1,4 @@
1# config #KEYVIEW 1 config KEYVIEW
2# boolean "keyview" 2 boolean "Keyview (Debugging tool for viewing keypresses)"
3# default "y" 3 default "y"
4# depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE 4 depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
diff --git a/example/config.in b/example/config.in
deleted file mode 100644
index b3e07d3..0000000
--- a/example/config.in
+++ b/dev/null
@@ -1,4 +0,0 @@
1# config #EXAMPLE
2# boolean "example"
3# default "y"
4# depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
diff --git a/libopie/config.in b/libopie/config.in
index 5894d0f..19279d8 100644
--- a/libopie/config.in
+++ b/libopie/config.in
@@ -1,6 +1,3 @@
1 config LIBOPIE 1 config LIBOPIE
2 boolean "Opie library" 2 boolean "Opie library"
3 default "y" 3 default "y"
4
5 source libopie/ofileselector/config.in
6 source libopie/pim/config.in
diff --git a/libsql/test/config.in b/libsql/test/config.in
deleted file mode 100644
index 238d27f..0000000
--- a/libsql/test/config.in
+++ b/dev/null
@@ -1,4 +0,0 @@
1# config #TEST
2# boolean "test"
3# default "y"
4# depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
diff --git a/scripts/deps.pl b/scripts/deps.pl
index feced6e..a219e36 100755
--- a/scripts/deps.pl
+++ b/scripts/deps.pl
@@ -1,77 +1,77 @@
1#!/usr/bin/perl -w 1#!/usr/bin/perl -w
2 2
3use strict; 3use strict;
4 4
5my %depends; 5my %depends;
6my %tokenpath; 6my %tokenpath;
7 7
8sub getdepends ($$) 8sub getdepends ($$)
9{ 9{
10 my ($token, $path, $intoken); 10 my ($token, $path, $intoken);
11 $token = shift || return; 11 $token = shift || return;
12 $token =~ s/CONFIG_//; 12 $token =~ s/CONFIG_//;
13 $path = shift || return; 13 $path = shift || return;
14#print "opening $path/config.in\n"; 14#print "opening $path/config.in\n";
15 #print "token is $token\n"; 15 #print "token is $token\n";
16 open( FILE, "< $path/config.in" ) || return; 16 open( FILE, "< $path/config.in" ) || return;
17 $intoken = 0; 17 $intoken = 0;
18 while( <FILE> ) { 18 while( <FILE> ) {
19 if( $intoken == 1 ) { 19 if( $intoken == 1 ) {
20 /depends\S*(.*)/ && return $1; 20 /depends\S*(.*)/ && return $1;
21 if( /\S*(config|menu)/ ) { 21 if( /\S*(config|menu)/ ) {
22 $intoken = 0; 22 $intoken = 0;
23 return; 23 return;
24 } 24 }
25 } else { 25 } else {
26 /$token/ || next; 26 /$token/ || next;
27 $intoken = 1; 27 $intoken = 1;
28 } 28 }
29 /$token/ || next; 29 /$token/ || next;
30 } 30 }
31 close( FILE ); 31 close( FILE );
32 return; 32 return;
33} 33}
34 34
35sub makedepends ($$) 35sub makedepends ($$)
36{ 36{
37 my ($depends, $tokenpath, $token, $depword, $mustbesep, $state); 37 my ($depends, $tokenpath, $token, $depword, $mustbesep, $state);
38 $depends = shift || return; 38 $depends = shift || return;
39 $tokenpath = shift || return; 39 $tokenpath = shift || return;
40 $mustbesep = 0; 40 $mustbesep = 0;
41 41
42 for $token (keys %$depends){ 42 for $token (keys %$depends){
43 print ${$tokenpath}{$token} . " : "; 43 print ${$tokenpath}{$token} . " : ";
44 for (split(/\s+/, ${$depends}{$token})){ 44 for (split(/\s+/, ${$depends}{$token})){
45 /^\s+$/ && next; 45 /^\s+$/ && next;
46 /\&\&/ && next; 46 /\&\&/ && next;
47 /\|\|/ && next; 47 /\|\|/ && next;
48 /^$/ && next; 48 /^$/ && next;
49 /^\($/ && next; 49 /^\($/ && next;
50 /^\)$/ && next; 50 /^\)$/ && next;
51 /^on$/ && next; 51 /^on$/ && next;
52 /^!$/ && next; 52 /^!$/ && next;
53 if(defined(${$tokenpath}{"CONFIG_" . $_})){ 53 if(defined(${$tokenpath}{"CONFIG_" . $_})){
54 print '$(if $(CONFIG_' . $_ . '),' . ${$tokenpath}{"CONFIG_" . $_} . ') '; 54 print '$(if $(CONFIG_' . $_ . '),' . ${$tokenpath}{"CONFIG_" . $_} . ') ';
55 } else { 55 } else {
56 print STDERR "Warning: unable to locate path for token CONFIG_$_\n"; 56 # print STDERR "Warning: unable to locate path for token CONFIG_$_\n";
57 } 57 }
58 } 58 }
59 print "\n"; 59 print "\n";
60 } 60 }
61} 61}
62 62
63while( <> ) { 63while( <> ) {
64 my $dep; 64 my $dep;
65 my ($token, $path, $pro); 65 my ($token, $path, $pro);
66 chomp; 66 chomp;
67 s/^\s*//g; 67 s/^\s*//g;
68 s/\s*$//g; 68 s/\s*$//g;
69 ($token, $path, $pro) = split(/\s+/,$_); 69 ($token, $path, $pro) = split(/\s+/,$_);
70 $tokenpath{$token} = $path; 70 $tokenpath{$token} = $path;
71 $dep = getdepends($token, $path); 71 $dep = getdepends($token, $path);
72 if( $dep ) { 72 if( $dep ) {
73 $depends{$token} = $dep; 73 $depends{$token} = $dep;
74 } 74 }
75} 75}
76 76
77makedepends(\%depends, \%tokenpath); 77makedepends(\%depends, \%tokenpath);
diff --git a/share/opie-login/pre-session b/share/opie-login/pre-session
index 8219f94..6bf9e4c 100644
--- a/share/opie-login/pre-session
+++ b/share/opie-login/pre-session
@@ -1,16 +1,56 @@
1#!/bin/sh 1#!/bin/sh
2 2
3USER=$1 3USER=$1
4 4
5# NOTE about permissions in OpenZaurus
6 # The devices in question here by default
7 #are accessible to everyone in the group in
8 #question. We wish to ensure that, as a policy
9 #choice, a login to opie makes access to these
10 #devices exclusive by 1) changing device ownership
11 #to the user, and 2) removing group access.
12#
13 #A better implementation would probably be to store
14 #existing device permissions at load time, and restore
15 #them at exit, rather than making assumptions about
16 #user/group ownership, or permissions.
17
18permin ()
19{
20 if [ -e $1 ]
21 then
22
23 chown $USER $1
24 chmod g-rw $1
25
26 else
27 return 1
28 fi
29}
30
31permout ()
32{
33 [ -e $1 ]&& chown root $1
34 [ -e $1 ]&& chmod g+rw $1
35}
36
5if [ -e /proc/hal/model ]; then 37if [ -e /proc/hal/model ]; then
6 38
7 # fix for misconfigured devfsd 39 # fix for misconfigured devfsd
8 chmod +x /dev/sound /dev/touchscreen /dev/fb /dev/vc 40 chmod +x /dev/sound /dev/touchscreen /dev/fb /dev/vc
9 41
10 [ -e /dev/sound/dsp ] && chown $USER /dev/sound/dsp 42 [ -e /dev/sound/dsp ] && chown $USER /dev/sound/dsp
11 [ -e /dev/sound/mixer ] && chown $USER /dev/sound/mixer 43 [ -e /dev/sound/mixer ] && chown $USER /dev/sound/mixer
12 [ -e /dev/touchscreen/0 ] && chown $USER /dev/touchscreen/0 44 [ -e /dev/touchscreen/0 ] && chown $USER /dev/touchscreen/0
13 [ -e /dev/fb/0 ] && chown $USER /dev/fb/0 45 [ -e /dev/fb/0 ] && chown $USER /dev/fb/0
14 [ -e /dev/vc/0 ] && chown $USER /dev/vc/0 46 [ -e /dev/vc/0 ] && chown $USER /dev/vc/0
15fi
16 47
48else
49
50 for dev in /dev/dsp /dev/dsp1 /dev/mixer \
51 /dev/ts /dev/fb0
52 do
53 permin( $dev )
54 done
55
56fi