Skip to content

Comments

Fix copyright in MSFT VersionInfo#5704

Closed
richsalz wants to merge 4 commits intoopenssl:masterfrom
richsalz:fix-mkrc
Closed

Fix copyright in MSFT VersionInfo#5704
richsalz wants to merge 4 commits intoopenssl:masterfrom
richsalz:fix-mkrc

Conversation

@richsalz
Copy link
Contributor

Also add rc file to openssl app

Thanks to user RTT for pointing this out.

@richsalz richsalz added branch: master Applies to master branch approval: review pending This pull request needs review by a committer branch: 1.1.1 Applies to OpenSSL_1_1_1-stable branch (EOL) labels Mar 21, 2018
@richsalz richsalz self-assigned this Mar 21, 2018
levitte
levitte previously approved these changes Mar 21, 2018
@levitte levitte dismissed their stale review March 21, 2018 04:22

No, wait, there's something not quite right here

apps/build.info Outdated
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Appveyor shows us that this creates a "surprising" disturbance... this section in apps/progs.pl needs to be rewritten by inserting a grep in the middle, like this:

diff --git a/apps/progs.pl b/apps/progs.pl
index f832467b57..f16bc10fac 100644
--- a/apps/progs.pl
+++ b/apps/progs.pl
@@ -23,6 +23,7 @@ my $apps_openssl = shift @ARGV;
 # the lookups in %unified_info
 my @openssl_source =
     map { @{$unified_info{sources}->{$_}} }
+    grep { /\.o$/ }
         @{$unified_info{sources}->{$apps_openssl}};
 
 foreach my $filename (@openssl_source) {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done, and also updated copyright year generation. please reconfirm.

levitte
levitte previously approved these changes Mar 21, 2018
Copy link
Member

@levitte levitte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only as long as the CIs run fine

@levitte levitte removed the approval: review pending This pull request needs review by a committer label Mar 21, 2018
@richsalz
Copy link
Contributor Author

@levitte
Copy link
Member

levitte commented Mar 21, 2018

Try this patch:

diff --git a/Configure b/Configure
index 0934088d2d..ce33f488d6 100755
--- a/Configure
+++ b/Configure
@@ -2015,6 +2015,13 @@ EOF
                     $o = cleanfile($buildd, $o, $blddir);
                     $unified_info{sources}->{$ddest}->{$o} = 1;
                     $unified_info{sources}->{$o}->{$s} = 1;
+                } elsif ($s =~ /\.rc$/) {
+                    # We also recognise resource files
+                    my $o = $_;
+                    $o =~ s/\.rc$/.res/; # Resource configuration
+                    my $o = cleanfile($buildd, $o, $blddir);
+                    $unified_info{sources}->{$ddest}->{$o} = 1;
+                    $unified_info{sources}->{$o}->{$s} = 1;
                 } else {
                     $unified_info{sources}->{$ddest}->{$s} = 1;
                 }

@levitte
Copy link
Member

levitte commented Mar 21, 2018

What was wrong was that .rc files was only recognised in SHARED_SOURCE, not in SOURCE. The diff I just submitted fixes that

@levitte levitte dismissed their stale review March 21, 2018 14:27

Let's see the CIs work right first

@richsalz
Copy link
Contributor Author

pushed and watching the CI's now ...

Rich Salz added 3 commits March 21, 2018 11:14
Also add rc file to openssl app

Thanks to user RTT for pointing this out.
@richsalz
Copy link
Contributor Author

it builds and passes (and was confirmed by RTT), but I'll wait for an explicit reconfirm.

levitte pushed a commit that referenced this pull request Mar 22, 2018
Add it to apps as well as libraries.
Fix the copyright year generation.
Thanks to user RTT for pointing this out.

Reviewed-by: Richard Levitte <[email protected]>
(Merged from #5704)
@richsalz
Copy link
Contributor Author

Not backporting; fixed in master.

@richsalz richsalz closed this Mar 22, 2018
@richsalz richsalz deleted the fix-mkrc branch March 22, 2018 15:33
@bernd-edlinger
Copy link
Member

Apparently this broke the mingw build:

Setting up wine1.6-amd64 (1:1.6.2-0ubuntu4) ...
Processing triggers for libc-bin (2.19-0ubuntu6.13) ...
Processing triggers for initramfs-tools (0.103ubuntu4.9) ...
update-initramfs: Not updating initramfs.
W: --force-yes is deprecated, use one of the options starting with --allow instead.
make depend && make _tests
make[1]: Entering directory `/home/travis/build/openssl/openssl'
make[1]: Leaving directory `/home/travis/build/openssl/openssl'
make[1]: Entering directory `/home/travis/build/openssl/openssl'
i686-w64-mingw32-gcc   apps/openssl.res.o   -o apps/openssl.res
/usr/lib/gcc/i686-w64-mingw32/4.8/../../../../i686-w64-mingw32/lib/../lib/libmingw32.a(lib32_libmingw32_a-crt0_c.o): In function `main':
/build/buildd/mingw-w64-3.1.0/build/i686-w64-mingw32-i686-w64-mingw32-crt/../../mingw-w64-crt/crt/crt0_c.c:18: undefined reference to `WinMain@16'
collect2: error: ld returned 1 exit status
make[1]: *** [apps/openssl.res] Error 1
make[1]: Leaving directory `/home/travis/build/openssl/openssl'
make: *** [tests] Error 2
+//// MAKE TEST FAILED

@bernd-edlinger
Copy link
Member

Regarding generation of source files with copyright year from current time:
I hope this apps/progs.pl is not run automatically.

@richsalz
Copy link
Contributor Author

Why do you hope it's not run automatically?
Looking at apps/build.info it looks like it's run whenever config is run (configdata.pm is new)

@richsalz
Copy link
Contributor Author

I wonder why MingW broke with this, but the other rc files didn't cause an error. Do you have a complete build log you can send me?

@bernd-edlinger
Copy link
Member

Why do you hope it's not run automatically?

It appears to me as if you have a book where every time you open
the book the copyright notice changes to the current year.

I am not a lawyer but to me that looks like it makes the whole copy-right
notice void.

@richsalz
Copy link
Contributor Author

What are the odds that a whole year goes by when progs.pl doesn't change, or no new apps source file is added? Pretty small I'd say.

@bernd-edlinger
Copy link
Member

@bernd-edlinger
Copy link
Member

Yes, as I said I am not a lawyer...
It is just the first time I see an automatically adjusting copy-right.

@richsalz
Copy link
Contributor Author

@dot-asm, @levitte any thoughts on the build-break Travis logs?
Why only apps/openssl.res ? I could just remove the file?

@levitte
Copy link
Member

levitte commented Mar 22, 2018

Oh, interesting thing is that the resource file wasn't ever included when linking the .dlls on MinGW or Cygwin... Looking at it, it looks like a very simple fix...

@richsalz
Copy link
Contributor Author

Like just remove cygwin and mingw from the patterns? I'll do a PR for that, if you're not already on it. :)

@levitte
Copy link
Member

levitte commented Mar 22, 2018

No, the other way around, make sure that the support in Configurations/unix-Makefile.tmpl is done right.

@levitte
Copy link
Member

levitte commented Mar 22, 2018

See #5730

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

branch: master Applies to master branch branch: 1.1.1 Applies to OpenSSL_1_1_1-stable branch (EOL)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants