Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Many times lib file is not produced #77

Closed
davidsanda opened this issue Jun 13, 2018 · 20 comments
Closed

Many times lib file is not produced #77

davidsanda opened this issue Jun 13, 2018 · 20 comments
Labels
bug ⛶ user-build End user projects using IDE, MSBuild, CMake, ... and related
Milestone

Comments

@davidsanda
Copy link

davidsanda commented Jun 13, 2018

With direct cmake config, dllexport sometimes fails to produce the lib. Here is the the minimal testcase.
Just run cmake [path to source] and appli dllexport. No lib files gets produced, because the trigger to process the dll does not work.

Also, if you click apply, when the project file is already modified, it crashes on something proj file related.
minimal.zip

@3F 3F added the bug label Jun 16, 2018
@3F
Copy link
Owner

3F commented Jun 16, 2018

Thanks for the report and especially for the minimal testcase!
I will look into later.

Also, if you click apply, when the project file is already modified, it crashes on something proj file related.

I checked one below. Is this same for you or it unhandled exception at all ?

System.ArgumentException: The node is not parented by this object so it cannot be removed from it.
   at Microsoft.Build.Shared.ErrorUtilities.ThrowArgument(Exception innerException, String resourceName, Object[] args)
   at Microsoft.Build.Construction.ProjectElementContainer.RemoveChild(ProjectElement child)
   at net.r_eg.MvsSln.Core.XProject.RemoveImport(ImportElement element) in D:\prg\projects\MvsSln\MvsSln\MvsSln\Core\XProject.cs:line 199
   at net.r_eg.DllExport.Wizard.Project.RemoveDllExportLib() in D:\prg\projects\DllExport\DllExport\Wizard\Project.cs:line 528
   at net.r_eg.DllExport.Wizard.Project.ActionConfigure() in D:\prg\projects\DllExport\DllExport\Wizard\Project.cs:line 277
   at net.r_eg.DllExport.Wizard.Project.Configure(ActionType type) in D:\prg\projects\DllExport\DllExport\Wizard\Project.cs:line 217
   at net.r_eg.DllExport.Wizard.UI.ConfiguratorForm.btnApply_Click(Object sender, EventArgs e) in D:\prg\projects\DllExport\DllExport\Wizard\UI\ConfiguratorForm.cs:line 200

@3F 3F added the ⛶ user-build End user projects using IDE, MSBuild, CMake, ... and related label Jun 16, 2018
@davidsanda
Copy link
Author

davidsanda commented Jun 16, 2018 via email

@davidsanda
Copy link
Author

davidsanda commented Jul 5, 2018 via email

@3F
Copy link
Owner

3F commented Jul 5, 2018 via email

@davidsanda
Copy link
Author

davidsanda commented Jul 6, 2018 via email

@3F
Copy link
Owner

3F commented Jul 6, 2018

David,

Before me, you can try to isolate incorrect VA for clr.dll. Try also inspect manually via memory tool with disassembling for native instructions (non IL).

What about architecture? seems your host side x64, can you check for x86 (of course for both modules).

Check also .ctor body before calling your base type ~call instance {...}::.ctor(), and any defs that may affect on stack before calling.

Is this reproducible for any derived class? steps?

By the way, try Conari engine if you're using native/unmanaged code/librraies inside clr (host side).

3F added a commit to 3F/MvsSln that referenced this issue Jul 14, 2018
…moveImport is used for `Import` elements inside `ImportGroup`.

Related issue: 3F/DllExport#77

Also updated signature: `bool RemoveImport(ImportElement element, bool holdEmptyGroup = true)`
@3F
Copy link
Owner

3F commented Jul 14, 2018

@davidsanda, I've fixed problem in MvsSln which could cause an exception above: 'The node is not parented by this object'.

And also inspected the initial bug for this issue. Well, this is closely related to problem above (because it affects from grouping). However, it requires additional logic to avoid an incorrect ordering of the tags from project files.

I'll push the fixes soon after some checking.

You can also check first patch via our CI build. Use -server or -pkg-link key to select the new package.

