Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix gh-1426 Implement -Wl, and related changes
* -Wl was passed to the compiler instead of the linker. * Any linker options set before setExe()/setDebug() were called were ignored. * #option action was ignored in a beginc++ (bugzilla bug #84603) * #option wasn't stripped from beginc++ that wasn't defined as a function (not very usual). * Added #option library 'mylib' within a beginc++ to add a library to the list passed to the linker. Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
- Loading branch information
Showing
14 changed files
with
260 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/*############################################################################## | ||
|
||
Copyright (C) 2011 HPCC Systems. | ||
|
||
All rights reserved. This program is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU Affero General Public License as | ||
published by the Free Software Foundation, either version 3 of the | ||
License, or (at your option) any later version. | ||
|
||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU Affero General Public License for more details. | ||
|
||
You should have received a copy of the GNU Affero General Public License | ||
along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
############################################################################## */ | ||
|
||
|
||
|
||
integer4 add1(integer4 x, integer4 y) := | ||
BEGINC++ | ||
return x + y; | ||
ENDC++; | ||
|
||
integer4 add2(integer4 x, integer4 y) := | ||
BEGINC++ | ||
#option action | ||
return x + y; | ||
ENDC++; | ||
|
||
integer4 add3(integer4 x, integer4 y) := | ||
BEGINC++ | ||
#option pure | ||
return x + y; | ||
ENDC++; | ||
|
||
output(add1(10,20) * add1(10,20)); | ||
output(add2(10,20) * add2(10,20)); | ||
output(add3(10,20) * add3(10,20)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/*############################################################################## | ||
|
||
Copyright (C) 2011 HPCC Systems. | ||
|
||
All rights reserved. This program is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU Affero General Public License as | ||
published by the Free Software Foundation, either version 3 of the | ||
License, or (at your option) any later version. | ||
|
||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU Affero General Public License for more details. | ||
|
||
You should have received a copy of the GNU Affero General Public License | ||
along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
############################################################################## */ | ||
|
||
|
||
|
||
integer4 mkRandom1 := | ||
BEGINC++ | ||
rtlRandom() | ||
ENDC++; | ||
|
||
integer4 mkRandom2 := | ||
BEGINC++ | ||
#option pure | ||
rtlRandom() | ||
ENDC++; | ||
|
||
integer4 mkRandom3 := | ||
BEGINC++ | ||
#option action | ||
rtlRandom() | ||
ENDC++; | ||
|
||
output(mkRandom1 * mkRandom1); | ||
output(mkRandom2 * mkRandom2); | ||
output(mkRandom3 * mkRandom3); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/*############################################################################## | ||
|
||
Copyright (C) 2011 HPCC Systems. | ||
|
||
All rights reserved. This program is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU Affero General Public License as | ||
published by the Free Software Foundation, either version 3 of the | ||
License, or (at your option) any later version. | ||
|
||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU Affero General Public License for more details. | ||
|
||
You should have received a copy of the GNU Affero General Public License | ||
along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
############################################################################## */ | ||
|
||
|
||
|
||
integer4 add1(integer4 x, integer4 y) := | ||
BEGINC++ | ||
#option library 'MySpecialLibrary' | ||
return x + y; | ||
ENDC++; | ||
|
||
output(add1(10,20) * add1(10,20)); |
Oops, something went wrong.