Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
acf002d4
Commit
acf002d4
authored
Sep 12, 2011
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of claes@pwrcvs:/data1/git/pwr
parents
cfc534d4
7bad33d8
Changes
20
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
186 additions
and
55 deletions
+186
-55
src/exp/com/src/os_openbsd/pwr_stop.sh
src/exp/com/src/os_openbsd/pwr_stop.sh
+4
-2
src/exp/com/src/os_openbsd/pwrp_env.sh
src/exp/com/src/os_openbsd/pwrp_env.sh
+8
-8
src/lib/rt/src/os_freebsd/rt_errl.c
src/lib/rt/src/os_freebsd/rt_errl.c
+11
-1
src/lib/rt/src/os_macos/rt_errl.c
src/lib/rt/src/os_macos/rt_errl.c
+11
-1
src/lib/rt/src/os_openbsd/rt_errl.c
src/lib/rt/src/os_openbsd/rt_errl.c
+13
-2
src/lib/rt/src/rt_errh.c
src/lib/rt/src/rt_errh.c
+8
-0
src/lib/rt/src/rt_sect.c
src/lib/rt/src/rt_sect.c
+1
-1
src/tools/bld/src/os_openbsd/hw_x86_64/variables.mk
src/tools/bld/src/os_openbsd/hw_x86_64/variables.mk
+1
-1
src/tools/bld/src/os_templ/hw_templ/variables.mk
src/tools/bld/src/os_templ/hw_templ/variables.mk
+1
-1
src/tools/exe/tools_javac/src/tools_javac.c
src/tools/exe/tools_javac/src/tools_javac.c
+8
-8
src/tools/exe/tools_msg2cmsg/src/tools_msg2cmsg.c
src/tools/exe/tools_msg2cmsg/src/tools_msg2cmsg.c
+9
-9
src/tools/pwre/src/os_openbsd/pwre.pl
src/tools/pwre/src/os_openbsd/pwre.pl
+1
-1
src/tools/pwre/src/os_openbsd/pwre_configure.sh
src/tools/pwre/src/os_openbsd/pwre_configure.sh
+57
-9
wb/lib/wb/src/wb_exo.cpp
wb/lib/wb/src/wb_exo.cpp
+4
-4
xtt/lib/ge/src/ge.cpp
xtt/lib/ge/src/ge.cpp
+1
-1
xtt/lib/ge/src/ge_graph.h
xtt/lib/ge/src/ge_graph.h
+1
-1
xtt/lib/glow/gtk/glow_curvewidget_gtk.cpp
xtt/lib/glow/gtk/glow_curvewidget_gtk.cpp
+4
-2
xtt/lib/glow/gtk/glow_draw_gtk.cpp
xtt/lib/glow/gtk/glow_draw_gtk.cpp
+36
-0
xtt/lib/glow/gtk/glow_growwidget_gtk.cpp
xtt/lib/glow/gtk/glow_growwidget_gtk.cpp
+4
-2
xtt/lib/glow/src/glow_growctx.cpp
xtt/lib/glow/src/glow_growctx.cpp
+3
-1
No files found.
src/exp/com/src/os_openbsd/pwr_stop.sh
View file @
acf002d4
...
...
@@ -40,7 +40,8 @@
kill
-9
`
ps ax |
grep
"rt_qmon"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"rt_emon"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"rt_tmon"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"rt_
\|
/pwr/exe/rs"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"[0-9] rt_"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"/pwr/exe/rs"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"
\[
rt_"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"plc_"
|
awk
'{ print $1}'
`
kill
-9
`
ps ax |
grep
"jpwr.rt"
|
awk
'{ print $1}'
`
...
...
@@ -54,13 +55,14 @@
user
=
$USER
fi
user
=
`
eval whoami
`
echo
"User
$user
"
eval
`
ipcs
-s
|grep ^s|grep
"[
\t
]
$user
[
\t
]"
|awk
'{printf "ipcrm -s %s;", $2
}'
`
# remove message queues
eval
`
ipcs
-q
|grep ^q|grep
"[
\t
]
$user
[
\t
]"
|awk
'{printf "ipcrm -
q %s;", $2
eval
`
ipcs
-q
|grep ^q|grep
"[
\t
]
$user
[
\t
]"
|awk
'{printf "ipcrm -
Q %s;", $3
}'
`
# remove shared memory
...
...
src/exp/com/src/os_openbsd/pwrp_env.sh
View file @
acf002d4
...
...
@@ -75,20 +75,20 @@ pwrc_get_variables()
local
socket
if
[
-e
/etc/proview.cnf
]
;
then
socket
=
`
eval cat
/etc/proview.cnf |
grep
"
\b
mysql_socket
\b
"
|
awk
'{print $2}'
`
socket
=
`
eval cat
/etc/proview.cnf |
grep
"
[[:<:]]mysql_socket[[:>:]]
"
|
awk
'{print $2}'
`
if
[
!
-z
$socket
]
;
then
mysql_socket
=
"--socket
$socket
"
fi
pwr_projectroot
=
`
eval cat
/etc/proview.cnf |
grep
"
\b
projectroot
\b
"
|
awk
'{print $2}'
`
pwr_projectroot
=
`
eval cat
/etc/proview.cnf |
grep
"
[[:<:]]projectroot[[:>:]]
"
|
awk
'{print $2}'
`
if
[
-z
$pwr_projectroot
]
;
then
pwr_projectroot
=
/home/pwrp
fi
fi
if
[
-e
$pwr_inc
/pwr_version.h
]
;
then
# pwr_dbversion=`eval grep "
\bpwrv_cWbdbVersionShortStr\b
" $pwr_inc/pwr_version.h | awk '{print $2}'`
pwr_dbversion
=
`
eval cat
$pwr_inc
/pwr_version.h |
grep
"
\b
pwrv_cWbdbVersionShortStr
\b
"
|
awk
'{print $3}'
`
# pwr_dbversion=`eval grep "
[[:<:]]pwrv_cWbdbVersionShortStr[[:>:]]
" $pwr_inc/pwr_version.h | awk '{print $2}'`
pwr_dbversion
=
`
eval cat
$pwr_inc
/pwr_version.h |
grep
"
[[:<:]]pwrv_cWbdbVersionShortStr[[:>:]]
"
|
awk
'{print $3}'
`
if
[
-z
$pwr_dbversion
]
;
then
echo
"Unable to get pwr db version"
...
...
@@ -475,7 +475,7 @@ pwrc_get_projectname()
let found=0
# if [ -e
$pwrp_db
/pwrp_cnf_sysobject.dat ]; then
# pname=
`
eval cat
-n
$pwrp_db
/pwrp_cnf_sysobject.dat |
grep
"
\b
1
\b
"
|
awk
'{print $2}'
`
# pname=
`
eval cat
-n
$pwrp_db
/pwrp_cnf_sysobject.dat |
grep
"
[[:<:]]1[[:>:]]
"
|
awk
'{print $2}'
`
# if [ ! -z
$pname
]; then
# found=1
# fi
...
...
@@ -640,12 +640,12 @@ EndVolume
EOF
# Set ownership to user and group pwrp
user_pwrp=`eval cat /etc/passwd | grep "
\b
pwrp:"`
user_pwrp=`eval cat /etc/passwd | grep "
[[:<:]]
pwrp:"`
#if [ ! -z "$user_pwrp" ]; then
# chown -R pwrp $proot/
#fi
user_pwrp=`eval cat /etc/group | grep "
\b
pwrp:"`
user_pwrp=`eval cat /etc/group | grep "
[[:<:]]
pwrp:"`
if [ ! -z "$user_pwrp" ]; then
chgrp -R pwrp $proot/
chmod -R g+w $proot/
...
...
@@ -965,7 +965,7 @@ pwrc_set_func()
if
[
"
$bus_id
"
==
""
]
;
then
if
[
-e
/etc/proview.cnf
]
;
then
bus_id
=
`
eval cat
/etc/proview.cnf |
grep
"
\\
bqcomBusId
\\
b
"
|
awk
'{print $2}'
`
bus_id
=
`
eval cat
/etc/proview.cnf |
grep
"
[[:<:]]qcomBusId[[:>:]]
"
|
awk
'{print $2}'
`
fi
fi
export
PWR_BUS_ID
=
$bus_id
...
...
src/lib/rt/src/os_freebsd/rt_errl.c
View file @
acf002d4
...
...
@@ -91,6 +91,9 @@ errl_Init (
int
policy
;
struct
sched_param
param
;
key_t
key
;
int
fd
;
int
flags
=
O_RDWR
|
O_CREAT
;
mode_t
mode
=
S_IRUSR
|
S_IWUSR
|
S_IRGRP
|
S_IWGRP
;
errl_log_cb
=
log_cb
;
errl_log_userdata
=
userdata
;
...
...
@@ -125,7 +128,12 @@ errl_Init (
#endif
sprintf
(
name
,
"%s_%s"
,
LOG_QUEUE_NAME
,
busid
?
busid
:
""
);
fd
=
open
(
name
,
flags
,
mode
);
if
(
fd
==
-
1
)
{
printf
(
"Message Queue, open failed on %s, errno: %d
\n
"
,
name
,
errno
);
}
key
=
ftok
(
name
,
'm'
);
close
(
fd
);
mqid
=
msgget
(
key
,
IPC_CREAT
|
0660
);
if
(
mqid
==
-
1
)
{
...
...
@@ -247,8 +255,10 @@ log_thread (void *arg)
while
(
1
)
{
len
=
msgrcv
(
mqid
,
(
char
*
)
&
buf
,
LOG_MAX_MSG_SIZE
,
0
,
0
);
if
(
len
==
-
1
)
{
if
(
errno
!=
EINTR
)
if
(
errno
!=
EINTR
)
{
perror
(
"rt_logmod.c: mq_receive "
);
sleep
(
1
);
}
}
else
{
switch
(
buf
.
message_type
)
{
case
errh_eMsgType_Log
:
...
...
src/lib/rt/src/os_macos/rt_errl.c
View file @
acf002d4
...
...
@@ -91,6 +91,9 @@ errl_Init (
int
policy
;
struct
sched_param
param
;
key_t
key
;
int
fd
;
int
flags
=
O_RDWR
|
O_CREAT
;
mode_t
mode
=
S_IRUSR
|
S_IWUSR
|
S_IRGRP
|
S_IWGRP
;
errl_log_cb
=
log_cb
;
errl_log_userdata
=
userdata
;
...
...
@@ -125,7 +128,12 @@ errl_Init (
#endif
sprintf
(
name
,
"%s_%s"
,
LOG_QUEUE_NAME
,
busid
?
busid
:
""
);
fd
=
open
(
name
,
flags
,
mode
);
if
(
fd
==
-
1
)
{
printf
(
"Message Queue, open failed on %s, errno: %d
\n
"
,
name
,
errno
);
}
key
=
ftok
(
name
,
'm'
);
close
(
fd
);
mqid
=
msgget
(
key
,
IPC_CREAT
|
0660
);
if
(
mqid
==
-
1
)
{
...
...
@@ -247,8 +255,10 @@ log_thread (void *arg)
while
(
1
)
{
len
=
msgrcv
(
mqid
,
(
char
*
)
&
buf
,
LOG_MAX_MSG_SIZE
,
0
,
0
);
if
(
len
==
-
1
)
{
if
(
errno
!=
EINTR
)
if
(
errno
!=
EINTR
)
{
perror
(
"rt_logmod.c: mq_receive "
);
sleep
(
1
);
}
}
else
{
switch
(
buf
.
message_type
)
{
case
errh_eMsgType_Log
:
...
...
src/lib/rt/src/os_openbsd/rt_errl.c
View file @
acf002d4
...
...
@@ -91,6 +91,9 @@ errl_Init (
int
policy
;
struct
sched_param
param
;
key_t
key
;
int
fd
;
int
flags
=
O_RDWR
|
O_CREAT
;
mode_t
mode
=
S_IRUSR
|
S_IWUSR
|
S_IRGRP
|
S_IWGRP
;
errl_log_cb
=
log_cb
;
errl_log_userdata
=
userdata
;
...
...
@@ -125,7 +128,12 @@ errl_Init (
#endif
sprintf
(
name
,
"%s_%s"
,
LOG_QUEUE_NAME
,
busid
?
busid
:
""
);
fd
=
open
(
name
,
flags
,
mode
);
if
(
fd
==
-
1
)
{
printf
(
"Message Queue, open failed on %s, errno: %d
\n
"
,
name
,
errno
);
}
key
=
ftok
(
name
,
'm'
);
close
(
fd
);
mqid
=
msgget
(
key
,
IPC_CREAT
|
0660
);
if
(
mqid
==
-
1
)
{
...
...
@@ -134,7 +142,7 @@ errl_Init (
}
pthread_attr_init
(
&
pthreadattr
);
if
(
pthread_create
(
&
tid
,
/* &pthreadattr
*/
NULL
,
log_thread
,
NULL
)
==
-
1
)
{
if
(
pthread_create
(
&
tid
,
/* &pthreadattr*/
NULL
,
log_thread
,
NULL
)
==
-
1
)
{
perror
(
"rt_logmod: pthread_create "
);
pthread_attr_destroy
(
&
pthreadattr
);
return
;
...
...
@@ -244,11 +252,14 @@ log_thread (void *arg)
int
len
;
errh_sMsg
buf
;
sleep
(
1
);
while
(
1
)
{
len
=
msgrcv
(
mqid
,
(
char
*
)
&
buf
,
LOG_MAX_MSG_SIZE
,
0
,
0
);
if
(
len
==
-
1
)
{
if
(
errno
!=
EINTR
)
if
(
errno
!=
EINTR
)
{
perror
(
"rt_logmod.c: mq_receive "
);
sleep
(
1
);
}
}
else
{
switch
(
buf
.
message_type
)
{
case
errh_eMsgType_Log
:
...
...
src/lib/rt/src/rt_errh.c
View file @
acf002d4
...
...
@@ -645,9 +645,17 @@ openLog ()
char
name
[
64
];
char
*
busid
=
getenv
(
pwr_dEnvBusId
);
key_t
key
;
int
fd
;
int
flags
=
O_RDWR
|
O_CREAT
;
mode_t
mode
=
S_IRUSR
|
S_IWUSR
|
S_IRGRP
|
S_IWGRP
;
sprintf
(
name
,
"%s_%s"
,
LOG_QUEUE_NAME
,
busid
?
busid
:
""
);
fd
=
open
(
name
,
flags
,
mode
);
if
(
fd
==
-
1
)
{
printf
(
"Message Queue, open failed on %s, errno: %d
\n
"
,
name
,
errno
);
}
key
=
ftok
(
name
,
'm'
);
close
(
fd
);
mqid
=
msgget
(
key
,
IPC_CREAT
|
0660
);
if
(
mqid
==
-
1
)
{
...
...
src/lib/rt/src/rt_sect.c
View file @
acf002d4
...
...
@@ -315,7 +315,7 @@ sect_Alloc (
shm_id
=
shmget
(
shm_key
,
size
,
IPC_CREAT
|
0660
);
if
(
shm_id
==
-
1
)
{
lsts
=
2
;
errh_Error
(
"sect_Alloc: Couldn't attach/create shm section
"
);
errh_Error
(
"sect_Alloc: Couldn't attach/create shm section
size: %d. Check shmmax."
,
size
);
break
;
}
...
...
src/tools/bld/src/os_openbsd/hw_x86_64/variables.mk
View file @
acf002d4
...
...
@@ -160,7 +160,7 @@ else
tools_msg2cmsg
:=
$(eexe_dir)
/tools_msg2cmsg
tools_cmsg2c
:=
$(eexe_dir)
/tools_cmsg2c
tools_pdrgen
:=
$(eexe_dir)
/tools_pdrgen
wb_rtt
:=
$(e
e
xe_dir)
/wb_rtt
wb_rtt
:=
$(exe_dir)
/wb_rtt
co_convert
:=
$(eexe_dir)
/co_convert
co_merge
:=
$(eexe_dir)
/co_merge
endif
...
...
src/tools/bld/src/os_templ/hw_templ/variables.mk
View file @
acf002d4
...
...
@@ -160,7 +160,7 @@ else
tools_msg2cmsg
:=
$(eexe_dir)
/tools_msg2cmsg
tools_cmsg2c
:=
$(eexe_dir)
/tools_cmsg2c
tools_pdrgen
:=
$(eexe_dir)
/tools_pdrgen
wb_rtt
:=
$(e
e
xe_dir)
/wb_rtt
wb_rtt
:=
$(exe_dir)
/wb_rtt
co_convert
:=
$(eexe_dir)
/co_convert
co_merge
:=
$(eexe_dir)
/co_merge
endif
...
...
src/tools/exe/tools_javac/src/tools_javac.c
View file @
acf002d4
...
...
@@ -44,8 +44,8 @@ char prefix[][10] = {"gdhr", "gdh", "cdhr", "cdh", "pwrb", "pwrt", "pwr",
int
main
(
int
argc
,
char
*
argv
[])
{
char
filename
[
80
];
char
destination
[
80
];
char
filename
[
256
];
char
destination
[
256
];
char
cmd
[
200
];
char
*
s
,
*
t
;
int
i
;
...
...
@@ -53,7 +53,7 @@ int main( int argc, char *argv[])
if
(
argc
>
3
&&
strcmp
(
argv
[
1
],
"-d"
)
==
0
)
{
str
cpy
(
destination
,
argv
[
2
]
);
str
ncpy
(
destination
,
argv
[
2
],
sizeof
(
destination
)
);
/* Cut last to segments in directory (package name) */
if
((
s
=
strrchr
(
destination
,
'/'
)))
...
...
@@ -66,12 +66,12 @@ int main( int argc, char *argv[])
*
s
=
0
;
}
}
str
cpy
(
filename
,
argv
[
3
]
);
str
ncpy
(
filename
,
argv
[
3
],
sizeof
(
filename
)
);
}
else
if
(
argc
>
1
)
{
str
cpy
(
filename
,
argv
[
1
]
);
str
cpy
(
destination
,
""
);
str
ncpy
(
filename
,
argv
[
1
],
sizeof
(
filename
)
);
str
ncpy
(
destination
,
""
,
sizeof
(
destination
)
);
}
else
{
...
...
@@ -144,9 +144,9 @@ int main( int argc, char *argv[])
if
(
strcmp
(
destination
,
""
)
==
0
)
s
printf
(
cmd
,
"javac %s"
,
filename
);
s
nprintf
(
cmd
,
sizeof
(
cmd
)
,
"javac %s"
,
filename
);
else
s
printf
(
cmd
,
"javac -d %s %s"
,
destination
,
filename
);
s
nprintf
(
cmd
,
sizeof
(
cmd
)
,
"javac -d %s %s"
,
destination
,
filename
);
printf
(
"Cmd: %s
\n
"
,
cmd
);
sts
=
system
(
cmd
);
...
...
src/tools/exe/tools_msg2cmsg/src/tools_msg2cmsg.c
View file @
acf002d4
...
...
@@ -59,7 +59,7 @@
#include "msg2cmsg.h"
#define MSG_NEW_STRING(str) str
cpy(malloc(strlen(str) + 1), str
)
#define MSG_NEW_STRING(str) str
ncpy(malloc(strlen(str) + 1), str, strlen(str) + 1
)
typedef
struct
s_FacilityCB
sFacilityCB
;
...
...
@@ -171,9 +171,9 @@ int main(int argc, char **argv)
fname
[
i
]
=
'\0'
;
#else
if
((
p
=
strrchr
(
argv
[
2
],
'/'
)))
str
cpy
(
fname
,
p
+
1
);
str
ncpy
(
fname
,
p
+
1
,
sizeof
(
fname
)
);
else
str
cpy
(
fname
,
argv
[
2
]
);
str
ncpy
(
fname
,
argv
[
2
],
sizeof
(
fname
)
);
#endif
...
...
@@ -282,19 +282,19 @@ static void WriteFiles(char *fname, FILE *cfp, FILE *hfp)
for
(
fl
=
LstFir
(
&
lFacH
);
fl
!=
LstEnd
(
&
lFacH
);
fl
=
LstNex
(
fl
))
{
facid
=
0x800
+
LstObj
(
fl
)
->
f
.
FacNum
;
#if defined OS_VMS || OS_ELN
s
printf
(
name
,
"%s$_FACILITY"
,
LstObj
(
fl
)
->
f
.
FacName
);
s
nprintf
(
name
,
sizeof
(
name
)
,
"%s$_FACILITY"
,
LstObj
(
fl
)
->
f
.
FacName
);
#else
s
printf
(
name
,
"%s_FACILITY"
,
LstObj
(
fl
)
->
f
.
FacName
);
s
nprintf
(
name
,
sizeof
(
name
)
,
"%s_FACILITY"
,
LstObj
(
fl
)
->
f
.
FacName
);
#endif
fprintf
(
hfp
,
"#define %-29s %9d /* x%08x */
\n
"
,
name
,
facid
,
facid
);
facid
=
facid
<<
16
;
if
(
LstObj
(
fl
)
->
f
.
Prefix
)
str
cpy
(
prefix
,
LstObj
(
fl
)
->
f
.
Prefix
);
str
ncpy
(
prefix
,
LstObj
(
fl
)
->
f
.
Prefix
,
sizeof
(
prefix
)
);
else
s
printf
(
prefix
,
"%s_"
,
LstObj
(
fl
)
->
f
.
FacName
);
s
nprintf
(
prefix
,
sizeof
(
prefix
)
,
"%s_"
,
LstObj
(
fl
)
->
f
.
FacName
);
s
printf
(
msgName
,
"%smsg"
,
LstObj
(
fl
)
->
f
.
FacName
);
s
nprintf
(
msgName
,
sizeof
(
msgName
)
,
"%smsg"
,
LstObj
(
fl
)
->
f
.
FacName
);
fprintf
(
cfp
,
"static msg_sMsg %s[] = {
\n
"
,
msgName
);
...
...
@@ -303,7 +303,7 @@ static void WriteFiles(char *fname, FILE *cfp, FILE *hfp)
fprintf
(
cfp
,
",
\n
"
);
msg
=
facid
+
0x8000
+
(
idx
<<
3
)
+
LstObj
(
ml
)
->
Severity
;
s
printf
(
name
,
"%s%s"
,
prefix
,
LstObj
(
ml
)
->
m
.
MsgName
);
s
nprintf
(
name
,
sizeof
(
name
)
,
"%s%s"
,
prefix
,
LstObj
(
ml
)
->
m
.
MsgName
);
fprintf
(
hfp
,
"#define %-29s %9.9d /* x%08x */
\n
"
,
name
,
msg
,
msg
);
fprintf
(
cfp
,
"
\t
{
\"
%s
\"
,
\"
%s
\"
}"
,
LstObj
(
ml
)
->
m
.
MsgName
,
LstObj
(
ml
)
->
m
.
MsgTxt
);
}
...
...
src/tools/pwre/src/os_openbsd/pwre.pl
View file @
acf002d4
...
...
@@ -151,7 +151,7 @@ sub configure()
exit
1
;
}
my
$fname
=
$ENV
{"
pwre_bin
"}
.
"
/pwre_configure.sh
";
my
$fname
=
$ENV
{"
pwre_bin
"}
.
"
/pwre_configure.sh
"
.
"
"
.
$_
[
0
]
.
"
"
.
$_
[
1
]
.
"
"
.
$_
[
2
]
;
system
(
$fname
);
}
...
...
src/tools/pwre/src/os_openbsd/pwre_configure.sh
View file @
acf002d4
#!/bin/bash
pwre_help
()
{
cat
<<
EOF
pwre_configure.h
Arguments
--help Display help.
--version State fix version of loadfiles, eg
> pwre configure --version "29-MAY-2011 16:00:00"
--reset-version Reset previous version
EOF
}
pwre_config_init
()
{
d
=
`
eval date
+
\"
%F %X
\"
`
...
...
@@ -225,32 +243,55 @@ if test ! -e $pwre_croot; then
exit
fi
# Options
if
[
"
$1
"
=
"--help"
]
;
then
pwre_help
exit
elif
[
"
$1
"
=
"--version"
]
&&
[
"
$2
"
!=
""
]
&&
[
"
$3
"
!=
""
]
;
then
buildversion
=
$2
" "
$3
elif
[
"
$1
"
=
"--reset-version"
]
;
then
buildversion
=
""
elif
[
"
$1
"
!=
""
]
;
then
echo
"Unknown option
\"
$1
\"
"
exit
else
# Catch current version
if
[
-e
$cfile
]
;
then
ver
=
`
eval cat
$cfile
|
grep
"[[:<:]]export PWRE_CONF_BUILDVERSION"
`
ver
=
${
ver
#*=\
"}
ver=
${
ver
%\
"}
buildversion=
$ver
fi
fi
pwre_create_blddir
pwre_create_makedir
pwre_config_init
if [ "
$buildversion
" != "" ]; then
echo "
export
PWRE_CONF_BUILDVERSION=\
"
$buildversion
\"
"
>>
$cfile
else
echo
"export PWRE_CONF_BUILDVERSION=
\"
0
\"
"
>>
$cfile
fi
#Gtk
echo
""
echo
"Mandatory :"
pwre_config_check_lib gtk GTK gtk gtk 0 /usr/local/lib/libgtk-x11-2.0.a
pwre_config_check_lib libantlr LIBANTLR lib lib 0 /usr/local/lib/libantlr.a
pwre_config_check_lib librpcsvc LIBRPCSVC lib lib 0 /usr/lib/librpcsvc.so
:/usr/lib/librpcsvc.a
pwre_config_check_lib libasound LIBASOUND lib lib 0 /usr/lib/libasound.so:/usr/lib/libasound.a
#
pwre_config_check_lib libasound LIBASOUND lib lib 0 /usr/lib/libasound.so
:/usr/lib/libasound.a
pwre_config_check_lib libpthread LIBPTHREAD lib lib 0 /usr/lib/libpthread.so
:/usr/lib/libpthread.a
pwre_config_check_lib libm LIBM lib lib 0 /usr/lib/libm.so
:/usr/lib/libm.a
pwre_config_check_lib libdb_cxx LIBDB_CXX lib lib 0 /usr/local/lib/libdb_cxx.so.6.0
pwre_config_check_lib libz LIBZ lib lib 0 /usr/lib/libz.so
:/usr/lib/libz.a
pwre_config_check_lib libcrypt LIBCRYPT lib lib 0 /usr/lib/libcrypt.so:/usr/lib/libcrypt.a
pwre_config_check_lib mysql MYSQL lib lib 1 /usr/lib/libmysqlclient.so
pwre_config_check_lib mq MQ lib lib 1 /usr/lib/libdmq.so
pwre_config_check_lib libpnioif PNAK lib lib 1 /usr/lib/libpnioif.so:/usr/local/lib/libpnioif.a
pwre_config_check_lib libusb LIBUSB lib lib 1 /usr/lib/libusb-1.0.so
pwre_config_check_lib librt LIBRT lib lib 0 /usr/lib/librt.dylib:/usr/lib/librt.a
#pwre_config_check_lib libcrypt LIBCRYPT lib lib 0 /usr/lib/libcrypt.so
:/usr/lib/libcrypt.a
#pwre_config_check_lib librt LIBRT lib lib 0 /usr/lib/librt.dylib
:/usr/lib/librt.a
pwre_config_check_lib libiconv LIBICONV lib lib 0 /usr/local/lib/libiconv.so
:/usr/local/lib/libiconv.a
pwre_config_check_lib libfl LIBFL lib lib 0 /usr/lib/libfl.os
:/usr/lib/libfl.a
#set -o xtrace
pwre_config_check_include antlr ANTLR 1 /usr/local/include/antlr/CommonAST.hpp
pwre_config_check_include gtk GTK 1 /usr/local/include/gtk-2.0/gtk/gtk.h
pwre_config_check_include iconv ICONV 1 /usr/local/include/iconv.h
...
...
@@ -258,6 +299,13 @@ pwre_config_check_include jni JNI 1 /usr/local/jdk-1.7.0/include/jni.h
pwre_config_check_include jni JNI 0 /usr/local/jdk-1.7.0/include/openbsd/jni_md.h
pwre_config_check_include libdb_cxx LIBDB_CXX 0 /usr/local/include/db4/db_cxx.h
echo
""
echo
"Optional :"
pwre_config_check_lib mysql MYSQL lib lib 1 /usr/lib/libmysqlclient.so
pwre_config_check_lib mq MQ lib lib 1 /usr/lib/libdmq.so
pwre_config_check_lib libpnioif PNAK lib lib 1 /usr/lib/libpnioif.so
:/usr/local/lib/libpnioif.a
pwre_config_check_lib libusb LIBUSB lib lib 1 /usr/lib/libusb-1.0.so
export pwre_conf_alsa=1
...
...
wb/lib/wb/src/wb_exo.cpp
View file @
acf002d4
...
...
@@ -304,8 +304,8 @@ int exo_exec_m0( exo_ctx exoctx, vldh_t_node node)
"RtBody"
,
1
,
&
bodydef
,
&
rows
);
if
(
ODD
(
sts
)
)
{
i
=
0
;
while
(
(
bodydef
[
i
].
ParClass
==
pwr_eClass_Input
)
&&
(
i
<
rows
)
)
{
while
(
i
<
rows
&&
bodydef
[
i
].
ParClass
==
pwr_eClass_Input
)
{
/* Get the point for this parameter if there is one */
sts
=
gcg_get_inputpoint
(
node
,
i
,
&
point
,
&
par_inverted
);
if
(
ODD
(
sts
))
{
...
...
@@ -435,8 +435,8 @@ int exo_exec_m2( exo_ctx exoctx, vldh_t_node node)
if
(
EVEN
(
sts
)
)
return
sts
;
i
=
0
;
while
(
(
bodydef
[
i
].
ParClass
==
pwr_eClass_Input
)
&&
(
i
<
rows
)
)
{
while
(
i
<
rows
&&
bodydef
[
i
].
ParClass
==
pwr_eClass_Input
)
{
/* Get the point for this parameter if there is one */
sts
=
gcg_get_inputpoint
(
node
,
i
,
&
point
,
&
par_inverted
);
if
(
ODD
(
sts
))
{
...
...
xtt/lib/ge/src/ge.cpp
View file @
acf002d4
...
...
@@ -40,7 +40,7 @@
#include <vector>
#include "glow_std.h"
#if defined OS_VMS || defined OS_
LINU
X
#if defined OS_VMS || defined OS_
POSI
X
#define LDH 1
#endif
...
...
xtt/lib/ge/src/ge_graph.h
View file @
acf002d4
...
...
@@ -64,7 +64,7 @@
#include "ge_attr.h"
#endif
#if defined OS_VMS || defined OS_
LINU
X
#if defined OS_VMS || defined OS_
POSI
X
#define LDH 1
#endif
...
...
xtt/lib/glow/gtk/glow_curvewidget_gtk.cpp
View file @
acf002d4
...
...
@@ -287,8 +287,10 @@ static void curvewidgetgtk_destroy( GtkObject *object)
curvew
->
destroyed
=
1
;
if
(
curvew
->
scroll_timerid
)
g_source_remove
(
curvew
->
scroll_timerid
);
if
(
curvew
->
is_navigator
&&
curvew
->
curve_ctx
)
if
(
curvew
->
is_navigator
)
{
if
(
curvew
->
curve_ctx
&&
!
((
CurveWidgetGtk
*
)
curvew
->
main_curve_widget
)
->
destroyed
)
((
CurveCtx
*
)
curvew
->
curve_ctx
)
->
no_nav
=
1
;
}
else
delete
(
GlowDrawGtk
*
)
curvew
->
draw_ctx
;
}
...
...
xtt/lib/glow/gtk/glow_draw_gtk.cpp
View file @
acf002d4
...
...
@@ -859,20 +859,28 @@ int GlowDrawGtk::event_handler( GdkEvent event)
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
!
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1ClickShift
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
!
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1ClickCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1ClickShiftCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1Click
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
break
;
...
...
@@ -880,20 +888,28 @@ int GlowDrawGtk::event_handler( GdkEvent event)
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
!
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2ClickShift
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
!
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2ClickCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2ClickShiftCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2Click
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
break
;
...
...
@@ -911,6 +927,8 @@ int GlowDrawGtk::event_handler( GdkEvent event)
else
#endif
sts
=
ctx
->
event_handler
(
glow_eEvent_MB3Click
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
break
;
}
...
...
@@ -919,6 +937,8 @@ int GlowDrawGtk::event_handler( GdkEvent event)
/* Button release */
// cout << "Button release detected" << endl;
sts
=
ctx
->
event_handler
(
glow_eEvent_ButtonRelease
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
}
}
else
{
...
...
@@ -945,20 +965,28 @@ int GlowDrawGtk::event_handler( GdkEvent event)
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
!
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1DoubleClickShift
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
!
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1DoubleClickCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1DoubleClickShiftCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB1DoubleClick
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
break
;
...
...
@@ -966,20 +994,28 @@ int GlowDrawGtk::event_handler( GdkEvent event)
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
!
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2DoubleClickShift
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
!
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2DoubleClickCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
if
(
(
event
.
button
.
state
&
GDK_SHIFT_MASK
)
&&
(
event
.
button
.
state
&
GDK_CONTROL_MASK
))
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2DoubleClickShiftCtrl
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
else
{
sts
=
ctx
->
event_handler
(
glow_eEvent_MB2DoubleClick
,
(
int
)
event
.
button
.
x
,
(
int
)
event
.
button
.
y
,
0
,
0
);
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
1
;
click_sensitivity
=
0
;
}
break
;
...
...
xtt/lib/glow/gtk/glow_growwidget_gtk.cpp
View file @
acf002d4
...
...
@@ -291,8 +291,10 @@ static void growwidgetgtk_destroy( GtkObject *object)
grow
->
destroyed
=
1
;
if
(
grow
->
scroll_timerid
)
g_source_remove
(
grow
->
scroll_timerid
);
if
(
grow
->
is_navigator
&&
grow
->
grow_ctx
)
if
(
grow
->
is_navigator
)
{
if
(
grow
->
grow_ctx
&&
!
((
GrowWidgetGtk
*
)
grow
->
main_grow_widget
)
->
destroyed
)
((
GrowCtx
*
)
grow
->
grow_ctx
)
->
no_nav
=
1
;
}
else
delete
(
GlowDrawGtk
*
)
grow
->
draw_ctx
;
}
...
...
xtt/lib/glow/src/glow_growctx.cpp
View file @
acf002d4
...
...
@@ -266,7 +266,9 @@ int GrowCtx::event_handler( glow_eEvent event, int x, int y, int w, int h)
case
glow_eEvent_MB1Up
:
case
glow_eEvent_MB1Click
:
sts
=
a
[
a
.
a_size
-
1
]
->
event_handler
(
&
mw
,
event
,
x
,
y
,
fx
,
fy
);
if
(
sts
)
if
(
sts
==
GLOW__TERMINATED
||
sts
==
GLOW__DESTROYED
)
return
sts
;
else
if
(
sts
)
return
1
;
break
;
default:
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment