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
15245f74
Commit
15245f74
authored
Jun 27, 2017
by
Christoffer Ackelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
32-bit versions can now be compiled on 64-bit machines.
parent
72de1d67
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
50 additions
and
41 deletions
+50
-41
.gitignore
.gitignore
+5
-1
src/exe/co_merge/src/co_merge.c
src/exe/co_merge/src/co_merge.c
+9
-2
src/exp/com/src/os_linux/wb_rtt_appl.sh
src/exp/com/src/os_linux/wb_rtt_appl.sh
+3
-3
src/exp/com/src/os_linux/wb_rtt_comppicture.sh
src/exp/com/src/os_linux/wb_rtt_comppicture.sh
+2
-2
src/exp/inc/src/pwrp_rules.mk
src/exp/inc/src/pwrp_rules.mk
+3
-3
src/tools/bld/src/os_linux/hw_x86/variables.mk
src/tools/bld/src/os_linux/hw_x86/variables.mk
+10
-10
src/tools/pwre/src/os_linux/pwre.pl
src/tools/pwre/src/os_linux/pwre.pl
+10
-1
src/tools/pwre/src/os_linux/pwre_configure.sh
src/tools/pwre/src/os_linux/pwre_configure.sh
+6
-18
xtt/exe/wb_ge/gtk/os_templ/link_rule.mk
xtt/exe/wb_ge/gtk/os_templ/link_rule.mk
+2
-1
No files found.
.gitignore
View file @
15245f74
...
...
@@ -5,4 +5,8 @@
*.wb_load.*
#Ignore build files
*.os_*
*.hw_*
\ No newline at end of file
*.hw_*
rls/
adm/
pwre_db
src/exe/co_merge/src/co_merge.c
View file @
15245f74
...
...
@@ -82,6 +82,13 @@ static int check_os( char *str, char *os)
return
0
;
}
const
char
*
getenvsafe
(
const
char
*
name
)
{
const
char
*
s
=
getenv
(
name
);
if
(
s
==
NULL
)
return
""
;
return
s
;
}
int
main
(
int
argc
,
char
*
argv
[])
{
pwr_tFileName
filespec
;
...
...
@@ -288,10 +295,10 @@ int main( int argc, char *argv[])
dcli_translate_filename
(
incdir
,
"$pwr_einc"
);
switch
(
mtype
)
{
case
merge_eMtype_WbBase
:
snprintf
(
cmd
,
sizeof
(
cmd
),
"%s -c %s
-I%s %s -o %s %s"
,
pwre_cxx
,
cflags
,
incdir
,
dos
,
ofile
,
cfile
);
snprintf
(
cmd
,
sizeof
(
cmd
),
"%s -c %s
%s -I%s %s -o %s %s"
,
pwre_cxx
,
getenvsafe
(
"cross_compile"
)
,
cflags
,
incdir
,
dos
,
ofile
,
cfile
);
break
;
default:
snprintf
(
cmd
,
sizeof
(
cmd
),
"%s -c %s
-I%s %s -o %s %s"
,
pwre_cc
,
cflags
,
incdir
,
dos
,
ofile
,
cfile
);
snprintf
(
cmd
,
sizeof
(
cmd
),
"%s -c %s
%s -I%s %s -o %s %s"
,
pwre_cc
,
getenvsafe
(
"cross_compile"
)
,
cflags
,
incdir
,
dos
,
ofile
,
cfile
);
}
if
(
arg_verbose
)
printf
(
"co_merge: %s
\n
"
,
cmd
);
...
...
src/exp/com/src/os_linux/wb_rtt_appl.sh
View file @
15245f74
...
...
@@ -80,14 +80,14 @@ then
cc
=
gcc
cinc
=
"-I
$pwr_inc
-I
$pwrp_rttbld
-I-"
cflags
=
"-DOS_LINUX=1 -DOS_POSIX=1 -DOS=linux -DHW_X86=1 -DHW=x86 -O3 -DGNU_SOURCE -DPWR_NDEBUG -D_REENTRANT"
cflags
=
"
${
cross_compile
}
-DOS_LINUX=1 -DOS_POSIX=1 -DOS=linux -DHW_X86=1 -DHW=x86 -O3 -DGNU_SOURCE -DPWR_NDEBUG -D_REENTRANT"
${
cc
}
-c
-o
$pwrp_obj
/
${
menuname
}
.o
\
$pwrp_rttbld
/
${
menuname
}
.c
\
${
cinc
}
${
cflags
}
ld
=
g++
linkflags
=
"-g -L/lib/thread -L
$pwrp_lib
-L
$pwr_lib
"
linkflags
=
"
${
cross_compile
}
-g -L/lib/thread -L
$pwrp_lib
-L
$pwr_lib
"
${
ld
}
${
linkflags
}
-o
$pwrp_exe
/
${
exename
}
$pwrp_obj
/
${
menuname
}
.o
\
$pwr_obj
/dtt_rttsys.o
$pwr_obj
/rt_io_user.o
\
...
...
@@ -102,7 +102,7 @@ then
# echo "Compile"
cc
=
gcc
cinc
=
"-I
$pwr_inc
-I
$pwrp_rttbld
-I
$pwrp_inc
-I
$pwrp_cmn
/common/inc -I-"
cflags
=
"-DOS_LINUX=1 -DOS=linux -DHW_X86=1 -DHW=x86 -O3 -DGNU_SOURCE -DPWR_NDEBUG -D_REENTRANT"
cflags
=
"
${
cross_compile
}
-DOS_LINUX=1 -DOS=linux -DHW_X86=1 -DHW=x86 -O3 -DGNU_SOURCE -DPWR_NDEBUG -D_REENTRANT"
${
cc
}
-c
-o
$pwrp_obj
/
${
applname
}
.o
\
$pwrp_rtt
/
${
applname
}
.c
\
...
...
src/exp/com/src/os_linux/wb_rtt_comppicture.sh
View file @
15245f74
...
...
@@ -55,7 +55,7 @@ if [ $opsys = "64" ] || [ $opsys == "128" ]; then
cc
=
gcc
cinc
=
"-I
$pwr_inc
-I
$pwrp_rttbld
"
cflags
=
"
-DOS_LINUX -DOS_POSIX -DOS=linux -DHW_X86=1 -DPOSIX_SOURCE -DWall"
cflags
=
"
${
cross_compile
}
-DOS_LINUX -DOS_POSIX -DOS=linux -DHW_X86=1 -DPOSIX_SOURCE -DWall"
${
cc
}
-c
-o
$pwrp_obj
/
${
name
}
.o
$pwrp_rttbld
/
${
name
}
.c
${
cinc
}
${
cflags
}
ar rc
${
ar_name_pict
}
$pwrp_obj
/
${
name
}
.o
else
...
...
@@ -66,7 +66,7 @@ if [ $opsys = "64" ] || [ $opsys == "128" ]; then
cc
=
gcc
cinc
=
"-I
$pwr_inc
-I
${
bld_dir
}
"
cflags
=
"-DOS_LINUX -DOS_POSIX -DOS=linux -DHW_X86=1 -DPOSIX_SOURCE -DWall"
cflags
=
"
${
cross_compile
}
-DOS_LINUX -DOS_POSIX -DOS=linux -DHW_X86=1 -DPOSIX_SOURCE -DWall"
${
cc
}
-c
-o
${
bld_dir
}
/
${
name
}
.o
\
${
bld_dir
}
/
${
name
}
.c
${
cinc
}
${
cflags
}
ar rc
${
ar_name_pict
}
${
bld_dir
}
/
${
name
}
.o
...
...
src/exp/inc/src/pwrp_rules.mk
View file @
15245f74
...
...
@@ -9,11 +9,11 @@ cxx := g++
f77
:=
g77
ld
:=
gcc
ldxx
:=
g++
linkflags
:=
-g
-L
/usr/local/lib
-L
$(pwr_obj)
-L
$(pwrp_obj)
-lm
-lrt
cflags
:=
-c
-g
-Wall
-D_GNU_SOURCE
-D_REENTRANT
linkflags
:=
$(cross_compile)
-g
-L
/usr/local/lib
-L
$(pwr_obj)
-L
$(pwrp_obj)
-lm
-lrt
cflags
:=
$(cross_compile)
-c
-g
-Wall
-D_GNU_SOURCE
-D_REENTRANT
cxxflags
:=
$(cflags)
-Wno-deprecated
f77flags
:=
linkflags
:=
-g
-L
/usr/local/lib
-L
$(pwr_lib)
-L
$(pwrp_lib)
-lrt
linkflags
:=
$(cross_compile)
-g
-L
/usr/local/lib
-L
$(pwr_lib)
-L
$(pwrp_lib)
-lrt
csetos
:=
-DOS_LINUX
=
1
-DOS_POSIX
=
1
-DOS
=
linux
-DHW_X86
=
1
-DHW
=
x86
cinc
:=
-I
$(pwr_inc)
-I
$(pwrp_inc)
$(PWR_EXT_INC)
-I
/usr/local/include
-I
/usr/X11R6/include
-I
$(jdk)
/include
-I
$(jdk)
/include/linux
f77inc
:=
-I
$(pwr_inc)
-I
$(pwrp_inc)
...
...
src/tools/bld/src/os_linux/hw_x86/variables.mk
View file @
15245f74
...
...
@@ -196,21 +196,21 @@ mkdir := mkdir
wblflags
:=
ifeq
($(pwre_btype),rls)
cflags
:=
-c
-O3
-D_GNU_SOURCE
-DPWR_NDEBUG
-D_REENTRANT
-fPIC
-Wno-deprecated-declarations
-Wno-unused-but-set-variable
cxxflags
:=
$(cflags)
linkflags
:=
-O3
-L
$(
lib_dir)
e
linkflags
:=
-O3
-L
$(lib_dir)
-L
$(elib_dir)
explinkflags
:=
-g
-L
$(elib_dir
)
cflags
:=
$(cross_compile)
-c
-O3
-D_GNU_SOURCE
-DPWR_NDEBUG
-D_REENTRANT
-fPIC
-Wno-deprecated-declarations
-Wno-unused-but-set-variable
linkflags
:=
$(cross_compile)
-O3
-L
$(lib_dir)
elinkflags
:=
$(cross_compile)
-O3
-L
$(lib_dir)
-L
$(e
lib_dir)
e
xplinkflags
:=
$(cross_compile)
-g
-L
$(elib_dir)
cxxflags
:=
$(cflags
)
clis
=
/lis
=
$(list)
dolist
=
/lis
=
$(list)
domap
=
-Xlinker
-Map
-Xlinker
$(map)
else
cflags
:=
-c
-g
-Wall
-D_GNU_SOURCE
-D_REENTRANT
-fPIC
-Wno-deprecated-declarations
-Wno-unused-but-set-variable
cxxflags
:=
$(cflags)
-Wno-deprecated
cflags
:=
$(cross_compile)
-c
-g
-Wall
-D_GNU_SOURCE
-D_REENTRANT
-fPIC
-Wno-deprecated-declarations
-Wno-unused-but-set-variable
mmflags
:=
-Wno-deprecated
linkflags
:=
-g
-L
$(lib_dir)
elinkflags
:=
-g
-L
$(lib_dir)
-L
$(elib_dir)
explinkflags
:=
-g
-L
$(elib_dir)
linkflags
:=
$(cross_compile)
-g
-L
$(lib_dir)
elinkflags
:=
$(cross_compile)
-g
-L
$(lib_dir)
-L
$(elib_dir)
explinkflags
:=
$(cross_compile)
-g
-L
$(elib_dir)
cxxflags
:=
$(cflags)
-Wno-deprecated
dolist
=
/lis
=
$(list)
clis
:=
domap
=
-Xlinker
-Map
-Xlinker
$(map)
...
...
src/tools/pwre/src/os_linux/pwre.pl
View file @
15245f74
...
...
@@ -54,6 +54,7 @@ if ($ENV{"pwre_hosttype"} eq "rs6000") {
$hw
=
"
x86
";
}
}
$real_hw
=
$hw
;
$desc
=
$user
.
"
's environment
";
@vars
;
...
...
@@ -139,7 +140,6 @@ sub add ()
update_db
();
}
untie
(
%
envdb
)
||
die
"
++ can't untie
$dbname
!
";
}
#
...
...
@@ -152,6 +152,9 @@ sub configure()
exit
1
;
}
if
(
$hw
eq
"
x86
"
&&
$real_hw
eq
"
x86_64
")
{
$ENV
{"
cross_compile
"}
=
"
-m32
";
}
my
$fname
=
$ENV
{"
pwre_bin
"}
.
"
/pwre_configure.sh
"
.
"
"
.
$_
[
0
]
.
"
"
.
$_
[
1
]
.
"
"
.
$_
[
2
];
system
(
$fname
);
}
...
...
@@ -1176,6 +1179,9 @@ sub copy ()
system
("
$cmd
");
}
else
{
if
(
$hw
eq
"
x86
"
&&
$real_hw
eq
"
x86_64
")
{
$ENV
{"
cross_compile
"}
=
"
-m32
";
}
my
(
$cmd
)
=
"
make -f
$bindir
/import_files.mk
"
.
"
"
.
$_
[
0
];
system
("
$cmd
");
...
...
@@ -1461,6 +1467,9 @@ sub _build () # args: branch, subbranch, flavour, phase
#print("\n$_\n");
chdir
(
$_
)
||
die
"
cannot cd to
$_
($!)
";
$ENV
{"
PWD
"}
=
$_
;
if
(
$hw
eq
"
x86
"
&&
$real_hw
eq
"
x86_64
")
{
$ENV
{"
cross_compile
"}
=
"
-m32
";
}
system
("
make
@_
")
&&
exit
1
;
}
}
...
...
src/tools/pwre/src/os_linux/pwre_configure.sh
View file @
15245f74
...
...
@@ -283,25 +283,13 @@ conf_incdirgst=""
let
inc_cnt
=
0
let
lib_cnt
=
0
let
i
=
0
hwpl
=
`
eval uname
-i
`
machine
=
`
eval uname
-m
`
if
[
$machine
==
"i686"
]
||
[
$machine
==
"x86_64"
]
;
then
hwpl
=
$machine
fi
if
[
${
machine
:0:3
}
==
"arm"
]
;
then
hwpl
=
i386
if
[
${
pwre_hw
:3
}
==
"arm"
]
;
then
hwpl
=
arm
else
ubuntu_ver
=
`
cat
/etc/issue |
grep
Ubuntu |
awk
'{ print $2 }'
`
debian_ver
=
`
cat
/etc/issue |
grep
Debian |
awk
'{ print $3 }'
`
if
[
"
$ubuntu_ver
"
==
""
]
;
then
ubuntu_ver
=
`
cat
/etc/issue |
grep
Mint |
awk
'{ print $3 }'
`
fi
if
[
"
$ubuntu_ver
"
!=
""
]
&&
[
$hwpl
==
"i686"
]
;
then
hwpl
=
i386
fi
if
[
"
$debian_ver
"
!=
""
]
&&
[
"
$debian_ver
"
!=
"6"
]
&&
[
$hwpl
==
"i686"
]
;
then
hwpl
=
i386
fi
fi
if
[
${
pwre_hw
:3
}
==
"x86_64"
]
;
then
hwpl
=
x86_64
fi
# Bash
...
...
xtt/exe/wb_ge/gtk/os_templ/link_rule.mk
View file @
15245f74
...
...
@@ -3,7 +3,8 @@ link_rule_mk := 1
# Link with local wb to avoid profibus wb methods
link
=
$(ldxx)
-L
$(release_root)
/wb/lib
-L
$(pwr_lib)
-L
$(pwr_elib)
$(domap)
-o
$(pwr_exe)
/wb_ge_gtk
\
link
=
$(ldxx)
$(cross_compile)
\
-L
$(release_root)
/wb/lib
-L
$(pwr_lib)
-L
$(pwr_elib)
$(domap)
-o
$(pwr_exe)
/wb_ge_gtk
\
$(bld_dir)
/wb_ge_gtk.o
$(wb_msg_eobjs)
$(rt_msg_eobjs)
$(pwr_eobj)
/pwr_msg_glow.o
\
$(pwr_eobj)
/rt_io_user.o
$(pwr_eobj)
/wb_provider.o
\
$(pwre_conf_libdir)
$(pwre_conf_libpwrwbgtk)
$(pwre_conf_libpwrxttgtk)
$(pwre_conf_libpwrwb)
\
...
...
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