@davidsanda
Copy link
Author

davidsanda commented Jul 14, 2018 via email

@3F
Copy link
Owner

3F commented Jul 14, 2018

Temporarily please use from ci.appveyor.com. For -pkg-link it should be like:

DllExport -pkg-link https://ci.appveyor.com/api/buildjobs/ng0kg9yhm0x85y90/artifacts/bin/Release/DllExport.1.6.0.nupkg -action Configure

I mean, I also added GitHub Releases for new artefacts, but seems we have some other problem:

The request was aborted: Could not create SSL/TLS secure channel.

Don't worry, I'll fix it too :)

@davidsanda
Copy link
Author

davidsanda commented Jul 15, 2018 via email

@3F
Copy link
Owner

3F commented Jul 15, 2018 via email

3F added a commit to 3F/GetNuTool that referenced this issue Jul 15, 2018
3F added a commit that referenced this issue Jul 15, 2018
```
Fixes possible problem 'The request was aborted: Could not create SSL/TLS secure channel.'

Related issue: #77 (comment)
```
@3F
Copy link
Owner

3F commented Jul 15, 2018

@davidsanda I fixed problem with SSL/TLS secure channel. Thus, you can also use packages from GitHub, e.g.:

DllExport -pkg-link https://github.com/3F/DllExport/releases/download/CI-build-83/DllExport.1.6.0.nupkg -action Configure

@davidsanda
Copy link
Author

davidsanda commented Jul 15, 2018 via email

@davidsanda
Copy link
Author

davidsanda commented Jul 15, 2018 via email

@3F
Copy link
Owner

3F commented Jul 15, 2018

The request was aborted: Could not create SSL/TLS secure channel.

Is this new version of DllExport.bat? from https://github.com/3F/DllExport/releases/download/CI-build-83/DllExport.bat

DllExport -version

v1.6.0.21418 [ 9c89fac ]

However, lib for linking with c++ is not generated, so that part of bug is not fixed yet.

yes, because this issue contains two related bugs, and I fixed only one of this :) Please wait, as I said:

I'll push the fixes soon after some checking.

@3F
Copy link
Owner

3F commented Jul 15, 2018

I nailed it in asm to some static call to reserved region of memory.

please for details in #79

@davidsanda
Copy link
Author

davidsanda commented Jul 15, 2018 via email

3F added a commit that referenced this issue Jul 15, 2018
…ement should be inside `ImportGroup` via updated MvsSln IXProject.
@3F
Copy link
Owner

3F commented Jul 15, 2018

@davidsanda, Please check the final fixes via efddbdb. I added new support of groups exactly for MvsSln.

See build-84 from GHR

@davidsanda
Copy link
Author

davidsanda commented Jul 15, 2018 via email

@3F
Copy link
Owner

3F commented Jul 16, 2018

It works:)

Good! This changes was planned for v1.6.1

About #79, I'm waiting additional details for how to reproduce if this bug still is related to our project.

@3F 3F closed this as completed Jul 16, 2018
3F added a commit to 3F/GetNuTool that referenced this issue Aug 5, 2018
* FIXED: Bug when the output path for packages may contain `:`
         e.g. like absolute path from %cd% ~ D:\path\...

* FIXED: Possible 'The request was aborted: Could not create SSL/TLS secure channel.'
         Related issue: 3F/DllExport#77 (comment)

* NEW: Implemented proxy support via `$(proxycfg)`. Issue #5
3F added a commit to 3F/MvsSln that referenced this issue Aug 5, 2018
* FIXED: Fixed bug 'The node is not parented by this object'
         When IXProject.RemoveImport is used for `Import` elements inside `ImportGroup`.
         Related issue: 3F/DllExport#77

* NEW: Added `IXProject.AddImport(IEnumerable<ImportElement> elements, ...`
       To add 'import' elements inside ImportGroup.

* CHANGED: IXProject changes:
    * +`IXProject.PId` an unique identifier for project (not instance).
    * +`IXProject.GetRelativePath(string path)` Makes relative path from used project.
    * +`IXProject.AddImport(ImportElement element);`
    * Compatible signature update: `bool RemoveImport(ImportElement element, bool holdEmptyGroup = false)`

* CHANGED: Additional .ctors for XProject:
    * +`XProject()`
    * +`XProject(string file)`
    * +`XProject(string file, IDictionary<string, string> properties)`
    * +`XProject(Project prj)`
3F added a commit that referenced this issue Aug 5, 2018
* FIXED: Fixed bug when some methods cannot be exported. Issue #59.
* FIXED: Bug 'The node is not parented by this object' when Configuring projects. Issue: #77.
* FIXED: Fixed GDI objects leak in Wizard.
* FIXED: `-msb` key cannot affect for GetNuTool section. Issue #74.
* FIXED: Bug when automatic restoring still uses default keys from manager after configuring with custom `-server`.
* FIXED: Problem with double quotes for `-packages` key.
* FIXED: Possible incorrect repetition of the relative path for `-packages` key.
* FIXED: Possible problem 'The request was aborted: Could not create SSL/TLS secure channel.'. Issue: #77.
* FIXED: Possible problem with path when `-msb` key contains round brackets,
         e.g.: `D:\C\Program Files (x86)\Microsoft Visual Studio\`...

* NEW: Implemented features for additional automation. Issue #76.
        New actions:
            * `-action Export`
            * `-action Recover`
            * `-action Unset`

        Documentation: https://github.com/3F/DllExport/wiki/DllExport-Manager#automation

* NEW: Added proxy support for manager.
        The common format: `[usr[:pwd]@]host[:port]`

        Documentation: https://github.com/3F/DllExport/wiki/DllExport-Manager#proxy

* NEW: Wizard. Added sorting an projects in main window by its installing status and by availability.
* NEW: Wizard. Added filter for list of projects in main wizard window.
* NEW: New 'Offline' versions from our packages. See GitHub Releases page.
* NEW: Added key to force update `Reference` without PublicKeyToken. Issue #65.
* NEW: Added `-force` key for manager to use aggressive behavior, e.g. like removing pkg when updating.
       Wiki: https://github.com/3F/DllExport/wiki/DllExport-Manager#receiving-new-package-version

* NEW: New action `-action Upgrade`.
       Aggregates an Update action with additions for upgrading.

            Today's an Upgrade action:
            ```
            DllExport -action Upgrade ...
            ```

            is equal to:
            ```
            DllExport -action Update -mgr-up -force ...
            ```

            Wiki: https://github.com/3F/DllExport/wiki/DllExport-Manager#updating

* CHANGED: Case sensitivity for the Action names.
* CHANGED: `-action Default` for nothing.
* CHANGED: UI layout fixes for -Info form (Thanks @Genteure, Issue #61).
* CHANGED: Allows absolute path for `-packages` key.
* CHANGED: `-sln-file` key now can affect to `-action Configure`
* CHANGED: hMSBuild tool now is also distributed inside root directory of the packages zip & nupkg.
           Use this for EXP0014 problem: "RunIlAsm. The library manager still cannot be found."
           Example: https://www.youtube.com/watch?v=zUejJ4vUPGw

* CHANGED: Updated GetNuTool v1.6.2
* CHANGED: Updated MvsSln v2.1.0
* OTHER: Some other fixes and changes with manager and wizard.
* NOTE: To upgrade configured version: `DllExport -action Upgrade ...`
* NOTE: Configuring projects: `DllExport -action Configure ...`
* NOTE: Screencasts:
            * Quick start: https://www.youtube.com/watch?v=sBWt-KdQtoc
            * Basic examples for C++ and C#: https://www.youtube.com/watch?v=9Hyg3_WE9Ks
            * Complex types and Strings: https://www.youtube.com/watch?v=QXMj9-8XJnY

* NOTE: Our actual wiki - https://github.com/3F/DllExport/wiki
        * Documentation for manager: https://github.com/3F/DllExport/wiki/DllExport-Manager
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug ⛶ user-build End user projects using IDE, MSBuild, CMake, ... and related
Projects
None yet
Development

No branches or pull requests

2 participants